Devang Patel
9d91785987
s/isReturnStruct()/hasStructRetAttr()/g
...
llvm-svn: 47857
2008-03-03 21:46:28 +00:00
Chris Lattner
c93b48caeb
add support for lvsl, fixing PR1481
...
llvm-svn: 47825
2008-03-02 08:54:27 +00:00
Chris Lattner
8fb4c98284
add support for the sse.cmp.* intrinsics, which fixes sse.isamax with the CBE.
...
llvm-svn: 47824
2008-03-02 08:47:13 +00:00
Chris Lattner
9044719798
refactor intrinsic handling code out into its own method.
...
llvm-svn: 47823
2008-03-02 08:29:41 +00:00
Chris Lattner
2541f1dac6
fix printing of undef vectors, this fixes "simple" and "build" in UnitTests/Vector.
...
Now they all pass.
llvm-svn: 47820
2008-03-02 08:14:45 +00:00
Chris Lattner
4c058b39e4
insertelement got the wrong operands.
...
llvm-svn: 47819
2008-03-02 08:10:16 +00:00
Chris Lattner
051709436e
Several changes:
...
* Simplify handling of byval, making it easier to understand and more
consistent. This fixes PR2065.
* Clean up and simplify handling of GEPs. I can actually understand it now!
* Implement support for GEP'ing into vectors, this fixes
SingleSource/UnitTests/Vector/build2 among others.
llvm-svn: 47818
2008-03-02 08:07:24 +00:00
Chris Lattner
9140fba6ad
Fix a bug I introduced in constant array and constant vector handling.
...
llvm-svn: 47816
2008-03-02 05:46:57 +00:00
Chris Lattner
7295bc15a0
implement shufflevector.
...
llvm-svn: 47815
2008-03-02 05:41:07 +00:00
Chris Lattner
689d830b6d
implement extractelement.
...
llvm-svn: 47812
2008-03-02 03:57:08 +00:00
Chris Lattner
d9cc003b0d
implement insertelement.
...
llvm-svn: 47811
2008-03-02 03:52:39 +00:00
Chris Lattner
92d929c21d
respect isSigned for vector types, fixing sdiv of vectors etc.
...
llvm-svn: 47810
2008-03-02 03:41:23 +00:00
Chris Lattner
fe1083be61
print the attribute in the right place, this fixes function returning vectors.
...
llvm-svn: 47809
2008-03-02 03:39:43 +00:00
Chris Lattner
d861066d15
vector types are simple types. This fixes div/rem of vectors.
...
llvm-svn: 47807
2008-03-02 03:33:31 +00:00
Chris Lattner
b104be599a
Print vector types appropriately. This gets basic vector code working
...
(PR1126)
llvm-svn: 47806
2008-03-02 03:29:50 +00:00
Chris Lattner
c8d974a323
rename PT -> VT for VectorTypes.
...
llvm-svn: 47805
2008-03-02 03:18:46 +00:00
Chris Lattner
895aef4720
Print i32/i64 integer constants as 1u instead of ((unsigned int)1).
...
Use dyn_cast better.
llvm-svn: 47804
2008-03-02 03:16:38 +00:00
Lauro Ramos Venancio
9781aee03c
Avoid collisions in value names.
...
llvm-svn: 47725
2008-02-28 20:26:04 +00:00
Dale Johannesen
09f410b6d7
Split ParameterAttributes.h, putting the complicated
...
stuff into ParamAttrsList.h. Per feedback from
ParamAttrs changes.
llvm-svn: 47504
2008-02-22 22:17:59 +00:00
Evan Cheng
e43b6054b1
Temporarily backing out r47337. It breaks a number of CBE tests.
...
llvm-svn: 47385
2008-02-20 18:32:05 +00:00
Anton Korobeynikov
40d67c59d5
Remove bunch of gcc 4.3-related warnings from Target
...
llvm-svn: 47369
2008-02-20 11:22:39 +00:00
Andrew Lenharth
4aa9e208fa
fix some byval problems in the cbe. Closes PR2065
...
llvm-svn: 47337
2008-02-19 19:47:54 +00:00
Andrew Lenharth
fedcf477b5
I cannot find a libgcc function for this builtin. Therefor expanding it to a noop (which is how it use to be treated). If someone who knows the x86 backend better than me could tell me how to get a lock prefix on an instruction, that would be nice to complete x86 support.
...
llvm-svn: 47213
2008-02-16 14:46:26 +00:00
Lauro Ramos Venancio
192c07b727
CBackend: Implement unaligned load/store.
...
llvm-svn: 46646
2008-02-01 21:25:59 +00:00
Evan Cheng
f755ff7be3
Indirect call with byval parameter requires a cast first.
...
llvm-svn: 45911
2008-01-12 18:53:07 +00:00
Chris Lattner
459dc52df4
Add support for NetBSD, patch by Krister Walfridsson!
...
llvm-svn: 45902
2008-01-12 06:46:09 +00:00
Evan Cheng
b51d228e79
More cbe byval fixes.
...
llvm-svn: 45891
2008-01-11 23:10:11 +00:00
Evan Cheng
ef5285ef88
Some C backend ByVal parameter attribute support. Not yet complete.
...
llvm-svn: 45864
2008-01-11 09:12:49 +00:00
Evan Cheng
aaef8ce856
A couple of obvious off-by-one bugs.
...
llvm-svn: 45852
2008-01-11 03:07:46 +00:00
Gordon Henriksen
5180e85675
Enabling the target-independent garbage collection infrastructure by hooking it
...
up to the various compiler pipelines.
This doesn't actually add support for any GC algorithms, which means it
temporarily breaks a few tests. To be fixed shortly.
llvm-svn: 45669
2008-01-07 01:30:38 +00:00
Chris Lattner
f3ebc3f3d2
Remove attribution from file headers, per discussion on llvmdev.
...
llvm-svn: 45418
2007-12-29 20:36:04 +00:00
Chris Lattner
a087a8d2ce
remove attribution from lib Makefiles.
...
llvm-svn: 45415
2007-12-29 20:09:26 +00:00
Anton Korobeynikov
1e8c1308bb
Fix silly typo in the FP CEP handling.
...
llvm-svn: 45300
2007-12-21 23:33:44 +00:00
Duncan Sands
38ef3a8ec7
Rather than having special rules like "intrinsics cannot
...
throw exceptions", just mark intrinsics with the nounwind
attribute. Likewise, mark intrinsics as readnone/readonly
and get rid of special aliasing logic (which didn't use
anything more than this anyway).
llvm-svn: 44544
2007-12-03 20:06:50 +00:00
Chris Lattner
246b7b2dbf
Work around a GCC bug, producing this code:
...
unsigned char *llvm_cbe_X;
...
llvm_cbe_X = 0; *((void**)&llvm_cbe_X) = __builtin_stack_save();
instead of:
llvm_cbe_X = __builtin_stack_save();
See PR1809 for details.
llvm-svn: 44415
2007-11-28 21:26:17 +00:00
Duncan Sands
ad0ea2d430
Fix PR1146: parameter attributes are longer part of
...
the function type, instead they belong to functions
and function calls. This is an updated and slightly
corrected version of Reid Spencer's original patch.
The only known problem is that auto-upgrading of
bitcode files doesn't seem to work properly (see
test/Bitcode/AutoUpgradeIntrinsics.ll). Hopefully
a bitcode guru (who might that be? :) ) will fix it.
llvm-svn: 44359
2007-11-27 13:23:08 +00:00
Gordon Henriksen
ef5d08f4ea
Switching TargetMachineRegistry to use the new generic Registry.
...
llvm-svn: 43094
2007-10-17 21:28:48 +00:00
Dale Johannesen
207bd4d90e
Handle PPC long double in CBackend.
...
llvm-svn: 42972
2007-10-15 01:05:37 +00:00
Dale Johannesen
4d4e77af8e
Rewrite sqrt and powi to use anyfloat. By popular demand.
...
llvm-svn: 42537
2007-10-02 17:43:59 +00:00
Dale Johannesen
34aa41c475
Make temporaries explicit to avoid premature
...
destruction of compiler-created ones.
llvm-svn: 42383
2007-09-26 23:20:33 +00:00
Chris Lattner
e48195e0f3
Fix PR1679, by printing GEP indices as signed values instead of unsigned.
...
llvm-svn: 42239
2007-09-22 20:16:48 +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
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
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
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
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
Dale Johannesen
9e70086c8f
Apply feedback from previous patch.
...
llvm-svn: 41774
2007-09-07 21:07:57 +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
Lauro Ramos Venancio
3d70855dd2
Handle packed structs in the CBackend.
...
llvm-svn: 39752
2007-07-11 19:56:53 +00:00
Chris Lattner
1904e45d0c
Fix PR1413
...
llvm-svn: 37023
2007-05-13 22:19:27 +00:00