diff --git a/src/front/wgsl/mod.rs b/src/front/wgsl/mod.rs index 87fdccc6d2..04f115fbe8 100644 --- a/src/front/wgsl/mod.rs +++ b/src/front/wgsl/mod.rs @@ -3353,25 +3353,26 @@ impl Parser { let _ = context.resolve_type(reference.handle)?; let ty = context.typifier.get(reference.handle, context.types); - let constant_inner = match ty.canonical_form(context.types) { - Some(crate::TypeInner::ValuePointer { + let (kind, width) = match *ty { + crate::TypeInner::ValuePointer { size: None, kind, width, - space: _, - }) => crate::ConstantInner::Scalar { - width, - value: match kind { - crate::ScalarKind::Sint => crate::ScalarValue::Sint(1), - crate::ScalarKind::Uint => crate::ScalarValue::Uint(1), - _ => { - return Err(Error::BadIncrDecrReferenceType(lhs_span)); - } - }, + .. + } => (kind, width), + crate::TypeInner::Pointer { base, .. } => match context.types[base].inner { + crate::TypeInner::Scalar { kind, width } => (kind, width), + _ => return Err(Error::BadIncrDecrReferenceType(lhs_span)), + }, + _ => return Err(Error::BadIncrDecrReferenceType(lhs_span)), + }; + let constant_inner = crate::ConstantInner::Scalar { + width, + value: match kind { + crate::ScalarKind::Sint => crate::ScalarValue::Sint(1), + crate::ScalarKind::Uint => crate::ScalarValue::Uint(1), + _ => return Err(Error::BadIncrDecrReferenceType(lhs_span)), }, - _ => { - return Err(Error::BadIncrDecrReferenceType(lhs_span)); - } }; let constant = context.constants.append( crate::Constant { diff --git a/tests/in/operators.wgsl b/tests/in/operators.wgsl index cfc5896595..332fb25dae 100644 --- a/tests/in/operators.wgsl +++ b/tests/in/operators.wgsl @@ -277,6 +277,10 @@ fn assignment() { a++; a--; + + var vec0: vec3 = vec3(); + vec0[1]++; + vec0[1]--; } @compute @workgroup_size(1) diff --git a/tests/out/glsl/operators.main.Compute.glsl b/tests/out/glsl/operators.main.Compute.glsl index a27e97939a..f6f15fc7b2 100644 --- a/tests/out/glsl/operators.main.Compute.glsl +++ b/tests/out/glsl/operators.main.Compute.glsl @@ -196,6 +196,7 @@ void comparison() { void assignment() { int a = 1; + ivec3 vec0_ = ivec3(0, 0, 0); int _e6 = a; a = (_e6 + 1); int _e9 = a; @@ -222,6 +223,10 @@ void assignment() { a = (_e36 + 1); int _e39 = a; a = (_e39 - 1); + int _e46 = vec0_.y; + vec0_.y = (_e46 + 1); + int _e51 = vec0_.y; + vec0_.y = (_e51 - 1); return; } diff --git a/tests/out/hlsl/operators.hlsl b/tests/out/hlsl/operators.hlsl index e6356d201f..9cd73942ed 100644 --- a/tests/out/hlsl/operators.hlsl +++ b/tests/out/hlsl/operators.hlsl @@ -224,6 +224,7 @@ void comparison() void assignment() { int a = 1; + int3 vec0_ = int3(0, 0, 0); int _expr6 = a; a = (_expr6 + 1); @@ -251,6 +252,10 @@ void assignment() a = (_expr36 + 1); int _expr39 = a; a = (_expr39 - 1); + int _expr46 = vec0_.y; + vec0_.y = (_expr46 + 1); + int _expr51 = vec0_.y; + vec0_.y = (_expr51 - 1); return; } diff --git a/tests/out/msl/operators.msl b/tests/out/msl/operators.msl index 8cc741a4ef..e9415d12bb 100644 --- a/tests/out/msl/operators.msl +++ b/tests/out/msl/operators.msl @@ -28,6 +28,7 @@ constant metal::float3 const_type_4_ = {0.0, 0.0, 0.0}; constant metal::float3x3 const_type_14_ = {const_type_4_, const_type_4_, const_type_4_}; constant metal::float4x3 const_type_15_ = {const_type_4_, const_type_4_, const_type_4_, const_type_4_}; constant metal::float3x4 const_type_16_ = {const_type, const_type, const_type}; +constant metal::int3 const_type_17_ = {0, 0, 0}; metal::float4 builtins( ) { @@ -225,6 +226,7 @@ void comparison( void assignment( ) { int a = 1; + metal::int3 vec0_ = const_type_17_; int _e6 = a; a = _e6 + 1; int _e9 = a; @@ -251,6 +253,10 @@ void assignment( a = _e36 + 1; int _e39 = a; a = _e39 - 1; + int _e46 = vec0_.y; + vec0_.y = _e46 + 1; + int _e51 = vec0_.y; + vec0_.y = _e51 - 1; return; } diff --git a/tests/out/spv/operators.spvasm b/tests/out/spv/operators.spvasm index 850295757c..e805de91c2 100644 --- a/tests/out/spv/operators.spvasm +++ b/tests/out/spv/operators.spvasm @@ -1,12 +1,12 @@ ; SPIR-V ; Version: 1.1 ; Generator: rspirv -; Bound: 502 +; Bound: 515 OpCapability Shader %1 = OpExtInstImport "GLSL.std.450" OpMemoryModel Logical GLSL450 -OpEntryPoint GLCompute %490 "main" -OpExecutionMode %490 LocalSize 1 1 1 +OpEntryPoint GLCompute %503 "main" +OpExecutionMode %503 LocalSize 1 1 1 OpMemberDecorate %30 0 Offset 0 OpMemberDecorate %30 1 Offset 16 OpDecorate %35 ArrayStride 32 @@ -49,508 +49,523 @@ OpDecorate %36 ArrayStride 4 %37 = OpTypeMatrix %29 3 %38 = OpTypeMatrix %29 4 %39 = OpTypeMatrix %26 3 -%40 = OpConstantComposite %26 %3 %3 %3 %3 -%41 = OpConstantComposite %26 %5 %5 %5 %5 -%42 = OpConstantComposite %26 %6 %6 %6 %6 -%43 = OpConstantComposite %27 %7 %7 %7 %7 -%44 = OpConstantComposite %34 %19 %19 -%45 = OpConstantComposite %31 %5 %5 -%46 = OpConstantComposite %32 %45 %45 -%47 = OpConstantComposite %26 %5 %5 %5 %5 -%48 = OpConstantComposite %30 %47 %11 -%49 = OpConstantComposite %35 %48 %48 %48 -%50 = OpConstantComposite %29 %5 %5 %5 -%51 = OpConstantComposite %37 %50 %50 %50 -%52 = OpConstantComposite %38 %50 %50 %50 %50 -%53 = OpConstantComposite %39 %47 %47 %47 -%56 = OpTypeFunction %26 -%98 = OpTypeFunction %29 %29 -%100 = OpTypeVector %10 3 -%107 = OpTypePointer Function %30 -%108 = OpConstantNull %30 -%111 = OpTypeFunction %4 -%128 = OpTypePointer Function %26 -%129 = OpTypePointer Function %4 -%134 = OpTypeFunction %2 -%137 = OpTypeVector %10 2 -%153 = OpTypeVector %8 2 -%164 = OpTypeVector %20 3 -%459 = OpTypePointer Function %8 -%55 = OpFunction %26 None %56 -%54 = OpLabel -OpBranch %57 -%57 = OpLabel -%58 = OpSelect %8 %9 %7 %11 -%60 = OpCompositeConstruct %28 %9 %9 %9 %9 -%59 = OpSelect %26 %60 %40 %41 -%61 = OpCompositeConstruct %28 %12 %12 %12 %12 -%62 = OpSelect %26 %61 %41 %40 -%63 = OpExtInst %26 %1 FMix %41 %40 %42 -%65 = OpCompositeConstruct %26 %13 %13 %13 %13 -%64 = OpExtInst %26 %1 FMix %41 %40 %65 -%66 = OpCompositeExtract %8 %43 0 -%67 = OpBitcast %4 %66 -%68 = OpBitcast %26 %43 -%69 = OpConvertFToS %27 %41 -%70 = OpCompositeConstruct %27 %58 %58 %58 %58 -%71 = OpIAdd %27 %70 %69 -%72 = OpConvertSToF %26 %71 -%73 = OpFAdd %26 %72 %59 -%74 = OpFAdd %26 %73 %63 -%75 = OpFAdd %26 %74 %64 -%76 = OpCompositeConstruct %26 %67 %67 %67 %67 -%77 = OpFAdd %26 %75 %76 -%78 = OpFAdd %26 %77 %68 -OpReturnValue %78 +%40 = OpTypeVector %8 3 +%41 = OpConstantComposite %26 %3 %3 %3 %3 +%42 = OpConstantComposite %26 %5 %5 %5 %5 +%43 = OpConstantComposite %26 %6 %6 %6 %6 +%44 = OpConstantComposite %27 %7 %7 %7 %7 +%45 = OpConstantComposite %34 %19 %19 +%46 = OpConstantComposite %31 %5 %5 +%47 = OpConstantComposite %32 %46 %46 +%48 = OpConstantComposite %26 %5 %5 %5 %5 +%49 = OpConstantComposite %30 %48 %11 +%50 = OpConstantComposite %35 %49 %49 %49 +%51 = OpConstantComposite %29 %5 %5 %5 +%52 = OpConstantComposite %37 %51 %51 %51 +%53 = OpConstantComposite %38 %51 %51 %51 %51 +%54 = OpConstantComposite %39 %48 %48 %48 +%55 = OpConstantComposite %40 %11 %11 %11 +%58 = OpTypeFunction %26 +%100 = OpTypeFunction %29 %29 +%102 = OpTypeVector %10 3 +%109 = OpTypePointer Function %30 +%110 = OpConstantNull %30 +%113 = OpTypeFunction %4 +%130 = OpTypePointer Function %26 +%131 = OpTypePointer Function %4 +%136 = OpTypeFunction %2 +%139 = OpTypeVector %10 2 +%155 = OpTypeVector %8 2 +%166 = OpTypeVector %20 3 +%461 = OpTypePointer Function %8 +%463 = OpTypePointer Function %40 +%493 = OpTypePointer Function %8 +%57 = OpFunction %26 None %58 +%56 = OpLabel +OpBranch %59 +%59 = OpLabel +%60 = OpSelect %8 %9 %7 %11 +%62 = OpCompositeConstruct %28 %9 %9 %9 %9 +%61 = OpSelect %26 %62 %41 %42 +%63 = OpCompositeConstruct %28 %12 %12 %12 %12 +%64 = OpSelect %26 %63 %42 %41 +%65 = OpExtInst %26 %1 FMix %42 %41 %43 +%67 = OpCompositeConstruct %26 %13 %13 %13 %13 +%66 = OpExtInst %26 %1 FMix %42 %41 %67 +%68 = OpCompositeExtract %8 %44 0 +%69 = OpBitcast %4 %68 +%70 = OpBitcast %26 %44 +%71 = OpConvertFToS %27 %42 +%72 = OpCompositeConstruct %27 %60 %60 %60 %60 +%73 = OpIAdd %27 %72 %71 +%74 = OpConvertSToF %26 %73 +%75 = OpFAdd %26 %74 %61 +%76 = OpFAdd %26 %75 %65 +%77 = OpFAdd %26 %76 %66 +%78 = OpCompositeConstruct %26 %69 %69 %69 %69 +%79 = OpFAdd %26 %77 %78 +%80 = OpFAdd %26 %79 %70 +OpReturnValue %80 OpFunctionEnd -%80 = OpFunction %26 None %56 -%79 = OpLabel -OpBranch %81 +%82 = OpFunction %26 None %58 %81 = OpLabel -%82 = OpCompositeConstruct %31 %14 %14 -%83 = OpCompositeConstruct %31 %3 %3 -%84 = OpFAdd %31 %83 %82 -%85 = OpCompositeConstruct %31 %15 %15 -%86 = OpFSub %31 %84 %85 -%87 = OpCompositeConstruct %31 %16 %16 -%88 = OpFDiv %31 %86 %87 -%89 = OpCompositeConstruct %27 %17 %17 %17 %17 -%90 = OpCompositeConstruct %27 %18 %18 %18 %18 -%91 = OpSRem %27 %89 %90 -%92 = OpVectorShuffle %26 %88 %88 0 1 0 1 -%93 = OpConvertSToF %26 %91 -%94 = OpFAdd %26 %92 %93 -OpReturnValue %94 +OpBranch %83 +%83 = OpLabel +%84 = OpCompositeConstruct %31 %14 %14 +%85 = OpCompositeConstruct %31 %3 %3 +%86 = OpFAdd %31 %85 %84 +%87 = OpCompositeConstruct %31 %15 %15 +%88 = OpFSub %31 %86 %87 +%89 = OpCompositeConstruct %31 %16 %16 +%90 = OpFDiv %31 %88 %89 +%91 = OpCompositeConstruct %27 %17 %17 %17 %17 +%92 = OpCompositeConstruct %27 %18 %18 %18 %18 +%93 = OpSRem %27 %91 %92 +%94 = OpVectorShuffle %26 %90 %90 0 1 0 1 +%95 = OpConvertSToF %26 %93 +%96 = OpFAdd %26 %94 %95 +OpReturnValue %96 OpFunctionEnd -%97 = OpFunction %29 None %98 -%96 = OpFunctionParameter %29 -%95 = OpLabel -OpBranch %99 -%99 = OpLabel -%101 = OpCompositeConstruct %29 %5 %5 %5 -%102 = OpFUnordNotEqual %100 %96 %101 +%99 = OpFunction %29 None %100 +%98 = OpFunctionParameter %29 +%97 = OpLabel +OpBranch %101 +%101 = OpLabel %103 = OpCompositeConstruct %29 %5 %5 %5 -%104 = OpCompositeConstruct %29 %3 %3 %3 -%105 = OpSelect %29 %102 %104 %103 -OpReturnValue %105 +%104 = OpFUnordNotEqual %102 %98 %103 +%105 = OpCompositeConstruct %29 %5 %5 %5 +%106 = OpCompositeConstruct %29 %3 %3 %3 +%107 = OpSelect %29 %104 %106 %105 +OpReturnValue %107 OpFunctionEnd -%110 = OpFunction %4 None %111 -%109 = OpLabel -%106 = OpVariable %107 Function %108 -OpBranch %112 -%112 = OpLabel -%113 = OpCompositeConstruct %26 %3 %3 %3 %3 -%114 = OpCompositeConstruct %30 %113 %7 -OpStore %106 %114 -%115 = OpCompositeConstruct %31 %3 %5 -%116 = OpCompositeConstruct %31 %5 %3 -%117 = OpCompositeConstruct %32 %115 %116 -%118 = OpCompositeConstruct %26 %3 %5 %5 %5 -%119 = OpCompositeConstruct %26 %5 %3 %5 %5 -%120 = OpCompositeConstruct %26 %5 %5 %3 %5 -%121 = OpCompositeConstruct %26 %5 %5 %5 %3 -%122 = OpCompositeConstruct %33 %118 %119 %120 %121 -%123 = OpCompositeConstruct %34 %19 %19 -%124 = OpCompositeConstruct %31 %5 %5 -%125 = OpCompositeConstruct %31 %5 %5 -%126 = OpCompositeConstruct %32 %124 %125 -%127 = OpCompositeConstruct %36 %11 %7 %18 %21 -%130 = OpAccessChain %129 %106 %19 %19 -%131 = OpLoad %4 %130 -OpReturnValue %131 +%112 = OpFunction %4 None %113 +%111 = OpLabel +%108 = OpVariable %109 Function %110 +OpBranch %114 +%114 = OpLabel +%115 = OpCompositeConstruct %26 %3 %3 %3 %3 +%116 = OpCompositeConstruct %30 %115 %7 +OpStore %108 %116 +%117 = OpCompositeConstruct %31 %3 %5 +%118 = OpCompositeConstruct %31 %5 %3 +%119 = OpCompositeConstruct %32 %117 %118 +%120 = OpCompositeConstruct %26 %3 %5 %5 %5 +%121 = OpCompositeConstruct %26 %5 %3 %5 %5 +%122 = OpCompositeConstruct %26 %5 %5 %3 %5 +%123 = OpCompositeConstruct %26 %5 %5 %5 %3 +%124 = OpCompositeConstruct %33 %120 %121 %122 %123 +%125 = OpCompositeConstruct %34 %19 %19 +%126 = OpCompositeConstruct %31 %5 %5 +%127 = OpCompositeConstruct %31 %5 %5 +%128 = OpCompositeConstruct %32 %126 %127 +%129 = OpCompositeConstruct %36 %11 %7 %18 %21 +%132 = OpAccessChain %131 %108 %19 %19 +%133 = OpLoad %4 %132 +OpReturnValue %133 OpFunctionEnd -%133 = OpFunction %2 None %134 -%132 = OpLabel -OpBranch %135 -%135 = OpLabel -%136 = OpLogicalNot %10 %9 -%138 = OpCompositeConstruct %137 %9 %9 -%139 = OpLogicalNot %137 %138 -%140 = OpLogicalOr %10 %9 %12 -%141 = OpLogicalAnd %10 %9 %12 +%135 = OpFunction %2 None %136 +%134 = OpLabel +OpBranch %137 +%137 = OpLabel +%138 = OpLogicalNot %10 %9 +%140 = OpCompositeConstruct %139 %9 %9 +%141 = OpLogicalNot %139 %140 %142 = OpLogicalOr %10 %9 %12 -%143 = OpCompositeConstruct %100 %9 %9 %9 -%144 = OpCompositeConstruct %100 %12 %12 %12 -%145 = OpLogicalOr %100 %143 %144 -%146 = OpLogicalAnd %10 %9 %12 -%147 = OpCompositeConstruct %28 %9 %9 %9 %9 -%148 = OpCompositeConstruct %28 %12 %12 %12 %12 -%149 = OpLogicalAnd %28 %147 %148 +%143 = OpLogicalAnd %10 %9 %12 +%144 = OpLogicalOr %10 %9 %12 +%145 = OpCompositeConstruct %102 %9 %9 %9 +%146 = OpCompositeConstruct %102 %12 %12 %12 +%147 = OpLogicalOr %102 %145 %146 +%148 = OpLogicalAnd %10 %9 %12 +%149 = OpCompositeConstruct %28 %9 %9 %9 %9 +%150 = OpCompositeConstruct %28 %12 %12 %12 %12 +%151 = OpLogicalAnd %28 %149 %150 OpReturn OpFunctionEnd -%151 = OpFunction %2 None %134 -%150 = OpLabel -OpBranch %152 +%153 = OpFunction %2 None %136 %152 = OpLabel -%154 = OpCompositeConstruct %153 %7 %7 -%155 = OpSNegate %153 %154 -%156 = OpCompositeConstruct %31 %3 %3 -%157 = OpFNegate %31 %156 -%158 = OpIAdd %8 %18 %7 -%159 = OpIAdd %20 %24 %25 -%160 = OpFAdd %4 %14 %3 -%161 = OpCompositeConstruct %153 %18 %18 -%162 = OpCompositeConstruct %153 %7 %7 -%163 = OpIAdd %153 %161 %162 -%165 = OpCompositeConstruct %164 %24 %24 %24 -%166 = OpCompositeConstruct %164 %25 %25 %25 -%167 = OpIAdd %164 %165 %166 -%168 = OpCompositeConstruct %26 %14 %14 %14 %14 -%169 = OpCompositeConstruct %26 %3 %3 %3 %3 -%170 = OpFAdd %26 %168 %169 -%171 = OpISub %8 %18 %7 -%172 = OpISub %20 %24 %25 -%173 = OpFSub %4 %14 %3 -%174 = OpCompositeConstruct %153 %18 %18 -%175 = OpCompositeConstruct %153 %7 %7 -%176 = OpISub %153 %174 %175 -%177 = OpCompositeConstruct %164 %24 %24 %24 -%178 = OpCompositeConstruct %164 %25 %25 %25 -%179 = OpISub %164 %177 %178 -%180 = OpCompositeConstruct %26 %14 %14 %14 %14 -%181 = OpCompositeConstruct %26 %3 %3 %3 %3 -%182 = OpFSub %26 %180 %181 -%183 = OpIMul %8 %18 %7 -%184 = OpIMul %20 %24 %25 -%185 = OpFMul %4 %14 %3 -%186 = OpCompositeConstruct %153 %18 %18 -%187 = OpCompositeConstruct %153 %7 %7 -%188 = OpIMul %153 %186 %187 -%189 = OpCompositeConstruct %164 %24 %24 %24 -%190 = OpCompositeConstruct %164 %25 %25 %25 -%191 = OpIMul %164 %189 %190 -%192 = OpCompositeConstruct %26 %14 %14 %14 %14 -%193 = OpCompositeConstruct %26 %3 %3 %3 %3 -%194 = OpFMul %26 %192 %193 -%195 = OpSDiv %8 %18 %7 -%196 = OpUDiv %20 %24 %25 -%197 = OpFDiv %4 %14 %3 -%198 = OpCompositeConstruct %153 %18 %18 -%199 = OpCompositeConstruct %153 %7 %7 -%200 = OpSDiv %153 %198 %199 -%201 = OpCompositeConstruct %164 %24 %24 %24 -%202 = OpCompositeConstruct %164 %25 %25 %25 -%203 = OpUDiv %164 %201 %202 -%204 = OpCompositeConstruct %26 %14 %14 %14 %14 -%205 = OpCompositeConstruct %26 %3 %3 %3 %3 -%206 = OpFDiv %26 %204 %205 -%207 = OpSRem %8 %18 %7 -%208 = OpUMod %20 %24 %25 -%209 = OpFRem %4 %14 %3 -%210 = OpCompositeConstruct %153 %18 %18 -%211 = OpCompositeConstruct %153 %7 %7 -%212 = OpSRem %153 %210 %211 -%213 = OpCompositeConstruct %164 %24 %24 %24 -%214 = OpCompositeConstruct %164 %25 %25 %25 -%215 = OpUMod %164 %213 %214 -%216 = OpCompositeConstruct %26 %14 %14 %14 %14 -%217 = OpCompositeConstruct %26 %3 %3 %3 %3 -%218 = OpFRem %26 %216 %217 -%219 = OpCompositeConstruct %153 %18 %18 -%220 = OpCompositeConstruct %153 %7 %7 -%221 = OpIAdd %153 %219 %220 -%222 = OpCompositeConstruct %153 %7 %7 -%223 = OpCompositeConstruct %153 %18 %18 -%224 = OpIAdd %153 %223 %222 -%225 = OpCompositeConstruct %34 %24 %24 -%226 = OpCompositeConstruct %34 %25 %25 -%227 = OpIAdd %34 %225 %226 +OpBranch %154 +%154 = OpLabel +%156 = OpCompositeConstruct %155 %7 %7 +%157 = OpSNegate %155 %156 +%158 = OpCompositeConstruct %31 %3 %3 +%159 = OpFNegate %31 %158 +%160 = OpIAdd %8 %18 %7 +%161 = OpIAdd %20 %24 %25 +%162 = OpFAdd %4 %14 %3 +%163 = OpCompositeConstruct %155 %18 %18 +%164 = OpCompositeConstruct %155 %7 %7 +%165 = OpIAdd %155 %163 %164 +%167 = OpCompositeConstruct %166 %24 %24 %24 +%168 = OpCompositeConstruct %166 %25 %25 %25 +%169 = OpIAdd %166 %167 %168 +%170 = OpCompositeConstruct %26 %14 %14 %14 %14 +%171 = OpCompositeConstruct %26 %3 %3 %3 %3 +%172 = OpFAdd %26 %170 %171 +%173 = OpISub %8 %18 %7 +%174 = OpISub %20 %24 %25 +%175 = OpFSub %4 %14 %3 +%176 = OpCompositeConstruct %155 %18 %18 +%177 = OpCompositeConstruct %155 %7 %7 +%178 = OpISub %155 %176 %177 +%179 = OpCompositeConstruct %166 %24 %24 %24 +%180 = OpCompositeConstruct %166 %25 %25 %25 +%181 = OpISub %166 %179 %180 +%182 = OpCompositeConstruct %26 %14 %14 %14 %14 +%183 = OpCompositeConstruct %26 %3 %3 %3 %3 +%184 = OpFSub %26 %182 %183 +%185 = OpIMul %8 %18 %7 +%186 = OpIMul %20 %24 %25 +%187 = OpFMul %4 %14 %3 +%188 = OpCompositeConstruct %155 %18 %18 +%189 = OpCompositeConstruct %155 %7 %7 +%190 = OpIMul %155 %188 %189 +%191 = OpCompositeConstruct %166 %24 %24 %24 +%192 = OpCompositeConstruct %166 %25 %25 %25 +%193 = OpIMul %166 %191 %192 +%194 = OpCompositeConstruct %26 %14 %14 %14 %14 +%195 = OpCompositeConstruct %26 %3 %3 %3 %3 +%196 = OpFMul %26 %194 %195 +%197 = OpSDiv %8 %18 %7 +%198 = OpUDiv %20 %24 %25 +%199 = OpFDiv %4 %14 %3 +%200 = OpCompositeConstruct %155 %18 %18 +%201 = OpCompositeConstruct %155 %7 %7 +%202 = OpSDiv %155 %200 %201 +%203 = OpCompositeConstruct %166 %24 %24 %24 +%204 = OpCompositeConstruct %166 %25 %25 %25 +%205 = OpUDiv %166 %203 %204 +%206 = OpCompositeConstruct %26 %14 %14 %14 %14 +%207 = OpCompositeConstruct %26 %3 %3 %3 %3 +%208 = OpFDiv %26 %206 %207 +%209 = OpSRem %8 %18 %7 +%210 = OpUMod %20 %24 %25 +%211 = OpFRem %4 %14 %3 +%212 = OpCompositeConstruct %155 %18 %18 +%213 = OpCompositeConstruct %155 %7 %7 +%214 = OpSRem %155 %212 %213 +%215 = OpCompositeConstruct %166 %24 %24 %24 +%216 = OpCompositeConstruct %166 %25 %25 %25 +%217 = OpUMod %166 %215 %216 +%218 = OpCompositeConstruct %26 %14 %14 %14 %14 +%219 = OpCompositeConstruct %26 %3 %3 %3 %3 +%220 = OpFRem %26 %218 %219 +%221 = OpCompositeConstruct %155 %18 %18 +%222 = OpCompositeConstruct %155 %7 %7 +%223 = OpIAdd %155 %221 %222 +%224 = OpCompositeConstruct %155 %7 %7 +%225 = OpCompositeConstruct %155 %18 %18 +%226 = OpIAdd %155 %225 %224 +%227 = OpCompositeConstruct %34 %24 %24 %228 = OpCompositeConstruct %34 %25 %25 -%229 = OpCompositeConstruct %34 %24 %24 -%230 = OpIAdd %34 %229 %228 -%231 = OpCompositeConstruct %31 %14 %14 -%232 = OpCompositeConstruct %31 %3 %3 -%233 = OpFAdd %31 %231 %232 +%229 = OpIAdd %34 %227 %228 +%230 = OpCompositeConstruct %34 %25 %25 +%231 = OpCompositeConstruct %34 %24 %24 +%232 = OpIAdd %34 %231 %230 +%233 = OpCompositeConstruct %31 %14 %14 %234 = OpCompositeConstruct %31 %3 %3 -%235 = OpCompositeConstruct %31 %14 %14 -%236 = OpFAdd %31 %235 %234 -%237 = OpCompositeConstruct %153 %18 %18 -%238 = OpCompositeConstruct %153 %7 %7 -%239 = OpISub %153 %237 %238 -%240 = OpCompositeConstruct %153 %7 %7 -%241 = OpCompositeConstruct %153 %18 %18 -%242 = OpISub %153 %241 %240 -%243 = OpCompositeConstruct %34 %24 %24 -%244 = OpCompositeConstruct %34 %25 %25 -%245 = OpISub %34 %243 %244 +%235 = OpFAdd %31 %233 %234 +%236 = OpCompositeConstruct %31 %3 %3 +%237 = OpCompositeConstruct %31 %14 %14 +%238 = OpFAdd %31 %237 %236 +%239 = OpCompositeConstruct %155 %18 %18 +%240 = OpCompositeConstruct %155 %7 %7 +%241 = OpISub %155 %239 %240 +%242 = OpCompositeConstruct %155 %7 %7 +%243 = OpCompositeConstruct %155 %18 %18 +%244 = OpISub %155 %243 %242 +%245 = OpCompositeConstruct %34 %24 %24 %246 = OpCompositeConstruct %34 %25 %25 -%247 = OpCompositeConstruct %34 %24 %24 -%248 = OpISub %34 %247 %246 -%249 = OpCompositeConstruct %31 %14 %14 -%250 = OpCompositeConstruct %31 %3 %3 -%251 = OpFSub %31 %249 %250 +%247 = OpISub %34 %245 %246 +%248 = OpCompositeConstruct %34 %25 %25 +%249 = OpCompositeConstruct %34 %24 %24 +%250 = OpISub %34 %249 %248 +%251 = OpCompositeConstruct %31 %14 %14 %252 = OpCompositeConstruct %31 %3 %3 -%253 = OpCompositeConstruct %31 %14 %14 -%254 = OpFSub %31 %253 %252 -%255 = OpCompositeConstruct %153 %18 %18 -%257 = OpCompositeConstruct %153 %7 %7 -%256 = OpIMul %153 %255 %257 -%258 = OpCompositeConstruct %153 %7 %7 -%260 = OpCompositeConstruct %153 %18 %18 -%259 = OpIMul %153 %258 %260 -%261 = OpCompositeConstruct %34 %24 %24 -%263 = OpCompositeConstruct %34 %25 %25 -%262 = OpIMul %34 %261 %263 -%264 = OpCompositeConstruct %34 %25 %25 -%266 = OpCompositeConstruct %34 %24 %24 -%265 = OpIMul %34 %264 %266 -%267 = OpCompositeConstruct %31 %14 %14 -%268 = OpVectorTimesScalar %31 %267 %3 -%269 = OpCompositeConstruct %31 %3 %3 -%270 = OpVectorTimesScalar %31 %269 %14 -%271 = OpCompositeConstruct %153 %18 %18 -%272 = OpCompositeConstruct %153 %7 %7 -%273 = OpSDiv %153 %271 %272 -%274 = OpCompositeConstruct %153 %7 %7 -%275 = OpCompositeConstruct %153 %18 %18 -%276 = OpSDiv %153 %275 %274 -%277 = OpCompositeConstruct %34 %24 %24 -%278 = OpCompositeConstruct %34 %25 %25 -%279 = OpUDiv %34 %277 %278 +%253 = OpFSub %31 %251 %252 +%254 = OpCompositeConstruct %31 %3 %3 +%255 = OpCompositeConstruct %31 %14 %14 +%256 = OpFSub %31 %255 %254 +%257 = OpCompositeConstruct %155 %18 %18 +%259 = OpCompositeConstruct %155 %7 %7 +%258 = OpIMul %155 %257 %259 +%260 = OpCompositeConstruct %155 %7 %7 +%262 = OpCompositeConstruct %155 %18 %18 +%261 = OpIMul %155 %260 %262 +%263 = OpCompositeConstruct %34 %24 %24 +%265 = OpCompositeConstruct %34 %25 %25 +%264 = OpIMul %34 %263 %265 +%266 = OpCompositeConstruct %34 %25 %25 +%268 = OpCompositeConstruct %34 %24 %24 +%267 = OpIMul %34 %266 %268 +%269 = OpCompositeConstruct %31 %14 %14 +%270 = OpVectorTimesScalar %31 %269 %3 +%271 = OpCompositeConstruct %31 %3 %3 +%272 = OpVectorTimesScalar %31 %271 %14 +%273 = OpCompositeConstruct %155 %18 %18 +%274 = OpCompositeConstruct %155 %7 %7 +%275 = OpSDiv %155 %273 %274 +%276 = OpCompositeConstruct %155 %7 %7 +%277 = OpCompositeConstruct %155 %18 %18 +%278 = OpSDiv %155 %277 %276 +%279 = OpCompositeConstruct %34 %24 %24 %280 = OpCompositeConstruct %34 %25 %25 -%281 = OpCompositeConstruct %34 %24 %24 -%282 = OpUDiv %34 %281 %280 -%283 = OpCompositeConstruct %31 %14 %14 -%284 = OpCompositeConstruct %31 %3 %3 -%285 = OpFDiv %31 %283 %284 +%281 = OpUDiv %34 %279 %280 +%282 = OpCompositeConstruct %34 %25 %25 +%283 = OpCompositeConstruct %34 %24 %24 +%284 = OpUDiv %34 %283 %282 +%285 = OpCompositeConstruct %31 %14 %14 %286 = OpCompositeConstruct %31 %3 %3 -%287 = OpCompositeConstruct %31 %14 %14 -%288 = OpFDiv %31 %287 %286 -%289 = OpCompositeConstruct %153 %18 %18 -%290 = OpCompositeConstruct %153 %7 %7 -%291 = OpSRem %153 %289 %290 -%292 = OpCompositeConstruct %153 %7 %7 -%293 = OpCompositeConstruct %153 %18 %18 -%294 = OpSRem %153 %293 %292 -%295 = OpCompositeConstruct %34 %24 %24 -%296 = OpCompositeConstruct %34 %25 %25 -%297 = OpUMod %34 %295 %296 +%287 = OpFDiv %31 %285 %286 +%288 = OpCompositeConstruct %31 %3 %3 +%289 = OpCompositeConstruct %31 %14 %14 +%290 = OpFDiv %31 %289 %288 +%291 = OpCompositeConstruct %155 %18 %18 +%292 = OpCompositeConstruct %155 %7 %7 +%293 = OpSRem %155 %291 %292 +%294 = OpCompositeConstruct %155 %7 %7 +%295 = OpCompositeConstruct %155 %18 %18 +%296 = OpSRem %155 %295 %294 +%297 = OpCompositeConstruct %34 %24 %24 %298 = OpCompositeConstruct %34 %25 %25 -%299 = OpCompositeConstruct %34 %24 %24 -%300 = OpUMod %34 %299 %298 -%301 = OpCompositeConstruct %31 %14 %14 -%302 = OpCompositeConstruct %31 %3 %3 -%303 = OpFRem %31 %301 %302 +%299 = OpUMod %34 %297 %298 +%300 = OpCompositeConstruct %34 %25 %25 +%301 = OpCompositeConstruct %34 %24 %24 +%302 = OpUMod %34 %301 %300 +%303 = OpCompositeConstruct %31 %14 %14 %304 = OpCompositeConstruct %31 %3 %3 -%305 = OpCompositeConstruct %31 %14 %14 -%306 = OpFRem %31 %305 %304 -%308 = OpCompositeExtract %29 %51 0 -%309 = OpCompositeExtract %29 %51 0 -%310 = OpFAdd %29 %308 %309 -%311 = OpCompositeExtract %29 %51 1 -%312 = OpCompositeExtract %29 %51 1 -%313 = OpFAdd %29 %311 %312 -%314 = OpCompositeExtract %29 %51 2 -%315 = OpCompositeExtract %29 %51 2 -%316 = OpFAdd %29 %314 %315 -%307 = OpCompositeConstruct %37 %310 %313 %316 -%318 = OpCompositeExtract %29 %51 0 -%319 = OpCompositeExtract %29 %51 0 -%320 = OpFSub %29 %318 %319 -%321 = OpCompositeExtract %29 %51 1 -%322 = OpCompositeExtract %29 %51 1 -%323 = OpFSub %29 %321 %322 -%324 = OpCompositeExtract %29 %51 2 -%325 = OpCompositeExtract %29 %51 2 -%326 = OpFSub %29 %324 %325 -%317 = OpCompositeConstruct %37 %320 %323 %326 -%327 = OpMatrixTimesScalar %37 %51 %3 -%328 = OpMatrixTimesScalar %37 %51 %14 -%329 = OpCompositeConstruct %26 %3 %3 %3 %3 -%330 = OpMatrixTimesVector %29 %52 %329 -%331 = OpCompositeConstruct %29 %14 %14 %14 -%332 = OpVectorTimesMatrix %26 %331 %52 -%333 = OpMatrixTimesMatrix %37 %52 %53 +%305 = OpFRem %31 %303 %304 +%306 = OpCompositeConstruct %31 %3 %3 +%307 = OpCompositeConstruct %31 %14 %14 +%308 = OpFRem %31 %307 %306 +%310 = OpCompositeExtract %29 %52 0 +%311 = OpCompositeExtract %29 %52 0 +%312 = OpFAdd %29 %310 %311 +%313 = OpCompositeExtract %29 %52 1 +%314 = OpCompositeExtract %29 %52 1 +%315 = OpFAdd %29 %313 %314 +%316 = OpCompositeExtract %29 %52 2 +%317 = OpCompositeExtract %29 %52 2 +%318 = OpFAdd %29 %316 %317 +%309 = OpCompositeConstruct %37 %312 %315 %318 +%320 = OpCompositeExtract %29 %52 0 +%321 = OpCompositeExtract %29 %52 0 +%322 = OpFSub %29 %320 %321 +%323 = OpCompositeExtract %29 %52 1 +%324 = OpCompositeExtract %29 %52 1 +%325 = OpFSub %29 %323 %324 +%326 = OpCompositeExtract %29 %52 2 +%327 = OpCompositeExtract %29 %52 2 +%328 = OpFSub %29 %326 %327 +%319 = OpCompositeConstruct %37 %322 %325 %328 +%329 = OpMatrixTimesScalar %37 %52 %3 +%330 = OpMatrixTimesScalar %37 %52 %14 +%331 = OpCompositeConstruct %26 %3 %3 %3 %3 +%332 = OpMatrixTimesVector %29 %53 %331 +%333 = OpCompositeConstruct %29 %14 %14 %14 +%334 = OpVectorTimesMatrix %26 %333 %53 +%335 = OpMatrixTimesMatrix %37 %53 %54 OpReturn OpFunctionEnd -%335 = OpFunction %2 None %134 -%334 = OpLabel -OpBranch %336 +%337 = OpFunction %2 None %136 %336 = OpLabel -%337 = OpNot %8 %7 -%338 = OpNot %20 %25 -%339 = OpCompositeConstruct %153 %7 %7 -%340 = OpNot %153 %339 -%341 = OpCompositeConstruct %164 %25 %25 %25 -%342 = OpNot %164 %341 -%343 = OpBitwiseOr %8 %18 %7 -%344 = OpBitwiseOr %20 %24 %25 -%345 = OpCompositeConstruct %153 %18 %18 -%346 = OpCompositeConstruct %153 %7 %7 -%347 = OpBitwiseOr %153 %345 %346 -%348 = OpCompositeConstruct %164 %24 %24 %24 -%349 = OpCompositeConstruct %164 %25 %25 %25 -%350 = OpBitwiseOr %164 %348 %349 -%351 = OpBitwiseAnd %8 %18 %7 -%352 = OpBitwiseAnd %20 %24 %25 -%353 = OpCompositeConstruct %153 %18 %18 -%354 = OpCompositeConstruct %153 %7 %7 -%355 = OpBitwiseAnd %153 %353 %354 -%356 = OpCompositeConstruct %164 %24 %24 %24 -%357 = OpCompositeConstruct %164 %25 %25 %25 -%358 = OpBitwiseAnd %164 %356 %357 -%359 = OpBitwiseXor %8 %18 %7 -%360 = OpBitwiseXor %20 %24 %25 -%361 = OpCompositeConstruct %153 %18 %18 -%362 = OpCompositeConstruct %153 %7 %7 -%363 = OpBitwiseXor %153 %361 %362 -%364 = OpCompositeConstruct %164 %24 %24 %24 -%365 = OpCompositeConstruct %164 %25 %25 %25 -%366 = OpBitwiseXor %164 %364 %365 -%367 = OpShiftLeftLogical %8 %18 %25 -%368 = OpShiftLeftLogical %20 %24 %25 -%369 = OpCompositeConstruct %153 %18 %18 -%370 = OpCompositeConstruct %34 %25 %25 -%371 = OpShiftLeftLogical %153 %369 %370 -%372 = OpCompositeConstruct %164 %24 %24 %24 -%373 = OpCompositeConstruct %164 %25 %25 %25 -%374 = OpShiftLeftLogical %164 %372 %373 -%375 = OpShiftRightArithmetic %8 %18 %25 -%376 = OpShiftRightLogical %20 %24 %25 -%377 = OpCompositeConstruct %153 %18 %18 -%378 = OpCompositeConstruct %34 %25 %25 -%379 = OpShiftRightArithmetic %153 %377 %378 -%380 = OpCompositeConstruct %164 %24 %24 %24 -%381 = OpCompositeConstruct %164 %25 %25 %25 -%382 = OpShiftRightLogical %164 %380 %381 +OpBranch %338 +%338 = OpLabel +%339 = OpNot %8 %7 +%340 = OpNot %20 %25 +%341 = OpCompositeConstruct %155 %7 %7 +%342 = OpNot %155 %341 +%343 = OpCompositeConstruct %166 %25 %25 %25 +%344 = OpNot %166 %343 +%345 = OpBitwiseOr %8 %18 %7 +%346 = OpBitwiseOr %20 %24 %25 +%347 = OpCompositeConstruct %155 %18 %18 +%348 = OpCompositeConstruct %155 %7 %7 +%349 = OpBitwiseOr %155 %347 %348 +%350 = OpCompositeConstruct %166 %24 %24 %24 +%351 = OpCompositeConstruct %166 %25 %25 %25 +%352 = OpBitwiseOr %166 %350 %351 +%353 = OpBitwiseAnd %8 %18 %7 +%354 = OpBitwiseAnd %20 %24 %25 +%355 = OpCompositeConstruct %155 %18 %18 +%356 = OpCompositeConstruct %155 %7 %7 +%357 = OpBitwiseAnd %155 %355 %356 +%358 = OpCompositeConstruct %166 %24 %24 %24 +%359 = OpCompositeConstruct %166 %25 %25 %25 +%360 = OpBitwiseAnd %166 %358 %359 +%361 = OpBitwiseXor %8 %18 %7 +%362 = OpBitwiseXor %20 %24 %25 +%363 = OpCompositeConstruct %155 %18 %18 +%364 = OpCompositeConstruct %155 %7 %7 +%365 = OpBitwiseXor %155 %363 %364 +%366 = OpCompositeConstruct %166 %24 %24 %24 +%367 = OpCompositeConstruct %166 %25 %25 %25 +%368 = OpBitwiseXor %166 %366 %367 +%369 = OpShiftLeftLogical %8 %18 %25 +%370 = OpShiftLeftLogical %20 %24 %25 +%371 = OpCompositeConstruct %155 %18 %18 +%372 = OpCompositeConstruct %34 %25 %25 +%373 = OpShiftLeftLogical %155 %371 %372 +%374 = OpCompositeConstruct %166 %24 %24 %24 +%375 = OpCompositeConstruct %166 %25 %25 %25 +%376 = OpShiftLeftLogical %166 %374 %375 +%377 = OpShiftRightArithmetic %8 %18 %25 +%378 = OpShiftRightLogical %20 %24 %25 +%379 = OpCompositeConstruct %155 %18 %18 +%380 = OpCompositeConstruct %34 %25 %25 +%381 = OpShiftRightArithmetic %155 %379 %380 +%382 = OpCompositeConstruct %166 %24 %24 %24 +%383 = OpCompositeConstruct %166 %25 %25 %25 +%384 = OpShiftRightLogical %166 %382 %383 OpReturn OpFunctionEnd -%384 = OpFunction %2 None %134 -%383 = OpLabel -OpBranch %385 +%386 = OpFunction %2 None %136 %385 = OpLabel -%386 = OpIEqual %10 %18 %7 -%387 = OpIEqual %10 %24 %25 -%388 = OpFOrdEqual %10 %14 %3 -%389 = OpCompositeConstruct %153 %18 %18 -%390 = OpCompositeConstruct %153 %7 %7 -%391 = OpIEqual %137 %389 %390 -%392 = OpCompositeConstruct %164 %24 %24 %24 -%393 = OpCompositeConstruct %164 %25 %25 %25 -%394 = OpIEqual %100 %392 %393 -%395 = OpCompositeConstruct %26 %14 %14 %14 %14 -%396 = OpCompositeConstruct %26 %3 %3 %3 %3 -%397 = OpFOrdEqual %28 %395 %396 -%398 = OpINotEqual %10 %18 %7 -%399 = OpINotEqual %10 %24 %25 -%400 = OpFOrdNotEqual %10 %14 %3 -%401 = OpCompositeConstruct %153 %18 %18 -%402 = OpCompositeConstruct %153 %7 %7 -%403 = OpINotEqual %137 %401 %402 -%404 = OpCompositeConstruct %164 %24 %24 %24 -%405 = OpCompositeConstruct %164 %25 %25 %25 -%406 = OpINotEqual %100 %404 %405 -%407 = OpCompositeConstruct %26 %14 %14 %14 %14 -%408 = OpCompositeConstruct %26 %3 %3 %3 %3 -%409 = OpFOrdNotEqual %28 %407 %408 -%410 = OpSLessThan %10 %18 %7 -%411 = OpULessThan %10 %24 %25 -%412 = OpFOrdLessThan %10 %14 %3 -%413 = OpCompositeConstruct %153 %18 %18 -%414 = OpCompositeConstruct %153 %7 %7 -%415 = OpSLessThan %137 %413 %414 -%416 = OpCompositeConstruct %164 %24 %24 %24 -%417 = OpCompositeConstruct %164 %25 %25 %25 -%418 = OpULessThan %100 %416 %417 -%419 = OpCompositeConstruct %26 %14 %14 %14 %14 -%420 = OpCompositeConstruct %26 %3 %3 %3 %3 -%421 = OpFOrdLessThan %28 %419 %420 -%422 = OpSLessThanEqual %10 %18 %7 -%423 = OpULessThanEqual %10 %24 %25 -%424 = OpFOrdLessThanEqual %10 %14 %3 -%425 = OpCompositeConstruct %153 %18 %18 -%426 = OpCompositeConstruct %153 %7 %7 -%427 = OpSLessThanEqual %137 %425 %426 -%428 = OpCompositeConstruct %164 %24 %24 %24 -%429 = OpCompositeConstruct %164 %25 %25 %25 -%430 = OpULessThanEqual %100 %428 %429 -%431 = OpCompositeConstruct %26 %14 %14 %14 %14 -%432 = OpCompositeConstruct %26 %3 %3 %3 %3 -%433 = OpFOrdLessThanEqual %28 %431 %432 -%434 = OpSGreaterThan %10 %18 %7 -%435 = OpUGreaterThan %10 %24 %25 -%436 = OpFOrdGreaterThan %10 %14 %3 -%437 = OpCompositeConstruct %153 %18 %18 -%438 = OpCompositeConstruct %153 %7 %7 -%439 = OpSGreaterThan %137 %437 %438 -%440 = OpCompositeConstruct %164 %24 %24 %24 -%441 = OpCompositeConstruct %164 %25 %25 %25 -%442 = OpUGreaterThan %100 %440 %441 -%443 = OpCompositeConstruct %26 %14 %14 %14 %14 -%444 = OpCompositeConstruct %26 %3 %3 %3 %3 -%445 = OpFOrdGreaterThan %28 %443 %444 -%446 = OpSGreaterThanEqual %10 %18 %7 -%447 = OpUGreaterThanEqual %10 %24 %25 -%448 = OpFOrdGreaterThanEqual %10 %14 %3 -%449 = OpCompositeConstruct %153 %18 %18 -%450 = OpCompositeConstruct %153 %7 %7 -%451 = OpSGreaterThanEqual %137 %449 %450 -%452 = OpCompositeConstruct %164 %24 %24 %24 -%453 = OpCompositeConstruct %164 %25 %25 %25 -%454 = OpUGreaterThanEqual %100 %452 %453 -%455 = OpCompositeConstruct %26 %14 %14 %14 %14 -%456 = OpCompositeConstruct %26 %3 %3 %3 %3 -%457 = OpFOrdGreaterThanEqual %28 %455 %456 +OpBranch %387 +%387 = OpLabel +%388 = OpIEqual %10 %18 %7 +%389 = OpIEqual %10 %24 %25 +%390 = OpFOrdEqual %10 %14 %3 +%391 = OpCompositeConstruct %155 %18 %18 +%392 = OpCompositeConstruct %155 %7 %7 +%393 = OpIEqual %139 %391 %392 +%394 = OpCompositeConstruct %166 %24 %24 %24 +%395 = OpCompositeConstruct %166 %25 %25 %25 +%396 = OpIEqual %102 %394 %395 +%397 = OpCompositeConstruct %26 %14 %14 %14 %14 +%398 = OpCompositeConstruct %26 %3 %3 %3 %3 +%399 = OpFOrdEqual %28 %397 %398 +%400 = OpINotEqual %10 %18 %7 +%401 = OpINotEqual %10 %24 %25 +%402 = OpFOrdNotEqual %10 %14 %3 +%403 = OpCompositeConstruct %155 %18 %18 +%404 = OpCompositeConstruct %155 %7 %7 +%405 = OpINotEqual %139 %403 %404 +%406 = OpCompositeConstruct %166 %24 %24 %24 +%407 = OpCompositeConstruct %166 %25 %25 %25 +%408 = OpINotEqual %102 %406 %407 +%409 = OpCompositeConstruct %26 %14 %14 %14 %14 +%410 = OpCompositeConstruct %26 %3 %3 %3 %3 +%411 = OpFOrdNotEqual %28 %409 %410 +%412 = OpSLessThan %10 %18 %7 +%413 = OpULessThan %10 %24 %25 +%414 = OpFOrdLessThan %10 %14 %3 +%415 = OpCompositeConstruct %155 %18 %18 +%416 = OpCompositeConstruct %155 %7 %7 +%417 = OpSLessThan %139 %415 %416 +%418 = OpCompositeConstruct %166 %24 %24 %24 +%419 = OpCompositeConstruct %166 %25 %25 %25 +%420 = OpULessThan %102 %418 %419 +%421 = OpCompositeConstruct %26 %14 %14 %14 %14 +%422 = OpCompositeConstruct %26 %3 %3 %3 %3 +%423 = OpFOrdLessThan %28 %421 %422 +%424 = OpSLessThanEqual %10 %18 %7 +%425 = OpULessThanEqual %10 %24 %25 +%426 = OpFOrdLessThanEqual %10 %14 %3 +%427 = OpCompositeConstruct %155 %18 %18 +%428 = OpCompositeConstruct %155 %7 %7 +%429 = OpSLessThanEqual %139 %427 %428 +%430 = OpCompositeConstruct %166 %24 %24 %24 +%431 = OpCompositeConstruct %166 %25 %25 %25 +%432 = OpULessThanEqual %102 %430 %431 +%433 = OpCompositeConstruct %26 %14 %14 %14 %14 +%434 = OpCompositeConstruct %26 %3 %3 %3 %3 +%435 = OpFOrdLessThanEqual %28 %433 %434 +%436 = OpSGreaterThan %10 %18 %7 +%437 = OpUGreaterThan %10 %24 %25 +%438 = OpFOrdGreaterThan %10 %14 %3 +%439 = OpCompositeConstruct %155 %18 %18 +%440 = OpCompositeConstruct %155 %7 %7 +%441 = OpSGreaterThan %139 %439 %440 +%442 = OpCompositeConstruct %166 %24 %24 %24 +%443 = OpCompositeConstruct %166 %25 %25 %25 +%444 = OpUGreaterThan %102 %442 %443 +%445 = OpCompositeConstruct %26 %14 %14 %14 %14 +%446 = OpCompositeConstruct %26 %3 %3 %3 %3 +%447 = OpFOrdGreaterThan %28 %445 %446 +%448 = OpSGreaterThanEqual %10 %18 %7 +%449 = OpUGreaterThanEqual %10 %24 %25 +%450 = OpFOrdGreaterThanEqual %10 %14 %3 +%451 = OpCompositeConstruct %155 %18 %18 +%452 = OpCompositeConstruct %155 %7 %7 +%453 = OpSGreaterThanEqual %139 %451 %452 +%454 = OpCompositeConstruct %166 %24 %24 %24 +%455 = OpCompositeConstruct %166 %25 %25 %25 +%456 = OpUGreaterThanEqual %102 %454 %455 +%457 = OpCompositeConstruct %26 %14 %14 %14 %14 +%458 = OpCompositeConstruct %26 %3 %3 %3 %3 +%459 = OpFOrdGreaterThanEqual %28 %457 %458 OpReturn OpFunctionEnd -%461 = OpFunction %2 None %134 -%460 = OpLabel -%458 = OpVariable %459 Function %7 -OpBranch %462 -%462 = OpLabel -%463 = OpLoad %8 %458 -%464 = OpIAdd %8 %463 %7 -OpStore %458 %464 -%465 = OpLoad %8 %458 -%466 = OpISub %8 %465 %7 -OpStore %458 %466 -%467 = OpLoad %8 %458 -%468 = OpLoad %8 %458 -%469 = OpIMul %8 %467 %468 -OpStore %458 %469 -%470 = OpLoad %8 %458 -%471 = OpLoad %8 %458 -%472 = OpSDiv %8 %470 %471 -OpStore %458 %472 -%473 = OpLoad %8 %458 -%474 = OpSRem %8 %473 %7 -OpStore %458 %474 -%475 = OpLoad %8 %458 -%476 = OpBitwiseAnd %8 %475 %11 -OpStore %458 %476 -%477 = OpLoad %8 %458 -%478 = OpBitwiseOr %8 %477 %11 -OpStore %458 %478 -%479 = OpLoad %8 %458 -%480 = OpBitwiseXor %8 %479 %11 -OpStore %458 %480 -%481 = OpLoad %8 %458 -%482 = OpShiftLeftLogical %8 %481 %24 -OpStore %458 %482 -%483 = OpLoad %8 %458 -%484 = OpShiftRightArithmetic %8 %483 %25 -OpStore %458 %484 -%485 = OpLoad %8 %458 -%486 = OpIAdd %8 %485 %7 -OpStore %458 %486 -%487 = OpLoad %8 %458 -%488 = OpISub %8 %487 %7 -OpStore %458 %488 +%465 = OpFunction %2 None %136 +%464 = OpLabel +%460 = OpVariable %461 Function %7 +%462 = OpVariable %463 Function %55 +OpBranch %466 +%466 = OpLabel +%467 = OpLoad %8 %460 +%468 = OpIAdd %8 %467 %7 +OpStore %460 %468 +%469 = OpLoad %8 %460 +%470 = OpISub %8 %469 %7 +OpStore %460 %470 +%471 = OpLoad %8 %460 +%472 = OpLoad %8 %460 +%473 = OpIMul %8 %471 %472 +OpStore %460 %473 +%474 = OpLoad %8 %460 +%475 = OpLoad %8 %460 +%476 = OpSDiv %8 %474 %475 +OpStore %460 %476 +%477 = OpLoad %8 %460 +%478 = OpSRem %8 %477 %7 +OpStore %460 %478 +%479 = OpLoad %8 %460 +%480 = OpBitwiseAnd %8 %479 %11 +OpStore %460 %480 +%481 = OpLoad %8 %460 +%482 = OpBitwiseOr %8 %481 %11 +OpStore %460 %482 +%483 = OpLoad %8 %460 +%484 = OpBitwiseXor %8 %483 %11 +OpStore %460 %484 +%485 = OpLoad %8 %460 +%486 = OpShiftLeftLogical %8 %485 %24 +OpStore %460 %486 +%487 = OpLoad %8 %460 +%488 = OpShiftRightArithmetic %8 %487 %25 +OpStore %460 %488 +%489 = OpLoad %8 %460 +%490 = OpIAdd %8 %489 %7 +OpStore %460 %490 +%491 = OpLoad %8 %460 +%492 = OpISub %8 %491 %7 +OpStore %460 %492 +%494 = OpAccessChain %493 %462 %25 +%495 = OpLoad %8 %494 +%496 = OpIAdd %8 %495 %7 +%497 = OpAccessChain %493 %462 %25 +OpStore %497 %496 +%498 = OpAccessChain %493 %462 %25 +%499 = OpLoad %8 %498 +%500 = OpISub %8 %499 %7 +%501 = OpAccessChain %493 %462 %25 +OpStore %501 %500 OpReturn OpFunctionEnd -%490 = OpFunction %2 None %134 -%489 = OpLabel -OpBranch %491 -%491 = OpLabel -%492 = OpFunctionCall %26 %55 -%493 = OpFunctionCall %26 %80 -%494 = OpVectorShuffle %29 %40 %40 0 1 2 -%495 = OpFunctionCall %29 %97 %494 -%496 = OpFunctionCall %4 %110 -%497 = OpFunctionCall %2 %133 -%498 = OpFunctionCall %2 %151 -%499 = OpFunctionCall %2 %335 -%500 = OpFunctionCall %2 %384 -%501 = OpFunctionCall %2 %461 +%503 = OpFunction %2 None %136 +%502 = OpLabel +OpBranch %504 +%504 = OpLabel +%505 = OpFunctionCall %26 %57 +%506 = OpFunctionCall %26 %82 +%507 = OpVectorShuffle %29 %41 %41 0 1 2 +%508 = OpFunctionCall %29 %99 %507 +%509 = OpFunctionCall %4 %112 +%510 = OpFunctionCall %2 %135 +%511 = OpFunctionCall %2 %153 +%512 = OpFunctionCall %2 %337 +%513 = OpFunctionCall %2 %386 +%514 = OpFunctionCall %2 %465 OpReturn OpFunctionEnd \ No newline at end of file diff --git a/tests/out/wgsl/operators.wgsl b/tests/out/wgsl/operators.wgsl index 952ab60681..ec6a736543 100644 --- a/tests/out/wgsl/operators.wgsl +++ b/tests/out/wgsl/operators.wgsl @@ -194,6 +194,7 @@ fn comparison() { fn assignment() { var a: i32 = 1; + var vec0_: vec3 = vec3(0, 0, 0); let _e6 = a; a = (_e6 + 1); @@ -221,6 +222,10 @@ fn assignment() { a = (_e36 + 1); let _e39 = a; a = (_e39 - 1); + let _e46 = vec0_.y; + vec0_.y = (_e46 + 1); + let _e51 = vec0_.y; + vec0_.y = (_e51 - 1); return; }