2011-09-20 05:14:35 +08:00
|
|
|
// RUN: %clang_cc1 %s -ffake-address-space-map -emit-llvm -o - | FileCheck %s
|
|
|
|
|
|
|
|
__kernel void foo(void) {
|
|
|
|
// CHECK: @foo.i = internal addrspace(2)
|
|
|
|
__local int i;
|
|
|
|
++i;
|
|
|
|
}
|
2013-02-08 09:07:32 +08:00
|
|
|
|
2013-08-15 14:47:53 +08:00
|
|
|
// CHECK-LABEL: define void @_Z3barPU3AS2i
|
2013-02-08 09:07:32 +08:00
|
|
|
__kernel void __attribute__((__overloadable__)) bar(local int *x) {
|
|
|
|
*x = 5;
|
|
|
|
}
|