From 899eaa35696bb0a9a625acd70a14876834af6cc5 Mon Sep 17 00:00:00 2001 From: Cameron Zwarich Date: Fri, 11 Mar 2011 21:52:04 +0000 Subject: Roll r127459 back in: Optimize trivial branches in CodeGenPrepare, which often get created from the lowering of objectsize intrinsics. Unfortunately, a number of tests were relying on llc not optimizing trivial branches, so I had to add an option to allow them to continue to test what they originally tested. This fixes and . git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127498 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CodeGen/Thumb2/2009-08-06-SpDecBug.ll | 2 +- test/CodeGen/Thumb2/2009-09-28-ITBlockBug.ll | 2 +- test/CodeGen/Thumb2/2010-11-22-EpilogueBug.ll | 2 +- test/CodeGen/Thumb2/cross-rc-coalescing-2.ll | 2 -- 4 files changed, 3 insertions(+), 5 deletions(-) (limited to 'test/CodeGen/Thumb2') diff --git a/test/CodeGen/Thumb2/2009-08-06-SpDecBug.ll b/test/CodeGen/Thumb2/2009-08-06-SpDecBug.ll index 550b3ef..ff68e66 100644 --- a/test/CodeGen/Thumb2/2009-08-06-SpDecBug.ll +++ b/test/CodeGen/Thumb2/2009-08-06-SpDecBug.ll @@ -8,7 +8,7 @@ entry: ; CHECK: sub sp, #8 ; CHECK: push ; CHECK: add r7, sp, #4 -; CHECK: subs r4, r7, #4 +; CHECK: sub.w r4, r7, #4 ; CHECK: mov sp, r4 ; CHECK-NOT: mov sp, r7 ; CHECK: add sp, #8 diff --git a/test/CodeGen/Thumb2/2009-09-28-ITBlockBug.ll b/test/CodeGen/Thumb2/2009-09-28-ITBlockBug.ll index b2ed8fc..ac3e80a 100644 --- a/test/CodeGen/Thumb2/2009-09-28-ITBlockBug.ll +++ b/test/CodeGen/Thumb2/2009-09-28-ITBlockBug.ll @@ -1,4 +1,4 @@ -; RUN: llc < %s -mtriple=thumbv7-apple-darwin -mcpu=cortex-a8 | FileCheck %s +; RUN: llc < %s -mtriple=thumbv7-apple-darwin -mcpu=cortex-a8 -disable-cgp-branch-opts | FileCheck %s %struct.pix_pos = type { i32, i32, i32, i32, i32, i32 } diff --git a/test/CodeGen/Thumb2/2010-11-22-EpilogueBug.ll b/test/CodeGen/Thumb2/2010-11-22-EpilogueBug.ll index 313728c..d2140a1 100644 --- a/test/CodeGen/Thumb2/2010-11-22-EpilogueBug.ll +++ b/test/CodeGen/Thumb2/2010-11-22-EpilogueBug.ll @@ -8,7 +8,7 @@ declare void @bar() nounwind optsize define void @foo() nounwind optsize { ; CHECK: foo: ; CHECK: push -; CHECK: add r7, sp, #4 +; CHECK: mov r7, sp ; CHECK: sub sp, #4 entry: %m.i = alloca %struct.buf*, align 4 diff --git a/test/CodeGen/Thumb2/cross-rc-coalescing-2.ll b/test/CodeGen/Thumb2/cross-rc-coalescing-2.ll index b8c8cb1..edbf834 100644 --- a/test/CodeGen/Thumb2/cross-rc-coalescing-2.ll +++ b/test/CodeGen/Thumb2/cross-rc-coalescing-2.ll @@ -6,8 +6,6 @@ entry: br label %bb5 bb5: ; preds = %bb5, %entry -; CHECK: %bb5 -; CHECK: bne br i1 undef, label %bb5, label %bb.nph bb.nph: ; preds = %bb5 -- cgit v1.1