Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

spirv-opt: CombineAccessChains doesn't support identical pointer types #3707

Open
Vasniktel opened this issue Aug 15, 2020 · 2 comments
Open

Comments

@Vasniktel
Copy link
Collaborator

data.zip

               OpCapability Shader
          %1 = OpExtInstImport "GLSL.std.450"
               OpMemoryModel Logical GLSL450
               OpEntryPoint Fragment %4 "main" %9
               OpExecutionMode %4 OriginUpperLeft
               OpSource ESSL 320
          %2 = OpTypeVoid
          %3 = OpTypeFunction %2
          %6 = OpTypeInt 32 1
         %12 = OpTypeVector %6 2
         %14 = OpConstant %6 1
         %13 = OpConstantComposite %12 %14 %14
          %7 = OpTypePointer Private %6
          %8 = OpTypePointer Private %6
         %15 = OpTypePointer Private %12
          %9 = OpVariable %15 Private %13
          %4 = OpFunction %2 None %3
          %5 = OpLabel
         %10 = OpAccessChain %7 %9 %14
         %11 = OpAccessChain %8 %10
               OpReturn
               OpFunctionEnd

spirv-opt produces the following error

error: line 20: Expected Result Type and Operand type to be the same
%11 = OpCopyObject %_ptr_Private_int_0 %10

error: line 0: Validation failed after pass combine-access-chains

if executed with the following command spirv-opt <attached shader> -o out.spv --validate-after-all --combine-access-chains.

Can be reproduced on c20995e.

@Vasniktel Vasniktel changed the title spirv-opt: CombineAccessChains doesn't supportidentical pointer types spirv-opt: CombineAccessChains doesn't support identical pointer types Aug 15, 2020
@Vasniktel
Copy link
Collaborator Author

@s-perron @alan-baker ping.

@Vasniktel
Copy link
Collaborator Author

Persists on 69f07da.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants