From 4a16efa3e43e35f0cc9efe3a67f620f0017c3d36 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Mon, 8 Apr 2013 18:41:23 +0000 Subject: Vendor import of llvm trunk r178860: http://llvm.org/svn/llvm-project/llvm/trunk@178860 --- test/ExecutionEngine/MCJIT/test-data-align-remote.ll | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 test/ExecutionEngine/MCJIT/test-data-align-remote.ll (limited to 'test/ExecutionEngine/MCJIT/test-data-align-remote.ll') diff --git a/test/ExecutionEngine/MCJIT/test-data-align-remote.ll b/test/ExecutionEngine/MCJIT/test-data-align-remote.ll new file mode 100644 index 000000000000..9daf1684de81 --- /dev/null +++ b/test/ExecutionEngine/MCJIT/test-data-align-remote.ll @@ -0,0 +1,16 @@ +; RUN: %lli_mcjit -remote-mcjit -O0 %s +; XFAIL: armv7, mips + +; Check that a variable is always aligned as specified. + +@var = global i32 0, align 32 +define i32 @main() { + %addr = ptrtoint i32* @var to i64 + %mask = and i64 %addr, 31 + %tst = icmp eq i64 %mask, 0 + br i1 %tst, label %good, label %bad +good: + ret i32 0 +bad: + ret i32 1 +} -- cgit v1.3