Reuse loads generated for repeated function arguments

This commit is contained in:
Jeff Bolz 2024-05-31 11:46:03 -05:00 committed by arcady-lunarg
parent 0e311906b9
commit 6a8b2b2439
11 changed files with 9106 additions and 9441 deletions

View file

@ -735,13 +735,13 @@ gl_FragCoord origin is upper left
// Module Version 10000
// Generated by (magic number): 8000b
// Id's are bound by 520
// Id's are bound by 519
Capability Shader
Capability Float64
1: ExtInstImport "GLSL.std.450"
MemoryModel Logical GLSL450
EntryPoint Fragment 4 "PixelShaderFunction" 513 516
EntryPoint Fragment 4 "PixelShaderFunction" 512 515
ExecutionMode 4 OriginUpperLeft
Source HLSL 500
Name 4 "PixelShaderFunction"
@ -923,17 +923,17 @@ gl_FragCoord origin is upper left
Name 471 "param"
Name 475 "param"
Name 480 "param"
Name 487 "param"
Name 491 "param"
Name 497 "param"
Name 500 "param"
Name 506 "param"
Name 511 "input"
Name 513 "input"
Name 516 "@entryPointOutput"
Name 517 "param"
Decorate 513(input) Location 0
Decorate 516(@entryPointOutput) Location 0
Name 486 "param"
Name 490 "param"
Name 496 "param"
Name 499 "param"
Name 505 "param"
Name 510 "input"
Name 512 "input"
Name 515 "@entryPointOutput"
Name 516 "param"
Decorate 512(input) Location 0
Decorate 515(@entryPointOutput) Location 0
2: TypeVoid
3: TypeFunction 2
6: TypeFloat 64
@ -984,23 +984,23 @@ gl_FragCoord origin is upper left
374: 22(int) Constant 1
394: 29(float) Constant 1065353216
414:6(float64_t) Constant 0 1072693248
484: TypeVector 22(int) 2
494: TypeVector 22(int) 4
503: TypeVector 8(bool) 3
512: TypePointer Input 149(fvec4)
513(input): 512(ptr) Variable Input
515: TypePointer Output 149(fvec4)
516(@entryPointOutput): 515(ptr) Variable Output
483: TypeVector 22(int) 2
493: TypeVector 22(int) 4
502: TypeVector 8(bool) 3
511: TypePointer Input 149(fvec4)
512(input): 511(ptr) Variable Input
514: TypePointer Output 149(fvec4)
515(@entryPointOutput): 514(ptr) Variable Output
4(PixelShaderFunction): 2 Function None 3
5: Label
511(input): 150(ptr) Variable Function
517(param): 150(ptr) Variable Function
514: 149(fvec4) Load 513(input)
Store 511(input) 514
518: 149(fvec4) Load 511(input)
Store 517(param) 518
519: 149(fvec4) FunctionCall 153(@PixelShaderFunction(vf4;) 517(param)
Store 516(@entryPointOutput) 519
510(input): 150(ptr) Variable Function
516(param): 150(ptr) Variable Function
513: 149(fvec4) Load 512(input)
Store 510(input) 513
517: 149(fvec4) Load 510(input)
Store 516(param) 517
518: 149(fvec4) FunctionCall 153(@PixelShaderFunction(vf4;) 516(param)
Store 515(@entryPointOutput) 518
Return
FunctionEnd
13(foo1(d1;b1;): 2 Function None 10
@ -1278,11 +1278,11 @@ gl_FragCoord origin is upper left
471(param): 16(ptr) Variable Function
475(param): 7(ptr) Variable Function
480(param): 126(ptr) Variable Function
487(param): 135(ptr) Variable Function
491(param): 105(ptr) Variable Function
497(param): 23(ptr) Variable Function
500(param): 9(ptr) Variable Function
506(param): 9(ptr) Variable Function
486(param): 135(ptr) Variable Function
490(param): 105(ptr) Variable Function
496(param): 23(ptr) Variable Function
499(param): 9(ptr) Variable Function
505(param): 9(ptr) Variable Function
158:6(float64_t) Load 155(d)
Store 157(param) 158
160: 8(bool) Load 156(b)
@ -1598,28 +1598,27 @@ gl_FragCoord origin is upper left
Store 480(param) 479
481: 2 FunctionCall 129(foo12(vd3;) 480(param)
482: 22(int) Load 173(i)
483: 22(int) Load 173(i)
485: 484(ivec2) CompositeConstruct 482 483
486: 134(ivec2) Bitcast 485
Store 487(param) 486
488: 2 FunctionCall 138(foo16(vu2;) 487(param)
489: 29(float) Load 179(f)
490: 104(fvec3) CompositeConstruct 489 489 489
Store 491(param) 490
492: 2 FunctionCall 141(foo13(vf3;) 491(param)
493: 22(int) Load 173(i)
495: 494(ivec4) CompositeConstruct 493 493 493 493
496: 22(int) CompositeExtract 495 0
Store 497(param) 496
498: 2 FunctionCall 144(foo14(vi1;) 497(param)
499: 8(bool) Load 156(b)
Store 500(param) 499
501: 2 FunctionCall 147(foo15(vb1;) 500(param)
502: 8(bool) Load 156(b)
504: 503(bvec3) CompositeConstruct 502 502 502
505: 8(bool) CompositeExtract 504 0
Store 506(param) 505
507: 2 FunctionCall 147(foo15(vb1;) 506(param)
508: 149(fvec4) Load 152(input)
ReturnValue 508
484: 483(ivec2) CompositeConstruct 482 482
485: 134(ivec2) Bitcast 484
Store 486(param) 485
487: 2 FunctionCall 138(foo16(vu2;) 486(param)
488: 29(float) Load 179(f)
489: 104(fvec3) CompositeConstruct 488 488 488
Store 490(param) 489
491: 2 FunctionCall 141(foo13(vf3;) 490(param)
492: 22(int) Load 173(i)
494: 493(ivec4) CompositeConstruct 492 492 492 492
495: 22(int) CompositeExtract 494 0
Store 496(param) 495
497: 2 FunctionCall 144(foo14(vi1;) 496(param)
498: 8(bool) Load 156(b)
Store 499(param) 498
500: 2 FunctionCall 147(foo15(vb1;) 499(param)
501: 8(bool) Load 156(b)
503: 502(bvec3) CompositeConstruct 501 501 501
504: 8(bool) CompositeExtract 503 0
Store 505(param) 504
506: 2 FunctionCall 147(foo15(vb1;) 505(param)
507: 149(fvec4) Load 152(input)
ReturnValue 507
FunctionEnd