Chris Lattner
af6912f980
gcroot testcase, patch by Eric Christopher.
...
llvm-svn: 42198
2007-09-21 17:48:39 +00:00
Chris Lattner
1af762f736
I cannot spell coalesce :)
...
llvm-svn: 42196
2007-09-21 17:43:52 +00:00
Chris Lattner
12477735f9
gcroot must take concrete types, not arbitrary types.
...
clean up intrinsic descriptions in langref a bit.
llvm-svn: 42194
2007-09-21 17:30:40 +00:00
Chris Lattner
b3d01d2f56
initialize SetCCResultContents, fixing PR1693
...
llvm-svn: 42193
2007-09-21 17:06:39 +00:00
Rafael Espindola
4730c04904
Don't add a default STACK_ALIGN (use the generic ABI alignment)
...
Implement calls to functions with byval arguments on X86
llvm-svn: 42192
2007-09-21 15:50:22 +00:00
Dan Gohman
3bb3452dbc
There is no {rsqrt,rcp}{p,s}d.
...
llvm-svn: 42190
2007-09-21 15:24:00 +00:00
Rafael Espindola
f065f0e2a1
small cleanup: use LowerMemArgument in LowerFastCCArguments also
...
llvm-svn: 42189
2007-09-21 14:55:38 +00:00
Chris Lattner
0a1fd10483
Initial hack at 2.1 release notes.
...
llvm-svn: 42186
2007-09-21 03:54:09 +00:00
Owen Anderson
46da2a6262
Add partial caching of non-local memory dependence queries. This provides a modest
...
speedup for GVN.
llvm-svn: 42185
2007-09-21 03:53:52 +00:00
Evan Cheng
1ff71872c2
Honor user-defined section specification of a global, ignores whether its initializer is null.
...
llvm-svn: 42182
2007-09-21 00:41:19 +00:00
Dale Johannesen
146a0ea071
Fix PR 1688. See comments there.
...
llvm-svn: 42181
2007-09-20 23:47:58 +00:00
Devang Patel
83cc3f8f51
Update aux. info associated with an instruction before erasing instruction.
...
llvm-svn: 42180
2007-09-20 23:45:50 +00:00
Devang Patel
d29f938335
Do not override user specified section.
...
llvm-svn: 42179
2007-09-20 23:07:37 +00:00
Devang Patel
6117a3b696
Don't increment invalid iterator.
...
llvm-svn: 42178
2007-09-20 23:01:50 +00:00
Duncan Sands
416b9f0410
Testcase for PR1678.
...
llvm-svn: 42171
2007-09-20 18:56:24 +00:00
Evan Cheng
723dab1005
Disable if-conversion for this test.
...
llvm-svn: 42170
2007-09-20 18:06:22 +00:00
Evan Cheng
77d4771405
-enable-arm-if-conversion is gone.
...
llvm-svn: 42169
2007-09-20 18:03:23 +00:00
Dale Johannesen
cc7c475705
Fix dumb regression in constant folding (Regression/C/casts)
...
llvm-svn: 42165
2007-09-20 16:50:21 +00:00
Gordon Henriksen
d1e1645a4e
Regenerate.
...
llvm-svn: 42164
2007-09-20 16:48:18 +00:00
Gordon Henriksen
1f982339e7
Incorporating review feedback for GC verifier patch.
...
llvm-svn: 42163
2007-09-20 16:47:41 +00:00
Dan Gohman
4dbc582a36
Fix several more entries in the x86 reload/remat folding tables.
...
llvm-svn: 42162
2007-09-20 14:17:21 +00:00
Gabor Greif
4a46052d30
use typenames equivalent to
...
(u)intval, because latter are not
present in older caml/mlvalues.h
(e.g. 2004/07/07, 1.48.6.1)
Using this as a workaround for now,
until --without-ocaml works
or we settle on a better solution
llvm-svn: 42160
2007-09-20 10:20:34 +00:00
Dale Johannesen
95be037d67
another long double buglet
...
llvm-svn: 42159
2007-09-20 01:27:54 +00:00
Nick Lewycky
e7be16a053
Excuse me.
...
llvm-svn: 42158
2007-09-20 00:57:00 +00:00
Nick Lewycky
eae7e7d00b
Fix optimization. %x = sub %x, %y does not imply that %y is zero.
...
llvm-svn: 42157
2007-09-20 00:48:36 +00:00
Evan Cheng
8010320365
Enable if-conversion for ARM by default.
...
llvm-svn: 42156
2007-09-20 00:48:22 +00:00
Dale Johannesen
7d67e547b5
More long double fixes. x86_64 should build now.
...
llvm-svn: 42155
2007-09-19 23:55:34 +00:00
Evan Cheng
d0e360e16e
Avoid referencing deleted instruction.
...
llvm-svn: 42153
2007-09-19 21:48:07 +00:00
Ted Kremenek
ebc5500e50
Previously GraphWriter assumed operator*() for node_iterator always
...
returned a reference type. This patch allows operator*() to return a
non-reference type while still maintaining the old behavior when it
does return a reference type.
This patch was motivated when I tried to use "df_iterator" (see
llvm/ADT/DepthFirstIterator.h) as a "node_iterator", as df_iterator
does not return a reference type and thus we would get a compilation
error when trying to take the address of a temporary.
llvm-svn: 42151
2007-09-19 21:26:49 +00:00
Devang Patel
464276f831
Avoid unsafe promotion.
...
llvm-svn: 42149
2007-09-19 20:18:51 +00:00
Evan Cheng
513874cf3c
PSHUFDmi, etc. are actually folding a load, not a store.
...
llvm-svn: 42147
2007-09-19 19:02:47 +00:00
Dale Johannesen
b59d25fe54
Fix longdouble -> uint conversion.
...
llvm-svn: 42143
2007-09-19 17:53:26 +00:00
Chris Lattner
d79f3d51b1
reject things like "declare internal @foo"
...
llvm-svn: 42140
2007-09-19 17:14:45 +00:00
Owen Anderson
c201cbc802
Add a flag to mark a dirty cache entry. This is not yet used, but will eventually
...
help non-local memdep caching.
llvm-svn: 42137
2007-09-19 16:13:57 +00:00
Dale Johannesen
f4bad97ea0
Fix some long double issues.
...
llvm-svn: 42133
2007-09-19 14:22:58 +00:00
Duncan Sands
d31649bc59
Improve comment.
...
llvm-svn: 42132
2007-09-19 10:25:38 +00:00
Duncan Sands
a38e527523
Partial fix for PR1678: correct some parts of constant
...
fold that were missed in the fix for PR1646. Probably
this null/not-null logic should be factorized somewhere.
llvm-svn: 42131
2007-09-19 10:16:17 +00:00
Duncan Sands
56df7dec2b
A global variable with external weak linkage can be null, while
...
an alias could alias such a global variable.
llvm-svn: 42130
2007-09-19 10:10:31 +00:00
Gabor Greif
ef858c9ff6
include alloca.h if available. this helps Solaris, but intnat and uintnat types are still undefined, causing errors
...
llvm-svn: 42129
2007-09-19 09:29:58 +00:00
Duncan Sands
4e426623f5
Testcase for PR1678.
...
llvm-svn: 42128
2007-09-19 07:43:17 +00:00
Evan Cheng
0effc3a6b8
Use struct SDep instead of std::pair for SUnit pred and succ lists. First step
...
in tracking physical register output dependencies.
llvm-svn: 42125
2007-09-19 01:38:40 +00:00
Evan Cheng
17f589f76e
Set CCR (EFLAGS) copy cost to -1, i.e. extremely expensive to copy.
...
llvm-svn: 42124
2007-09-19 01:36:39 +00:00
Evan Cheng
f73fb6261b
Add CopyCost to TargetRegisterClass. This specifies the cost of copying a value
...
between two registers in the specific class.
llvm-svn: 42123
2007-09-19 01:35:01 +00:00
Devang Patel
69a55a38ed
Relax loop ExitCondition predicate restriction.
...
llvm-svn: 42122
2007-09-19 00:28:47 +00:00
Devang Patel
455a53b7db
Filter loops where split condition's false branch is not empty. For example
...
for (int i = 0; i < N; ++i) {
if (i == somevalue)
dosomething();
else
dosomethingelse();
}
llvm-svn: 42121
2007-09-19 00:15:16 +00:00
Devang Patel
4c238c451f
Bail out early, before modifying anything.
...
llvm-svn: 42120
2007-09-19 00:11:01 +00:00
Devang Patel
31f2c8592c
Work is incomplete. Loop is not modified at all right now.
...
llvm-svn: 42119
2007-09-19 00:08:13 +00:00
Devang Patel
ee35011d01
ooops...
...
llvm-svn: 42118
2007-09-18 23:58:14 +00:00
Evan Cheng
e7ff9da64b
Clean up.
...
llvm-svn: 42112
2007-09-18 22:56:31 +00:00
Evan Cheng
e2e8f2d96b
Fix a bogus splat xform:
...
shuffle <undef, undef, x, undef>, <undef, undef, undef, undef>, <2, 2, 2, 2>
!=
<undef, undef, x, undef>
llvm-svn: 42111
2007-09-18 21:54:37 +00:00
Gabor Greif
49122edc98
rename test, it is obviously misspelled
...
llvm-svn: 42108
2007-09-18 21:42:39 +00:00
Dale Johannesen
af12b57405
Prevent crash on long double.
...
llvm-svn: 42103
2007-09-18 18:36:59 +00:00
Gordon Henriksen
dc88c06732
Tests of the ocaml (and thus C) bindings for constants.
...
llvm-svn: 42101
2007-09-18 18:07:51 +00:00
Dan Gohman
8cca8469de
Move the entries for 64-bit CMP, IMUL, and a few others into the correct
...
tables so that they are eligible for reload/remat folding. And add
entries for JMP and CALL.
llvm-svn: 42094
2007-09-18 14:59:14 +00:00
Gordon Henriksen
37582f74cd
Adding ocaml language bindings for the vmcore and bitwriter libraries. These are
...
built atop the C language bindings, and user programs can link with them as
such:
# Bytecode
ocamlc -cc g++ llvm.cma llvmbitwriter.cma -o example example.ml
# Native
ocamlopt -cc g++ llvm.cmxa llvmbitwriter.cmxa -o example.opt example.ml
The vmcore.ml test exercises most/all of the APIs thus far bound. Unfortunately,
they're not yet numerous enough to write hello world. But:
$ cat example.ml
(* example.ml *)
open Llvm
open Llvm_bitwriter
let _ =
let filename = Sys.argv.(1) in
let m = create_module filename in
let v = make_int_constant i32_type 42 false in
let g = define_global "hello_world" v m in
if not (write_bitcode_file m filename) then exit 1;
dispose_module m;
$ ocamlc -cc g++ llvm.cma llvm_bitwriter.cma -o example example.ml
File "example.ml", line 11, characters 6-7:
Warning Y: unused variable g.
$ ./example example.bc
$ llvm-dis < example.bc
; ModuleID = '<stdin>'
@hello_world = global i32 42 ; <i32*> [#uses=0]
The ocaml test cases provide effective tests for the C interfaces.
llvm-svn: 42093
2007-09-18 12:49:39 +00:00
Gordon Henriksen
4c7ca7d61e
Regenerate.
...
llvm-svn: 42092
2007-09-18 12:27:13 +00:00
Gordon Henriksen
c0f56013e1
(no commit message)
...
llvm-svn: 42091
2007-09-18 12:26:59 +00:00
Gordon Henriksen
5c4d7b8052
(no commit message)
...
llvm-svn: 42090
2007-09-18 12:26:17 +00:00
Gordon Henriksen
be6bd16418
Incorporating review feedback for GC verifier patch.
...
llvm-svn: 42087
2007-09-18 10:14:30 +00:00
Bill Wendling
e8c885f261
Don't pass back a reference to a temporary.
...
llvm-svn: 42086
2007-09-18 09:10:16 +00:00
Bill Wendling
a83fd8014d
Update my entry.
...
llvm-svn: 42079
2007-09-18 05:28:19 +00:00
Bill Wendling
69833b61ac
The exception handling function info should be reset for each new
...
function. The information isn't used heavily -- it's only used at the end
of exception handling emission -- so there's no need to cache it.
llvm-svn: 42078
2007-09-18 05:03:44 +00:00
Gordon Henriksen
76a0374b25
C bindings for libLLVMCore.a and libLLVMBitWriter.a.
...
- The naming prefix is LLVM.
- All types are represented using opaque references.
- Functions are not named LLVM{Type}{Method}; the names became
unreadable goop. Instead, they are named LLVM{ImperativeSentence}.
- Where an attribute only appears once in the class hierarchy (e.g.,
linkage only applies to values; parameter types only apply to
function types), the class is omitted from identifiers for
brevity. Tastes like methods.
- Strings are C strings or string/length tuples on a case-by-case
basis.
- APIs which give the caller ownership of an object are not mapped
(removeFromParent, certain constructor overloads). This keeps
keep memory management as simple as possible.
For each library with bindings:
llvm-c/<LIB>.h - Declares the bindings.
lib/<LIB>/<LIB>.cpp - Implements the bindings.
So just link with the library of your choice and use the C header
instead of the C++ one.
llvm-svn: 42077
2007-09-18 03:18:57 +00:00
Gordon Henriksen
64e72c034a
Fixing an comment in Module.h that refers to a nonexistent parameter.
...
Also adding some missing svn:ignores that've been bothering me.
llvm-svn: 42076
2007-09-18 02:09:34 +00:00
Devang Patel
fcda998ab2
Fix PR1657
...
llvm-svn: 42075
2007-09-18 01:54:42 +00:00
Bill Wendling
067f1d8e95
Objective-C was generating EH frame info like this:
...
"_-[NSString(local) isNullOrNil]".eh = 0
.no_dead_strip "_-[NSString(local) isNullOrNil]".eh
The ".eh" should be inside the quotes.
llvm-svn: 42074
2007-09-18 01:47:22 +00:00
Bill Wendling
5752f692ed
Add support for appending a suffix to the end of a mangled name.
...
llvm-svn: 42071
2007-09-17 22:39:32 +00:00
Evan Cheng
ffd6995cc7
Bug fix and minor clean up of generated code.
...
llvm-svn: 42069
2007-09-17 22:26:41 +00:00
Devang Patel
00064e1bab
Do not hide APInt::dump() inside #ifndef NDEBUG.
...
llvm-svn: 42068
2007-09-17 22:24:00 +00:00
Tanya Lattner
613ccacb49
Fix broken default help strings for enable-shared, enable-static, and enable-fast-install. Regenerate configure script.
...
llvm-svn: 42066
2007-09-17 21:41:15 +00:00
Devang Patel
267c07b51f
Do not eliminate loop when it is invalid to do so. For example,
...
for(int i = 0; i < N; i++) {
if ( i == XYZ) {
A;
else
B;
}
C;
D;
}
llvm-svn: 42058
2007-09-17 21:01:05 +00:00
Devang Patel
712dbe9d13
Skeleton for transformations to truncate loop's iteration space.
...
llvm-svn: 42054
2007-09-17 20:39:48 +00:00
Gordon Henriksen
a2f3e13cf4
Fix for PR1633: Verifier doesn't fully verify GC intrinsics
...
LLVM now enforces the following prototypes for the write barriers:
<ty>* @llvm.gcread(<ty2>*, <ty>**)
void @llvm.gcwrite(<ty>*, <ty2>*, <ty>**)
And for @llvm.gcroot, the first stack slot is verified to be an alloca or a
bitcast of an alloca.
Fixes test/CodeGen/Generic/GC/lower_gcroot.ll, which violated these.
llvm-svn: 42051
2007-09-17 20:30:04 +00:00
Dale Johannesen
ff7e443792
Remove RSTRegClass case from loadRegFromStackSlot
...
and storeRegToStackSlot. Evan and I concluded this
should never be needed and it appears to be true.
(It if is needed, adjustment would be needed for
long double to work.)
llvm-svn: 42049
2007-09-17 20:15:38 +00:00
Devang Patel
9d1af9b63d
Fix comment.
...
llvm-svn: 42048
2007-09-17 20:07:40 +00:00
Devang Patel
77ae4d358f
This is not ideal but unbreaks build failure.
...
APInt::dump() is inside #ifndef NDEBUG, however SelectionDAG dump() routines are not.
llvm-svn: 42047
2007-09-17 20:03:03 +00:00
Dale Johannesen
a1336cf57e
Implement x86 long double in jit (not really
...
complete, but common cases work)
llvm-svn: 42043
2007-09-17 18:44:13 +00:00
Chris Lattner
0625bd6472
Merge DenseMapKeyInfo & DenseMapValueInfo into DenseMapInfo
...
Add a new DenseMapInfo::isEqual method to allow clients to redefine
the equality predicate used when probing the hash table.
llvm-svn: 42042
2007-09-17 18:34:04 +00:00
Daniel Berlin
bd590a8287
That's what i get for using carbon emacs in a terminal
...
llvm-svn: 42040
2007-09-17 18:05:59 +00:00
Daniel Berlin
28ae955181
Fix iterator so it doesn't sometimes report bits that aren't in the bitmap
...
llvm-svn: 42039
2007-09-17 18:04:21 +00:00
Dan Gohman
e903c1021f
Add a utility function to SDOperand for testing if a value is unused.
...
llvm-svn: 42038
2007-09-17 17:44:31 +00:00
Evan Cheng
8070099fef
X86ISD::TEST is dead.
...
llvm-svn: 42037
2007-09-17 17:42:53 +00:00
Chris Lattner
1406f7143b
regenerate
...
llvm-svn: 42036
2007-09-17 17:40:48 +00:00
Dan Gohman
2ac2652779
Instcombine x-((x/y)*y) into a remainder operator.
...
llvm-svn: 42035
2007-09-17 17:31:57 +00:00
Gordon Henriksen
8f0e2f2329
Adding myself to credits.
...
llvm-svn: 42032
2007-09-17 17:04:44 +00:00
Dan Gohman
3243e10ef0
Add 64-bit jmp instructions to the list of instructions that
...
can terminate a block with no fall-through.
llvm-svn: 42029
2007-09-17 15:19:08 +00:00
Dan Gohman
96aee15d33
Use xorl instead of xorq to enter a zero into a 64-bit register.
...
llvm-svn: 42027
2007-09-17 14:55:08 +00:00
Dan Gohman
863bdc332d
Emit integer x<1 as x<=0, as comparisons with zero (now includeing
...
64-bit) can use test instead of cmp with an immediate.
llvm-svn: 42026
2007-09-17 14:49:27 +00:00
Dan Gohman
51d1929b9e
Use "test reg,reg" in place of "cmp reg,0" for 64-bit operands. This was
...
previously only done for 32-bit and smaller operands.
llvm-svn: 42024
2007-09-17 14:35:24 +00:00
Duncan Sands
6d5da71288
Factor the trampoline transformation into a subroutine.
...
llvm-svn: 42021
2007-09-17 10:26:40 +00:00
Dale Johannesen
7511e6b622
Implement x86 long double (uses host long double,
...
so only works on x86 target).
llvm-svn: 42019
2007-09-17 00:38:27 +00:00
Daniel Berlin
90aaa1dcf7
Fix bug in andersen's related to test_and_set.
...
Add operator == and != to SparseBitVector.
Simplify code for test_and_set
llvm-svn: 42018
2007-09-16 23:59:53 +00:00
Daniel Berlin
c637abee96
Fix a few bugs related to zero'ing of elements
...
llvm-svn: 42017
2007-09-16 22:31:47 +00:00
Daniel Berlin
ffce584d1c
Rewrite of andersen's to be about 100x faster, cleaner, and begin to support field sensitivity
...
llvm-svn: 42016
2007-09-16 21:45:02 +00:00
Bill Wendling
327e1a386c
Follow-up to patch r41999. Make the conditional that emits the personality stub
...
match the conditional that turns on exception handling emittion in the asm
printer.
llvm-svn: 42008
2007-09-16 19:21:08 +00:00
Dale Johannesen
7f724e9b94
Adjust per revew comments.
...
llvm-svn: 42002
2007-09-16 16:51:49 +00:00
Bill Wendling
e5615156cc
Only emit the personality function as a global value if the backend actually
...
supports it. This solves this error on the Darwin x86-64 platform:
$ cat testcase.ii
struct A {
A();
};
A *bork() {
return new A;
}
$ llvm-g++ -arch x86_64 -c testcase.ii
/var/tmp//cc3U8fd8.s:52:unknown section type: non_lazy_symbol_pointers
/var/tmp//cc3U8fd8.s:52:Rest of line ignored. 1st junk character valued 76 (L).
/var/tmp//cc3U8fd8.s:53:Unknown pseudo-op: .indirect_symbol
/var/tmp//cc3U8fd8.s:53:Rest of line ignored. 1st junk character valued 95 (_).
llvm-svn: 41999
2007-09-16 10:36:17 +00:00
Owen Anderson
4cd516b50b
Be more careful when constant-folding PHI nodes.
...
llvm-svn: 41998
2007-09-16 08:04:16 +00:00
Chris Lattner
dd76f2f4ab
remove obsolete tests.
...
llvm-svn: 41984
2007-09-15 17:38:04 +00:00
Chris Lattner
4f230451e1
Fix PR1666, SPASS with the CBE and 254.gap with the CBE.
...
GCC optimizes away things like ptr < NULL to false. To "fix" this,
have the CBE emit casts of pointers to intptr_t when doing relational
pointer comparisons.
llvm-svn: 41983
2007-09-15 06:51:03 +00:00
Chris Lattner
6ad68c220a
New testcase for PR1662. GCC trees are horrible :(
...
llvm-svn: 41979
2007-09-15 05:46:41 +00:00
Dan Gohman
48ea03d169
Add patterns for SHLD64* and SHRD64*.
...
llvm-svn: 41975
2007-09-14 23:17:45 +00:00
Chris Lattner
6395e5060d
fix a gcc warning: comparison between signed and unsigned integer expressions
...
llvm-svn: 41972
2007-09-14 22:57:00 +00:00
Owen Anderson
3454dd3750
Remove RLE from the headers, since the pass itself is gone now.
...
llvm-svn: 41971
2007-09-14 22:54:46 +00:00
Owen Anderson
8d0cb881e5
Remove RLE. It is subsumed by GVN.
...
llvm-svn: 41968
2007-09-14 22:33:52 +00:00
Dale Johannesen
98d3a08d8f
Remove the assumption that FP's are either float or
...
double from some of the many places in the optimizers
it appears, and do something reasonable with x86
long double.
Make APInt::dump() public, remove newline, use it to
dump ConstantSDNode's.
Allow APFloats in FoldingSet.
Expand X86 backend handling of long doubles (conversions
to/from int, mostly).
llvm-svn: 41967
2007-09-14 22:26:36 +00:00
Evan Cheng
483e1ce16e
Add implicit def of EFLAGS on those instructions that may modify flags.
...
llvm-svn: 41962
2007-09-14 21:48:26 +00:00
Dan Gohman
14cf78cde5
And an FoldingSetImpl::NodeID::AddInteger overload for int64_t, to avoid
...
ambiguity.
llvm-svn: 41960
2007-09-14 20:48:42 +00:00
Dan Gohman
c519c38629
Add explicit triples to avoid default behavior that varies by host.
...
llvm-svn: 41959
2007-09-14 20:37:18 +00:00
Dan Gohman
9da02f5ee2
Remove isReg, isImm, and isMBB, and change all their users to use
...
isRegister, isImmediate, and isMachineBasicBlock, which are equivalent,
and more popular.
llvm-svn: 41958
2007-09-14 20:33:02 +00:00
Dan Gohman
a7b26e6bb3
Change "tmp." to "tmp" for temporaries created by ScalarEvolutionExpander
...
for consistency with many other transforms.
llvm-svn: 41957
2007-09-14 20:11:40 +00:00
Dan Gohman
58c468fb09
Remove spurious consts. This fixes warnings with compilers that
...
are strict about such things.
llvm-svn: 41956
2007-09-14 20:08:19 +00:00
Rafael Espindola
272f7304f0
Add support for functions with byval arguments on x86
...
llvm-svn: 41953
2007-09-14 15:48:13 +00:00
Chris Lattner
5d13fb538f
Fix a logic error in ValueIsOnlyUsedLocallyOrStoredToOneGlobal that caused
...
miscompilation of 188.ammp. Reject select and bitcast in
ValueIsOnlyUsedLocallyOrStoredToOneGlobal because RewriteHeapSROALoadUser can't handle it.
llvm-svn: 41950
2007-09-14 03:41:21 +00:00
Chris Lattner
d9111b88d1
silence a bogus gcc warning.
...
llvm-svn: 41949
2007-09-14 03:07:24 +00:00
Evan Cheng
5196f617a1
Fix comments.
...
llvm-svn: 41947
2007-09-14 01:57:02 +00:00
Tanya Lattner
36a6fcd327
Change to 2.2svn.
...
llvm-svn: 41941
2007-09-14 01:24:13 +00:00
Bill Wendling
264d4813c7
Temporary reverting r41817
...
(http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070910/053370.html ). It's
causing SPASS to fail.
llvm-svn: 41938
2007-09-14 01:13:55 +00:00
Chris Lattner
011f91b5b2
Teach GlobalLoadUsesSimpleEnoughForHeapSRA and the SROA rewriter how to handle
...
a limited form of PHI nodes. This finally fixes PR1639, speeding 179.art up
from 7.84s to 3.13s on PPC.
llvm-svn: 41933
2007-09-13 21:31:36 +00:00
Chris Lattner
ba98f89388
be tolerant of PHI nodes when rewriting heap SROA code. This is a step
...
along the way of PR1639
llvm-svn: 41930
2007-09-13 18:00:31 +00:00
Chris Lattner
f315d4f1a7
refactor some code, no functionality change. On the path to PR1639
...
llvm-svn: 41929
2007-09-13 17:29:05 +00:00
Chris Lattner
6eed0e7366
Make ValueIsOnlyUsedLocallyOrStoredToOneGlobal smart enough to see through
...
bitcasts and phis. This is a step to fixing PR1639.
llvm-svn: 41928
2007-09-13 16:37:20 +00:00
Chris Lattner
2d2892ee6e
Make AllUsesOfLoadedValueWillTrapIfNull strong enough to see through PHI
...
nodes. This is the first step of the fix for PR1639.
llvm-svn: 41927
2007-09-13 16:30:19 +00:00
Chris Lattner
3fd6bf8275
remove dead enum value.
...
llvm-svn: 41925
2007-09-13 06:18:04 +00:00
Chris Lattner
6ff85b2e5a
Make single-argument ctors explicit to avoid tricky bugs :)
...
llvm-svn: 41924
2007-09-13 06:15:57 +00:00
Chris Lattner
7955bbd9fd
Fix build problems on Cygwin (PR1652), patch by Patrick Walton.
...
llvm-svn: 41923
2007-09-13 06:09:48 +00:00
Evan Cheng
b2c42621df
Added getNumDefs().
...
llvm-svn: 41901
2007-09-13 00:16:29 +00:00
Evan Cheng
100c8d6c8f
Bug fixes.
...
llvm-svn: 41900
2007-09-13 00:06:00 +00:00
Evan Cheng
57ff158255
Remove dead code.
...
llvm-svn: 41899
2007-09-12 23:45:46 +00:00
Evan Cheng
bb6a574def
Yet another getTargetNode variant.
...
llvm-svn: 41898
2007-09-12 23:39:49 +00:00
Evan Cheng
59c39dc197
Initial support for multi-result patterns:
...
1.
[(set GR32:$dst, (add GR32:$src1, GR32:$src2)),
(modify EFLAGS)]
This indicates the source pattern expects the instruction would produce 2 values. The first is the result of the addition. The second is an implicit definition in register EFLAGS.
2.
def : Pat<(parallel (addc GR32:$src1, GR32:$src2), (modify EFLAGS)), ()>
Similar to #1 except this is used for def : Pat patterns.
llvm-svn: 41897
2007-09-12 23:30:14 +00:00
Evan Cheng
d8317967aa
Fixed a typo that's causing a missing kill marker.
...
llvm-svn: 41893
2007-09-12 23:02:04 +00:00
Chris Lattner
909ef0973b
add a new BF->LLVM translator, contributed by Sterling Stein.
...
llvm-svn: 41881
2007-09-12 18:24:00 +00:00
Chris Lattner
7b412cb823
Change llvm.gcroot to not init the root to null at runtime, this prevents
...
using it for live-in values etc.
llvm-svn: 41879
2007-09-12 17:53:10 +00:00
Dale Johannesen
100410af13
Generated files for previous patch.
...
llvm-svn: 41876
2007-09-12 03:31:28 +00:00
Dale Johannesen
028084efe5
Revise previous patch per review comments.
...
Next round of x87 long double stuff.
Getting close now, basically works.
llvm-svn: 41875
2007-09-12 03:30:33 +00:00
Dale Johannesen
521988b604
Compensate for partCount change in Bogus definition
...
(could break hash table in ConstantFP)
llvm-svn: 41874
2007-09-12 01:22:05 +00:00
Bill Wendling
66c22e8fd6
Enable indirect encoding for the personality function
...
llvm-svn: 41873
2007-09-11 23:55:40 +00:00
Daniel Berlin
a3bba5ce20
Move dump out of class, use "\n" instead of endl
...
llvm-svn: 41872
2007-09-11 22:58:27 +00:00
Evan Cheng
c16847b157
Sometimes a MI can define a register as well as defining a super-register at the
...
same time. Do not mark the "smaller" def as dead.
llvm-svn: 41871
2007-09-11 22:34:47 +00:00
Anton Korobeynikov
9811eb3d07
Fix date :)
...
llvm-svn: 41870
2007-09-11 22:20:27 +00:00
Anton Korobeynikov
38f9e2a4b6
Testcase for recent pragma pack stuff
...
llvm-svn: 41869
2007-09-11 22:12:26 +00:00
Evan Cheng
3e18e504ae
Remove (somewhat confusing) Imp<> helper, use let Defs = [], Uses = [] instead.
...
llvm-svn: 41863
2007-09-11 19:55:27 +00:00
Evan Cheng
50b6730ae4
Added status flags register: EFLAGS.
...
llvm-svn: 41862
2007-09-11 19:53:28 +00:00
Evan Cheng
c7852a689a
Allow set operators with multiple destinations, i.e. (set x, y, (op a, b)).
...
llvm-svn: 41861
2007-09-11 19:52:18 +00:00
Dale Johannesen
216788aacb
Generated files for previous patch.
...
llvm-svn: 41859
2007-09-11 18:33:39 +00:00
Dale Johannesen
245dceb06d
Add APInt interfaces to APFloat (allows directly
...
access to bits). Use them in place of float and
double interfaces where appropriate.
First bits of x86 long double constants handling
(untested, probably does not work).
llvm-svn: 41858
2007-09-11 18:32:33 +00:00
Daniel Berlin
32ef96186f
Convert to use ilist and non-pointer lists for extra goodness
...
llvm-svn: 41855
2007-09-11 17:42:22 +00:00
Bill Wendling
beb541544d
Add accessor method.
...
llvm-svn: 41854
2007-09-11 17:24:38 +00:00
Bill Wendling
74fb0f1a1c
Add a bool to indicate if we should set the "indirect encoding" bit in the Dwarf
...
information for EH.
llvm-svn: 41852
2007-09-11 17:20:55 +00:00
Chris Lattner
69c1b10993
Reenable libgc and libprofile is explicitly requested.
...
llvm-svn: 41851
2007-09-11 17:12:32 +00:00
Chris Lattner
e09791c399
remove an obsolete library.
...
llvm-svn: 41850
2007-09-11 17:10:52 +00:00
Chris Lattner
9190ffe62e
update this to use llvm-config, patch by Jose M. Moya
...
llvm-svn: 41849
2007-09-11 17:09:54 +00:00
Duncan Sands
94580c7522
Test that a call to a trampoline is turned into a call to
...
the underlying nested function.
llvm-svn: 41846
2007-09-11 15:07:50 +00:00
Duncan Sands
d781335d39
Two ParamAttrsVectors which differ by a permutation
...
of their elements do not yield the same ParamAttrsList,
though they should. On the other hand, everyone seems
to pass such vectors with elements ordered by increasing
index, so rather than sorting the elements simply assert
that the elements are ordered in this way.
llvm-svn: 41845
2007-09-11 14:40:04 +00:00
Duncan Sands
9204663bcb
Turn calls to trampolines into calls to the underlying
...
nested function.
llvm-svn: 41844
2007-09-11 14:35:41 +00:00
Duncan Sands
86e0119822
Fold the adjust_trampoline intrinsic into
...
init_trampoline. There is now only one
trampoline intrinsic.
llvm-svn: 41841
2007-09-11 14:10:23 +00:00
Duncan Sands
1a11e1c14f
My compiler warns about the semicolon.
...
llvm-svn: 41840
2007-09-11 12:30:25 +00:00
Bill Wendling
2b8fc31df9
The personality function on Darwin needs a global stub. We then refer to
...
that global stub instead of doing the ".set" thingy we were doing before.
llvm-svn: 41838
2007-09-11 08:27:17 +00:00
Owen Anderson
887ecdeb01
Add a ValueInfoT template parameter to DenseMap so that it can properly make decisions
...
based on whether the key AND the value require ctors/dtors.
llvm-svn: 41837
2007-09-11 05:08:05 +00:00
Owen Anderson
d7a698afc5
Don't bother to initialize values corresponding to empty or tombstone
...
keys.
llvm-svn: 41834
2007-09-11 04:43:51 +00:00
Owen Anderson
f9203ab36a
Fix a typo in memdep, which was causing PR1648.
...
llvm-svn: 41833
2007-09-11 04:31:00 +00:00
Daniel Berlin
d10be14a97
Fix bugs with &=, intersect with complement. Add three argument version of intersect with complement.
...
llvm-svn: 41832
2007-09-11 04:11:28 +00:00
Owen Anderson
4484d0d51a
Fix non-deterministic behavior in the DenseMap copy constructor.
...
llvm-svn: 41831
2007-09-11 03:48:08 +00:00
Daniel Berlin
2b6e98b89a
Add remaining functions necessary for andersen's
...
llvm-svn: 41830
2007-09-11 01:38:07 +00:00
Devang Patel
7ed6eb8992
Avoid negative logic.
...
llvm-svn: 41829
2007-09-11 01:10:45 +00:00
Devang Patel
8c95373ced
Refactor code into a separate method.
...
llvm-svn: 41826
2007-09-11 00:42:56 +00:00
Chris Lattner
0678def8d3
Testcase for PR1634
...
llvm-svn: 41824
2007-09-11 00:39:43 +00:00
Devang Patel
d67479b6ee
Clear split info object.
...
llvm-svn: 41823
2007-09-11 00:23:56 +00:00
Devang Patel
a28a7f1b2d
Split condition does not have to be ICmpInst in all cases.
...
llvm-svn: 41822
2007-09-11 00:12:56 +00:00
Devang Patel
f4202e91f8
Check all terminators inside loop.
...
llvm-svn: 41821
2007-09-10 23:57:58 +00:00
Chris Lattner
6cf04f4952
remove obsolete testcase
...
llvm-svn: 41820
2007-09-10 23:51:41 +00:00
Chris Lattner
e804567cd8
remove some dead code, this is handled by constant folding.
...
llvm-svn: 41819
2007-09-10 23:46:29 +00:00
Chris Lattner
52fe869374
Fix a buggy constant folding transformation when handling aliases.
...
llvm-svn: 41818
2007-09-10 23:42:42 +00:00
Devang Patel
2181b8e86a
Swap exit condition operands if it works.
...
llvm-svn: 41817
2007-09-10 23:34:06 +00:00
Chris Lattner
740d8049f4
regenerate
...
llvm-svn: 41816
2007-09-10 23:24:14 +00:00
Chris Lattner
dae70d4d36
Fix PR1645 by resolving forward alias references.
...
llvm-svn: 41815
2007-09-10 23:23:53 +00:00
Dale Johannesen
62a48cea56
Add missing llvm-dis.
...
llvm-svn: 41813
2007-09-10 22:47:59 +00:00
Evan Cheng
f948772f9e
80 col.
...
llvm-svn: 41812
2007-09-10 22:22:23 +00:00
Evan Cheng
8c3c198499
New entry.
...
llvm-svn: 41810
2007-09-10 22:16:37 +00:00
Evan Cheng
3b9f777f47
Observation of rematerialization.
...
llvm-svn: 41809
2007-09-10 22:11:18 +00:00
Chris Lattner
6777b72659
Add some notes about better flag handling.
...
llvm-svn: 41808
2007-09-10 21:43:18 +00:00
Chris Lattner
58c227bd09
Emit:
...
cmpl %eax, %ecx
setae %al
movzbl %al, %eax
instead of:
cmpl %eax, %ecx
setb %al
xorb $1, %al
movzbl %al, %eax
when using logical not of a C comparison.
llvm-svn: 41807
2007-09-10 21:39:07 +00:00
Chris Lattner
7a9935c31f
this is not infinite recursion.
...
llvm-svn: 41806
2007-09-10 21:16:23 +00:00
Chris Lattner
33a7f51412
1. Don't call Value::getName(), which is slow.
...
2. Lower calls to fabs and friends to FABS nodes etc unless the function has
internal linkage. Before we wouldn't lower if it had a definition, which
is incorrect. This allows us to compile:
define double @fabs(double %f) {
%tmp2 = tail call double @fabs( double %f )
ret double %tmp2
}
into:
_fabs:
fabs f1, f1
blr
llvm-svn: 41805
2007-09-10 21:15:22 +00:00
Chris Lattner
c75cbe6473
Prevent tailcallelim from breaking "recursive" calls to builtins.
...
llvm-svn: 41804
2007-09-10 20:58:55 +00:00
Evan Cheng
637395e6bd
It's not safe to rematerialize MOV32r0 etc. by simply cloning the original
...
instruction. These are implemented with xor which will modify the conditional
code. They should be rematerialized as move instructions.
llvm-svn: 41802
2007-09-10 20:48:53 +00:00
Devang Patel
f8ab0a9acc
Filter exit conditions which are not yet handled.
...
llvm-svn: 41800
2007-09-10 18:33:42 +00:00
Devang Patel
c24099ac82
New test.
...
llvm-svn: 41799
2007-09-10 18:12:52 +00:00
Devang Patel
d7409fdce5
Require SCEV before LCSSA.
...
llvm-svn: 41798
2007-09-10 18:08:23 +00:00
Owen Anderson
82e4fa1020
Remove an un-needed dependence query. This improves compile time marginally on 401.bzip2.
...
llvm-svn: 41792
2007-09-09 21:43:49 +00:00
Daniel Berlin
e80ca9c2c6
Add SparseBitVector implementation
...
llvm-svn: 41790
2007-09-09 01:10:40 +00:00
Owen Anderson
4266bb73e8
Turn GVN on by default.
...
llvm-svn: 41787
2007-09-08 22:23:52 +00:00
Dale Johannesen
29e6ac4281
Implement misaligned FP loads and stores.
...
llvm-svn: 41786
2007-09-08 19:29:23 +00:00
Nick Lewycky
a9b13d5cc1
Fix description of the call instruction. There are two types, with one being
...
optional.
llvm-svn: 41785
2007-09-08 13:57:50 +00:00
Chuck Rose III
bf19e0a556
Fix for VisualStudio. It is treating a 2 bit enum as a signed int for comparison purposes, causing failures. Using an extra bit fixes it.
...
llvm-svn: 41784
2007-09-08 04:17:08 +00:00
Evan Cheng
ee8d9a0e81
Smarter Reset(). Instead of deallocating all memory regions and reallocate the
...
first region, just deallocate all but the last region in the list.
llvm-svn: 41782
2007-09-08 00:02:17 +00:00
Evan Cheng
cef2c0efcc
TableGen no longer emit CopyFromReg nodes for implicit results in physical
...
registers. The scheduler is now responsible for emitting them.
llvm-svn: 41781
2007-09-07 23:59:02 +00:00
Bill Wendling
9929bc403d
Add missing index versions of instructions to the map.
...
llvm-svn: 41776
2007-09-07 22:01:02 +00:00
Dan Gohman
a95cbb0007
Avoid storing and reloading zeros and other constants from stack slots
...
by flagging the associated instructions as being trivially rematerializable.
llvm-svn: 41775
2007-09-07 21:32:51 +00:00
Dale Johannesen
9e70086c8f
Apply feedback from previous patch.
...
llvm-svn: 41774
2007-09-07 21:07:57 +00:00
Dale Johannesen
b6d795c1fc
Revert previous change to IR.
...
llvm-svn: 41769
2007-09-07 18:31:50 +00:00
Rafael Espindola
1de0c86717
Add support for having different alignment for objects on call frames.
...
The x86-64 ABI states that objects passed on the stack have
8 byte alignment. Implement that.
llvm-svn: 41768
2007-09-07 14:52:14 +00:00
Anton Korobeynikov
122bf4be7e
Split eh.select / eh.typeid.for intrinsics into i32/i64 versions. This is needed, because they just "mark" register
...
liveins and we let frontend solve type issue, not lowering code :)
llvm-svn: 41763
2007-09-07 11:39:35 +00:00
Bill Wendling
5f912b9149
Test for PR1641.
...
llvm-svn: 41762
2007-09-07 08:30:09 +00:00
Chris Lattner
85a51e0060
Don't zap back to back volatile load/stores
...
llvm-svn: 41759
2007-09-07 05:33:03 +00:00
Owen Anderson
e2f23a3abf
Add lengthof and endof templates that hide a lot of sizeof computations.
...
Patch by Sterling Stein!
llvm-svn: 41758
2007-09-07 04:06:50 +00:00
David Greene
517d5d8ebe
Constify to catch bugs.
...
llvm-svn: 41751
2007-09-06 19:46:46 +00:00
Dale Johannesen
bed9dc423c
Next round of APFloat changes.
...
Use APFloat in UpgradeParser and AsmParser.
Change all references to ConstantFP to use the
APFloat interface rather than double. Remove
the ConstantFP double interfaces.
Use APFloat functions for constant folding arithmetic
and comparisons.
(There are still way too many places APFloat is
just a wrapper around host float/double, but we're
getting there.)
llvm-svn: 41747
2007-09-06 18:13:44 +00:00
Anton Korobeynikov
a07765b8f4
Proper handle case, when aliasee is external weak symbol referenced only by alias itself.
...
Also, fix a case, when target doesn't have weak symbols supported.
llvm-svn: 41746
2007-09-06 17:21:48 +00:00
David Greene
a6d5d2a6a0
Add instruction dump output. This helps find bugs.
...
llvm-svn: 41744
2007-09-06 16:36:39 +00:00
David Greene
65d2a697dc
Pluggable coalescers inplementation.
...
llvm-svn: 41743
2007-09-06 16:18:45 +00:00
Nick Lewycky
0c5c47944a
Use isTrueWhenEqual. Thanks Chris!
...
llvm-svn: 41741
2007-09-06 02:40:25 +00:00
Nick Lewycky
b0b066eaaa
When the two operands of an icmp are equal, there are five possible predicates
...
that would make the icmp true. Fixes PR1637.
llvm-svn: 41740
2007-09-06 01:10:22 +00:00
Evan Cheng
d059eed1c1
Fix a memory leak.
...
llvm-svn: 41739
2007-09-06 01:07:24 +00:00
Evan Cheng
189df733ed
Fix a bug in X86InstrInfo::convertToThreeAddress that caused it to codegen:
...
leal (,%rcx,8), %rcx
It should be
leal (,%rcx,8), %ecx
llvm-svn: 41735
2007-09-06 00:14:41 +00:00
Bill Wendling
b65ef38590
LVXL and STVXL are also a load and store resp.
...
llvm-svn: 41733
2007-09-05 23:47:12 +00:00
Evan Cheng
26038c3918
Accidentially left this out.
...
llvm-svn: 41730
2007-09-05 21:58:18 +00:00
Evan Cheng
db53aef53e
Use pool allocator for all the VNInfo's to improve memory access locality. This reduces coalescing time on siod Mac OS X PPC by 35%. Also remove the back ptr from VNInfo to LiveInterval and other tweaks.
...
llvm-svn: 41729
2007-09-05 21:46:51 +00:00
Evan Cheng
3dba41bf37
Added Reset() to free all allocated memory regions and reset state to be the same as right after ctor.
...
llvm-svn: 41728
2007-09-05 21:41:34 +00:00
Evan Cheng
19ce37a1cd
Missing break. Patch by Wojciech Matyjewicz.
...
llvm-svn: 41727
2007-09-05 21:36:14 +00:00
Dale Johannesen
728687c423
Fix mod so it actually works. Fix conversions to
...
native types to handle denormals correctly.
llvm-svn: 41726
2007-09-05 20:39:49 +00:00
Chuck Rose III
2320323647
Forgot to obey 80 column rule. Fixing that.
...
llvm-svn: 41725
2007-09-05 20:36:41 +00:00
Dale Johannesen
6480cc6f8c
Change all floating constants that are not exactly
...
representable to use hex format.
llvm-svn: 41722
2007-09-05 17:50:36 +00:00
Chuck Rose III
e58572233d
Added default parameters to GetElementPtrInstr constructor call. Visual Studio 2k5 was getting confused and was unable to compile it. Suspected compiler error.
...
llvm-svn: 41721
2007-09-05 16:54:38 +00:00
Duncan Sands
2c0a0fb725
Due to label merging, the last label for an invoke
...
may be the same as the first label for the following
invoke. Remove a micro-optimization which was wrong
in this case.
llvm-svn: 41720
2007-09-05 14:12:46 +00:00
Duncan Sands
6820abe101
Testcases for PR1628.
...
llvm-svn: 41719
2007-09-05 11:53:04 +00:00
Duncan Sands
3c1b7fc056
Fix PR1628. When exception handling is turned on,
...
labels are generated bracketing each call (not just
invokes). This is used to generate entries in
the exception table required by the C++ personality.
However it gets in the way of tail-merging. This
patch solves the problem by no longer placing labels
around ordinary calls. Instead we generate entries
in the exception table that cover every instruction
in the function that wasn't covered by an invoke
range (the range given by the labels around the invoke).
As an optimization, such entries are only generated for
parts of the function that contain a call, since for
the moment those are the only instructions that can
throw an exception [1]. As a happy consequence, we
now get a smaller exception table, since the same
region can cover many calls. While there, I also
implemented folding of invoke ranges - successive
ranges are merged when safe to do so. Finally, if
a selector contains only a cleanup, there's a special
shorthand for it - place a 0 in the call-site entry.
I implemented this while there. As a result, the
exception table output (excluding filters) is now
optimal - it cannot be made smaller [2]. The
problem with throw filters is that folding them
optimally is hard, and the benefit of folding them is
minimal.
[1] I tested that having trapping instructions (eg
divide by zero) in such a region doesn't cause trouble.
[2] It could be made smaller with the help of higher
layers, eg by having branch folding reorder basic blocks
ending in invokes with the same landing pad so they
follow each other. I don't know if this is worth doing.
llvm-svn: 41718
2007-09-05 11:27:52 +00:00
Bill Wendling
b9bf812ba5
Add the 64-bit versions of the DS* Altivec instructions.
...
llvm-svn: 41717
2007-09-05 04:05:20 +00:00
Devang Patel
42e2abe0e8
Enable loop index split pass.
...
llvm-svn: 41714
2007-09-04 20:46:58 +00:00
Devang Patel
f6ef552f3d
Insert cloned loop basic blocks before original loop header.
...
llvm-svn: 41713
2007-09-04 20:46:35 +00:00
Evan Cheng
e0cb6bb8da
Fix for PR1632. EHSELECTION always produces a i32 value.
...
llvm-svn: 41712
2007-09-04 20:39:26 +00:00
Evan Cheng
4dbd9f254a
Fix for PR1613: added 64-bit rotate left PPC instructions and patterns.
...
llvm-svn: 41711
2007-09-04 20:20:29 +00:00
Evan Cheng
20711a8b9a
Always check the type of node. This prevents situations such as selecting 32-bit rotate target instruction for a 64-bit node when 64-bit pattern is missing.
...
llvm-svn: 41710
2007-09-04 20:18:28 +00:00
David Greene
85948d7474
Update generated files.
...
llvm-svn: 41706
2007-09-04 18:46:50 +00:00
Dale Johannesen
427faa9247
fix reversal bug in preceding checkin
...
llvm-svn: 41705
2007-09-04 17:32:27 +00:00
David Greene
9bf8760a52
Revert this because the interface hasn't been updated yet.
...
llvm-svn: 41703
2007-09-04 17:15:07 +00:00
David Greene
4f4dc729d4
Fix typo.
...
llvm-svn: 41702
2007-09-04 17:00:44 +00:00
Evan Cheng
623dd88775
Mac OS X X86-64 ABI is same as the standard.
...
llvm-svn: 41700
2007-09-04 16:44:41 +00:00
David Greene
c656cbb8c2
Update GEP constructors to use an iterator interface to fix
...
GLIBCXX_DEBUG issues.
llvm-svn: 41697
2007-09-04 15:46:09 +00:00
Anton Korobeynikov
50ab26e835
Reapply r41578 with proper fix
...
llvm-svn: 41680
2007-09-03 00:36:06 +00:00
Anton Korobeynikov
35322d745c
Silence warning while compiling with gcc 4.2
...
llvm-svn: 41676
2007-09-02 22:11:14 +00:00
Anton Korobeynikov
38ce90fd44
Emit proper "secrel" directive, where possible. This fixes invalid asm syntax of debug info on mingw32. Also, cleanup
...
some stuff.
llvm-svn: 41675
2007-09-02 22:07:21 +00:00
Evan Cheng
2089a21360
More tweaks to improve compile time.
...
llvm-svn: 41669
2007-09-01 02:03:17 +00:00
Evan Cheng
ffac17a223
Fix a gcroot lowering bug.
...
llvm-svn: 41668
2007-09-01 02:00:51 +00:00
Dale Johannesen
689d17d282
Oops, should be part of 41664; won't work very well without this piece.
...
llvm-svn: 41665
2007-08-31 23:35:31 +00:00
Dale Johannesen
446b900192
Add mod, copysign, abs operations to APFloat.
...
Implement some constant folding in SelectionDAG and
DAGCombiner using APFloat. Remove double versions
of constructor and getValue from ConstantFPSDNode.
llvm-svn: 41664
2007-08-31 23:34:27 +00:00
Evan Cheng
7bef79a1c3
std::map -> DenseMap for slight compile time benefit.
...
llvm-svn: 41650
2007-08-31 21:23:06 +00:00
Reid Spencer
5028b76f93
Allow the configure options to be set according to the llvm-top options.
...
Patch improved from one by Holger Schurig.
llvm-svn: 41649
2007-08-31 19:53:42 +00:00
Dale Johannesen
da7469f2b5
Revise per review of previous patch.
...
llvm-svn: 41645
2007-08-31 17:03:33 +00:00
Rafael Espindola
e636fc05d6
Initial support for calling functions with byval arguments on x86-64
...
llvm-svn: 41643
2007-08-31 15:06:30 +00:00
Rafael Espindola
bb8a5cff67
Align i64 and f64 at 8 byte on x86-64.
...
This is mandated table 3.1 at
http://www.x86-64.org/documentation/abi.pdf
llvm-svn: 41642
2007-08-31 12:23:58 +00:00
Evan Cheng
91becf4ffa
Remove an unnecessary element, saving 4 bytes per LiveInterval.
...
llvm-svn: 41641
2007-08-31 08:26:44 +00:00
Evan Cheng
262596e76a
Use std::map instead of a (potentially very sparse) array to track val# defined by copy from the other live range. Minor compile time win when number of val# is large.
...
llvm-svn: 41640
2007-08-31 08:04:17 +00:00
Evan Cheng
2e9d48aa0d
Update test case to reflect Dale's change.
...
llvm-svn: 41639
2007-08-31 06:29:32 +00:00
Dale Johannesen
3cf889f75e
Enhance APFloat to retain bits of NaNs (fixes oggenc).
...
Use APFloat interfaces for more references, mostly
of ConstantFPSDNode.
llvm-svn: 41632
2007-08-31 04:03:46 +00:00
Raul Herbster
ab871baaf8
Instruction formats added used to generate multiply instructions of V5TE.
...
llvm-svn: 41629
2007-08-30 23:34:14 +00:00
Raul Herbster
ff32b62942
Unused relocation type reloc_arm_absolute removed.
...
llvm-svn: 41628
2007-08-30 23:31:35 +00:00
Raul Herbster
1457b2b3b1
Comments added. It now generates V5TE multiply instructions. However, it is still necessary to model PUWLSH bits more clearly.
...
llvm-svn: 41627
2007-08-30 23:29:26 +00:00
Raul Herbster
73489273ae
ARM instruction table was modified by adding information to generate multiply instruction of V5TE.
...
llvm-svn: 41626
2007-08-30 23:25:47 +00:00
Raul Herbster
ae1b924c79
JITInfo now resolves function addrs and also relocations. It always emits a stub.
...
llvm-svn: 41625
2007-08-30 23:21:27 +00:00
Ted Kremenek
ed99b8a2a8
Added Graphviz escaping for the '|' character.
...
llvm-svn: 41610
2007-08-30 17:01:41 +00:00
Tanya Lattner
ffb806cf0e
Do not run on darwin.
...
llvm-svn: 41608
2007-08-30 16:07:20 +00:00
Evan Cheng
ebb8540067
Added support to fold X86 load / store instructions. This allow rematerialized loads to be folded into their uses.
...
llvm-svn: 41599
2007-08-30 05:54:07 +00:00
Evan Cheng
32a0a995c6
Try fold re-materialized load instructions into its uses.
...
llvm-svn: 41598
2007-08-30 05:53:02 +00:00
Evan Cheng
9a25d98c86
Add a variant of foldMemoryOperand to fold any load / store, not just load / store from / to stack slots.
...
llvm-svn: 41597
2007-08-30 05:52:20 +00:00
Evan Cheng
ecf5342104
Added CreateFrameIndex to create a FrameIndex MachineOperand without a MachineInstr.
...
llvm-svn: 41596
2007-08-30 05:50:32 +00:00
Evan Cheng
c2081fe573
Mark load instructions with isLoad = 1.
...
llvm-svn: 41595
2007-08-30 05:49:43 +00:00
Bill Wendling
10e18dea2a
Use i64 on a PPC64 machine
...
llvm-svn: 41590
2007-08-30 00:59:19 +00:00
Dale Johannesen
d246b2ca5c
Change LegalFPImmediates to use APFloat.
...
Add APFloat interfaces to ConstantFP, SelectionDAG.
Fix integer bit in double->APFloat conversion.
Convert LegalizeDAG to use APFloat interface in
ConstantFPSDNode uses.
llvm-svn: 41587
2007-08-30 00:23:21 +00:00
Anton Korobeynikov
2bdec2a5ee
Fix use of declaration inside case block
...
llvm-svn: 41584
2007-08-29 23:18:48 +00:00
Evan Cheng
1ad4a6117b
Change LiveRange so it keeps a pointer to the VNInfo rather than an index.
...
Changes related modules so VNInfo's are not copied. This decrease
copy coalescing time by 45% and overall compilation time by 10% on siod.
llvm-svn: 41579
2007-08-29 20:45:00 +00:00
Anton Korobeynikov
830b1cb4e9
Lower FRAME_TO_ADDR_OFFSET to zero by default (if not custom lowered)
...
llvm-svn: 41578
2007-08-29 19:28:29 +00:00
Duncan Sands
7741427a09
Move getX86RegNum into X86RegisterInfo and use it
...
in the trampoline lowering. Lookup the jump and
mov opcodes for the trampoline rather than hard
coding them.
llvm-svn: 41577
2007-08-29 19:01:20 +00:00
Raul Herbster
f1aaa801ed
Alphabetize Raul's entry.
...
llvm-svn: 41576
2007-08-29 18:21:29 +00:00
Raul Herbster
4c5fac3977
New contributor added
...
llvm-svn: 41569
2007-08-29 16:51:52 +00:00
Tanya Lattner
bca16c80ed
Updating configure script to enable MIPS.
...
llvm-svn: 41568
2007-08-29 16:38:16 +00:00
Chris Lattner
2198ea9097
Silence implicit 64->32-bit conversion warnings.
...
llvm-svn: 41567
2007-08-29 16:32:50 +00:00
Chris Lattner
2408d769eb
getMinSignedBits needs to take into consider the sign bit when the value is positive.
...
llvm-svn: 41566
2007-08-29 16:21:18 +00:00
Chris Lattner
8d22b4e18a
update these
...
llvm-svn: 41565
2007-08-29 16:15:23 +00:00
Dan Gohman
81b62e1218
Add an option, -view-sunit-dags, for viewing the actual SUnit DAGs used by
...
scheduling.
llvm-svn: 41556
2007-08-28 20:32:58 +00:00
Chuck Rose III
e87935b379
Update win32 VStudio project files to keep pace with recently added and deleted files
...
llvm-svn: 41553
2007-08-28 18:59:02 +00:00
Evan Cheng
a5b10b334f
Recover most of the compile time regression due to recent live interval changes.
...
1. Eliminate the costly live interval "swapping".
2. Change ValueNumberInfo container from SmallVector to std::vector. The former
performs slowly when the vector size is very large.
llvm-svn: 41536
2007-08-28 08:28:51 +00:00
Bruno Cardoso Lopes
43318839c9
Added method to get Mips register numbers
...
Changed the stack frame layout, StackGrowsUp fits better to Mips strange stack.
Stack offset calculation bug fixed!
llvm-svn: 41529
2007-08-28 05:13:42 +00:00
Bruno Cardoso Lopes
14033fb5cb
Changed stack allocation On LowerFORMAL_ARGUMENTS.
...
Added comments about new stack allocation.
Expand SelectCC for i32 results
llvm-svn: 41527
2007-08-28 05:08:16 +00:00
Bruno Cardoso Lopes
cfd1638e2d
Mask directive completed with CalleeSave info
...
Comments for Mips directives added.
llvm-svn: 41526
2007-08-28 05:06:17 +00:00
Bruno Cardoso Lopes
f55a785e56
Added methods to record SPOffsets from LowerFORMAL_ARGUMENTS
...
llvm-svn: 41525
2007-08-28 05:04:41 +00:00
Chris Lattner
0e258b8518
Cut off crazy computation. This helps PR1622 slightly.
...
llvm-svn: 41522
2007-08-28 04:23:55 +00:00
Devang Patel
d2456a171d
Use simpler test to filter loops.
...
llvm-svn: 41516
2007-08-27 21:34:31 +00:00
Dan Gohman
312b70a970
Add explicit triples to avoid default behavior that varies by host.
...
llvm-svn: 41510
2007-08-27 20:54:48 +00:00
David Greene
703623d571
Update InvokeInst to work like CallInst
...
llvm-svn: 41506
2007-08-27 19:04:21 +00:00
Rafael Espindola
b602461f48
Add a comment about using libc memset/memcpy or generating inline code.
...
llvm-svn: 41502
2007-08-27 17:48:26 +00:00
Duncan Sands
dd94bde661
Remove this test as it is too hard to fix after the
...
latest EH changes, and in any case it is hard to
imagine how the original bug could be reintroduced.
llvm-svn: 41497
2007-08-27 17:08:14 +00:00
Duncan Sands
68b773df24
Fix this test: llvm-gcc-4.2 optimizes almost everything away,
...
resulting in zero matches, while llvm-gcc-4.1 manages to
remove one pointless selector changing the number of matches.
llvm-svn: 41494
2007-08-27 16:47:32 +00:00
Dan Gohman
9625d812c9
Make DAGCombiner's global alias analysis query more precise in the case
...
where both pointers have non-zero offsets.
llvm-svn: 41491
2007-08-27 16:32:11 +00:00
Duncan Sands
90064ed445
Now that we don't output cleanups by default, the action
...
offset needs to be adjusted in this test.
llvm-svn: 41490
2007-08-27 16:30:05 +00:00
Dan Gohman
8dc0b93151
If the source and destination pointers in an llvm.memmove are known
...
to not alias each other, it can be translated as an llvm.memcpy.
llvm-svn: 41489
2007-08-27 16:26:13 +00:00
Dan Gohman
71eaf62e5f
Change comments to refer to @malloc and @free instead of %malloc and %free.
...
llvm-svn: 41488
2007-08-27 16:11:48 +00:00
Duncan Sands
ef5a654216
There is an impedance matching problem between LLVM and
...
gcc exception handling: if an exception unwinds through
an invoke, then execution must branch to the invoke's
unwind target. We previously tried to enforce this by
appending a cleanup action to every selector, however
this does not always work correctly due to an optimization
in the C++ unwinding runtime: if only cleanups would be
run while unwinding an exception, then the program just
terminates without actually executing the cleanups, as
invoke semantics would require. I was hoping this
wouldn't be a problem, but in fact it turns out to be the
cause of all the remaining failures in the LLVM testsuite
(these also fail with -enable-correct-eh-support, so turning
on -enable-eh didn't make things worse!). Instead we need
to append a full-blown catch-all to the end of each
selector. The correct way of doing this depends on the
personality function, i.e. it is language dependent, so
can only be done by gcc. Thus this patch which generalizes
the eh.selector intrinsic so that it can handle all possible
kinds of action table entries (before it didn't accomodate
cleanups): now 0 indicates a cleanup, and filters have to be
specified using the number of type infos plus one rather than
the number of type infos. Related gcc patches will cause
Ada to pass a cleanup (0) to force the selector to always
fire, while C++ will use a C++ catch-all (null).
llvm-svn: 41484
2007-08-27 15:47:50 +00:00
Dan Gohman
032d89828e
Add explicit keywords and remove spurious trailing semicolons.
...
llvm-svn: 41482
2007-08-27 14:50:10 +00:00