mirror of
				https://github.com/encounter/dawn-cmake.git
				synced 2025-10-26 11:40:29 +00:00 
			
		
		
		
	This is required to handle materialized values, and for constant expressions. Bug: tint:1504 Change-Id: If0a49e9b03566c06aa6e4e4c284fc427e1541e91 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/92082 Reviewed-by: Dan Sinclair <dsinclair@chromium.org> Kokoro: Kokoro <noreply+kokoro@google.com> Commit-Queue: Ben Clayton <bclayton@chromium.org>
		
			
				
	
	
		
			43 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			43 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
| ; SPIR-V
 | |
| ; Version: 1.3
 | |
| ; Generator: Google Tint Compiler; 0
 | |
| ; Bound: 21
 | |
| ; Schema: 0
 | |
|                OpCapability Shader
 | |
|                OpMemoryModel Logical GLSL450
 | |
|                OpEntryPoint GLCompute %main "main"
 | |
|                OpExecutionMode %main LocalSize 1 1 1
 | |
|                OpName %func "func"
 | |
|                OpName %value "value"
 | |
|                OpName %pointer "pointer"
 | |
|                OpName %main_1 "main_1"
 | |
|                OpName %i "i"
 | |
|                OpName %main "main"
 | |
|        %void = OpTypeVoid
 | |
|         %int = OpTypeInt 32 1
 | |
| %_ptr_Function_int = OpTypePointer Function %int
 | |
|           %1 = OpTypeFunction %void %int %_ptr_Function_int
 | |
|          %10 = OpTypeFunction %void
 | |
|          %13 = OpConstantNull %int
 | |
|     %int_123 = OpConstant %int 123
 | |
|        %func = OpFunction %void None %1
 | |
|       %value = OpFunctionParameter %int
 | |
|     %pointer = OpFunctionParameter %_ptr_Function_int
 | |
|           %8 = OpLabel
 | |
|                OpStore %pointer %value
 | |
|                OpReturn
 | |
|                OpFunctionEnd
 | |
|      %main_1 = OpFunction %void None %10
 | |
|          %12 = OpLabel
 | |
|           %i = OpVariable %_ptr_Function_int Function %13
 | |
|                OpStore %i %13
 | |
|                OpStore %i %int_123
 | |
|          %16 = OpFunctionCall %void %func %int_123 %i
 | |
|                OpReturn
 | |
|                OpFunctionEnd
 | |
|        %main = OpFunction %void None %10
 | |
|          %19 = OpLabel
 | |
|          %20 = OpFunctionCall %void %main_1
 | |
|                OpReturn
 | |
|                OpFunctionEnd
 |