mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-28 01:56:05 +00:00

I am looking at constant-folding changes that could affect these tests, so check that it emits the expected global value instead of just checking that it doesn't crash.
10 lines
266 B
C++
10 lines
266 B
C++
// RUN: %clang_cc1 -triple=x86_64-linux-gnu -emit-llvm %s -o - | FileCheck %s
|
|
// RUN: %clang_cc1 -triple=i386-linux-gnu -emit-llvm %s -o - | FileCheck %s
|
|
|
|
struct S {
|
|
int A[2];
|
|
};
|
|
|
|
// CHECK: @XX = global i32 4, align 4
|
|
int XX = (int)(long)&(((struct S*)0)->A[1]);
|