1*f4a2713aSLionel Sambuc// RUN: %clang_cc1 %s -triple "spir-unknown-unknown" -emit-llvm -o - | FileCheck %s 2*f4a2713aSLionel Sambuc 3*f4a2713aSLionel Sambuc// CHECK: target triple = "spir-unknown-unknown" 4*f4a2713aSLionel Sambuc 5*f4a2713aSLionel Sambuctypedef struct { 6*f4a2713aSLionel Sambuc char c; 7*f4a2713aSLionel Sambuc void *v; 8*f4a2713aSLionel Sambuc void *v2; 9*f4a2713aSLionel Sambuc} my_st; 10*f4a2713aSLionel Sambuc 11*f4a2713aSLionel Sambuckernel void foo(global long *arg) { 12*f4a2713aSLionel Sambuc int res1[sizeof(my_st) == 12 ? 1 : -1]; 13*f4a2713aSLionel Sambuc int res2[sizeof(void *) == 4 ? 1 : -1]; 14*f4a2713aSLionel Sambuc int res3[sizeof(arg) == 4 ? 1 : -1]; 15*f4a2713aSLionel Sambuc 16*f4a2713aSLionel Sambuc my_st *tmp = 0; 17*f4a2713aSLionel Sambuc 18*f4a2713aSLionel Sambuc arg[0] = (long)(&tmp->v); 19*f4a2713aSLionel Sambuc//CHECK: store i64 4, i64 addrspace(1)* 20*f4a2713aSLionel Sambuc arg[1] = (long)(&tmp->v2); 21*f4a2713aSLionel Sambuc//CHECK: store i64 8, i64 addrspace(1)* 22*f4a2713aSLionel Sambuc} 23