[clang] [llvm] [HLSL][SPIR-V] implement SV_GroupID semantic lowering (PR #121521)
Justin Bogner via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 3 12:49:25 PST 2025
================
@@ -0,0 +1,82 @@
+; RUN: llc -O0 -verify-machineinstrs -mtriple=spirv-vulkan-unknown %s -o - | FileCheck %s
+; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv-vulkan-unknown %s -o - -filetype=obj | spirv-val %}
+
+; This file generated from the following command:
+; clang -cc1 -triple spirv-vulkan-library -x hlsl -emit-llvm -disable-llvm-passes -finclude-default-header - -o - <<EOF
+; [shader("compute")]
+; [numthreads(1,1,1)]
+; void main(uint3 ID : SV_GroupID) {}
+; EOF
----------------
bogner wrote:
We generally do some clean up on test files so that they're easier to read and edit. Things like the `source_filename` and `datalayout` aren't really necessary, mangled names are more annoying to read than simple ones, and attributes and metadata that aren't necessary for the test can be removed. It's also nice to run things through `opt -instnamer` or manually name all of the SSA values so it's easier to edit in the future.
https://github.com/llvm/llvm-project/pull/121521
More information about the llvm-commits
mailing list