Chris Lattner
39dbb82db2
Fix many regressions on x86 by avoiding dereferencing the end iterator.
...
llvm-svn: 42738
2007-10-07 21:53:12 +00:00
Chris Lattner
ddd980044f
Finish off PR1723, by working around some strange compiler bug.
...
llvm-svn: 42737
2007-10-07 17:57:10 +00:00
Gordon Henriksen
454d171c26
C and Objective Caml bindings for GlobalVariable::isConstant.
...
llvm-svn: 42736
2007-10-07 17:31:42 +00:00
Neil Booth
6f9602ac12
Add back convertFromSignExtendedInteger.
...
llvm-svn: 42735
2007-10-07 12:15:41 +00:00
Neil Booth
ac998332c3
Now that convertFromUnsignedParts has a sane, constant interface,
...
convertFromZeroExtendedInteger can be simplified as it doesn't need
to make a copy of the source bignum.
llvm-svn: 42734
2007-10-07 12:10:57 +00:00
Neil Booth
db4dbedfea
Reimplement convertFromUnsignedInteger so it is passed a const bignum.
...
It used to modify its argument in-place.
This interface is saner and the implementation more efficient. It will
be needed for decimal->binary conversion.
llvm-svn: 42733
2007-10-07 12:07:53 +00:00
Neil Booth
6e01c5df37
convertFromInteger, as originally written, expected sign-extended
...
input. APInt unfortunately zero-extends signed integers, so Dale
modified the function to expect zero-extended input. Make this
assumption explicit in the function name.
llvm-svn: 42732
2007-10-07 11:45:55 +00:00
Neil Booth
726126f4d6
combineLostFractions does not need to be a member function
...
llvm-svn: 42729
2007-10-07 08:51:21 +00:00
Daniel Berlin
afb1610cf3
Some more problems noticed by Curtis
...
llvm-svn: 42717
2007-10-07 04:47:57 +00:00
Gordon Henriksen
99c0e2918b
C and Objective Caml bindings for PATypeHolder.
...
llvm-svn: 42713
2007-10-07 00:13:35 +00:00
Gordon Henriksen
06eeba26c1
Bindings for the verifier.
...
llvm-svn: 42707
2007-10-06 21:00:36 +00:00
Gordon Henriksen
64b6555e60
Deleting some unnecessary glue.
...
llvm-svn: 42702
2007-10-06 17:10:44 +00:00
Gordon Henriksen
36d61a4b79
Adopting a uniform naming convention for type constructors in
...
bindings (part le deux).
llvm-svn: 42701
2007-10-06 16:56:09 +00:00
Anton Korobeynikov
54ecd77023
Oops, I really wanted to commit this part also :)
...
llvm-svn: 42700
2007-10-06 16:39:43 +00:00
Anton Korobeynikov
34fefcf678
Move merge code into new helper function.
...
llvm-svn: 42699
2007-10-06 16:17:49 +00:00
Gordon Henriksen
ee9c8932e4
Adopting a uniform naming convention for type constructors in bindings.
...
llvm-svn: 42698
2007-10-06 16:05:20 +00:00
Gordon Henriksen
574434313a
Adopting a uniform naming convention for constant constructors in bindings.
...
llvm-svn: 42697
2007-10-06 15:11:06 +00:00
Gordon Henriksen
65ce7c3085
Adding C and Ocaml bindings for ConstantExpr.
...
llvm-svn: 42696
2007-10-06 14:29:36 +00:00
Anton Korobeynikov
1f11738913
Include DataTypes.h to provide intptr_t type. This fixes OpenBSD compilation of this file.
...
Inspired by Laurence Tratt's patch
llvm-svn: 42695
2007-10-06 13:07:11 +00:00
Evan Cheng
0eed7948ce
Reapply 42677.
...
llvm-svn: 42692
2007-10-06 08:19:55 +00:00
Evan Cheng
c6b349980a
Oops. Forgot this.
...
llvm-svn: 42691
2007-10-06 08:09:29 +00:00
Neil Booth
beba899ff0
Cleaner, more general exponent output.
...
llvm-svn: 42690
2007-10-06 07:29:25 +00:00
Chris Lattner
a1de966c80
silence warnings in no-assert build.
...
llvm-svn: 42687
2007-10-06 06:13:42 +00:00
Chris Lattner
63443a5bc3
revert evan's patch until the header is committed
...
llvm-svn: 42686
2007-10-06 06:08:17 +00:00
Evan Cheng
dc95020e30
Added DAG xforms. e.g.
...
(vextract (v4f32 s2v (f32 load $addr)), 0) -> (f32 load $addr)
(vextract (v4i32 bc (v4f32 s2v (f32 load $addr))), 0) -> (i32 load $addr)
Remove x86 specific patterns.
llvm-svn: 42677
2007-10-06 02:46:29 +00:00
Dale Johannesen
9b7ac95116
Next powerpc long double bits. Comparisons work,
...
although not well, and shortening FP converts.
llvm-svn: 42672
2007-10-06 01:24:11 +00:00
Dale Johannesen
b600202c68
Make test work on non-x86 hosts.
...
llvm-svn: 42671
2007-10-06 01:22:39 +00:00
Neil Booth
0613ec4ee6
Fix and clarify some comments.
...
llvm-svn: 42670
2007-10-06 00:43:45 +00:00
Neil Booth
2c4419d71b
Generalize tcFullMultiply so that the operands can be of differing
...
part widths. Also, return the number of parts actually required to
hold the result's value.
Remove an over-cautious condition from rounding of float->hex conversion.
llvm-svn: 42669
2007-10-06 00:24:48 +00:00
Gordon Henriksen
8d97ababb0
Wrapping Value::dump.
...
llvm-svn: 42668
2007-10-06 00:08:49 +00:00
Gordon Henriksen
543f859a00
Removing the silly CHelpers header by rolling wrap and unwrap into the C
...
bindings headers themselves, hidden behind #ifdef __cplusplus.
llvm-svn: 42666
2007-10-05 23:59:36 +00:00
Evan Cheng
0a642eaa62
Test case for 3-address conversion.
...
llvm-svn: 42664
2007-10-05 23:33:09 +00:00
Evan Cheng
9af50ee6ef
Commute x86 cmove instructions by swapping the operands and change the condition
...
to its inverse.
Testing this as llcbeta
llvm-svn: 42661
2007-10-05 23:13:21 +00:00
Evan Cheng
e0e36e4a0e
This is done.
...
llvm-svn: 42656
2007-10-05 22:34:59 +00:00
Evan Cheng
dc467c6323
Enable convertToThreeAddress for X86 by default.
...
llvm-svn: 42655
2007-10-05 22:31:10 +00:00
Devang Patel
36b68478cb
Fix bug in updating dominance frontier after loop
...
unswitch when frontier includes basic blocks that
are not inside loop.
llvm-svn: 42654
2007-10-05 22:29:34 +00:00
Evan Cheng
2b3122e56e
INC64_32r -> LEA64_32r is better than INC64_32r -> LEA32r, but it still can
...
cause performance degradation.
llvm-svn: 42653
2007-10-05 21:55:32 +00:00
Evan Cheng
688f34a273
In 64-bit mode, avoid using leal with 32-bit 32-bit address size, e.g.
...
leal 1(%ecx), %edi, which requires 67H prefix.
llvm-svn: 42647
2007-10-05 20:34:26 +00:00
Dale Johannesen
c7b51b678d
First round of ppc long double. call/return and
...
basic arithmetic works.
Rename RTLIB long double functions to distinguish
different flavors of long double; the lib functions
have different names, alas.
llvm-svn: 42644
2007-10-05 20:04:43 +00:00
Evan Cheng
b069dd6a25
Add support to convert more 64-bit instructions to 3-address instructions.
...
llvm-svn: 42642
2007-10-05 18:20:36 +00:00
Evan Cheng
f658191412
ADC and SBB uses EFLAGS.
...
llvm-svn: 42640
2007-10-05 17:59:57 +00:00
Chris Lattner
c604dd270a
Mark count method const.
...
llvm-svn: 42639
2007-10-05 17:40:38 +00:00
Dan Gohman
821635b63f
Change a few more spaces to tabs in assembly output.
...
llvm-svn: 42638
2007-10-05 15:58:41 +00:00
Dan Gohman
950f96e456
Change a space to a tab in the assembly output of a .globl directive
...
for consistency.
llvm-svn: 42637
2007-10-05 15:54:58 +00:00
Dan Gohman
06e6956edb
Legalize support for MUL_LOHI and DIVREM.
...
llvm-svn: 42636
2007-10-05 14:17:22 +00:00
Dan Gohman
6132098d91
Fix a typo in a comment.
...
llvm-svn: 42635
2007-10-05 14:11:58 +00:00
Dan Gohman
dab5fa8685
Provide names for MUL_LOHI and DIVREM operators.
...
llvm-svn: 42634
2007-10-05 14:11:04 +00:00
Dan Gohman
bc0aadce14
SMUL_LOHI and UMUL_LOHI are commutative.
...
llvm-svn: 42633
2007-10-05 14:09:33 +00:00
Dan Gohman
148f07390d
Define target-indepenent SDNode types for multiply and divide that
...
produce two results.
llvm-svn: 42632
2007-10-05 14:07:56 +00:00
Duncan Sands
922a92a9e2
Fix typo in comment.
...
llvm-svn: 42631
2007-10-05 10:37:00 +00:00