Revert "[llvm] Improve llvm.objectsize computation by computing GEP, alloca and mallo...
[llvm-project.git] / clang / test / CodeGen / ms-inline-asm-align.c
blob4a00cba2a1a3ef3e5c6cbd93b95de03ba88e9c05
1 // REQUIRES: x86-registered-target
2 // RUN: %clang_cc1 %s -triple i386-apple-darwin10 -fasm-blocks -emit-llvm -o - | FileCheck %s --check-prefix=DARWIN
3 // RUN: %clang_cc1 %s -triple i686-pc-win32 -fasm-blocks -emit-llvm -o - | FileCheck %s --check-prefix=WINDOWS
5 // On Windows, .align is in bytes, and on Darwin, .align is in log2 form. The
6 // Intel inline assembly parser should rewrite to the appropriate form depending
7 // on the platform.
9 void align_test(void) {
10 __asm align 8
11 __asm align 16;
12 __asm align 128;
13 __asm ALIGN 256;
16 // DARWIN-LABEL: define{{.*}} void @align_test()
17 // DARWIN: call void asm sideeffect inteldialect
18 // DARWIN-SAME: .align 3
19 // DARWIN-SAME: .align 4
20 // DARWIN-SAME: .align 7
21 // DARWIN-SAME: .align 8
22 // DARWIN-SAME: "~{dirflag},~{fpsr},~{flags}"()
24 // WINDOWS-LABEL: define dso_local void @align_test()
25 // WINDOWS: call void asm sideeffect inteldialect
26 // WINDOWS-SAME: .align 8
27 // WINDOWS-SAME: .align 16
28 // WINDOWS-SAME: .align 128
29 // WINDOWS-SAME: .align 256
30 // WINDOWS-SAME: "~{dirflag},~{fpsr},~{flags}"()