summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2007-04-16 17:36:08 +0000
committerReid Spencer <rspencer@reidspencer.com>2007-04-16 17:36:08 +0000
commiteb1d74e0c8b2c08b98e9175be137ec4ae617a8b7 (patch)
tree369be5c4e0bcec5a0a48cba3f45020ecda6b42db /test
parent725aed34076e70aa30a7a8d2ae3a44e6eef02410 (diff)
For PR1319:
Remove && from the end of the lines to prevent tests from throwing run lines into the background. Also, clean up places where the same command is run multiple times by using a temporary file. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36142 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/Analysis/BasicAA/modref.ll2
-rw-r--r--test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll3
-rw-r--r--test/Assembler/2003-05-21-MalformedShiftCrash.llx2
-rw-r--r--test/Assembler/2003-05-21-MalformedStructCrash.llx2
-rw-r--r--test/C++Frontend/2003-10-21-InnerClass.cpp.tr2
-rw-r--r--test/CFrontend/2006-01-13-Includes.c2
-rw-r--r--test/CodeGen/ARM/2007-04-03-PEIBug.ll2
-rw-r--r--test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll3
-rw-r--r--test/CodeGen/ARM/alloca.ll7
-rw-r--r--test/CodeGen/ARM/arguments.ll9
-rw-r--r--test/CodeGen/ARM/bits.ll12
-rw-r--r--test/CodeGen/ARM/branch.ll10
-rw-r--r--test/CodeGen/ARM/call_nolink.ll4
-rw-r--r--test/CodeGen/ARM/clz.ll3
-rw-r--r--test/CodeGen/ARM/compare-call.ll4
-rw-r--r--test/CodeGen/ARM/constants.ll22
-rw-r--r--test/CodeGen/ARM/div.ll10
-rw-r--r--test/CodeGen/ARM/dyn-stackalloc.ll8
-rw-r--r--test/CodeGen/ARM/fcopysign.ll7
-rw-r--r--test/CodeGen/ARM/fp.ll30
-rw-r--r--test/CodeGen/ARM/fparith.ll19
-rw-r--r--test/CodeGen/ARM/fpcmp.ll16
-rw-r--r--test/CodeGen/ARM/fpcmp_ueq.ll3
-rw-r--r--test/CodeGen/ARM/fpconv.ll22
-rw-r--r--test/CodeGen/ARM/fpmem.ll10
-rw-r--r--test/CodeGen/ARM/hello.ll6
-rw-r--r--test/CodeGen/ARM/imm.ll1
-rw-r--r--test/CodeGen/ARM/insn-sched1.ll5
-rw-r--r--test/CodeGen/ARM/ldm.ll10
-rw-r--r--test/CodeGen/ARM/ldr_ext.ll17
-rw-r--r--test/CodeGen/ARM/ldr_frame.ll4
-rw-r--r--test/CodeGen/ARM/ldr_pre.ll4
-rw-r--r--test/CodeGen/ARM/load.ll10
-rw-r--r--test/CodeGen/ARM/long-setcc.ll4
-rw-r--r--test/CodeGen/ARM/long_shift.ll10
-rw-r--r--test/CodeGen/ARM/pack.ll2
-rw-r--r--test/CodeGen/ARM/section.ll1
-rw-r--r--test/CodeGen/ARM/vfp.ll2
-rw-r--r--test/CodeGen/Alpha/weak.ll3
-rw-r--r--test/CodeGen/Generic/2006-07-03-schedulers.ll12
-rw-r--r--test/CodeGen/Generic/2006-11-06-MemIntrinsicExpand.ll1
-rw-r--r--test/CodeGen/Generic/2007-04-14-BitTestsBadMask.ll2
-rw-r--r--test/CodeGen/Generic/fpowi-promote.ll2
-rw-r--r--test/CodeGen/Generic/switch-lower-feature-2.ll19
-rw-r--r--test/CodeGen/Generic/switch-lower-feature.ll8
-rw-r--r--test/CodeGen/Generic/vector-identity-shuffle.ll4
-rw-r--r--test/CodeGen/Generic/vector.ll10
-rw-r--r--test/CodeGen/PowerPC/2006-08-11-RetVector.ll2
-rw-r--r--test/CodeGen/PowerPC/2006-10-13-Miscompile.ll1
-rw-r--r--test/CodeGen/PowerPC/2006-12-07-LargeAlloca.ll4
-rw-r--r--test/CodeGen/PowerPC/2006-12-07-SelectCrash.ll4
-rw-r--r--test/CodeGen/PowerPC/2007-01-04-ArgExtension.ll2
-rw-r--r--test/CodeGen/PowerPC/2007-01-29-lbrx-asm.ll2
-rw-r--r--test/CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll2
-rw-r--r--test/CodeGen/PowerPC/addc.ll11
-rw-r--r--test/CodeGen/PowerPC/addi-reassoc.ll1
-rw-r--r--test/CodeGen/PowerPC/align.ll9
-rw-r--r--test/CodeGen/PowerPC/and-branch.ll1
-rw-r--r--test/CodeGen/PowerPC/and-elim.ll1
-rw-r--r--test/CodeGen/PowerPC/and_add.ll7
-rw-r--r--test/CodeGen/PowerPC/and_sext.ll3
-rw-r--r--test/CodeGen/PowerPC/buildvec_canonicalize.ll8
-rw-r--r--test/CodeGen/PowerPC/cmp-cmp.ll1
-rw-r--r--test/CodeGen/PowerPC/div-2.ll2
-rw-r--r--test/CodeGen/PowerPC/eqv-andc-orc-nor.ll15
-rw-r--r--test/CodeGen/PowerPC/fold-li.ll4
-rw-r--r--test/CodeGen/PowerPC/fp-int-fp.ll1
-rw-r--r--test/CodeGen/PowerPC/fpcopy.ll1
-rw-r--r--test/CodeGen/PowerPC/inlineasm-copy.ll1
-rw-r--r--test/CodeGen/PowerPC/inverted-bool-compares.ll3
-rw-r--r--test/CodeGen/PowerPC/load-constant-addr.ll2
-rw-r--r--test/CodeGen/PowerPC/mem_update.ll8
-rw-r--r--test/CodeGen/PowerPC/mul-neg-power-2.ll1
-rw-r--r--test/CodeGen/PowerPC/mulhs.ll9
-rw-r--r--test/CodeGen/PowerPC/or-addressing-mode.ll3
-rw-r--r--test/CodeGen/PowerPC/reg-coalesce-simple.ll1
-rw-r--r--test/CodeGen/PowerPC/rlwimi.ll2
-rw-r--r--test/CodeGen/PowerPC/rlwimi2.ll7
-rw-r--r--test/CodeGen/PowerPC/rlwinm.ll11
-rw-r--r--test/CodeGen/PowerPC/rlwinm2.ll13
-rw-r--r--test/CodeGen/PowerPC/rotl-2.ll4
-rw-r--r--test/CodeGen/PowerPC/rotl.ll3
-rw-r--r--test/CodeGen/PowerPC/stfiwx.ll13
-rw-r--r--test/CodeGen/PowerPC/store-load-fwd.ll1
-rw-r--r--test/CodeGen/PowerPC/subc.ll11
-rw-r--r--test/CodeGen/PowerPC/unsafe-math.ll5
-rw-r--r--test/CodeGen/PowerPC/vec_br_cmp.ll5
-rw-r--r--test/CodeGen/PowerPC/vec_constants.ll1
-rw-r--r--test/CodeGen/PowerPC/vec_mul.ll3
-rw-r--r--test/CodeGen/PowerPC/vec_perf_shuffle.ll1
-rw-r--r--test/CodeGen/PowerPC/vec_shuffle.ll14
-rw-r--r--test/CodeGen/PowerPC/vec_spat.ll10
-rw-r--r--test/CodeGen/PowerPC/vec_vrsave.ll7
-rw-r--r--test/CodeGen/SPARC/ctpop.ll10
-rw-r--r--test/CodeGen/SPARC/xnor.ll4
-rw-r--r--test/CodeGen/X86/2006-10-19-SwitchUnnecessaryBranching.ll3
-rw-r--r--test/CodeGen/X86/bitcast.ll3
-rw-r--r--test/CodeGen/X86/bswap.ll3
-rw-r--r--test/CodeGen/X86/cmp-test.ll3
-rw-r--r--test/CodeGen/X86/compare-add.ll1
-rw-r--r--test/CodeGen/X86/compare_folding.llx6
-rw-r--r--test/CodeGen/X86/fp-stack-ret.ll2
-rw-r--r--test/CodeGen/X86/long-setcc.ll5
-rw-r--r--test/CodeGen/X86/mul-shift-reassoc.ll2
-rw-r--r--test/CodeGen/X86/packed_struct.ll10
-rw-r--r--test/CodeGen/X86/rdtsc.ll2
-rw-r--r--test/CodeGen/X86/scalar_sse_minmax.ll6
-rw-r--r--test/CodeGen/X86/select.ll2
-rw-r--r--test/CodeGen/X86/store-fp-constant.ll2
-rw-r--r--test/CodeGen/X86/test-hidden.ll7
-rw-r--r--test/CodeGen/X86/test-pic-1.ll2
-rw-r--r--test/CodeGen/X86/test-pic-2.ll9
-rw-r--r--test/CodeGen/X86/test-pic-3.ll9
-rw-r--r--test/CodeGen/X86/test-pic-4.ll4
-rw-r--r--test/CodeGen/X86/test-pic-5.ll9
-rw-r--r--test/CodeGen/X86/test-pic-6.ll9
-rw-r--r--test/CodeGen/X86/test-pic-cpool.ll11
-rw-r--r--test/CodeGen/X86/test-pic-jtbl.ll13
-rw-r--r--test/CodeGen/X86/vec_clear.ll1
-rw-r--r--test/CodeGen/X86/vec_extract.ll9
-rw-r--r--test/CodeGen/X86/vec_ins_extract.ll2
-rw-r--r--test/CodeGen/X86/vec_insert.ll5
-rw-r--r--test/CodeGen/X86/vec_set-2.ll2
-rw-r--r--test/CodeGen/X86/vec_set-3.ll7
-rw-r--r--test/CodeGen/X86/vec_set-5.ll7
-rw-r--r--test/CodeGen/X86/vec_set-6.ll5
-rw-r--r--test/CodeGen/X86/vec_shuffle-2.ll7
-rw-r--r--test/CodeGen/X86/vec_shuffle-3.ll5
-rw-r--r--test/CodeGen/X86/vec_shuffle-4.ll6
-rw-r--r--test/CodeGen/X86/vec_shuffle-5.ll5
-rw-r--r--test/CodeGen/X86/vec_shuffle-6.ll8
-rw-r--r--test/CodeGen/X86/vec_shuffle-7.ll6
-rw-r--r--test/CodeGen/X86/vec_shuffle-8.ll4
-rw-r--r--test/CodeGen/X86/vec_shuffle-9.ll6
-rw-r--r--test/CodeGen/X86/vec_shuffle.ll7
-rw-r--r--test/CodeGen/X86/vec_splat.ll2
-rw-r--r--test/CodeGen/X86/vec_ss_load_fold.ll5
-rw-r--r--test/CodeGen/X86/x86-64-mem.ll18
-rw-r--r--test/Feature/fold-fpcast.ll1
-rw-r--r--test/Feature/forwardreftest.ll1
-rw-r--r--test/Feature/inlineasm.ll6
-rw-r--r--test/Linker/basiclink.ll4
-rw-r--r--test/Transforms/ConstProp/bitcast.ll1
-rw-r--r--test/Transforms/DeadArgElim/dead_vaargs.ll3
-rw-r--r--test/Transforms/GCSE/vectorops.ll4
-rw-r--r--test/Transforms/GlobalOpt/ctor-list-opt.ll1
-rw-r--r--test/Transforms/IndVarsSimplify/loop_evaluate_2.ll2
-rw-r--r--test/Transforms/Inline/dynamic_alloca_test.ll4
-rw-r--r--test/Transforms/InstCombine/2007-04-04-BadFoldBitcastIntoMalloc.ll1
-rw-r--r--test/Transforms/InstCombine/add.ll1
-rw-r--r--test/Transforms/InstCombine/add2.ll1
-rw-r--r--test/Transforms/LCSSA/2006-06-03-IncorrectIDFPhis.ll4
-rw-r--r--test/Transforms/LCSSA/2006-06-12-MultipleExitsSameBlock.ll4
-rw-r--r--test/Transforms/LCSSA/basictest.ll4
-rw-r--r--test/Transforms/LoopRotate/PhiRename-1.ll4
-rw-r--r--test/Transforms/LoopStrengthReduce/nested-reduce.ll1
-rw-r--r--test/Transforms/LoopUnroll/2006-08-24-MultiBlockLoop.ll2
-rw-r--r--test/Transforms/LowerInvoke/basictest.ll1
-rw-r--r--test/Transforms/LowerSwitch/feature.ll7
-rw-r--r--test/Transforms/PredicateSimplifier/2006-10-22-IntOr.ll7
-rw-r--r--test/Transforms/PredicateSimplifier/2006-10-25-AddSetCC.ll5
-rw-r--r--test/Transforms/PredicateSimplifier/predsimplify.ll6
-rw-r--r--test/Transforms/Reassociate/mul-factor3.ll6
-rw-r--r--test/Transforms/Reassociate/mulfactor2.ll7
-rw-r--r--test/Transforms/Reassociate/shift-factor.ll6
-rw-r--r--test/Transforms/ScalarRepl/AggregatePromote.ll4
-rw-r--r--test/Transforms/ScalarRepl/vector_promote.ll5
-rw-r--r--test/Transforms/SimplifyLibCalls/floor.ll19
-rw-r--r--test/Transforms/TailCallElim/return-undef.ll5
-rw-r--r--test/Transforms/TailDup/if-tail-dup.ll8
170 files changed, 493 insertions, 468 deletions
diff --git a/test/Analysis/BasicAA/modref.ll b/test/Analysis/BasicAA/modref.ll
index 27b9c402f97..adf195e8847 100644
--- a/test/Analysis/BasicAA/modref.ll
+++ b/test/Analysis/BasicAA/modref.ll
@@ -1,6 +1,6 @@
; A very rudimentary test on AliasAnalysis::getModRefInfo.
; RUN: llvm-upgrade < %s | llvm-as | \
-; RUN: opt -print-all-alias-modref-info -aa-eval -disable-output |&
+; RUN: opt -print-all-alias-modref-info -aa-eval -disable-output |& \
; RUN: not grep NoModRef
int %callee() {
diff --git a/test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll b/test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll
index 3eeecae0534..e2023c5493f 100644
--- a/test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll
+++ b/test/Analysis/LoopInfo/2003-05-15-NestingProblem.ll
@@ -1,7 +1,8 @@
; This testcase was incorrectly computing that the loopentry.7 loop was
; not a child of the loopentry.6 loop.
;
-; RUN: llvm-upgrade < %s | llvm-as | opt -analyze -loops | grep "^ Loop Containing: %loopentry.7"
+; RUN: llvm-upgrade < %s | llvm-as | opt -analyze -loops | \
+; RUN: grep {^ Loop Containing: %loopentry.7}
void %getAndMoveToFrontDecode() { ; No predecessors!
br label %endif.2
diff --git a/test/Assembler/2003-05-21-MalformedShiftCrash.llx b/test/Assembler/2003-05-21-MalformedShiftCrash.llx
index d49d591b1ef..33e20e384ca 100644
--- a/test/Assembler/2003-05-21-MalformedShiftCrash.llx
+++ b/test/Assembler/2003-05-21-MalformedShiftCrash.llx
@@ -1,4 +1,4 @@
; Found by inspection of the code
-; RUN: llvm-as < %s > /dev/null |& grep "Logical operator requires integral"
+; RUN: llvm-as < %s > /dev/null |& grep {Logical operator requires integral}
global i32 ashr (float 1.0, float 2.0)
diff --git a/test/Assembler/2003-05-21-MalformedStructCrash.llx b/test/Assembler/2003-05-21-MalformedStructCrash.llx
index 386c413a542..91b0c9e0643 100644
--- a/test/Assembler/2003-05-21-MalformedStructCrash.llx
+++ b/test/Assembler/2003-05-21-MalformedStructCrash.llx
@@ -1,4 +1,4 @@
; Found by inspection of the code
-; RUN: llvm-as < %s > /dev/null |& grep "Illegal number of init"
+; RUN: llvm-as < %s > /dev/null |& grep {Illegal number of init}
global {} { i32 7, float 1.0, i32 7, i32 8 }
diff --git a/test/C++Frontend/2003-10-21-InnerClass.cpp.tr b/test/C++Frontend/2003-10-21-InnerClass.cpp.tr
index 0e8ff2cd30c..fadd51d2267 100644
--- a/test/C++Frontend/2003-10-21-InnerClass.cpp.tr
+++ b/test/C++Frontend/2003-10-21-InnerClass.cpp.tr
@@ -1,4 +1,4 @@
-// RUN: %llvmgcc -xc++ -S -o - %s | grep "struct.X::Y"
+// RUN: %llvmgcc -xc++ -S -o - %s | grep {struct.X::Y}
struct X {
struct Y {
diff --git a/test/CFrontend/2006-01-13-Includes.c b/test/CFrontend/2006-01-13-Includes.c
index 5847e9ee453..46e7867a282 100644
--- a/test/CFrontend/2006-01-13-Includes.c
+++ b/test/CFrontend/2006-01-13-Includes.c
@@ -1,5 +1,5 @@
// RUN: %llvmgcc %s -g -S -o - | llvm-as | opt -std-compile-opts | \
-// RUN: llvm-dis | grep "test/CFrontend"
+// RUN: llvm-dis | grep {test/CFrontend}
// PR676
#include <stdio.h>
diff --git a/test/CodeGen/ARM/2007-04-03-PEIBug.ll b/test/CodeGen/ARM/2007-04-03-PEIBug.ll
index 3e56b855732..e412127eae7 100644
--- a/test/CodeGen/ARM/2007-04-03-PEIBug.ll
+++ b/test/CodeGen/ARM/2007-04-03-PEIBug.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=arm | not grep "add.*#0"
+; RUN: llvm-as < %s | llc -march=arm | not grep {add.*#0}
define i32 @foo() {
entry:
diff --git a/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll b/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll
index ee983eb48de..42f5034c70a 100644
--- a/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll
+++ b/test/CodeGen/ARM/2007-04-03-UndefinedSymbol.ll
@@ -1,4 +1,5 @@
-; RUN: llvm-as < %s | llc -mtriple=arm-apple-darwin -relocation-model=pic | not grep "LPC9"
+; RUN: llvm-as < %s | llc -mtriple=arm-apple-darwin -relocation-model=pic | \
+; RUN: not grep LPC9
%struct.B = type { i32 }
%struct.anon = type { void (%struct.B*)*, i32 }
diff --git a/test/CodeGen/ARM/alloca.ll b/test/CodeGen/ARM/alloca.ll
index c04a8b0499b..b98a674ce2e 100644
--- a/test/CodeGen/ARM/alloca.ll
+++ b/test/CodeGen/ARM/alloca.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mtriple=arm-linux-gnu | grep "mov r11, sp" &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mtriple=arm-linux-gnu | grep "mov sp, r11"
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mtriple=arm-linux-gnu | \
+; RUN: grep {mov r11, sp}
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mtriple=arm-linux-gnu | \
+; RUN: grep {mov sp, r11}
void %f(uint %a) {
entry:
diff --git a/test/CodeGen/ARM/arguments.ll b/test/CodeGen/ARM/arguments.ll
index 018be239e30..fbaaa237086 100644
--- a/test/CodeGen/ARM/arguments.ll
+++ b/test/CodeGen/ARM/arguments.ll
@@ -1,10 +1,11 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -mtriple=arm-linux-gnueabi | grep "mov r0, r2" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -mtriple=arm-apple-darwin | grep "mov r0, r1" | wc -l | grep 1
+; RUN: llvm-as < %s | llc -mtriple=arm-linux-gnueabi | \
+; RUN: grep {mov r0, r2} | wc -l | grep 1
+; RUN: llvm-as < %s | llc -mtriple=arm-apple-darwin | \
+; RUN: grep {mov r0, r1} | wc -l | grep 1
define i32 @f(i32 %a, i64 %b) {
%tmp = call i32 @g(i64 %b)
ret i32 %tmp
}
-declare i32 @g(i64) \ No newline at end of file
+declare i32 @g(i64)
diff --git a/test/CodeGen/ARM/bits.ll b/test/CodeGen/ARM/bits.ll
index 7a0a08c301f..82b4fa7e910 100644
--- a/test/CodeGen/ARM/bits.ll
+++ b/test/CodeGen/ARM/bits.ll
@@ -1,9 +1,9 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep and | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep orr | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep eor | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep mov.*lsl | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep mov.*asr | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=arm > %t
+; RUN: grep and %t | wc -l | grep 1
+; RUN: grep orr %t | wc -l | grep 1
+; RUN: grep eor %t | wc -l | grep 1
+; RUN: grep mov.*lsl %t | wc -l | grep 1
+; RUN: grep mov.*asr %t | wc -l | grep 1
define i32 @f1(i32 %a, i32 %b) {
entry:
diff --git a/test/CodeGen/ARM/branch.ll b/test/CodeGen/ARM/branch.ll
index 12dd4a9f1e4..df28f42d010 100644
--- a/test/CodeGen/ARM/branch.ll
+++ b/test/CodeGen/ARM/branch.ll
@@ -1,8 +1,8 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep bne &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep bge &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep bhs &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep blo
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm > %t
+; RUN: grep bne %t
+; RUN: grep bge %t
+; RUN: grep bhs %t
+; RUN: grep blo %t
void %f1(int %a, int %b, int* %v) {
entry:
diff --git a/test/CodeGen/ARM/call_nolink.ll b/test/CodeGen/ARM/call_nolink.ll
index 4dbfe8d670e..1af6fad099b 100644
--- a/test/CodeGen/ARM/call_nolink.ll
+++ b/test/CodeGen/ARM/call_nolink.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm -mtriple=arm-linux-gnueabi | not grep "bx lr"
+; RUN: llvm-as < %s | llc -march=arm -mtriple=arm-linux-gnueabi | \
+; RUN: not grep {bx lr}
%struct.anon = type { i32 (i32, i32, i32)*, i32, i32, [3 x i32], i8*, i8*, i8* }
@r = external global [14 x i32] ; <[14 x i32]*> [#uses=4]
diff --git a/test/CodeGen/ARM/clz.ll b/test/CodeGen/ARM/clz.ll
index 80b7cd8fee9..cdde95a687d 100644
--- a/test/CodeGen/ARM/clz.ll
+++ b/test/CodeGen/ARM/clz.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v5t | grep "clz"
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v5t | grep clz
declare uint %llvm.ctlz.i32(uint)
diff --git a/test/CodeGen/ARM/compare-call.ll b/test/CodeGen/ARM/compare-call.ll
index 0c57e0e1c26..3fcded8431b 100644
--- a/test/CodeGen/ARM/compare-call.ll
+++ b/test/CodeGen/ARM/compare-call.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6,+vfp2 | grep fcmpes
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6,+vfp2 | \
+; RUN: grep fcmpes
void %test3(float* %glob, int %X) {
entry:
diff --git a/test/CodeGen/ARM/constants.ll b/test/CodeGen/ARM/constants.ll
index c8d35188c6c..7302617256b 100644
--- a/test/CodeGen/ARM/constants.ll
+++ b/test/CodeGen/ARM/constants.ll
@@ -1,11 +1,17 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #0" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #255$" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0.*256" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "orr.*256" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, .*-1073741761" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, .*1008" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "cmp r0, #1, 16" | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0, #0} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0, #255$} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0.*256} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {orr.*256} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0, .*-1073741761} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0, .*1008} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {cmp r0, #1, 16} | wc -l | grep 1
uint %f1() {
ret uint 0
diff --git a/test/CodeGen/ARM/div.ll b/test/CodeGen/ARM/div.ll
index 5ad660ed5ab..3f8a752b39f 100644
--- a/test/CodeGen/ARM/div.ll
+++ b/test/CodeGen/ARM/div.ll
@@ -1,8 +1,8 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep __divsi3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep __udivsi3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep __modsi3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep __umodsi3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm > %t
+; RUN: grep __divsi3 %t
+; RUN: grep __udivsi3 %t
+; RUN: grep __modsi3 %t
+; RUN: grep __umodsi3 %t
int %f1(int %a, int %b) {
entry:
diff --git a/test/CodeGen/ARM/dyn-stackalloc.ll b/test/CodeGen/ARM/dyn-stackalloc.ll
index 33740052b0b..602fd9bd550 100644
--- a/test/CodeGen/ARM/dyn-stackalloc.ll
+++ b/test/CodeGen/ARM/dyn-stackalloc.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=thumb &&
-; RUN: llvm-as < %s | llc -march=thumb | not grep "ldr sp" &&
-; RUN: llvm-as < %s | llc -mtriple=thumb-apple-darwin | not grep "sub.*r7" &&
+; RUN: llvm-as < %s | llc -march=arm
+; RUN: llvm-as < %s | llc -march=thumb | not grep {ldr sp}
+; RUN: llvm-as < %s | llc -mtriple=thumb-apple-darwin | \
+; RUN: not grep {sub.*r7}
; RUN: llvm-as < %s | llc -march=thumb | grep 4294967280
%struct.state = type { i32, %struct.info*, float**, i32, i32, i32, i32, i32, i32, i32, i32, i32, i64, i64, i64, i64, i64, i64, i8* }
diff --git a/test/CodeGen/ARM/fcopysign.ll b/test/CodeGen/ARM/fcopysign.ll
index b384f36a5c1..e24a5d8f0c2 100644
--- a/test/CodeGen/ARM/fcopysign.ll
+++ b/test/CodeGen/ARM/fcopysign.ll
@@ -1,7 +1,6 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep bic | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -march=arm -mattr=+v6,+vfp2 &&
-; RUN: llvm-as < %s | llc -march=arm -mattr=+v6,+vfp2 | grep fneg | wc -l | grep 2
+; RUN: llvm-as < %s | llc -march=arm | grep bic | wc -l | grep 2
+; RUN: llvm-as < %s | llc -march=arm -mattr=+v6,+vfp2 | \
+; RUN: grep fneg | wc -l | grep 2
define float @test1(float %x, double %y) {
%tmp = fpext float %x to double
diff --git a/test/CodeGen/ARM/fp.ll b/test/CodeGen/ARM/fp.ll
index b235fb215b7..78b819e9e0e 100644
--- a/test/CodeGen/ARM/fp.ll
+++ b/test/CodeGen/ARM/fp.ll
@@ -1,21 +1,15 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fmsr | wc -l | grep 4
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fsitos
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fmrs
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fsitod
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fmrrd | wc -l | grep 5
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fmdrr | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fldd
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep flds
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fuitod
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fuitos
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep 1065353216
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 > %t
+; RUN: grep fmsr %t | wc -l | grep 4
+; RUN: grep fsitos %t
+; RUN: grep fmrs %t
+; RUN: grep fsitod %t
+; RUN: grep fmrrd %t | wc -l | grep 5
+; RUN: grep fmdrr %t | wc -l | grep 2
+; RUN: grep fldd %t
+; RUN: grep flds %t
+; RUN: grep fuitod %t
+; RUN: grep fuitos %t
+; RUN: grep 1065353216 %t
float %f(int %a) {
entry:
diff --git a/test/CodeGen/ARM/fparith.ll b/test/CodeGen/ARM/fparith.ll
index 1ccf6a5ffc9..0e503a683fb 100644
--- a/test/CodeGen/ARM/fparith.ll
+++ b/test/CodeGen/ARM/fparith.ll
@@ -1,13 +1,12 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fadds &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep faddd &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fmuls &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fmuld &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fnegs &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fnegd &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fdivs &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fdivd
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 > %t
+; RUN: grep fadds %t
+; RUN: grep faddd %t
+; RUN: grep fmuls %t
+; RUN: grep fmuld %t
+; RUN: grep fnegs %t
+; RUN: grep fnegd %t
+; RUN: grep fdivs %t
+; RUN: grep fdivd %t
float %f1(float %a, float %b) {
diff --git a/test/CodeGen/ARM/fpcmp.ll b/test/CodeGen/ARM/fpcmp.ll
index 0ec7f168b46..adee88cccce 100644
--- a/test/CodeGen/ARM/fpcmp.ll
+++ b/test/CodeGen/ARM/fpcmp.ll
@@ -1,11 +1,11 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep movmi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep moveq &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep movgt &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep movge &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep movne &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fcmped | wc -l | grep 1
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fcmpes | wc -l | grep 6
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 > %t
+; RUN: grep movmi %t
+; RUN: grep moveq %t
+; RUN: grep movgt %t
+; RUN: grep movge %t
+; RUN: grep movne %t
+; RUN: grep fcmped %t | wc -l | grep 1
+; RUN: grep fcmpes %t | wc -l | grep 6
int %f1(float %a) {
entry:
diff --git a/test/CodeGen/ARM/fpcmp_ueq.ll b/test/CodeGen/ARM/fpcmp_ueq.ll
index 3ff824a097d..3e749afb400 100644
--- a/test/CodeGen/ARM/fpcmp_ueq.ll
+++ b/test/CodeGen/ARM/fpcmp_ueq.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep moveq &&
+; RUN: llvm-as < %s | llc -march=arm | grep moveq
; RUN: llvm-as < %s | llc -march=arm -mattr=+vfp2 | grep movvs
define i32 @f7(float %a, float %b) {
diff --git a/test/CodeGen/ARM/fpconv.ll b/test/CodeGen/ARM/fpconv.ll
index ba3976f3543..06e80696701 100644
--- a/test/CodeGen/ARM/fpconv.ll
+++ b/test/CodeGen/ARM/fpconv.ll
@@ -1,14 +1,14 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fcvtsd &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fcvtds &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep ftosizs &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep ftouizs &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep ftosizd &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep ftouizd &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fsitos &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fsitod &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fuitos &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep fuitod
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 > %t
+; RUN: grep fcvtsd %t
+; RUN: grep fcvtds %t
+; RUN: grep ftosizs %t
+; RUN: grep ftouizs %t
+; RUN: grep ftosizd %t
+; RUN: grep ftouizd %t
+; RUN: grep fsitos %t
+; RUN: grep fsitod %t
+; RUN: grep fuitos %t
+; RUN: grep fuitod %t
float %f1(double %x) {
entry:
diff --git a/test/CodeGen/ARM/fpmem.ll b/test/CodeGen/ARM/fpmem.ll
index 151fc99f78f..6e35138c016 100644
--- a/test/CodeGen/ARM/fpmem.ll
+++ b/test/CodeGen/ARM/fpmem.ll
@@ -1,7 +1,9 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #0" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep "flds.*\[" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | grep "fsts.*\[" | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {mov r0, #0} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
+; RUN: grep {flds.*\\\[} | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
+; RUN: grep {fsts.*\\\[} | wc -l | grep 1
float %f1(float %a) {
entry:
diff --git a/test/CodeGen/ARM/hello.ll b/test/CodeGen/ARM/hello.ll
index a46532e91a2..d49480019c7 100644
--- a/test/CodeGen/ARM/hello.ll
+++ b/test/CodeGen/ARM/hello.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-as < %s | llc -march=arm &&
+; RUN: llvm-as < %s | llc -march=arm
; RUN: llvm-as < %s | llc -mtriple=arm-linux-gnueabi | grep mov | wc -l | grep 1
-; RUN: llvm-as < %s | llc -mtriple=arm-linux-gnu --disable-fp-elim | grep mov \
-; RUN: | wc -l | grep 3
+; RUN: llvm-as < %s | llc -mtriple=arm-linux-gnu --disable-fp-elim | \
+; RUN: grep mov | wc -l | grep 3
; RUN: llvm-as < %s | llc -mtriple=arm-apple-darwin | grep mov | wc -l | grep 2
@str = internal constant [12 x i8] c"Hello World\00"
diff --git a/test/CodeGen/ARM/imm.ll b/test/CodeGen/ARM/imm.ll
index 0a645d3cac0..31db7a39e9c 100644
--- a/test/CodeGen/ARM/imm.ll
+++ b/test/CodeGen/ARM/imm.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | not grep CPI
int %test1(int %A) {
diff --git a/test/CodeGen/ARM/insn-sched1.ll b/test/CodeGen/ARM/insn-sched1.ll
index 7145351da07..6dc4650cf05 100644
--- a/test/CodeGen/ARM/insn-sched1.ll
+++ b/test/CodeGen/ARM/insn-sched1.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-apple-darwin -mattr=+v6 | grep mov | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6
+; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-apple-darwin -mattr=+v6 |\
+; RUN: grep mov | wc -l | grep 3
int %test(int %x) {
%tmp = cast int %x to short
diff --git a/test/CodeGen/ARM/ldm.ll b/test/CodeGen/ARM/ldm.ll
index bef0687795f..b69e04ddf07 100644
--- a/test/CodeGen/ARM/ldm.ll
+++ b/test/CodeGen/ARM/ldm.ll
@@ -1,7 +1,9 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "ldmia" | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "ldmib" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-apple-darwin | grep "ldmfd sp\!" | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep ldmia | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep ldmib | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-apple-darwin | \
+; RUN: grep {ldmfd sp\!} | wc -l | grep 3
%X = external global [0 x int]
diff --git a/test/CodeGen/ARM/ldr_ext.ll b/test/CodeGen/ARM/ldr_ext.ll
index d1be62cef8a..2b50b30aa72 100644
--- a/test/CodeGen/ARM/ldr_ext.ll
+++ b/test/CodeGen/ARM/ldr_ext.ll
@@ -1,12 +1,11 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep "ldrb" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep "ldrh" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep "ldrsb" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep "ldrsh" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=thumb | grep "ldrb" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=thumb | grep "ldrh" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=thumb | grep "ldrsb" | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=thumb | grep "ldrsh" | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=arm | grep ldrb | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=arm | grep ldrh | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=arm | grep ldrsb | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=arm | grep ldrsh | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=thumb | grep ldrb | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=thumb | grep ldrh | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=thumb | grep ldrsb | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=thumb | grep ldrsh | wc -l | grep 1
define i32 @test1(i8* %v.pntr.s0.u1) {
%tmp.u = load i8* %v.pntr.s0.u1
diff --git a/test/CodeGen/ARM/ldr_frame.ll b/test/CodeGen/ARM/ldr_frame.ll
index 597c02e3fc8..1fd6ed37c40 100644
--- a/test/CodeGen/ARM/ldr_frame.ll
+++ b/test/CodeGen/ARM/ldr_frame.ll
@@ -1,6 +1,4 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | not grep mov &&
-; RUN: llvm-as < %s | llc -march=thumb &&
+; RUN: llvm-as < %s | llc -march=arm | not grep mov
; RUN: llvm-as < %s | llc -march=thumb | grep cpy | wc -l | grep 2
define i32 @f1() {
diff --git a/test/CodeGen/ARM/ldr_pre.ll b/test/CodeGen/ARM/ldr_pre.ll
index bd273bc5aed..e9af1c90db9 100644
--- a/test/CodeGen/ARM/ldr_pre.ll
+++ b/test/CodeGen/ARM/ldr_pre.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "ldr.*\!" | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
+; RUN: grep {ldr.*\\!} | wc -l | grep 2
int *%test1(int *%X, int *%dest) {
%Y = getelementptr int* %X, int 4
diff --git a/test/CodeGen/ARM/load.ll b/test/CodeGen/ARM/load.ll
index 68d193b78f6..f3d6cf6f7ea 100644
--- a/test/CodeGen/ARM/load.ll
+++ b/test/CodeGen/ARM/load.ll
@@ -1,8 +1,8 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep ldrsb &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep ldrb &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep ldrsh &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep ldrh
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm > %t
+; RUN: grep ldrsb %t
+; RUN: grep ldrb %t
+; RUN: grep ldrsh %t
+; RUN: grep ldrh %t
int %f1(sbyte* %p) {
entry:
diff --git a/test/CodeGen/ARM/long-setcc.ll b/test/CodeGen/ARM/long-setcc.ll
index f5076e0289d..9111ab388ee 100644
--- a/test/CodeGen/ARM/long-setcc.ll
+++ b/test/CodeGen/ARM/long-setcc.ll
@@ -1,6 +1,4 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep cmp | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=thumb &&
+; RUN: llvm-as < %s | llc -march=arm | grep cmp | wc -l | grep 1
; RUN: llvm-as < %s | llc -march=thumb | grep cmp | wc -l | grep 1
diff --git a/test/CodeGen/ARM/long_shift.ll b/test/CodeGen/ARM/long_shift.ll
index b599a36808e..b0a3ee83ab8 100644
--- a/test/CodeGen/ARM/long_shift.ll
+++ b/test/CodeGen/ARM/long_shift.ll
@@ -1,9 +1,9 @@
-; RUN: llvm-as < %s | llc -march=arm &&
-; RUN: llvm-as < %s | llc -march=arm | grep rrx | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=arm | grep __ashldi3 &&
-; RUN: llvm-as < %s | llc -march=arm | grep __ashrdi3 &&
-; RUN: llvm-as < %s | llc -march=arm | grep __lshrdi3 &&
; RUN: llvm-as < %s | llc -march=thumb
+; RUN: llvm-as < %s | llc -march=arm > %t
+; RUN: grep rrx %t | wc -l | grep 1
+; RUN: grep __ashldi3 %t
+; RUN: grep __ashrdi3 %t
+; RUN: grep __lshrdi3 %t
define i64 @f0(i64 %A, i64 %B) {
%tmp = bitcast i64 %A to i64
diff --git a/test/CodeGen/ARM/pack.ll b/test/CodeGen/ARM/pack.ll
index 680f55e5e96..8cd392bcb82 100644
--- a/test/CodeGen/ARM/pack.ll
+++ b/test/CodeGen/ARM/pack.ll
@@ -1,5 +1,5 @@
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6 | \
-; RUN: grep pkhbt | wc -l | grep 5 &&
+; RUN: grep pkhbt | wc -l | grep 5
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+v6 | \
; RUN: grep pkhtb | wc -l | grep 4
; END.
diff --git a/test/CodeGen/ARM/section.ll b/test/CodeGen/ARM/section.ll
index e863acd2b62..fcb86c542a0 100644
--- a/test/CodeGen/ARM/section.ll
+++ b/test/CodeGen/ARM/section.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-linux
; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-linux | \
; RUN: grep {__DTOR_END__:}
; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=arm-linux | \
diff --git a/test/CodeGen/ARM/vfp.ll b/test/CodeGen/ARM/vfp.ll
index 49c484adf80..b2a6d707774 100644
--- a/test/CodeGen/ARM/vfp.ll
+++ b/test/CodeGen/ARM/vfp.ll
@@ -7,7 +7,7 @@
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
; RUN: grep fuito | wc -l | grep 2
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
-; RUN: grep fto.i | wc -l | grep 4 &&
+; RUN: grep fto.i | wc -l | grep 4
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
; RUN: grep bmi | wc -l | grep 1
; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -mattr=+vfp2 | \
diff --git a/test/CodeGen/Alpha/weak.ll b/test/CodeGen/Alpha/weak.ll
index f39360b8fc0..aefaefd110a 100644
--- a/test/CodeGen/Alpha/weak.ll
+++ b/test/CodeGen/Alpha/weak.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=alpha &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=alpha | grep .weak.*f &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=alpha | grep .weak.*f
; RUN: llvm-upgrade < %s | llvm-as | llc -march=alpha | grep .weak.*h
implementation ; Functions:
diff --git a/test/CodeGen/Generic/2006-07-03-schedulers.ll b/test/CodeGen/Generic/2006-07-03-schedulers.ll
index 7120c1ff409..70fc0731298 100644
--- a/test/CodeGen/Generic/2006-07-03-schedulers.ll
+++ b/test/CodeGen/Generic/2006-07-03-schedulers.ll
@@ -1,9 +1,9 @@
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=none &&
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=default &&
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=simple &&
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=simple-noitin &&
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=list-td &&
-; RUN: llvm-upgrade %s | llvm-as | llc -sched=list-tdrr &&
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=none
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=default
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=simple
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=simple-noitin
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=list-td
+; RUN: llvm-upgrade %s | llvm-as | llc -sched=list-tdrr
; RUN: llvm-upgrade %s | llvm-as | llc -sched=list-burr
; PR859
diff --git a/test/CodeGen/Generic/2006-11-06-MemIntrinsicExpand.ll b/test/CodeGen/Generic/2006-11-06-MemIntrinsicExpand.ll
index d7ef1db6353..330bee66314 100644
--- a/test/CodeGen/Generic/2006-11-06-MemIntrinsicExpand.ll
+++ b/test/CodeGen/Generic/2006-11-06-MemIntrinsicExpand.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep adc
; PR987
diff --git a/test/CodeGen/Generic/2007-04-14-BitTestsBadMask.ll b/test/CodeGen/Generic/2007-04-14-BitTestsBadMask.ll
index 0f5688db372..94b437c12f0 100644
--- a/test/CodeGen/Generic/2007-04-14-BitTestsBadMask.ll
+++ b/test/CodeGen/Generic/2007-04-14-BitTestsBadMask.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=x86 | grep 8388635 &&
+; RUN: llvm-as < %s | llc -march=x86 | grep 8388635
; RUN: llvm-as < %s | llc -march=x86-64 | grep 4294981120
; PR 1325
diff --git a/test/CodeGen/Generic/fpowi-promote.ll b/test/CodeGen/Generic/fpowi-promote.ll
index 118bd68cf39..55c2d2ad0c6 100644
--- a/test/CodeGen/Generic/fpowi-promote.ll
+++ b/test/CodeGen/Generic/fpowi-promote.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc &&
+; RUN: llvm-as < %s | llc
; RUN: llvm-as < %s | llc -march=x86 -mcpu=i386
; PR1239
diff --git a/test/CodeGen/Generic/switch-lower-feature-2.ll b/test/CodeGen/Generic/switch-lower-feature-2.ll
index 1edd47f83e5..6552cb1b34e 100644
--- a/test/CodeGen/Generic/switch-lower-feature-2.ll
+++ b/test/CodeGen/Generic/switch-lower-feature-2.ll
@@ -1,12 +1,13 @@
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep jb | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep \$6 | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep 1024 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep 1023 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep 119 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep JTI | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep jg | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep ja | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep js | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=x86 -o %t -f
+; RUN: grep jb %t | wc -l | grep 1
+; RUN: grep \\\$6 %t | wc -l | grep 2
+; RUN: grep 1024 %t | wc -l | grep 1
+; RUN: grep 1023 %t | wc -l | grep 1
+; RUN: grep 119 %t | wc -l | grep 1
+; RUN: grep JTI %t | wc -l | grep 2
+; RUN: grep jg %t | wc -l | grep 1
+; RUN: grep ja %t | wc -l | grep 1
+; RUN: grep js %t | wc -l | grep 1
target triple = "i686-pc-linux-gnu"
diff --git a/test/CodeGen/Generic/switch-lower-feature.ll b/test/CodeGen/Generic/switch-lower-feature.ll
index 195d2167138..71dbc26b8f2 100644
--- a/test/CodeGen/Generic/switch-lower-feature.ll
+++ b/test/CodeGen/Generic/switch-lower-feature.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep \$7 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep \$6 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep 1024 | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 -o - | grep jb | wc -l | grep 2 &&
+; RUN: llvm-as < %s | llc -march=x86 -o - | grep \$7 | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=x86 -o - | grep \$6 | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=x86 -o - | grep 1024 | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=x86 -o - | grep jb | wc -l | grep 2
; RUN: llvm-as < %s | llc -march=x86 -o - | grep je | wc -l | grep 1
define i32 @main(i32 %tmp158) {
diff --git a/test/CodeGen/Generic/vector-identity-shuffle.ll b/test/CodeGen/Generic/vector-identity-shuffle.ll
index 5b3de3fe765..9cccf4b381f 100644
--- a/test/CodeGen/Generic/vector-identity-shuffle.ll
+++ b/test/CodeGen/Generic/vector-identity-shuffle.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep test: &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep vperm &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep test:
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep vperm
; RUN: llvm-upgrade < %s | llvm-as | llc
void %test(<4 x float> *%tmp2.i) {
diff --git a/test/CodeGen/Generic/vector.ll b/test/CodeGen/Generic/vector.ll
index 207c51dc431..018ba6aab29 100644
--- a/test/CodeGen/Generic/vector.ll
+++ b/test/CodeGen/Generic/vector.ll
@@ -1,9 +1,9 @@
; Test that vectors are scalarized/lowered correctly.
-; RUN: llvm-upgrade < %s | llvm-as | llc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple a-b-c &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=i386 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc
+; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple a-b-c
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=i386
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah
%f1 = type <1 x float>
diff --git a/test/CodeGen/PowerPC/2006-08-11-RetVector.ll b/test/CodeGen/PowerPC/2006-08-11-RetVector.ll
index ab9ef35a0f1..cf0cd2c8be3 100644
--- a/test/CodeGen/PowerPC/2006-08-11-RetVector.ll
+++ b/test/CodeGen/PowerPC/2006-08-11-RetVector.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vsldoi &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vsldoi
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep vor
<4 x float> %func(<4 x float> %fp0, <4 x float> %fp1) {
diff --git a/test/CodeGen/PowerPC/2006-10-13-Miscompile.ll b/test/CodeGen/PowerPC/2006-10-13-Miscompile.ll
index 162cbdb1d37..95b5312e4c2 100644
--- a/test/CodeGen/PowerPC/2006-10-13-Miscompile.ll
+++ b/test/CodeGen/PowerPC/2006-10-13-Miscompile.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep IMPLICIT_DEF
void %foo(long %X) {
diff --git a/test/CodeGen/PowerPC/2006-12-07-LargeAlloca.ll b/test/CodeGen/PowerPC/2006-12-07-LargeAlloca.ll
index 8816ca003c9..f6103e5b6aa 100644
--- a/test/CodeGen/PowerPC/2006-12-07-LargeAlloca.ll
+++ b/test/CodeGen/PowerPC/2006-12-07-LargeAlloca.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32
; RUN: llvm-upgrade < %s | llvm-as | llc
void %bitap() {
diff --git a/test/CodeGen/PowerPC/2006-12-07-SelectCrash.ll b/test/CodeGen/PowerPC/2006-12-07-SelectCrash.ll
index 8c81db19a9e..6fa410e6fa5 100644
--- a/test/CodeGen/PowerPC/2006-12-07-SelectCrash.ll
+++ b/test/CodeGen/PowerPC/2006-12-07-SelectCrash.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32
; RUN: llvm-upgrade < %s | llvm-as | llc
%qsz.b = external global bool ; <bool*> [#uses=1]
diff --git a/test/CodeGen/PowerPC/2007-01-04-ArgExtension.ll b/test/CodeGen/PowerPC/2007-01-04-ArgExtension.ll
index a1dfc12b53e..19fedf9f596 100644
--- a/test/CodeGen/PowerPC/2007-01-04-ArgExtension.ll
+++ b/test/CodeGen/PowerPC/2007-01-04-ArgExtension.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=ppc32 | grep extsb &&
+; RUN: llvm-as < %s | llc -march=ppc32 | grep extsb
; RUN: llvm-as < %s | llc -march=ppc32 | grep extsh
define i32 @p1(i8 %c, i16 %s) {
diff --git a/test/CodeGen/PowerPC/2007-01-29-lbrx-asm.ll b/test/CodeGen/PowerPC/2007-01-29-lbrx-asm.ll
index f39e62a65ed..f2c951ec21d 100644
--- a/test/CodeGen/PowerPC/2007-01-29-lbrx-asm.ll
+++ b/test/CodeGen/PowerPC/2007-01-29-lbrx-asm.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=ppc32 &&
+; RUN: llvm-as < %s | llc -march=ppc32
; RUN: llvm-as < %s | llc -march=ppc64
define i16 @test(i8* %d1, i16* %d2) {
diff --git a/test/CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll b/test/CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll
index c4d57639872..d4764622af6 100644
--- a/test/CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll
+++ b/test/CodeGen/PowerPC/2007-01-31-InlineAsmAddrMode.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=ppc32 &&
+; RUN: llvm-as < %s | llc -march=ppc32
; RUN: llvm-as < %s | llc -march=ppc64
; Test two things: 1) that a frameidx can be rewritten in an inline asm
diff --git a/test/CodeGen/PowerPC/addc.ll b/test/CodeGen/PowerPC/addc.ll
index 25f38547cc2..b268389d1cc 100644
--- a/test/CodeGen/PowerPC/addc.ll
+++ b/test/CodeGen/PowerPC/addc.ll
@@ -1,9 +1,10 @@
; All of these should be codegen'd without loading immediates
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep addc | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep adde | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep addze | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep addme | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep addic | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: grep addc %t | wc -l | grep 1
+; RUN: grep adde %t | wc -l | grep 1
+; RUN: grep addze %t | wc -l | grep 1
+; RUN: grep addme %t | wc -l | grep 1
+; RUN: grep addic %t | wc -l | grep 2
implementation ; Functions:
diff --git a/test/CodeGen/PowerPC/addi-reassoc.ll b/test/CodeGen/PowerPC/addi-reassoc.ll
index 7cfbd8653f5..753f628c11d 100644
--- a/test/CodeGen/PowerPC/addi-reassoc.ll
+++ b/test/CodeGen/PowerPC/addi-reassoc.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep addi
%struct.X = type { [5 x sbyte] }
diff --git a/test/CodeGen/PowerPC/align.ll b/test/CodeGen/PowerPC/align.ll
index e74b6091686..caf4a5d6581 100644
--- a/test/CodeGen/PowerPC/align.ll
+++ b/test/CodeGen/PowerPC/align.ll
@@ -1,6 +1,9 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep "align.4" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep "align.2" | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep "align.3" | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep align.4 | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep align.2 | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep align.3 | wc -l | grep 1
%A = global <4 x uint> < uint 10, uint 20, uint 30, uint 40 >
diff --git a/test/CodeGen/PowerPC/and-branch.ll b/test/CodeGen/PowerPC/and-branch.ll
index ef53d6c314e..4b0e7fa86e6 100644
--- a/test/CodeGen/PowerPC/and-branch.ll
+++ b/test/CodeGen/PowerPC/and-branch.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep mfcr
void %foo(int %X, int %Y, int %Z) {
diff --git a/test/CodeGen/PowerPC/and-elim.ll b/test/CodeGen/PowerPC/and-elim.ll
index 958f1552513..f85b3d82b71 100644
--- a/test/CodeGen/PowerPC/and-elim.ll
+++ b/test/CodeGen/PowerPC/and-elim.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-as < %s | llc -march=ppc32 &&
; RUN: llvm-as < %s | llc -march=ppc32 | not grep rlwin
define void @test(i8* %P) {
diff --git a/test/CodeGen/PowerPC/and_add.ll b/test/CodeGen/PowerPC/and_add.ll
index dc82fc94402..1f6428a4300 100644
--- a/test/CodeGen/PowerPC/and_add.ll
+++ b/test/CodeGen/PowerPC/and_add.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep slwi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep addi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep rlwinm
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: grep slwi %t
+; RUN: not grep addi %t
+; RUN: not grep rlwinm %t
int %test(int %A) {
%B = mul int %A, 8 ;; shift
diff --git a/test/CodeGen/PowerPC/and_sext.ll b/test/CodeGen/PowerPC/and_sext.ll
index 84037e75907..ac277980bd4 100644
--- a/test/CodeGen/PowerPC/and_sext.ll
+++ b/test/CodeGen/PowerPC/and_sext.ll
@@ -1,6 +1,5 @@
; These tests should not contain a sign extend.
-; RUN: llvm-as < %s | llc -march=ppc32 &&
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep extsh &&
+; RUN: llvm-as < %s | llc -march=ppc32 | not grep extsh
; RUN: llvm-as < %s | llc -march=ppc32 | not grep extsb
define i32 @test1(i32 %mode.0.i.0) {
diff --git a/test/CodeGen/PowerPC/buildvec_canonicalize.ll b/test/CodeGen/PowerPC/buildvec_canonicalize.ll
index 6e41a59ceef..54cbdae9148 100644
--- a/test/CodeGen/PowerPC/buildvec_canonicalize.ll
+++ b/test/CodeGen/PowerPC/buildvec_canonicalize.ll
@@ -1,8 +1,12 @@
; There should be exactly one vxor here.
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 --enable-unsafe-fp-math | grep vxor | wc -l | grep 1 &&
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=ppc32 -mcpu=g5 --enable-unsafe-fp-math | \
+; RUN: grep vxor | wc -l | grep 1
; There should be exactly one vsplti here.
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 --enable-unsafe-fp-math | grep vsplti | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=ppc32 -mcpu=g5 --enable-unsafe-fp-math | \
+; RUN: grep vsplti | wc -l | grep 1
void %VXOR(<4 x float>* %P1, <4 x int>* %P2, <4 x float>* %P3) {
diff --git a/test/CodeGen/PowerPC/cmp-cmp.ll b/test/CodeGen/PowerPC/cmp-cmp.ll
index d505736005c..6dbe484a0fe 100644
--- a/test/CodeGen/PowerPC/cmp-cmp.ll
+++ b/test/CodeGen/PowerPC/cmp-cmp.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep mfcr
void %test(long %X) {
diff --git a/test/CodeGen/PowerPC/div-2.ll b/test/CodeGen/PowerPC/div-2.ll
index d89361820ab..a3cd73cbda1 100644
--- a/test/CodeGen/PowerPC/div-2.ll
+++ b/test/CodeGen/PowerPC/div-2.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep srawi &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep srawi
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep blr
int %test1(int %X) {
diff --git a/test/CodeGen/PowerPC/eqv-andc-orc-nor.ll b/test/CodeGen/PowerPC/eqv-andc-orc-nor.ll
index a2ab4e1a81a..359824c7ead 100644
--- a/test/CodeGen/PowerPC/eqv-andc-orc-nor.ll
+++ b/test/CodeGen/PowerPC/eqv-andc-orc-nor.ll
@@ -1,8 +1,13 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep eqv | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep andc | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep orc | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep nor | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep nand | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep eqv | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | \
+; RUN: grep andc | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep orc | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | \
+; RUN: grep nor | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep nand | wc -l | grep 1
int %EQV1(int %X, int %Y) {
%A = xor int %X, %Y
diff --git a/test/CodeGen/PowerPC/fold-li.ll b/test/CodeGen/PowerPC/fold-li.ll
index d3647753bc3..66a900faf06 100644
--- a/test/CodeGen/PowerPC/fold-li.ll
+++ b/test/CodeGen/PowerPC/fold-li.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep -v align | not grep li
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | \
+; RUN: grep -v align | not grep li
;; Test that immediates are folded into these instructions correctly.
diff --git a/test/CodeGen/PowerPC/fp-int-fp.ll b/test/CodeGen/PowerPC/fp-int-fp.ll
index bcea406ab71..63ebc494eb8 100644
--- a/test/CodeGen/PowerPC/fp-int-fp.ll
+++ b/test/CodeGen/PowerPC/fp-int-fp.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep r1
double %test1(double %X) {
diff --git a/test/CodeGen/PowerPC/fpcopy.ll b/test/CodeGen/PowerPC/fpcopy.ll
index 43087bd56dc..ce86da824bc 100644
--- a/test/CodeGen/PowerPC/fpcopy.ll
+++ b/test/CodeGen/PowerPC/fpcopy.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep fmr
double %test(float %F) {
diff --git a/test/CodeGen/PowerPC/inlineasm-copy.ll b/test/CodeGen/PowerPC/inlineasm-copy.ll
index 8b6aa3331a4..34594d2ff23 100644
--- a/test/CodeGen/PowerPC/inlineasm-copy.ll
+++ b/test/CodeGen/PowerPC/inlineasm-copy.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep mr
int %test(int %Y, int %X) {
diff --git a/test/CodeGen/PowerPC/inverted-bool-compares.ll b/test/CodeGen/PowerPC/inverted-bool-compares.ll
index 6c5c288a2bc..fbbf6a59e8f 100644
--- a/test/CodeGen/PowerPC/inverted-bool-compares.ll
+++ b/test/CodeGen/PowerPC/inverted-bool-compares.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep xori &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep xori
int %test(bool %B, int* %P) {
br bool %B, label %T, label %F
diff --git a/test/CodeGen/PowerPC/load-constant-addr.ll b/test/CodeGen/PowerPC/load-constant-addr.ll
index d7e3d454e4e..65ec78279eb 100644
--- a/test/CodeGen/PowerPC/load-constant-addr.ll
+++ b/test/CodeGen/PowerPC/load-constant-addr.ll
@@ -1,5 +1,5 @@
; Should fold the ori into the lfs.
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep lfs &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep lfs
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep ori
float %test() {
diff --git a/test/CodeGen/PowerPC/mem_update.ll b/test/CodeGen/PowerPC/mem_update.ll
index 2a8f83fbd36..4d3ebe96c2d 100644
--- a/test/CodeGen/PowerPC/mem_update.ll
+++ b/test/CodeGen/PowerPC/mem_update.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -enable-ppc-preinc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -enable-ppc-preinc | not grep addi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64 -enable-ppc-preinc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64 -enable-ppc-preinc | not grep addi
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -enable-ppc-preinc | \
+; RUN: not grep addi
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc64 -enable-ppc-preinc | \
+; RUN: not grep addi
%Glob = global ulong 4
int *%test0(int *%X, int *%dest) {
diff --git a/test/CodeGen/PowerPC/mul-neg-power-2.ll b/test/CodeGen/PowerPC/mul-neg-power-2.ll
index cb1f46c672d..b9be1cc4555 100644
--- a/test/CodeGen/PowerPC/mul-neg-power-2.ll
+++ b/test/CodeGen/PowerPC/mul-neg-power-2.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep mul
int %test1(int %a) {
diff --git a/test/CodeGen/PowerPC/mulhs.ll b/test/CodeGen/PowerPC/mulhs.ll
index e5e25e99f44..967905d9386 100644
--- a/test/CodeGen/PowerPC/mulhs.ll
+++ b/test/CodeGen/PowerPC/mulhs.ll
@@ -1,8 +1,9 @@
; All of these ands and shifts should be folded into rlwimi's
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep mulhwu &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep srawi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep add &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep mulhw | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: not grep mulhwu %t
+; RUN: not grep srawi %t
+; RUN: not grep add %t
+; RUN: grep mulhw %t | wc -l | grep 1
implementation ; Functions:
diff --git a/test/CodeGen/PowerPC/or-addressing-mode.ll b/test/CodeGen/PowerPC/or-addressing-mode.ll
index 9c1d949505a..7058fb2a45f 100644
--- a/test/CodeGen/PowerPC/or-addressing-mode.ll
+++ b/test/CodeGen/PowerPC/or-addressing-mode.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc | not grep ori &&
+; RUN: llvm-upgrade < %s | llvm-as | llc | not grep ori
; RUN: llvm-upgrade < %s | llvm-as | llc | not grep rlwimi
int %test1(sbyte* %P) { ;; or -> lwzx
diff --git a/test/CodeGen/PowerPC/reg-coalesce-simple.ll b/test/CodeGen/PowerPC/reg-coalesce-simple.ll
index 5f3049d221d..60e9458b3b3 100644
--- a/test/CodeGen/PowerPC/reg-coalesce-simple.ll
+++ b/test/CodeGen/PowerPC/reg-coalesce-simple.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep or
%struct.foo = type { int, int, [0 x ubyte] }
diff --git a/test/CodeGen/PowerPC/rlwimi.ll b/test/CodeGen/PowerPC/rlwimi.ll
index 3b5816b5a0e..92afcf91b3e 100644
--- a/test/CodeGen/PowerPC/rlwimi.ll
+++ b/test/CodeGen/PowerPC/rlwimi.ll
@@ -1,5 +1,5 @@
; All of these ands and shifts should be folded into rlwimi's
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep and &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep and
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep rlwimi | wc -l | grep 8
implementation ; Functions:
diff --git a/test/CodeGen/PowerPC/rlwimi2.ll b/test/CodeGen/PowerPC/rlwimi2.ll
index 966705dcffb..c264d2ef94d 100644
--- a/test/CodeGen/PowerPC/rlwimi2.ll
+++ b/test/CodeGen/PowerPC/rlwimi2.ll
@@ -1,7 +1,8 @@
; All of these ands and shifts should be folded into rlwimi's
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep rlwimi | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep srwi | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep slwi
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: grep rlwimi %t | wc -l | grep 3
+; RUN: grep srwi %t | wc -l | grep 1
+; RUN: not grep slwi %t
implementation ; Functions:
diff --git a/test/CodeGen/PowerPC/rlwinm.ll b/test/CodeGen/PowerPC/rlwinm.ll
index 45f26d77dd8..32e8f260682 100644
--- a/test/CodeGen/PowerPC/rlwinm.ll
+++ b/test/CodeGen/PowerPC/rlwinm.ll
@@ -1,9 +1,10 @@
; All of these ands and shifts should be folded into rlwimi's
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep and &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep srawi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep srwi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep slwi &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep rlwinm | wc -l | grep 8
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: not grep and %t
+; RUN: not grep srawi %t
+; RUN: not grep srwi %t
+; RUN: not grep slwi %t
+; RUN: grep rlwinm %t | wc -l | grep 8
implementation ; Functions:
diff --git a/test/CodeGen/PowerPC/rlwinm2.ll b/test/CodeGen/PowerPC/rlwinm2.ll
index e55da87591a..78127f1ff56 100644
--- a/test/CodeGen/PowerPC/rlwinm2.ll
+++ b/test/CodeGen/PowerPC/rlwinm2.ll
@@ -1,10 +1,11 @@
; All of these ands and shifts should be folded into rlw[i]nm instructions
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep and &&
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep srawi &&
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep srwi &&
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep slwi &&
-; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwnm | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwinm | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=ppc32 -o %t -f
+; RUN: not grep and %t
+; RUN: not grep srawi %t
+; RUN: not grep srwi %t
+; RUN: not grep slwi %t
+; RUN: grep rlwnm %t | wc -l | grep 1
+; RUN: grep rlwinm %t | wc -l | grep 1
define i32 @test1(i32 %X, i32 %Y) {
entry:
diff --git a/test/CodeGen/PowerPC/rotl-2.ll b/test/CodeGen/PowerPC/rotl-2.ll
index 0512357584f..523b5e4c4ae 100644
--- a/test/CodeGen/PowerPC/rotl-2.ll
+++ b/test/CodeGen/PowerPC/rotl-2.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwinm | wc -l | grep 4 &&
-; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwnm | wc -l | grep 2 &&
+; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwinm | wc -l | grep 4
+; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwnm | wc -l | grep 2
; RUN: llvm-as < %s | llc -march=ppc32 | not grep or
define i32 @rotl32(i32 %A, i8 %Amt) {
diff --git a/test/CodeGen/PowerPC/rotl.ll b/test/CodeGen/PowerPC/rotl.ll
index a000ec0b318..aa033cfc455 100644
--- a/test/CodeGen/PowerPC/rotl.ll
+++ b/test/CodeGen/PowerPC/rotl.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-as < %s | llc -march=ppc32 | not grep or &&
-; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwnm | wc -l | grep 2 &&
+; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwnm | wc -l | grep 2
; RUN: llvm-as < %s | llc -march=ppc32 | grep rlwinm | wc -l | grep 2
define i32 @rotlw(i32 %x, i32 %sh) {
diff --git a/test/CodeGen/PowerPC/stfiwx.ll b/test/CodeGen/PowerPC/stfiwx.ll
index 6d15787471d..2eebc070646 100644
--- a/test/CodeGen/PowerPC/stfiwx.ll
+++ b/test/CodeGen/PowerPC/stfiwx.ll
@@ -1,7 +1,12 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=stfiwx | grep stfiwx &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=stfiwx | not grep r1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=-stfiwx | not grep stfiwx &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=-stfiwx | grep r1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=stfiwx -o %t1 -f
+; RUN: grep stfiwx %t1
+; RUN: not grep r1 %t1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=ppc32 -mtriple=powerpc-apple-darwin8 -mattr=-stfiwx \
+; RUN: -o %t2 -f
+; RUN: not grep stfiwx %t2
+; RUN: grep r1 %t2
void %test(float %a, int* %b) {
%tmp.2 = cast float %a to int
diff --git a/test/CodeGen/PowerPC/store-load-fwd.ll b/test/CodeGen/PowerPC/store-load-fwd.ll
index d4a8a543d19..761fb5a318d 100644
--- a/test/CodeGen/PowerPC/store-load-fwd.ll
+++ b/test/CodeGen/PowerPC/store-load-fwd.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | not grep lwz
int %test(int* %P) {
store int 1, int* %P
diff --git a/test/CodeGen/PowerPC/subc.ll b/test/CodeGen/PowerPC/subc.ll
index 36e1c0a3703..36247912f5d 100644
--- a/test/CodeGen/PowerPC/subc.ll
+++ b/test/CodeGen/PowerPC/subc.ll
@@ -1,9 +1,10 @@
; All of these should be codegen'd without loading immediates
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep subfc | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep subfe | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep subfze | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep subfme | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 | grep subfic | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -o %t -f
+; RUN: grep subfc %t | wc -l | grep 1
+; RUN: grep subfe %t | wc -l | grep 1
+; RUN: grep subfze %t | wc -l | grep 1
+; RUN: grep subfme %t | wc -l | grep 1
+; RUN: grep subfic %t | wc -l | grep 2
implementation ; Functions:
long %sub_ll(long %a, long %b) {
diff --git a/test/CodeGen/PowerPC/unsafe-math.ll b/test/CodeGen/PowerPC/unsafe-math.ll
index 583c5421928..770dcb6862f 100644
--- a/test/CodeGen/PowerPC/unsafe-math.ll
+++ b/test/CodeGen/PowerPC/unsafe-math.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-as < %s | llc -march=ppc32 | grep fmul | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -march=ppc32 -enable-unsafe-fp-math | grep fmul | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=ppc32 | grep fmul | wc -l | grep 2
+; RUN: llvm-as < %s | llc -march=ppc32 -enable-unsafe-fp-math | \
+; RUN: grep fmul | wc -l | grep 1
define double @foo(double %X) {
%tmp1 = mul double %X, 1.23
diff --git a/test/CodeGen/PowerPC/vec_br_cmp.ll b/test/CodeGen/PowerPC/vec_br_cmp.ll
index 62a9552f080..bc60baea38e 100644
--- a/test/CodeGen/PowerPC/vec_br_cmp.ll
+++ b/test/CodeGen/PowerPC/vec_br_cmp.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vcmpeqfp. &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep mfcr
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 -o %t -f
+; RUN: grep vcmpeqfp. %t
+; RUN: not grep mfcr %t
; A predicate compare used immediately by a branch should not generate an mfcr.
diff --git a/test/CodeGen/PowerPC/vec_constants.ll b/test/CodeGen/PowerPC/vec_constants.ll
index 9d51e3c6821..507d2d98849 100644
--- a/test/CodeGen/PowerPC/vec_constants.ll
+++ b/test/CodeGen/PowerPC/vec_constants.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep CPI
diff --git a/test/CodeGen/PowerPC/vec_mul.ll b/test/CodeGen/PowerPC/vec_mul.ll
index 1f571f44867..eea1deff7c2 100644
--- a/test/CodeGen/PowerPC/vec_mul.ll
+++ b/test/CodeGen/PowerPC/vec_mul.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep mullw &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep mullw
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vmsumuhm
<4 x int> %test_v4i32(<4 x int>* %X, <4 x int>* %Y) {
diff --git a/test/CodeGen/PowerPC/vec_perf_shuffle.ll b/test/CodeGen/PowerPC/vec_perf_shuffle.ll
index 4f67f83f7e3..6177b5f4c68 100644
--- a/test/CodeGen/PowerPC/vec_perf_shuffle.ll
+++ b/test/CodeGen/PowerPC/vec_perf_shuffle.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep vperm
<4 x float> %test_uu72(<4 x float> *%P1, <4 x float> *%P2) {
diff --git a/test/CodeGen/PowerPC/vec_shuffle.ll b/test/CodeGen/PowerPC/vec_shuffle.ll
index 8e64aacb943..ba856ee98d4 100644
--- a/test/CodeGen/PowerPC/vec_shuffle.ll
+++ b/test/CodeGen/PowerPC/vec_shuffle.ll
@@ -1,9 +1,11 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llc -march=ppc32 -mcpu=g5 | not grep vperm &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vsldoi | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vmrgh | wc -l | grep 7 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vmrgl | wc -l | grep 6 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vpkuhum | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vpkuwum | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | \
+; RUN: llc -march=ppc32 -mcpu=g5 | not grep vperm
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 > %t
+; RUN: grep vsldoi %t | wc -l | grep 2
+; RUN: grep vmrgh %t | wc -l | grep 7
+; RUN: grep vmrgl %t | wc -l | grep 6
+; RUN: grep vpkuhum %t | wc -l | grep 1
+; RUN: grep vpkuwum %t | wc -l | grep 1
void %VSLDOI_xy(<8 x short>* %A, <8 x short>* %B) {
entry:
diff --git a/test/CodeGen/PowerPC/vec_spat.ll b/test/CodeGen/PowerPC/vec_spat.ll
index 6691995357b..15e29509270 100644
--- a/test/CodeGen/PowerPC/vec_spat.ll
+++ b/test/CodeGen/PowerPC/vec_spat.ll
@@ -1,8 +1,10 @@
; Test that vectors are scalarized/lowered correctly.
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vspltw | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g3 | grep stfs | wc -l | grep 4 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vsplti | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vsplth | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g3 | \
+; RUN: grep stfs | wc -l | grep 4
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 -o %t -f
+; RUN: grep vspltw %t | wc -l | grep 2
+; RUN: grep vsplti %t | wc -l | grep 3
+; RUN: grep vsplth %t | wc -l | grep 1
%f4 = type <4 x float>
%i4 = type <4 x int>
diff --git a/test/CodeGen/PowerPC/vec_vrsave.ll b/test/CodeGen/PowerPC/vec_vrsave.ll
index 936580aa798..63e3ebaf91c 100644
--- a/test/CodeGen/PowerPC/vec_vrsave.ll
+++ b/test/CodeGen/PowerPC/vec_vrsave.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | grep vrlw &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep spr &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 | not grep vrsave
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=ppc32 -mcpu=g5 -o %t -f
+; RUN: grep vrlw %t
+; RUN: not grep spr %t
+; RUN: not grep vrsave %t
<4 x int> %test_rol() {
ret <4 x int> < int -11534337, int -11534337, int -11534337, int -11534337 >
diff --git a/test/CodeGen/SPARC/ctpop.ll b/test/CodeGen/SPARC/ctpop.ll
index ea88bd2fbcd..55fa8c52edc 100644
--- a/test/CodeGen/SPARC/ctpop.ll
+++ b/test/CodeGen/SPARC/ctpop.ll
@@ -1,7 +1,9 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc -mattr=-v9 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc -mattr=v9 -enable-sparc-v9-insts &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc -mattr=-v9 | not grep popc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc -mattr=v9 -enable-sparc-v9-insts | grep popc
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=sparc -mattr=v9 -enable-sparc-v9-insts
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc -mattr=-v9 | \
+; RUN: not grep popc
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -march=sparc -mattr=v9 -enable-sparc-v9-insts | grep popc
declare uint %llvm.ctpop.i32(uint)
uint %test(uint %X) {
diff --git a/test/CodeGen/SPARC/xnor.ll b/test/CodeGen/SPARC/xnor.ll
index c3b8010595f..2365176964b 100644
--- a/test/CodeGen/SPARC/xnor.ll
+++ b/test/CodeGen/SPARC/xnor.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc | grep xnor | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=sparc | \
+; RUN: grep xnor | wc -l | grep 2
int %test1(int %X, int %Y) {
%A = xor int %X, %Y
diff --git a/test/CodeGen/X86/2006-10-19-SwitchUnnecessaryBranching.ll b/test/CodeGen/X86/2006-10-19-SwitchUnnecessaryBranching.ll
index 48c6a1a69e5..f0be2bb3171 100644
--- a/test/CodeGen/X86/2006-10-19-SwitchUnnecessaryBranching.ll
+++ b/test/CodeGen/X86/2006-10-19-SwitchUnnecessaryBranching.ll
@@ -1,4 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | %prcontext je 1 | grep "BB1_1:"
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | %prcontext je 1 | \
+; RUN: grep BB1_1:
%str = internal constant [14 x sbyte] c"Hello world!\0A\00" ; <[14 x sbyte]*> [#uses=1]
%str = internal constant [13 x sbyte] c"Blah world!\0A\00" ; <[13 x sbyte]*> [#uses=1]
diff --git a/test/CodeGen/X86/bitcast.ll b/test/CodeGen/X86/bitcast.ll
index d7c78edb62f..d8bc0695eb0 100644
--- a/test/CodeGen/X86/bitcast.ll
+++ b/test/CodeGen/X86/bitcast.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86-64
; PR1033
diff --git a/test/CodeGen/X86/bswap.ll b/test/CodeGen/X86/bswap.ll
index 79467e0838b..4749ea8f54d 100644
--- a/test/CodeGen/X86/bswap.ll
+++ b/test/CodeGen/X86/bswap.ll
@@ -1,6 +1,7 @@
; bswap should be constant folded when it is passed a constant argument
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep bswapl | wc -l | grep 3 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | \
+; RUN: grep bswapl | wc -l | grep 3
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep rolw | wc -l | grep 1
declare ushort %llvm.bswap.i16(ushort)
diff --git a/test/CodeGen/X86/cmp-test.ll b/test/CodeGen/X86/cmp-test.ll
index 7a7ec08d18b..78d8d8f3d8a 100644
--- a/test/CodeGen/X86/cmp-test.ll
+++ b/test/CodeGen/X86/cmp-test.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep cmp | wc -l | grep 1 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep cmp | wc -l | grep 1
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep test | wc -l | grep 1
int %f1(int %X, int* %y) {
diff --git a/test/CodeGen/X86/compare-add.ll b/test/CodeGen/X86/compare-add.ll
index 866e36b17d5..d3d7668a394 100644
--- a/test/CodeGen/X86/compare-add.ll
+++ b/test/CodeGen/X86/compare-add.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep add
bool %X(int %X) {
%Y = add int %X, 14
diff --git a/test/CodeGen/X86/compare_folding.llx b/test/CodeGen/X86/compare_folding.llx
index 652057e9bb7..631bc923122 100644
--- a/test/CodeGen/X86/compare_folding.llx
+++ b/test/CodeGen/X86/compare_folding.llx
@@ -1,5 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah | grep movsd | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah | grep ucomisd
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah | \
+; RUN: grep movsd | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah | \
+; RUN: grep ucomisd
declare bool %llvm.isunordered.f64(double,double)
bool %test1(double %X, double %Y) { ;; Returns isunordered(X,Y)
diff --git a/test/CodeGen/X86/fp-stack-ret.ll b/test/CodeGen/X86/fp-stack-ret.ll
index 85c5c02b569..69c5fc58e8c 100644
--- a/test/CodeGen/X86/fp-stack-ret.ll
+++ b/test/CodeGen/X86/fp-stack-ret.ll
@@ -1,7 +1,7 @@
; RUN: llvm-as < %s | \
; RUN: llc -mtriple=i686-apple-darwin8 -mcpu=yonah -march=x86 > %t
; RUN: grep fldl %t | wc -l | grep 1
-; RUN: not grep xmm %t &&
+; RUN: not grep xmm %t
; RUN: grep {sub.*esp} %t | wc -l | grep 1
; These testcases shouldn't require loading into an XMM register then storing
diff --git a/test/CodeGen/X86/long-setcc.ll b/test/CodeGen/X86/long-setcc.ll
index 2985623b6be..6097d968505 100644
--- a/test/CodeGen/X86/long-setcc.ll
+++ b/test/CodeGen/X86/long-setcc.ll
@@ -1,6 +1,5 @@
-; RUN: llvm-as < %s | llc -march=x86 &&
-; RUN: llvm-as < %s | llc -march=x86 | grep cmp | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -march=x86 | grep shr | wc -l | grep 1 &&
+; RUN: llvm-as < %s | llc -march=x86 | grep cmp | wc -l | grep 1
+; RUN: llvm-as < %s | llc -march=x86 | grep shr | wc -l | grep 1
; RUN: llvm-as < %s | llc -march=x86 | grep xor | wc -l | grep 1
define i1 @t1(i64 %x) {
diff --git a/test/CodeGen/X86/mul-shift-reassoc.ll b/test/CodeGen/X86/mul-shift-reassoc.ll
index 7a03b219aa7..52d188d9430 100644
--- a/test/CodeGen/X86/mul-shift-reassoc.ll
+++ b/test/CodeGen/X86/mul-shift-reassoc.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep lea &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep lea
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep add
int %test(int %X, int %Y) {
diff --git a/test/CodeGen/X86/packed_struct.ll b/test/CodeGen/X86/packed_struct.ll
index 172d0812b9a..d06f9164da6 100644
--- a/test/CodeGen/X86/packed_struct.ll
+++ b/test/CodeGen/X86/packed_struct.ll
@@ -1,8 +1,8 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep "foos+5" &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep "foos+1" &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep "foos+9" &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep "bara+19" &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep "bara+4"
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep foos+5
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep foos+1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep foos+9
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep bara+19
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep bara+4
; make sure we compute the correct offset for a packed structure
diff --git a/test/CodeGen/X86/rdtsc.ll b/test/CodeGen/X86/rdtsc.ll
index 1473c775880..f6c6c931bd9 100644
--- a/test/CodeGen/X86/rdtsc.ll
+++ b/test/CodeGen/X86/rdtsc.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep rdtsc &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep rdtsc
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86-64 | grep rdtsc
declare ulong %llvm.readcyclecounter()
diff --git a/test/CodeGen/X86/scalar_sse_minmax.ll b/test/CodeGen/X86/scalar_sse_minmax.ll
index 83401667edf..61894a4a20c 100644
--- a/test/CodeGen/X86/scalar_sse_minmax.ll
+++ b/test/CodeGen/X86/scalar_sse_minmax.ll
@@ -1,5 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse1,+sse2 | grep mins | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse1,+sse2 | grep maxs | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse1,+sse2 | \
+; RUN: grep mins | wc -l | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse1,+sse2 | \
+; RUN: grep maxs | wc -l | grep 2
declare bool %llvm.isunordered.f64( double %x, double %y )
declare bool %llvm.isunordered.f32( float %x, float %y )
diff --git a/test/CodeGen/X86/select.ll b/test/CodeGen/X86/select.ll
index 96b2e3ebae1..799d45c0e2d 100644
--- a/test/CodeGen/X86/select.ll
+++ b/test/CodeGen/X86/select.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=yonah
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mcpu=pentium
bool %boolSel(bool %A, bool %B, bool %C) {
diff --git a/test/CodeGen/X86/store-fp-constant.ll b/test/CodeGen/X86/store-fp-constant.ll
index 679bff8c625..3a80080383c 100644
--- a/test/CodeGen/X86/store-fp-constant.ll
+++ b/test/CodeGen/X86/store-fp-constant.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep rodata &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep rodata
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | not grep literal
;
; Check that no FP constants in this testcase ends up in the
diff --git a/test/CodeGen/X86/test-hidden.ll b/test/CodeGen/X86/test-hidden.ll
index da0a4f40e78..e95ca6af6a2 100644
--- a/test/CodeGen/X86/test-hidden.ll
+++ b/test/CodeGen/X86/test-hidden.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu | grep ".hidden" | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-apple-darwin8.8.0 | grep ".private_extern" | wc -l | grep 2
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu | \
+; RUN: grep .hidden | wc -l | grep 2
+; RUN: llvm-as < %s | llc -mtriple=i686-apple-darwin8.8.0 | \
+; RUN: grep .private_extern | wc -l | grep 2
%struct.Person = type { i32 }
@a = hidden global i32 0
diff --git a/test/CodeGen/X86/test-pic-1.ll b/test/CodeGen/X86/test-pic-1.ll
index 1cad6c5c096..4d9703e727f 100644
--- a/test/CodeGen/X86/test-pic-1.ll
+++ b/test/CodeGen/X86/test-pic-1.ll
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | \
-; RUN: llc -mtriple=i686-pc-linux-gnu -relocation-model=pic -o %t -f
+; RUN: llc -mtriple=i686-pc-linux-gnu -relocation-model=pic -o %t -f
; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
; RUN: grep piclabel %t | wc -l | grep 3
; RUN: grep GOT %t | wc -l | grep 3
diff --git a/test/CodeGen/X86/test-pic-2.ll b/test/CodeGen/X86/test-pic-2.ll
index 792c6d237ae..1d875fa6953 100644
--- a/test/CodeGen/X86/test-pic-2.ll
+++ b/test/CodeGen/X86/test-pic-2.ll
@@ -1,7 +1,8 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep GOTOFF | wc -l | grep 4
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep GOTOFF %t | wc -l | grep 4
@ptr = internal global i32* null
@dst = internal global i32 0
diff --git a/test/CodeGen/X86/test-pic-3.ll b/test/CodeGen/X86/test-pic-3.ll
index 79dce93cc5e..91b47613703 100644
--- a/test/CodeGen/X86/test-pic-3.ll
+++ b/test/CodeGen/X86/test-pic-3.ll
@@ -1,7 +1,8 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep PLT | wc -l | grep 1
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep PLT %t | wc -l | grep 1
define void @bar() {
entry:
diff --git a/test/CodeGen/X86/test-pic-4.ll b/test/CodeGen/X86/test-pic-4.ll
index 3ed1f71553d..7637d35fe49 100644
--- a/test/CodeGen/X86/test-pic-4.ll
+++ b/test/CodeGen/X86/test-pic-4.ll
@@ -3,8 +3,8 @@
; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
; RUN: grep piclabel %t | wc -l | grep 3
; RUN: grep PLT %t | wc -l | grep 1
-; RUN: grep "GOT" %t | wc -l | grep 1
-; RUN: not grep "GOTOFF" %t
+; RUN: grep GOT %t | wc -l | grep 1
+; RUN: not grep GOTOFF %t
@pfoo = external global void(...)*
diff --git a/test/CodeGen/X86/test-pic-5.ll b/test/CodeGen/X86/test-pic-5.ll
index 202ac9a0c2b..0ed38b979a8 100644
--- a/test/CodeGen/X86/test-pic-5.ll
+++ b/test/CodeGen/X86/test-pic-5.ll
@@ -1,7 +1,8 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep PLT | wc -l | grep 1
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep PLT %t | wc -l | grep 1
@ptr = external global i32*
diff --git a/test/CodeGen/X86/test-pic-6.ll b/test/CodeGen/X86/test-pic-6.ll
index fa3190fc087..43485c301c2 100644
--- a/test/CodeGen/X86/test-pic-6.ll
+++ b/test/CodeGen/X86/test-pic-6.ll
@@ -1,7 +1,8 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep GOT | wc -l | grep 3
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep GOT %t | wc -l | grep 3
@ptr = global i32* null
@dst = global i32 0
diff --git a/test/CodeGen/X86/test-pic-cpool.ll b/test/CodeGen/X86/test-pic-cpool.ll
index f52c5cadd35..79f5607b757 100644
--- a/test/CodeGen/X86/test-pic-cpool.ll
+++ b/test/CodeGen/X86/test-pic-cpool.ll
@@ -1,8 +1,9 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep GOTOFF | wc -l | grep 2 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep CPI | wc -l | grep 4
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep GOTOFF %t | wc -l | grep 2
+; RUN: grep CPI %t | wc -l | grep 4
define double @foo(i32 %a.u) {
entry:
diff --git a/test/CodeGen/X86/test-pic-jtbl.ll b/test/CodeGen/X86/test-pic-jtbl.ll
index b58e6de30f5..959fef5d8fd 100644
--- a/test/CodeGen/X86/test-pic-jtbl.ll
+++ b/test/CodeGen/X86/test-pic-jtbl.ll
@@ -1,9 +1,10 @@
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep _GLOBAL_OFFSET_TABLE_ &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep piclabel | wc -l | grep 3 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep PLT | wc -l | grep 13 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep GOTOFF | wc -l | grep 1 &&
-; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic | grep JTI | wc -l | grep 15
+; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
+; RUN: -o %t -f
+; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
+; RUN: grep piclabel %t | wc -l | grep 3
+; RUN: grep PLT %t | wc -l | grep 13
+; RUN: grep GOTOFF %t | wc -l | grep 1
+; RUN: grep JTI %t | wc -l | grep 15
define void @bar(i32 %n.u) {
entry:
diff --git a/test/CodeGen/X86/vec_clear.ll b/test/CodeGen/X86/vec_clear.ll
index a43d67ccd23..8289b6be024 100644
--- a/test/CodeGen/X86/vec_clear.ll
+++ b/test/CodeGen/X86/vec_clear.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | not grep and
<4 x float> %test(<4 x float>* %v1) {
%tmp = load <4 x float>* %v1
diff --git a/test/CodeGen/X86/vec_extract.ll b/test/CodeGen/X86/vec_extract.ll
index 2f729ad244d..2d3e87ea461 100644
--- a/test/CodeGen/X86/vec_extract.ll
+++ b/test/CodeGen/X86/vec_extract.ll
@@ -1,7 +1,8 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movss | wc -l | grep 3 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movhlps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep pshufd | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep unpckhpd | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movss %t | wc -l | grep 3
+; RUN: grep movhlps %t | wc -l | grep 1
+; RUN: grep pshufd %t | wc -l | grep 1
+; RUN: grep unpckhpd %t | wc -l | grep 1
void %test1(<4 x float>* %F, float* %f) {
%tmp = load <4 x float>* %F
diff --git a/test/CodeGen/X86/vec_ins_extract.ll b/test/CodeGen/X86/vec_ins_extract.ll
index b2435063a5e..9f44afe25de 100644
--- a/test/CodeGen/X86/vec_ins_extract.ll
+++ b/test/CodeGen/X86/vec_ins_extract.ll
@@ -1,6 +1,4 @@
; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl -instcombine | \
-; RUN: llc -march=x86 -mcpu=yonah &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl -instcombine | \
; RUN: llc -march=x86 -mcpu=yonah | not grep sub.*esp
; This checks that various insert/extract idiom work without going to the
diff --git a/test/CodeGen/X86/vec_insert.ll b/test/CodeGen/X86/vec_insert.ll
index fbe604d5a1e..021685e509e 100644
--- a/test/CodeGen/X86/vec_insert.ll
+++ b/test/CodeGen/X86/vec_insert.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movss | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep pinsrw | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movss %t | wc -l | grep 1
+; RUN: grep pinsrw %t | wc -l | grep 2
void %test(<4 x float>* %F, int %I) {
%tmp = load <4 x float>* %F
diff --git a/test/CodeGen/X86/vec_set-2.ll b/test/CodeGen/X86/vec_set-2.ll
index db748f289bd..1d1449d4e32 100644
--- a/test/CodeGen/X86/vec_set-2.ll
+++ b/test/CodeGen/X86/vec_set-2.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movss | wc -l | grep 1 &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movss | wc -l | grep 1
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movd | wc -l | grep 1
<4 x float> %test1(float %a) {
diff --git a/test/CodeGen/X86/vec_set-3.ll b/test/CodeGen/X86/vec_set-3.ll
index 23c5808af12..1edaa58703d 100644
--- a/test/CodeGen/X86/vec_set-3.ll
+++ b/test/CodeGen/X86/vec_set-3.ll
@@ -1,7 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | \
-; RUN: grep shufps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | \
-; RUN: grep pshufd | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep shufps %t | wc -l | grep 1
+; RUN: grep pshufd %t | wc -l | grep 1
<4 x float> %test(float %a) {
%tmp = insertelement <4 x float> zeroinitializer, float %a, uint 1
diff --git a/test/CodeGen/X86/vec_set-5.ll b/test/CodeGen/X86/vec_set-5.ll
index 8761417a98a..218f0415fd7 100644
--- a/test/CodeGen/X86/vec_set-5.ll
+++ b/test/CodeGen/X86/vec_set-5.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movlhps | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep unpcklps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep punpckldq | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movlhps %t | wc -l | grep 2
+; RUN: grep unpcklps %t | wc -l | grep 1
+; RUN: grep punpckldq %t | wc -l | grep 1
<4 x float> %test1(float %a, float %b) {
%tmp = insertelement <4 x float> zeroinitializer, float %a, uint 0
diff --git a/test/CodeGen/X86/vec_set-6.ll b/test/CodeGen/X86/vec_set-6.ll
index 439febb801f..ea6be7412a0 100644
--- a/test/CodeGen/X86/vec_set-6.ll
+++ b/test/CodeGen/X86/vec_set-6.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep unpcklps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shufps | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep unpcklps %t | wc -l | grep 1
+; RUN: grep shufps %t | wc -l | grep 1
<4 x float> %test(float %a, float %b, float %c) {
%tmp = insertelement <4 x float> zeroinitializer, float %a, uint 1
diff --git a/test/CodeGen/X86/vec_shuffle-2.ll b/test/CodeGen/X86/vec_shuffle-2.ll
index dd4c269e075..df78323a538 100644
--- a/test/CodeGen/X86/vec_shuffle-2.ll
+++ b/test/CodeGen/X86/vec_shuffle-2.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep pshufhw | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep pshuflw | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movhps | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep pshufhw %t | wc -l | grep 1
+; RUN: grep pshuflw %t | wc -l | grep 1
+; RUN: grep movhps %t | wc -l | grep 1
void %test1(<2 x long>* %res, <2 x long>* %A) {
%tmp = load <2 x long>* %A
diff --git a/test/CodeGen/X86/vec_shuffle-3.ll b/test/CodeGen/X86/vec_shuffle-3.ll
index d34a00646c7..a0ce0f06399 100644
--- a/test/CodeGen/X86/vec_shuffle-3.ll
+++ b/test/CodeGen/X86/vec_shuffle-3.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movlhps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movhlps | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movlhps %t | wc -l | grep 1
+; RUN: grep movhlps %t | wc -l | grep 1
<4 x float> %test1(<4 x float>* %x, <4 x float>* %y) {
%tmp = load <4 x float>* %y
diff --git a/test/CodeGen/X86/vec_shuffle-4.ll b/test/CodeGen/X86/vec_shuffle-4.ll
index 7632992fee4..5bb30bf5643 100644
--- a/test/CodeGen/X86/vec_shuffle-4.ll
+++ b/test/CodeGen/X86/vec_shuffle-4.ll
@@ -1,6 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shuf | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | not grep unpck
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 > %t
+; RUN: grep shuf %t | wc -l | grep 2
+; RUN: not grep unpck %t
void %test(<4 x float>* %res, <4 x float>* %A, <4 x float>* %B, <4 x float>* %C) {
%tmp3 = load <4 x float>* %B
%tmp5 = load <4 x float>* %C
diff --git a/test/CodeGen/X86/vec_shuffle-5.ll b/test/CodeGen/X86/vec_shuffle-5.ll
index b94769b1699..e980a124ee4 100644
--- a/test/CodeGen/X86/vec_shuffle-5.ll
+++ b/test/CodeGen/X86/vec_shuffle-5.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movhlps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shufps | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movhlps %t | wc -l | grep 1
+; RUN: grep shufps %t | wc -l | grep 1
void %test() {
%tmp1 = load <4 x float>* null
diff --git a/test/CodeGen/X86/vec_shuffle-6.ll b/test/CodeGen/X86/vec_shuffle-6.ll
index 92e141d8317..661fe09d5cd 100644
--- a/test/CodeGen/X86/vec_shuffle-6.ll
+++ b/test/CodeGen/X86/vec_shuffle-6.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movapd | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movaps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movups | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep movapd %t | wc -l | grep 1
+; RUN: grep movaps %t | wc -l | grep 1
+; RUN: grep movups %t | wc -l | grep 2
target triple = "i686-apple-darwin"
diff --git a/test/CodeGen/X86/vec_shuffle-7.ll b/test/CodeGen/X86/vec_shuffle-7.ll
index bd978836c88..ae64c2856a8 100644
--- a/test/CodeGen/X86/vec_shuffle-7.ll
+++ b/test/CodeGen/X86/vec_shuffle-7.ll
@@ -1,6 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep xorps | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | not grep shufps
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep xorps %t | wc -l | grep 1
+; RUN: not grep shufps %t
void %test() {
cast <4 x int> zeroinitializer to <4 x float>
diff --git a/test/CodeGen/X86/vec_shuffle-8.ll b/test/CodeGen/X86/vec_shuffle-8.ll
index 13e8b9c22a2..4daf73e75d1 100644
--- a/test/CodeGen/X86/vec_shuffle-8.ll
+++ b/test/CodeGen/X86/vec_shuffle-8.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | not grep shufps
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | \
+; RUN: not grep shufps
void %test(<4 x float>* %res, <4 x float>* %A) {
%tmp1 = load <4 x float>* %A
diff --git a/test/CodeGen/X86/vec_shuffle-9.ll b/test/CodeGen/X86/vec_shuffle-9.ll
index a9b325a77b5..e83e2984d46 100644
--- a/test/CodeGen/X86/vec_shuffle-9.ll
+++ b/test/CodeGen/X86/vec_shuffle-9.ll
@@ -1,6 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep punpck | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | not grep pextrw
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep punpck %t | wc -l | grep 2
+; RUN: not grep pextrw %t
<4 x int> %test(sbyte** %ptr) {
entry:
diff --git a/test/CodeGen/X86/vec_shuffle.ll b/test/CodeGen/X86/vec_shuffle.ll
index 65aafe54b32..d06efa5ff26 100644
--- a/test/CodeGen/X86/vec_shuffle.ll
+++ b/test/CodeGen/X86/vec_shuffle.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shufp | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep movups | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep pshufhw | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 -o %t -f
+; RUN: grep shufp %t | wc -l | grep 1
+; RUN: grep movups %t | wc -l | grep 1
+; RUN: grep pshufhw %t | wc -l | grep 1
void %test_v4sf(<4 x float>* %P, float %X, float %Y) {
%tmp = insertelement <4 x float> zeroinitializer, float %X, uint 0
diff --git a/test/CodeGen/X86/vec_splat.ll b/test/CodeGen/X86/vec_splat.ll
index bc0ae0327d6..3d73a87f84d 100644
--- a/test/CodeGen/X86/vec_splat.ll
+++ b/test/CodeGen/X86/vec_splat.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shufps &&
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse2 | grep shufps
; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse3 | grep movddup
void %test_v4sf(<4 x float>* %P, <4 x float>* %Q, float %X) {
diff --git a/test/CodeGen/X86/vec_ss_load_fold.ll b/test/CodeGen/X86/vec_ss_load_fold.ll
index 38eb1d1f2e1..1c9f6f1e0db 100644
--- a/test/CodeGen/X86/vec_ss_load_fold.ll
+++ b/test/CodeGen/X86/vec_ss_load_fold.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse,+sse2 | grep minss | grep CPI | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse,+sse2 | grep CPI | not grep movss
+; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 -mattr=+sse,+sse2 -o %t -f
+; RUN: grep minss %t | grep CPI | wc -l | grep 2
+; RUN: grep CPI %t | not grep movss
target endian = little
target pointersize = 32
diff --git a/test/CodeGen/X86/x86-64-mem.ll b/test/CodeGen/X86/x86-64-mem.ll
index 4af16bb0419..8e119761ec1 100644
--- a/test/CodeGen/X86/x86-64-mem.ll
+++ b/test/CodeGen/X86/x86-64-mem.ll
@@ -1,11 +1,13 @@
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin | grep GOTPCREL | wc -l | grep 4 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin | grep rip | wc -l | grep 6 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin | grep movq | wc -l | grep 6 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin | grep leaq | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin -relocation-model=static | grep rip | wc -l | grep 4 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin -relocation-model=static | grep movl | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin -relocation-model=static | grep movq | wc -l | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | llc -mtriple=x86_64-apple-darwin -o %t1 -f
+; RUN: grep GOTPCREL %t1 | wc -l | grep 4
+; RUN: grep rip %t1 | wc -l | grep 6
+; RUN: grep movq %t1 | wc -l | grep 6
+; RUN: grep leaq %t1 | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: llc -mtriple=x86_64-apple-darwin -relocation-model=static -o %t2 -f
+; RUN: grep rip %t2 | wc -l | grep 4
+; RUN: grep movl %t2 | wc -l | grep 2
+; RUN: grep movq %t2 | wc -l | grep 2
%ptr = external global int*
%src = external global [0 x int]
diff --git a/test/Feature/fold-fpcast.ll b/test/Feature/fold-fpcast.ll
index fc90a66b453..65759b599a2 100644
--- a/test/Feature/fold-fpcast.ll
+++ b/test/Feature/fold-fpcast.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llvm-dis -o /dev/null -f &&
; RUN: llvm-upgrade < %s | llvm-as | llvm-dis | not grep bitcast
int %test1() {
diff --git a/test/Feature/forwardreftest.ll b/test/Feature/forwardreftest.ll
index 59dff0e32f3..edb1f281eba 100644
--- a/test/Feature/forwardreftest.ll
+++ b/test/Feature/forwardreftest.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llvm-dis -o /dev/null -f &&
; RUN: llvm-upgrade < %s | llvm-as | llvm-dis > %t1.ll
; RUN: llvm-as %t1.ll -o - | llvm-dis > %t2.ll
; RUN: diff %t1.ll %t2.ll
diff --git a/test/Feature/inlineasm.ll b/test/Feature/inlineasm.ll
index c34324a3eed..c8f59f24cf4 100644
--- a/test/Feature/inlineasm.ll
+++ b/test/Feature/inlineasm.ll
@@ -1,6 +1,6 @@
-; RUN: llvm-upgrade %s -o - | llvm-as -o /dev/null -f &&
-; RUN: llvm-upgrade < %s | llvm-as | llvm-dis > Output/t1.ll &&
-; RUN: llvm-as Output/t1.ll -o - | llvm-dis > Output/t2.ll &&
+; RUN: llvm-upgrade %s -o - | llvm-as -o /dev/null -f
+; RUN: llvm-upgrade < %s | llvm-as | llvm-dis > Output/t1.ll
+; RUN: llvm-as Output/t1.ll -o - | llvm-dis > Output/t2.ll
; RUN: diff Output/t1.ll Output/t2.ll
diff --git a/test/Linker/basiclink.ll b/test/Linker/basiclink.ll
index 5a92b5d19c5..711a0f4715e 100644
--- a/test/Linker/basiclink.ll
+++ b/test/Linker/basiclink.ll
@@ -1,8 +1,8 @@
; Test linking two functions with different prototypes and two globals
; in different modules. This is for PR411
; RUN: llvm-as %s -o %t.bar.bc -f
-; RUN: echo "define i32* @foo(i32 %x) { ret i32* @baz } @baz = external global i32" | \
-; RUN: llvm-as -o %t.foo.bc -f
+; RUN: echo {define i32* @foo(i32 %x) \{ ret i32* @baz \} \
+; RUN: @baz = external global i32 } | llvm-as -o %t.foo.bc -f
; RUN: llvm-link %t.bar.bc %t.foo.bc -o %t.bc -f
; RUN: llvm-link %t.foo.bc %t.bar.bc -o %t.bc -f
declare i32* @foo(...)
diff --git a/test/Transforms/ConstProp/bitcast.ll b/test/Transforms/ConstProp/bitcast.ll
index 39cd53487f7..1fc25704a66 100644
--- a/test/Transforms/ConstProp/bitcast.ll
+++ b/test/Transforms/ConstProp/bitcast.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | llvm-dis &&
; RUN: llvm-upgrade < %s | llvm-as | llvm-dis | grep 0x36A0000000000000
%A = global float bitcast (int 1 to float)
diff --git a/test/Transforms/DeadArgElim/dead_vaargs.ll b/test/Transforms/DeadArgElim/dead_vaargs.ll
index c615ed06502..ecb84cc9650 100644
--- a/test/Transforms/DeadArgElim/dead_vaargs.ll
+++ b/test/Transforms/DeadArgElim/dead_vaargs.ll
@@ -1,5 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -deadargelim -disable-output &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -deadargelim | llvm-dis | not grep 47 &&
+; RUN: llvm-upgrade < %s | llvm-as | opt -deadargelim | llvm-dis | not grep 47
; RUN: llvm-upgrade < %s | llvm-as | opt -deadargelim | llvm-dis | not grep 1.0
int %bar(int %A) {
diff --git a/test/Transforms/GCSE/vectorops.ll b/test/Transforms/GCSE/vectorops.ll
index 3804c290d7c..694d9d590f0 100644
--- a/test/Transforms/GCSE/vectorops.ll
+++ b/test/Transforms/GCSE/vectorops.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -gcse -instcombine -disable-output &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -gcse -instcombine | llvm-dis | not grep sub
+; RUN: llvm-upgrade < %s | llvm-as | opt -gcse -instcombine | \
+; RUN: llvm-dis | not grep sub
uint %test_extractelement(<4 x uint> %V) {
%R = extractelement <4 x uint> %V, uint 1
diff --git a/test/Transforms/GlobalOpt/ctor-list-opt.ll b/test/Transforms/GlobalOpt/ctor-list-opt.ll
index 8f75deb61b6..6270f4fabc1 100644
--- a/test/Transforms/GlobalOpt/ctor-list-opt.ll
+++ b/test/Transforms/GlobalOpt/ctor-list-opt.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -globalopt -disable-output &&
; RUN: llvm-upgrade < %s | llvm-as | opt -globalopt | llvm-dis | not grep CTOR
%llvm.global_ctors = appending global [10 x { int, void ()* }] [
diff --git a/test/Transforms/IndVarsSimplify/loop_evaluate_2.ll b/test/Transforms/IndVarsSimplify/loop_evaluate_2.ll
index e11e3272576..c7426918462 100644
--- a/test/Transforms/IndVarsSimplify/loop_evaluate_2.ll
+++ b/test/Transforms/IndVarsSimplify/loop_evaluate_2.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | opt -indvars -adce -simplifycfg | llvm-dis | grep select &&
+; RUN: llvm-as < %s | opt -indvars -adce -simplifycfg | llvm-dis | grep select
; RUN: llvm-as < %s | opt -indvars -adce -simplifycfg | llvm-dis | not grep br
; PR1179
diff --git a/test/Transforms/Inline/dynamic_alloca_test.ll b/test/Transforms/Inline/dynamic_alloca_test.ll
index 2b30b30ab76..cccf2d9b46c 100644
--- a/test/Transforms/Inline/dynamic_alloca_test.ll
+++ b/test/Transforms/Inline/dynamic_alloca_test.ll
@@ -1,8 +1,8 @@
; Test that functions with dynamic allocas get inlined in a case where
; naively inlining it would result in a miscompilation.
-; RUN: llvm-upgrade < %s | llvm-as | opt -inline &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -inline | llvm-dis | grep llvm.stacksave &&
+; RUN: llvm-upgrade < %s | llvm-as | opt -inline | llvm-dis | \
+; RUN: grep llvm.stacksave
; RUN: llvm-upgrade < %s | llvm-as | opt -inline | llvm-dis | not grep callee
declare void %ext(int*)
diff --git a/test/Transforms/InstCombine/2007-04-04-BadFoldBitcastIntoMalloc.ll b/test/Transforms/InstCombine/2007-04-04-BadFoldBitcastIntoMalloc.ll
index d7a5b44b033..e738635be76 100644
--- a/test/Transforms/InstCombine/2007-04-04-BadFoldBitcastIntoMalloc.ll
+++ b/test/Transforms/InstCombine/2007-04-04-BadFoldBitcastIntoMalloc.ll
@@ -2,7 +2,6 @@
; a malloc messes up the element count, causing an extra 4GB to be allocated on
; 64-bit targets.
;
-; RUN: llvm-as < %s | opt -instcombine -disable-output &&
; RUN: llvm-as < %s | opt -instcombine | llvm-dis | not grep {= add }
target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64"
diff --git a/test/Transforms/InstCombine/add.ll b/test/Transforms/InstCombine/add.ll
index 87bb7733f3e..df99e96f5fe 100644
--- a/test/Transforms/InstCombine/add.ll
+++ b/test/Transforms/InstCombine/add.ll
@@ -1,6 +1,5 @@
; This test makes sure that add instructions are properly eliminated.
-; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine -disable-output &&
; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | \
; RUN: grep -v OK | not grep add
; END.
diff --git a/test/Transforms/InstCombine/add2.ll b/test/Transforms/InstCombine/add2.ll
index f9ca397caaa..ff899461dd1 100644
--- a/test/Transforms/InstCombine/add2.ll
+++ b/test/Transforms/InstCombine/add2.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-as < %s | opt -instcombine -disable-output &&
; RUN: llvm-as < %s | opt -instcombine | llvm-dis | \
; RUN: grep -v OK | not grep add
diff --git a/test/Transforms/LCSSA/2006-06-03-IncorrectIDFPhis.ll b/test/Transforms/LCSSA/2006-06-03-IncorrectIDFPhis.ll
index ffbe6fb4254..e7cfd76ec70 100644
--- a/test/Transforms/LCSSA/2006-06-03-IncorrectIDFPhis.ll
+++ b/test/Transforms/LCSSA/2006-06-03-IncorrectIDFPhis.ll
@@ -1,7 +1,7 @@
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: grep "%SJE.0.0.lcssa = phi .struct.SetJmpMapEntry" &&
+; RUN: grep {%SJE.0.0.lcssa = phi .struct.SetJmpMapEntry}
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: grep "%SJE.0.0.lcssa1 = phi .struct.SetJmpMapEntry"
+; RUN: grep {%SJE.0.0.lcssa1 = phi .struct.SetJmpMapEntry}
%struct.SetJmpMapEntry = type { sbyte*, uint, %struct.SetJmpMapEntry* }
diff --git a/test/Transforms/LCSSA/2006-06-12-MultipleExitsSameBlock.ll b/test/Transforms/LCSSA/2006-06-12-MultipleExitsSameBlock.ll
index 3647008e3a5..02765dcdc15 100644
--- a/test/Transforms/LCSSA/2006-06-12-MultipleExitsSameBlock.ll
+++ b/test/Transforms/LCSSA/2006-06-12-MultipleExitsSameBlock.ll
@@ -1,7 +1,7 @@
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: grep "%X.1.lcssa" &&
+; RUN: grep {%X.1.lcssa}
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: not grep "%X.1.lcssa1"
+; RUN: not grep {%X.1.lcssa1}
declare bool %c1()
declare bool %c2()
diff --git a/test/Transforms/LCSSA/basictest.ll b/test/Transforms/LCSSA/basictest.ll
index 1dc69a6b11a..4dc1f54cd72 100644
--- a/test/Transforms/LCSSA/basictest.ll
+++ b/test/Transforms/LCSSA/basictest.ll
@@ -1,7 +1,7 @@
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: grep "X3.lcssa = phi i32" &&
+; RUN: grep {X3.lcssa = phi i32}
; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
-; RUN: grep "X4 = add i32 3, %X3.lcssa"
+; RUN: grep {X4 = add i32 3, %X3.lcssa}
void %lcssa(bool %S2) {
entry:
diff --git a/test/Transforms/LoopRotate/PhiRename-1.ll b/test/Transforms/LoopRotate/PhiRename-1.ll
index 7ea0ca6b21a..573e3960bd8 100644
--- a/test/Transforms/LoopRotate/PhiRename-1.ll
+++ b/test/Transforms/LoopRotate/PhiRename-1.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-as < %s | opt -loop-rotate -disable-output &&
-; RUN: llvm-as < %s | opt -loop-rotate | llvm-dis | not grep "\[ .tmp224"
+; RUN: llvm-as < %s | opt -loop-rotate | llvm-dis | not grep {\\\[ .tmp224}
+; END.
target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64"
%struct.FILE = type { i8*, i32, i32, i16, i16, %struct.__sbuf, i32, i8*, i32 (i8*)*, i32 (i8*, i8*, i32)*, i64 (i8*, i64, i32)*, i32 (i8*, i8*, i32)*, %struct.__sbuf, %struct.__sFILEX*, i32, [3 x i8], [1 x i8], %struct.__sbuf, i32, i64 }
diff --git a/test/Transforms/LoopStrengthReduce/nested-reduce.ll b/test/Transforms/LoopStrengthReduce/nested-reduce.ll
index 1959832d51c..6f709e34bd5 100644
--- a/test/Transforms/LoopStrengthReduce/nested-reduce.ll
+++ b/test/Transforms/LoopStrengthReduce/nested-reduce.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -loop-reduce &&
; RUN: llvm-upgrade < %s | llvm-as | opt -loop-reduce | llvm-dis | not grep mul
; Make sure we don't get a multiply by 6 in this loop.
diff --git a/test/Transforms/LoopUnroll/2006-08-24-MultiBlockLoop.ll b/test/Transforms/LoopUnroll/2006-08-24-MultiBlockLoop.ll
index c21ae484db0..42ff3fafe7f 100644
--- a/test/Transforms/LoopUnroll/2006-08-24-MultiBlockLoop.ll
+++ b/test/Transforms/LoopUnroll/2006-08-24-MultiBlockLoop.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -loop-unroll | llvm-dis | grep "bb72.2"
+; RUN: llvm-upgrade < %s | llvm-as | opt -loop-unroll | llvm-dis | grep bb72.2
void %vorbis_encode_noisebias_setup() {
entry:
diff --git a/test/Transforms/LowerInvoke/basictest.ll b/test/Transforms/LowerInvoke/basictest.ll
index 4150ad3efbd..8c38b89c4bd 100644
--- a/test/Transforms/LowerInvoke/basictest.ll
+++ b/test/Transforms/LowerInvoke/basictest.ll
@@ -1,4 +1,3 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -lowerinvoke -disable-output &&
; RUN: llvm-upgrade < %s | llvm-as | opt -lowerinvoke -disable-output -enable-correct-eh-support
implementation
diff --git a/test/Transforms/LowerSwitch/feature.ll b/test/Transforms/LowerSwitch/feature.ll
index cb88e31c16c..0b3cdc780fb 100644
--- a/test/Transforms/LowerSwitch/feature.ll
+++ b/test/Transforms/LowerSwitch/feature.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-as %s -o - | opt -lowerswitch | llvm-dis | grep slt | wc -l | grep 10 &&
-; RUN: llvm-as %s -o - | opt -lowerswitch | llvm-dis | grep ule | wc -l | grep 3 &&
-; RUN: llvm-as %s -o - | opt -lowerswitch | llvm-dis | grep eq | wc -l | grep 9
+; RUN: llvm-as %s -o - | opt -lowerswitch | llvm-dis > %t
+; RUN: grep slt %t | wc -l | grep 10
+; RUN: grep ule %t | wc -l | grep 3
+; RUN: grep eq %t | wc -l | grep 9
define i32 @main(i32 %tmp158) {
entry:
diff --git a/test/Transforms/PredicateSimplifier/2006-10-22-IntOr.ll b/test/Transforms/PredicateSimplifier/2006-10-22-IntOr.ll
index 0cdd58085b7..01fbee1a569 100644
--- a/test/Transforms/PredicateSimplifier/2006-10-22-IntOr.ll
+++ b/test/Transforms/PredicateSimplifier/2006-10-22-IntOr.ll
@@ -1,6 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg -disable-output &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg | llvm-dis | grep -v declare | not grep fail &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg | llvm-dis | grep -v declare | grep -c pass | grep 3
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -predsimplify -instcombine -simplifycfg -o %t -f
+; RUN: grep -v declare %t | not grep fail
+; RUN: grep -v declare %t | grep -c pass | grep 3
int %test1(int %x, int %y) {
entry:
diff --git a/test/Transforms/PredicateSimplifier/2006-10-25-AddSetCC.ll b/test/Transforms/PredicateSimplifier/2006-10-25-AddSetCC.ll
index 5c5a4a48d46..a9040123e30 100644
--- a/test/Transforms/PredicateSimplifier/2006-10-25-AddSetCC.ll
+++ b/test/Transforms/PredicateSimplifier/2006-10-25-AddSetCC.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg -disable-output &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg | llvm-dis | grep -v declare | grep -c pass | grep 2
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -predsimplify -instcombine -simplifycfg | llvm-dis | \
+; RUN: grep -v declare | grep -c pass | grep 2
int %test(int %x, int %y) {
entry:
diff --git a/test/Transforms/PredicateSimplifier/predsimplify.ll b/test/Transforms/PredicateSimplifier/predsimplify.ll
index efe28d184ab..b88122f57c0 100644
--- a/test/Transforms/PredicateSimplifier/predsimplify.ll
+++ b/test/Transforms/PredicateSimplifier/predsimplify.ll
@@ -1,5 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg | llvm-dis | grep -v declare | not grep fail &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -predsimplify -instcombine -simplifycfg | llvm-dis | grep -v declare | grep -c pass | grep 4
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -predsimplify -instcombine -simplifycfg | llvm-dis > %t
+; RUN: grep -v declare %t | not grep fail
+; RUN: grep -v declare %t | grep -c pass | grep 4
void %test1(int %x) {
entry:
diff --git a/test/Transforms/Reassociate/mul-factor3.ll b/test/Transforms/Reassociate/mul-factor3.ll
index 5e06fbca847..1272ff62dd8 100644
--- a/test/Transforms/Reassociate/mul-factor3.ll
+++ b/test/Transforms/Reassociate/mul-factor3.ll
@@ -1,7 +1,9 @@
; This should be one add and two multiplies.
-; RUN: llvm-upgrade < %s | llvm-as | opt -reassociate -instcombine | llvm-dis | grep mul | wc -l | grep 2 &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -reassociate -instcombine | llvm-dis | grep add | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -reassociate -instcombine | llvm-dis > %t
+; RUN: grep mul %t | wc -l | grep 2
+; RUN: grep add %t | wc -l | grep 1
int %test(int %A, int %B, int %C) {
%aa = mul int %A, %A
diff --git a/test/Transforms/Reassociate/mulfactor2.ll b/test/Transforms/Reassociate/mulfactor2.ll
index 062e3af4f50..dd1e8ae8a35 100644
--- a/test/Transforms/Reassociate/mulfactor2.ll
+++ b/test/Transforms/Reassociate/mulfactor2.ll
@@ -1,7 +1,10 @@
; This should turn into one multiply and one add.
-; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine -reassociate -instcombine | llvm-dis | grep mul | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine -reassociate -instcombine | llvm-dis | grep add | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -instcombine -reassociate -instcombine | llvm-dis -o %t
+; RUN: grep mul %t | wc -l | grep 1
+; RUN: grep add %t | wc -l | grep 1
+
int %main(int %t) {
%tmp.3 = mul int %t, 12 ; <int> [#uses=1]
%tmp.4 = add int %tmp.3, 5 ; <int> [#uses=1]
diff --git a/test/Transforms/Reassociate/shift-factor.ll b/test/Transforms/Reassociate/shift-factor.ll
index 51513c28956..ed8ed392c5f 100644
--- a/test/Transforms/Reassociate/shift-factor.ll
+++ b/test/Transforms/Reassociate/shift-factor.ll
@@ -1,6 +1,8 @@
; There should be exactly one shift and one add left.
-; RUN: llvm-upgrade < %s | llvm-as | opt -reassociate -instcombine | llvm-dis | grep shl | wc -l | grep 1 &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -reassociate -instcombine | llvm-dis | grep add | wc -l | grep 1
+; RUN: llvm-upgrade < %s | llvm-as | \
+; RUN: opt -reassociate -instcombine | llvm-dis > %t
+; RUN: grep shl %t | wc -l | grep 1
+; RUN: grep add %t | wc -l | grep 1
int %test(int %X, int %Y) {
%tmp.2 = shl int %X, ubyte 1 ; <int> [#uses=1]
diff --git a/test/Transforms/ScalarRepl/AggregatePromote.ll b/test/Transforms/ScalarRepl/AggregatePromote.ll
index ea16b5e5eea..67ccad05cc2 100644
--- a/test/Transforms/ScalarRepl/AggregatePromote.ll
+++ b/test/Transforms/ScalarRepl/AggregatePromote.ll
@@ -1,5 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl | llvm-dis | not grep alloca &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl -disable-output
+; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl | llvm-dis | \
+; RUN: not grep alloca
target endian = big
target pointersize = 32
diff --git a/test/Transforms/ScalarRepl/vector_promote.ll b/test/Transforms/ScalarRepl/vector_promote.ll
index 2e9bce77402..73e2c64a3f7 100644
--- a/test/Transforms/ScalarRepl/vector_promote.ll
+++ b/test/Transforms/ScalarRepl/vector_promote.ll
@@ -1,6 +1,5 @@
-
-; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl -disable-output &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl | llvm-dis | not grep alloca
+; RUN: llvm-upgrade < %s | llvm-as | opt -scalarrepl | llvm-dis | \
+; RUN: not grep alloca
void %test(<4 x float>* %F, float %f) {
entry:
diff --git a/test/Transforms/SimplifyLibCalls/floor.ll b/test/Transforms/SimplifyLibCalls/floor.ll
index 06f159f0a08..2b940fdb800 100644
--- a/test/Transforms/SimplifyLibCalls/floor.ll
+++ b/test/Transforms/SimplifyLibCalls/floor.ll
@@ -1,15 +1,10 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: not grep {call.*floor(} &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: grep {call.*floorf(}
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: not grep {call.*ceil(} &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: grep {call.*ceilf(}
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: not grep {call.*nearbyint(} &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis | \
-; RUN: grep {call.*nearbyintf(}
+; RUN: llvm-upgrade < %s | llvm-as | opt -simplify-libcalls | llvm-dis > %t
+; RUN: not grep {call.*floor(} %t
+; RUN: grep {call.*floorf(} %t
+; RUN: not grep {call.*ceil(} %t
+; RUN: grep {call.*ceilf(} %t
+; RUN: not grep {call.*nearbyint(} %t
+; RUN: grep {call.*nearbyintf(} %t
; XFAIL: sparc
declare double %floor(double)
diff --git a/test/Transforms/TailCallElim/return-undef.ll b/test/Transforms/TailCallElim/return-undef.ll
index e721447e6f3..b7d2f816495 100644
--- a/test/Transforms/TailCallElim/return-undef.ll
+++ b/test/Transforms/TailCallElim/return-undef.ll
@@ -1,5 +1,6 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -tailcallelim | llvm-dis | grep sub &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -tailcallelim | llvm-dis | not grep call
+; RUN: llvm-upgrade < %s | llvm-as | opt -tailcallelim | llvm-dis > %t
+; RUN: grep sub %t
+; RUN: not grep call %t
int %test(int %X) {
%Y = sub int %X, 1
diff --git a/test/Transforms/TailDup/if-tail-dup.ll b/test/Transforms/TailDup/if-tail-dup.ll
index 2a4425e117f..87c90276278 100644
--- a/test/Transforms/TailDup/if-tail-dup.ll
+++ b/test/Transforms/TailDup/if-tail-dup.ll
@@ -1,7 +1,7 @@
-; RUN: llvm-upgrade < %s | llvm-as | opt -tailduplicate | llc -march=x86 | \
-; RUN: grep {je } &&
-; RUN: llvm-upgrade < %s | llvm-as | opt -tailduplicate | llc -march=x86 | \
-; RUN: not grep jmp
+; RUN: llvm-upgrade < %s | llvm-as | opt -tailduplicate | \
+; RUN: llc -march=x86 -o %t -f
+; RUN: grep {je } %t
+; RUN: not grep jmp %t
; END.
; This should have no unconditional jumps in it. The C source is: