mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-09 09:32:20 +00:00
74f02db922
v2: split into 2 patches use clang builtins for other intrinsics as well v3: Fix warnings Switch r600 to use implictarg.ptr Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu> llvm-svn: 276442
12 lines
239 B
Common Lisp
12 lines
239 B
Common Lisp
#include <clc/clc.h>
|
|
|
|
_CLC_DEF uint get_group_id(uint dim)
|
|
{
|
|
switch(dim) {
|
|
case 0: return __builtin_r600_read_tgid_x();
|
|
case 1: return __builtin_r600_read_tgid_y();
|
|
case 2: return __builtin_r600_read_tgid_z();
|
|
default: return 1;
|
|
}
|
|
}
|