Bill Wendling
bfd2f2f6d7
Don't pass back a reference to a temporary.
...
llvm-svn: 42086
2007-09-18 09:10:16 +00:00
Bill Wendling
537b869514
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
3dc9d9f145
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
25f8bcd5ee
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
Bill Wendling
803e0d9970
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
d269356b02
Add support for appending a suffix to the end of a mangled name.
...
llvm-svn: 42071
2007-09-17 22:39:32 +00:00
Devang Patel
547d418b8e
Do not hide APInt::dump() inside #ifndef NDEBUG.
...
llvm-svn: 42068
2007-09-17 22:24:00 +00:00
Dale Johannesen
9ce8a9d633
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
cc315726f7
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
a19af373e3
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
d26deb0a6d
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
81b5cda0aa
Add a utility function to SDOperand for testing if a value is unused.
...
llvm-svn: 42038
2007-09-17 17:44:31 +00:00
Daniel Berlin
d44b2016ca
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
688e8d9b60
Fix a few bugs related to zero'ing of elements
...
llvm-svn: 42017
2007-09-16 22:31:47 +00:00
Chris Lattner
1b622ad721
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
Owen Anderson
a37895cfee
Remove RLE from the headers, since the pass itself is gone now.
...
llvm-svn: 41971
2007-09-14 22:54:46 +00:00
Dale Johannesen
575bd6070a
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
Dan Gohman
1c9bf0bfb9
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
fb60c0dfed
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
53119779c2
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
Chris Lattner
6b18ffcafe
remove dead enum value.
...
llvm-svn: 41925
2007-09-13 06:18:04 +00:00
Chris Lattner
7b29e6a714
Make single-argument ctors explicit to avoid tricky bugs :)
...
llvm-svn: 41924
2007-09-13 06:15:57 +00:00
Evan Cheng
827f269fac
Added getNumDefs().
...
llvm-svn: 41901
2007-09-13 00:16:29 +00:00
Evan Cheng
e88f30877d
Yet another getTargetNode variant.
...
llvm-svn: 41898
2007-09-12 23:39:49 +00:00
Daniel Berlin
f778d9ea43
Move dump out of class, use "\n" instead of endl
...
llvm-svn: 41872
2007-09-11 22:58:27 +00:00
Dale Johannesen
7bc3969cea
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
b4c820ecfd
Convert to use ilist and non-pointer lists for extra goodness
...
llvm-svn: 41855
2007-09-11 17:42:22 +00:00
Bill Wendling
bde1aacffa
Add accessor method.
...
llvm-svn: 41854
2007-09-11 17:24:38 +00:00
Bill Wendling
74888e63e7
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
Duncan Sands
c358890f73
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
Bill Wendling
3c6a8b2814
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
0c2fdab32a
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
a96cf4c60a
Don't bother to initialize values corresponding to empty or tombstone
...
keys.
llvm-svn: 41834
2007-09-11 04:43:51 +00:00
Daniel Berlin
c0ef77b9f6
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
8014c7f1f3
Fix non-deterministic behavior in the DenseMap copy constructor.
...
llvm-svn: 41831
2007-09-11 03:48:08 +00:00
Daniel Berlin
be8b616451
Add remaining functions necessary for andersen's
...
llvm-svn: 41830
2007-09-11 01:38:07 +00:00
Daniel Berlin
f0f3834ee6
Add SparseBitVector implementation
...
llvm-svn: 41790
2007-09-09 01:10:40 +00:00
Chuck Rose III
788df70ec3
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
Rafael Espindola
8c57e70f93
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
899c0c9c8d
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
Owen Anderson
4b71e55287
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
04a132ad5f
Constify to catch bugs.
...
llvm-svn: 41751
2007-09-06 19:46:46 +00:00
Dale Johannesen
86f367a6b7
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
David Greene
2ca4b270db
Pluggable coalescers inplementation.
...
llvm-svn: 41743
2007-09-06 16:18:45 +00:00
Evan Cheng
884b7c0c81
Accidentially left this out.
...
llvm-svn: 41730
2007-09-05 21:58:18 +00:00
Evan Cheng
3bda699975
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
5977c55f5d
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
Dale Johannesen
1f864b259a
fix reversal bug in preceding checkin
...
llvm-svn: 41705
2007-09-04 17:32:27 +00:00
David Greene
8cda5af2e7
Update GEP constructors to use an iterator interface to fix
...
GLIBCXX_DEBUG issues.
llvm-svn: 41697
2007-09-04 15:46:09 +00:00
Dale Johannesen
b34e6b4898
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