| 1 |
//===----------------------------------------------------------------------===// |
| 2 |
// |
| 3 |
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
| 4 |
// See https://llvm.org/LICENSE.txt for license information. |
| 5 |
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
| 6 |
// |
| 7 |
//===----------------------------------------------------------------------===// |
| 8 |
|
| 9 |
#include <clc/opencl/opencl-base.h> |
| 10 |
|
| 11 |
_CLC_DEF _CLC_OVERLOAD uint get_work_dim(void) { |
| 12 |
__attribute__((address_space(7))) uint *ptr = |
| 13 |
(__attribute__((address_space(7))) |
| 14 |
uint *)__builtin_r600_implicitarg_ptr(); |
| 15 |
return ptr[0]; |
| 16 |
} |