Second attempt:

Massive check in. This changes the "-fast" flag to "-O#" in llc. If you want to
use the old behavior, the flag is -O0. This change allows for finer-grained
control over which optimizations are run at different -O levels.

Most of this work was pretty mechanical. The majority of the fixes came from
verifying that a "fast" variable wasn't used anymore. The JIT still uses a
"Fast" flag. I'll change the JIT with a follow-up patch.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70343 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bill Wendling
2009-04-29 00:15:41 +00:00
parent a24d1b1558
commit be8cc2a3de
93 changed files with 400 additions and 346 deletions
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -fast
; RUN: llvm-as < %s | llc -O0
define float @test(i32 %tmp12771278) {
switch i32 %tmp12771278, label %bb1279 [
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -fast
; RUN: llvm-as < %s | llc -O0
%struct.cl_perfunc_opts = type { i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i8, i32, i32, i32, i32, i32, i32, i32 }
@cl_pf_opts = external global %struct.cl_perfunc_opts ; <%struct.cl_perfunc_opts*> [#uses=2]
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -fast
; RUN: llvm-as < %s | llc -O0
; PR 1323
; ModuleID = 'test.bc'
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -march=ppc32 -regalloc=local -fast -relocation-model=pic -o -
; RUN: llvm-as < %s | llc -march=ppc32 -regalloc=local -O0 -relocation-model=pic -o -
; PR1638
@.str242 = external constant [3 x i8] ; <[3 x i8]*> [#uses=1]
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llc -mtriple=x86_64-apple-darwin
; RUN: llvm-as < %s | llc -mtriple=x86_64-apple-darwin -relocation-model=pic -disable-fp-elim -fast -regalloc=local
; RUN: llvm-as < %s | llc -mtriple=x86_64-apple-darwin -relocation-model=pic -disable-fp-elim -O0 -regalloc=local
%struct.CGPoint = type { double, double }
%struct.NSArray = type { %struct.NSObject }
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -march=x86 -fast -fast-isel=false | grep mov | count 5
; RUN: llvm-as < %s | llc -march=x86 -O0 -fast-isel=false | grep mov | count 5
; PR2343
%llvm.dbg.anchor.type = type { i32, i32 }
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -mtriple=i386-apple-darwin -fast
; RUN: llvm-as < %s | llc -mtriple=i386-apple-darwin -O0
define fastcc void @optimize_bit_field() nounwind {
bb4:
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -mtriple=i386-apple-darwin -fast -regalloc=local | not grep sil
; RUN: llvm-as < %s | llc -mtriple=i386-apple-darwin -O0 -regalloc=local | not grep sil
; rdar://6787136
%struct.X = type { i8, [32 x i8] }
+2 -2
View File
@@ -1,7 +1,7 @@
; RUN: llvm-as < %s | llc -march=x86 | grep {jo} | count 2
; RUN: llvm-as < %s | llc -march=x86 | grep {jb} | count 2
; RUN: llvm-as < %s | llc -march=x86 -fast | grep {jo} | count 2
; RUN: llvm-as < %s | llc -march=x86 -fast | grep {jb} | count 2
; RUN: llvm-as < %s | llc -march=x86 -O0 | grep {jo} | count 2
; RUN: llvm-as < %s | llc -march=x86 -O0 | grep {jb} | count 2
@ok = internal constant [4 x i8] c"%d\0A\00"
@no = internal constant [4 x i8] c"no\0A\00"
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -march=x86 -fast
; RUN: llvm-as < %s | llc -march=x86 -O0
; This file is for regression tests for cases where FastISel needs
; to gracefully bail out and let SelectionDAGISel take over.
+2 -2
View File
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llc -march=x86-64 -fast | grep movslq
; RUN: llvm-as < %s | llc -march=x86 -fast
; RUN: llvm-as < %s | llc -march=x86-64 -O0 | grep movslq
; RUN: llvm-as < %s | llc -march=x86 -O0
; PR3181
; GEP indices are interpreted as signed integers, so they
+1 -1
View File
@@ -1,4 +1,4 @@
; RUN: llvm-as < %s | llc -march=x86 -fast | grep {sarl \$80, %eax}
; RUN: llvm-as < %s | llc -march=x86 -O0 | grep {sarl \$80, %eax}
; PR3242
define i32 @foo(i32 %x) nounwind {
+2 -2
View File
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llc -disable-fp-elim -fast -mcpu=i486 | grep 1082126238 | count 3
; RUN: llvm-as < %s | llc -disable-fp-elim -fast -mcpu=i486 | grep 3058016715 | count 1
; RUN: llvm-as < %s | llc -disable-fp-elim -O0 -mcpu=i486 | grep 1082126238 | count 3
; RUN: llvm-as < %s | llc -disable-fp-elim -O0 -mcpu=i486 | grep 3058016715 | count 1
;; magic constants are 3.999f and half of 3.999
; ModuleID = '1489.c'
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"
+1 -1
View File
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llc -march=x86 -mattr=sse2 | grep movsd | count 5
; RUN: llvm-as < %s | llc -march=x86 -mattr=sse2 -fast | grep movsd | count 5
; RUN: llvm-as < %s | llc -march=x86 -mattr=sse2 -O0 | grep movsd | count 5
@x = external global double