diff options
author | Chris Lattner <sabre@nondot.org> | 2011-06-18 06:05:24 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2011-06-18 06:05:24 +0000 |
commit | b85e4eba85a38698f3b3332f82554bf8442547e2 (patch) | |
tree | ae680321c7e03ee37d612c42282038950d37ea13 /test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll | |
parent | 6be41eb7f00319f5ffa1a5435dcd1e81b3ce932d (diff) | |
download | external_llvm-b85e4eba85a38698f3b3332f82554bf8442547e2.zip external_llvm-b85e4eba85a38698f3b3332f82554bf8442547e2.tar.gz external_llvm-b85e4eba85a38698f3b3332f82554bf8442547e2.tar.bz2 |
rip out a ton of intrinsic modernization logic from AutoUpgrade.cpp, which is
for pre-2.9 bitcode files. We keep x86 unaligned loads, movnt, crc32, and the
target indep prefetch change.
As usual, updating the testsuite is a PITA.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133337 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll')
-rw-r--r-- | test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll | 64 |
1 files changed, 0 insertions, 64 deletions
diff --git a/test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll b/test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll deleted file mode 100644 index faac118..0000000 --- a/test/Transforms/FunctionAttrs/2008-10-04-LocalMemory.ll +++ /dev/null @@ -1,64 +0,0 @@ -; RUN: opt < %s -basicaa -functionattrs -S | FileCheck %s - -%struct.X = type { i32*, i32* } - -declare i32 @g(i32*) readnone - -define i32 @f() { -; CHECK: @f() readnone - %x = alloca i32 ; <i32*> [#uses=2] - store i32 0, i32* %x - %y = call i32 @g(i32* %x) ; <i32> [#uses=1] - ret i32 %y -} - -define i32 @foo() nounwind { -; CHECK: @foo() nounwind readonly -entry: - %y = alloca %struct.X ; <%struct.X*> [#uses=2] - %x = alloca %struct.X ; <%struct.X*> [#uses=2] - %j = alloca i32 ; <i32*> [#uses=2] - %i = alloca i32 ; <i32*> [#uses=2] - %"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] - store i32 0, i32* %i, align 4 - store i32 1, i32* %j, align 4 - %0 = getelementptr inbounds %struct.X* %y, i32 0, i32 0 ; <i32**> [#uses=1] - store i32* %i, i32** %0, align 8 - %1 = getelementptr inbounds %struct.X* %x, i32 0, i32 1 ; <i32**> [#uses=1] - store i32* %j, i32** %1, align 8 - %x1 = bitcast %struct.X* %x to i8* ; <i8*> [#uses=2] - %y2 = bitcast %struct.X* %y to i8* ; <i8*> [#uses=1] - call void @llvm.memcpy.i64(i8* %x1, i8* %y2, i64 8, i32 1) - %2 = bitcast i8* %x1 to i32** ; <i32**> [#uses=1] - %3 = load i32** %2, align 8 ; <i32*> [#uses=1] - %4 = load i32* %3, align 4 ; <i32> [#uses=1] - br label %return - -return: ; preds = %entry - ret i32 %4 -} - -define i32 @t(i32 %a, i32 %b, i32 %c) nounwind { -; CHECK: @t(i32 %a, i32 %b, i32 %c) nounwind readnone -entry: - %a.addr = alloca i32 ; <i32*> [#uses=3] - %c.addr = alloca i32 ; <i32*> [#uses=2] - store i32 %a, i32* %a.addr - store i32 %c, i32* %c.addr - %tmp = load i32* %a.addr ; <i32> [#uses=1] - %tobool = icmp ne i32 %tmp, 0 ; <i1> [#uses=1] - br i1 %tobool, label %if.then, label %if.else - -if.then: ; preds = %entry - br label %if.end - -if.else: ; preds = %entry - br label %if.end - -if.end: ; preds = %if.else, %if.then - %p.0 = phi i32* [ %a.addr, %if.then ], [ %c.addr, %if.else ] ; <i32*> [#uses=1] - %tmp2 = load i32* %p.0 ; <i32> [#uses=1] - ret i32 %tmp2 -} - -declare void @llvm.memcpy.i64(i8* nocapture, i8* nocapture, i64, i32) nounwind |