Reid Spencer
8d529a18f4
For PR1209:
...
Implement Type class's ContainedTys without using a std::vector.
llvm-svn: 35693
2007-04-06 02:02:20 +00:00
Reid Spencer
91b273ae39
XFAIL this test for now. It will be a while before I can implement this
...
intrinsic properly in SDISel.
llvm-svn: 35692
2007-04-05 22:57:45 +00:00
Chris Lattner
91e66dc136
eliminate a virtual method
...
llvm-svn: 35691
2007-04-05 22:21:39 +00:00
Chris Lattner
2031b02faf
remove the dead removeArgument method, rename Options to OptionsMap.
...
llvm-svn: 35690
2007-04-05 21:58:17 +00:00
Chris Lattner
1a9a760318
Fix Transforms/GlobalOpt/2007-04-05-Crash.ll
...
llvm-svn: 35689
2007-04-05 21:09:42 +00:00
Chris Lattner
cf1f986099
new testcase that crashes globalopt
...
llvm-svn: 35688
2007-04-05 21:09:29 +00:00
Dale Johannesen
0a3d673b4a
testcase for padding before zero-length fields.
...
llvm-svn: 35687
2007-04-05 19:05:43 +00:00
Devang Patel
9feae5c4d8
New tests for Packed structs.
...
llvm-svn: 35686
2007-04-05 17:14:21 +00:00
Devang Patel
bc09c71159
New tests for Packed structs.
...
llvm-svn: 35685
2007-04-05 17:07:48 +00:00
Chris Lattner
c7de6e0a75
run a late dce pass to clean up extra cruft.
...
llvm-svn: 35684
2007-04-05 16:50:20 +00:00
Anton Korobeynikov
506d8db8a4
Fix test
...
llvm-svn: 35683
2007-04-05 16:43:09 +00:00
Chris Lattner
9df6baa772
Add a helper class (APSInt) which can represent an APInt along with sign
...
information. This is useful when a value does have a sign associated with
it. This shouldn't be used generally in LLVM for mid-level optimizer stuff.
llvm-svn: 35681
2007-04-05 05:20:11 +00:00
Chris Lattner
108083edff
Use a worklist-driven algorithm instead of a recursive one.
...
llvm-svn: 35680
2007-04-05 01:27:02 +00:00
Reid Spencer
85460acfbf
Change the bit_part_select (non)implementation from "return 0" to abort.
...
llvm-svn: 35679
2007-04-05 01:20:18 +00:00
Reid Spencer
cce90f55ed
Implement the llvm.bit.part_select.iN.iN.iN overloaded intrinsic.
...
llvm-svn: 35678
2007-04-04 23:48:25 +00:00
Reid Spencer
9797fee9a1
Ignore some things generated by bugpoint.
...
llvm-svn: 35677
2007-04-04 22:47:38 +00:00
Lauro Ramos Venancio
6db5eb028c
Fix release build.
...
llvm-svn: 35676
2007-04-04 22:13:39 +00:00
Jeff Cohen
b4470fb0bf
Fix some FreeBSD/amd64 regressions.
...
llvm-svn: 35675
2007-04-04 22:07:44 +00:00
Reid Spencer
e9f516384d
Squelch a warning about mismatch between sign of constant and sign of return
...
type.
llvm-svn: 35674
2007-04-04 22:07:24 +00:00
Anton Korobeynikov
029ea7ee74
Fix test
...
llvm-svn: 35673
2007-04-04 21:28:36 +00:00
Anton Korobeynikov
915e61736b
Properly emit range comparisons for switch cases, where neighbour cases
...
go to the same destination. Now we're producing really good code for
switch-lower-feature.ll testcase
llvm-svn: 35672
2007-04-04 21:14:49 +00:00
Jeff Cohen
9da1cde86c
Any add is wrong, regardless of type.
...
llvm-svn: 35671
2007-04-04 20:40:44 +00:00
Jeff Cohen
62c300a415
Get it right...
...
llvm-svn: 35670
2007-04-04 20:35:31 +00:00
Dale Johannesen
9234629e60
Test for transformConstExprCastCall fix.
...
llvm-svn: 35669
2007-04-04 19:18:16 +00:00
Dale Johannesen
7c2001d014
Prevent transformConstExprCastCall from generating conversions that assert
...
elsewhere.
llvm-svn: 35668
2007-04-04 19:16:42 +00:00
Reid Spencer
edf61160b1
Remove the part_set intrinsic. It won't get implemented as an intrinsic.
...
llvm-svn: 35667
2007-04-04 19:15:59 +00:00
Chris Lattner
c770a0273d
stringmap memory managed with malloc now
...
llvm-svn: 35666
2007-04-04 17:24:28 +00:00
Jeff Cohen
5a1c750f31
Fix 2007-04-04-BadFoldBitcastIntoMalloc.ll
...
llvm-svn: 35665
2007-04-04 16:58:57 +00:00
Jeff Cohen
6f98cd3710
Add new test.
...
llvm-svn: 35664
2007-04-04 16:11:23 +00:00
Evan Cheng
8f61b79d60
Better still.
...
llvm-svn: 35663
2007-04-04 08:49:40 +00:00
Evan Cheng
06df995e9f
Fix test case.
...
llvm-svn: 35662
2007-04-04 07:41:33 +00:00
Evan Cheng
ee06655d6b
These got better.
...
llvm-svn: 35661
2007-04-04 07:41:15 +00:00
Evan Cheng
8be98c1572
Re-materialize all loads from fixed stack slots.
...
llvm-svn: 35660
2007-04-04 07:40:01 +00:00
Evan Cheng
44a28f7d77
Add isFixedObjectIndex. It returns true if the stack slot index is for a fixed stack object.
...
llvm-svn: 35659
2007-04-04 07:38:25 +00:00
Evan Cheng
2bf2aadd9a
Trivially re-materializable instructions have spill weights that are half of what it would be otherwise.
...
llvm-svn: 35658
2007-04-04 07:04:55 +00:00
Reid Spencer
12e2843475
Revert this until the Date::Parse module can be installed on the nightly
...
testers.
llvm-svn: 35657
2007-04-04 06:59:36 +00:00
Reid Spencer
d1b53f538d
For PR1302:
...
Use local variable names that match the function parameter name that it
is passed to so the code is more clear, to wit: is_bytecode -> is_native
llvm-svn: 35656
2007-04-04 06:44:18 +00:00
Duncan Sands
f01a47c93c
Fix comment.
...
llvm-svn: 35655
2007-04-04 06:42:45 +00:00
Reid Spencer
d7799fd17d
For PR1302:
...
Rename LinkItems as NativeLinkItems since it is filled out by the Linker
library to contain only those items deemed to be native.
llvm-svn: 35654
2007-04-04 06:34:22 +00:00
Reid Spencer
a2c415526c
For PR1302:
...
Implement file tests for both LinkInLibrary and LinkInFile to determine if
the file is native. Don't generate warnings if the file is native.
llvm-svn: 35653
2007-04-04 06:33:17 +00:00
Reid Spencer
031fb8d4dc
Make the LinkInFile and LinkInLibrary both return an indication of whether
...
the file was found to be a native library (and thus not linked by these
functions).
llvm-svn: 35652
2007-04-04 06:32:01 +00:00
Reid Spencer
e9d794e7b5
For PR1302:
...
Adjust useage of sys::Path::FileType for new enumerator names.
llvm-svn: 35651
2007-04-04 06:31:04 +00:00
Reid Spencer
4ef4c46c35
For PR1302:
...
Implement recognition of COFF, ELF and Mach-O object/shared lib files.
llvm-svn: 35650
2007-04-04 06:30:26 +00:00
Reid Spencer
6d211ab8ed
For PR1302:
...
Make the FileType enumerators more readable and add COFF, ELF and Mach-O.
llvm-svn: 35649
2007-04-04 06:29:49 +00:00
Chris Lattner
e7cc7c825b
trivial optimization
...
llvm-svn: 35648
2007-04-04 06:18:21 +00:00
Reid Spencer
91fd109d6b
Appease Chris' pedantic streak.
...
llvm-svn: 35647
2007-04-04 05:46:04 +00:00
Reid Spencer
ca5fdf3b1e
Fix links to intrinsic functions outside LangRef.html
...
llvm-svn: 35646
2007-04-04 04:14:31 +00:00
Reid Spencer
96a5f02392
Remove intrinsics that we will not be implementing.
...
Fix the anchor names of intrinsics to all be int_ so as to distinguish
them from the i_ prefix reserved for instructions.
llvm-svn: 35645
2007-04-04 02:42:35 +00:00
Chris Lattner
adf83a3513
use calloc instead of new/memset, it is more efficient
...
llvm-svn: 35644
2007-04-04 00:44:31 +00:00
Chris Lattner
c712a1322a
Initialize the symbol table to zero explicitly. This ensures that the
...
symbol table does no allocations for prototypes or other lazily deserialized
functions, saving significant space and time.
llvm-svn: 35643
2007-04-04 00:30:49 +00:00
Chris Lattner
2376346a8e
Extend StringMap to support being initialized as completely empty. When
...
initialized this way, they do not do a malloc to allocate their buckets.
llvm-svn: 35642
2007-04-04 00:29:37 +00:00
Evan Cheng
07d353c9d7
New asm test case.
...
llvm-svn: 35641
2007-04-04 00:15:17 +00:00
Evan Cheng
1e150dedd1
Implement inline asm modifier P.
...
llvm-svn: 35640
2007-04-04 00:13:29 +00:00
Evan Cheng
bd31f41daa
Typo.
...
llvm-svn: 35639
2007-04-04 00:06:07 +00:00
Bill Wendling
ac5b650a54
Adding more MMX instructions.
...
llvm-svn: 35638
2007-04-03 23:48:32 +00:00
Chris Lattner
f79fb5cad0
make a new missing features section
...
llvm-svn: 35637
2007-04-03 23:41:34 +00:00
Evan Cheng
10a25d43fa
New test case.
...
llvm-svn: 35636
2007-04-03 23:40:54 +00:00
Evan Cheng
3c68d4e8ba
Remove unused constant pool entries.
...
llvm-svn: 35635
2007-04-03 23:39:48 +00:00
Bill Wendling
2640b4a4ab
Updated
...
llvm-svn: 35634
2007-04-03 23:37:20 +00:00
Chris Lattner
e5bbb3cb1a
Fix a bug I introduced with my patch yesterday which broke Qt (I converted
...
some constant exprs to apints).
Thanks to Anton for tracking down a small testcase that triggered this!
llvm-svn: 35633
2007-04-03 23:29:39 +00:00
Chris Lattner
64df4ba422
greatly reduce hte default size of stringmap.
...
llvm-svn: 35632
2007-04-03 22:15:38 +00:00
Chris Lattner
85b0927c4b
move these to FrontendAda
...
llvm-svn: 35631
2007-04-03 21:48:02 +00:00
Chris Lattner
349987ed2c
testcase for recent bugfix
...
llvm-svn: 35630
2007-04-03 21:47:36 +00:00
Chris Lattner
412c70ed8a
move ada tests
...
llvm-svn: 35629
2007-04-03 21:46:22 +00:00
Evan Cheng
2c2ec5f138
New test case.
...
llvm-svn: 35628
2007-04-03 21:38:03 +00:00
Evan Cheng
39d8b4db92
Fixed a bug that causes codegen of noop like add r0, r0, #0 .
...
llvm-svn: 35627
2007-04-03 21:31:21 +00:00
Chris Lattner
a74deafb13
reinstate the previous two patches, with a bugfix :)
...
ldecod now passes.
llvm-svn: 35626
2007-04-03 17:43:25 +00:00
Nicolas Geoffray
23710a7da3
Starting implementation of the ELF32 ABI specification of varargs handling.
...
LowerVASTART emits the right code if the subtarget is ELF32, the other intrinsics
(VAARG, VACOPY and VAEND) are not yet implemented.
llvm-svn: 35625
2007-04-03 13:59:52 +00:00
Nicolas Geoffray
b3e99a18ee
The PPC64 ELF ABI is "intended to use the same structure layout and calling convention rules
...
as the 64-bit PowerOpen ABI" (Reference http://www.linux-foundation.org/spec/ELF/ppc64/ ).
Change all ELF tests to ELF32.
llvm-svn: 35624
2007-04-03 12:35:28 +00:00
Nicolas Geoffray
ab559f6e3c
Addition to the previous commit for getCalleeSavedRegClasses:
...
"The ELF ABI specifies F1-F8 registers as argument registers for double, not
F1-F10. This affects only ELF, not MachO."
llvm-svn: 35623
2007-04-03 10:57:49 +00:00
Nicolas Geoffray
fbfc451ba9
The ELF ABI specifies F1-F8 registers as argument registers for double, not
...
F1-F10. This affects only ELF, not MachO.
llvm-svn: 35622
2007-04-03 10:27:07 +00:00
Reid Spencer
d0b2dbfa03
Prepare for Subversion migration by implementing a -usesvn to tell the
...
script to to check out llvm and llvm-test from Subversion instead of CVS.
Without this option the script will continue to check out from CVS. To
specify the Subversion URL, set the SVNURL environment variable or pass
-svnurl followed by the URL. For now, -svnurl will default to Reid's
temporary (read-only, daily snapshot) SVN server. Try it out if you like!
llvm-svn: 35621
2007-04-03 08:28:44 +00:00
Evan Cheng
7511fa280d
Reverting back to 1.723. The last two commits broke JM (and possibily others) on ARM.
...
llvm-svn: 35620
2007-04-03 08:11:50 +00:00
Evan Cheng
e8315fe3f5
Inverted logic.
...
llvm-svn: 35619
2007-04-03 06:44:25 +00:00
Evan Cheng
06a7041ff9
Bad bad bug. findRegisterUseOperand() returns -1 if a use if not found.
...
llvm-svn: 35618
2007-04-03 06:43:29 +00:00
Bill Wendling
652c7b2d73
Changed to new MMX_ recipes.
...
llvm-svn: 35617
2007-04-03 06:18:31 +00:00
Bill Wendling
e7b2a864f2
Add FEMMS and ADDQ. Renamed MMX recipes to prepend the MMX_ to them.
...
llvm-svn: 35616
2007-04-03 06:00:37 +00:00
Chris Lattner
81e0707552
split some code out into a helper function
...
llvm-svn: 35615
2007-04-03 05:11:24 +00:00
Chris Lattner
64c764cebc
Split a whole ton of code out of visitICmpInst into visitICmpInstWithInstAndIntCst.
...
llvm-svn: 35614
2007-04-03 04:46:52 +00:00
Chris Lattner
fae5c8fae9
add missing operator
...
llvm-svn: 35613
2007-04-03 04:25:46 +00:00
Chris Lattner
8b2ec5f506
Fix PR1253 and xor2.ll:test[01]
...
llvm-svn: 35612
2007-04-03 01:47:41 +00:00
Chris Lattner
d4594adf43
new testcase for PR1253
...
llvm-svn: 35611
2007-04-03 01:45:32 +00:00
Chris Lattner
6b3ff17c70
add a helper function to constantint.
...
llvm-svn: 35610
2007-04-03 01:41:34 +00:00
Chris Lattner
f742e2fe70
Arm supports negative strides as well, add them. This lets us compile:
...
CodeGen/ARM/arm-negative-stride.ll to:
LBB1_2: @bb
str r1, [r3, -r0, lsl #2 ]
add r0, r0, #1
cmp r0, r2
bne LBB1_2 @bb
llvm-svn: 35609
2007-04-03 00:13:57 +00:00
Chris Lattner
67f99e955b
new testcase, where we should use a negative stride
...
llvm-svn: 35608
2007-04-03 00:13:16 +00:00
Chris Lattner
f3197a7d53
allow -1 strides to reuse "1" strides.
...
llvm-svn: 35607
2007-04-02 22:51:58 +00:00
Chris Lattner
d9eb0d9f5a
Add a regtest for cases we now recognize as rotates, thanks to Scott Michel's
...
recent dagcombine patch
llvm-svn: 35606
2007-04-02 22:08:54 +00:00
Scott Michel
16627a542f
1. Insert custom lowering hooks for ISD::ROTR and ISD::ROTL.
...
2. Help DAGCombiner recognize zero/sign/any-extended versions of ROTR and ROTL
patterns. This was motivated by the X86/rotate.ll testcase, which should now
generate code for other platforms (and soon-to-come platforms.) Rewrote code
slightly to make it easier to read.
llvm-svn: 35605
2007-04-02 21:36:32 +00:00
Chris Lattner
a7152a90d1
fix this testcase so it passes
...
llvm-svn: 35604
2007-04-02 20:46:28 +00:00
Chris Lattner
dd59227a73
fix this testcase on ppc hosts
...
llvm-svn: 35603
2007-04-02 20:39:48 +00:00
Dale Johannesen
d13786dd82
fix off by 1 error in displacement computation
...
llvm-svn: 35602
2007-04-02 20:31:06 +00:00
Chris Lattner
8e168a4f36
fix the CodeGen/ARM/2007-03-13-InstrSched.ll regression: allow IV's with scales
...
to be folded into non-store instructions.
llvm-svn: 35601
2007-04-02 18:51:18 +00:00
Evan Cheng
476fb6a5c9
Ugh. Copy coalescer does not update register numbers.
...
llvm-svn: 35600
2007-04-02 18:49:18 +00:00
Evan Cheng
f7f8e349d6
New test case.
...
llvm-svn: 35599
2007-04-02 18:47:13 +00:00
Chris Lattner
6223e83f6d
add support for the 'w' inline asm register class.
...
llvm-svn: 35598
2007-04-02 17:24:08 +00:00
Devang Patel
eb44d8fb19
Update example notes to clarify system linker's role.
...
llvm-svn: 35597
2007-04-02 16:54:12 +00:00
Reid Spencer
3b40d3887b
Regenerate.
...
llvm-svn: 35596
2007-04-02 15:41:39 +00:00
Reid Spencer
18c121d55d
Check for .svn directories too to determine if a debug build is appropriate.
...
llvm-svn: 35595
2007-04-02 15:40:39 +00:00
Zhou Sheng
9bc8ab100d
1. Make use of APInt operation instead of using ConstantExpr::getXXX.
...
2. Use cheaper APInt methods.
llvm-svn: 35594
2007-04-02 13:45:30 +00:00
Zhou Sheng
56cda95658
Use uint32_t for bitwidth instead of unsigned.
...
llvm-svn: 35593
2007-04-02 08:20:41 +00:00
Chris Lattner
28e0e4e11e
Pass the type of the store access, not the type of the store, into the
...
target hook. This allows us to codegen a loop as:
LBB1_1: @cond_next
mov r2, #0
str r2, [r0, +r3, lsl #2 ]
add r3, r3, #1
cmn r3, #1
bne LBB1_1 @cond_next
instead of:
LBB1_1: @cond_next
mov r2, #0
str r2, [r0], #+4
add r3, r3, #1
cmn r3, #1
bne LBB1_1 @cond_next
This looks the same, but has one fewer induction variable (and therefore,
one fewer register) live in the loop.
llvm-svn: 35592
2007-04-02 06:34:44 +00:00
Chris Lattner
be96c646dc
new testcase.
...
llvm-svn: 35591
2007-04-02 06:33:10 +00:00
Chris Lattner
3e21eb7fd7
Fix a bug which caused us to never be able to use signed comparisons for
...
equality comparisons of a constant. This allows us to codegen the 'sintzero'
loop in PR1288 as:
LBB1_1: ;cond_next
li r4, 0
addi r2, r2, 1
stw r4, 0(r3)
addi r3, r3, 4
cmpwi cr0, r2, -1
bne cr0, LBB1_1 ;cond_next
instead of:
LBB1_1: ;cond_next
addi r2, r2, 1
li r4, 0
xoris r5, r2, 65535
stw r4, 0(r3)
addi r3, r3, 4
cmplwi cr0, r5, 65535
bne cr0, LBB1_1 ;cond_next
This implements CodeGen/PowerPC/compare-simm.ll, and also cuts 74
instructions out of kc++.
llvm-svn: 35590
2007-04-02 05:59:42 +00:00
Chris Lattner
745f59bfde
new testcase
...
llvm-svn: 35589
2007-04-02 05:57:59 +00:00
Chris Lattner
9d5aacee92
Wrap long line
...
llvm-svn: 35588
2007-04-02 05:48:58 +00:00
Chris Lattner
50490d54f2
use more obvious function name.
...
llvm-svn: 35587
2007-04-02 05:42:22 +00:00
Chris Lattner
a3e0bb4ebb
Treat xor of signbit like an add.
...
llvm-svn: 35586
2007-04-02 05:41:38 +00:00
Chris Lattner
d14447833a
add a helper function.
...
llvm-svn: 35585
2007-04-02 05:41:00 +00:00
Chris Lattner
b24acc7bee
simplify (x+c)^signbit as (x+c+signbit), pointed out by PR1288. This implements
...
test/Transforms/InstCombine/xor.ll:test28
llvm-svn: 35584
2007-04-02 05:36:22 +00:00
Chris Lattner
2d81c6d706
creative way to add one.
...
llvm-svn: 35583
2007-04-02 05:35:08 +00:00
Chris Lattner
0a844d8df1
my patch fixed the fixme.
...
llvm-svn: 35582
2007-04-02 05:08:54 +00:00
Reid Spencer
e51961b5ba
Fix illegal assembly syntax.
...
llvm-svn: 35581
2007-04-02 03:24:47 +00:00
Reid Spencer
f361c4f4f8
bwsap -> bswap
...
llvm-svn: 35580
2007-04-02 02:25:19 +00:00
Reid Spencer
69e56c3461
Regenerate
...
llvm-svn: 35579
2007-04-02 02:08:35 +00:00
Reid Spencer
940fccb088
Upgrade the bit count intrinsics to have an i32 result.
...
llvm-svn: 35578
2007-04-02 02:08:05 +00:00
Reid Spencer
a3bc850712
Add a test case to make sure that constant folding of the bit counting
...
intrinsics works.
llvm-svn: 35577
2007-04-02 01:45:31 +00:00
Chris Lattner
b7b75145f1
reduce use of std::set
...
llvm-svn: 35576
2007-04-02 01:44:59 +00:00
Chris Lattner
c3748562bd
Various passes before isel split edges and do other CFG-restructuring changes.
...
isel has its own particular features that it wants in the CFG, in order to
reduce the number of times a constant is computed, etc. Make sure that we
clean up the CFG before doing any other things for isel. Doing so can
dramatically reduce the number of split edges and reduce the number of
places that constants get computed. For example, this shrinks
CodeGen/Generic/phi-immediate-factoring.ll from 44 to 37 instructions on X86,
and from 21 to 17 MBB's in the output. This is primarily a code size win,
not a performance win.
This implements CodeGen/Generic/phi-immediate-factoring.ll and PR1296.
llvm-svn: 35575
2007-04-02 01:35:34 +00:00
Chris Lattner
4cb30067c2
new testcase for PR1296
...
llvm-svn: 35574
2007-04-02 01:32:59 +00:00
Lauro Ramos Venancio
6be85337b0
- Divides the comparisons in two types: comparisons that only use N and Z
...
flags (ARMISD::CMPNZ) and comparisons that use all flags (ARMISD::CMP).
- Defines the instructions: TST, TEQ (ARM) and TST (Thumb).
llvm-svn: 35573
2007-04-02 01:30:03 +00:00
Chris Lattner
7c773e6850
add range version of insert()
...
llvm-svn: 35572
2007-04-02 01:21:19 +00:00
Reid Spencer
1bd88bdab3
Regenerate
...
llvm-svn: 35571
2007-04-02 01:14:00 +00:00
Reid Spencer
86207ee54d
Don't upgrade functions that look like a bswap intrinsic but aren't.
...
llvm-svn: 35570
2007-04-02 01:13:36 +00:00
Reid Spencer
84c90a9431
Let llvm-upgrade upgrade the bswap intrinsic.
...
llvm-svn: 35569
2007-04-02 01:09:19 +00:00
Reid Spencer
0b544372d4
Let llvm-upgrade upgrade bswap intrinsic.
...
llvm-svn: 35568
2007-04-02 01:08:02 +00:00
Reid Spencer
fad9bd6b92
For PR1297:
...
Make sure that the CTPOP result is casted to i32 as the bit counting
intrinsics all return i32 now (this affects CTLZ and CTTZ as well).
llvm-svn: 35567
2007-04-02 01:01:49 +00:00
Reid Spencer
a5f996bd27
Revert the name changes for llvm.bswap to allow (and test) llvm-upgrade of
...
this intrinsic.
llvm-svn: 35566
2007-04-02 00:51:15 +00:00
Reid Spencer
ef592214e2
Handle upgrade of llvm.bswap.iXX to llvm.bswap.iXX.iXX per new naming
...
rules for overloaded intrinsic functions.
llvm-svn: 35565
2007-04-02 00:50:28 +00:00
Reid Spencer
403a1c4517
Fix some bswap typos that Chris noticed.
...
llvm-svn: 35564
2007-04-02 00:19:52 +00:00
Chris Lattner
8fe3cbe6bd
print the type of an inserted IV in -debug mode.
...
llvm-svn: 35563
2007-04-01 22:21:39 +00:00
Anton Korobeynikov
ecc769e4f2
Add testcase for correct sret handling.
...
llvm-svn: 35562
2007-04-01 22:03:04 +00:00
Chris Lattner
c3eeb42809
simplify this code, make it work for ap ints
...
llvm-svn: 35561
2007-04-01 20:57:36 +00:00
Chris Lattner
59a6fa7af6
fix breakage from last night, simplify code.
...
llvm-svn: 35560
2007-04-01 20:49:36 +00:00
Chris Lattner
489ad3313a
gcc 3.4.4 is known-bad on x86-64
...
llvm-svn: 35559
2007-04-01 20:14:46 +00:00
Reid Spencer
8bc7d957cf
Preview documentation for additional intrinsic functions.
...
llvm-svn: 35558
2007-04-01 19:00:37 +00:00
Jeff Cohen
3e96df52d8
Unbreak VC++ build.
...
llvm-svn: 35557
2007-04-01 18:58:22 +00:00
Reid Spencer
add6123405
The bit counting intrinsics return i32 not the operand type. This fixes
...
last night's regression in SingleSource/UnitTests/2005-05-11-Popcount-ffs-fls
llvm-svn: 35556
2007-04-01 18:42:20 +00:00
Zhou Sheng
150f3bbab2
Avoid unnecessary APInt construction.
...
llvm-svn: 35555
2007-04-01 17:13:37 +00:00
Duncan Sands
2e45201769
Testcase for the problem worked around in
...
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070319/046204.html
llvm-svn: 35554
2007-04-01 15:29:02 +00:00
Zhou Sheng
63b6bc1c88
Remove unused methods.
...
llvm-svn: 35553
2007-04-01 12:45:33 +00:00
Reid Spencer
8a5799f558
For PR1297:
...
Preview documentation for the llvm.bit.concat intrinsic (yet to be
implemented).
llvm-svn: 35552
2007-04-01 08:27:01 +00:00
Evan Cheng
17d48a8bc2
Add i16 address mode.
...
llvm-svn: 35551
2007-04-01 08:06:46 +00:00
Reid Spencer
4eefaab3f6
For PR1297:
...
Document changes to bswap and bit counting intrinsics. bswap's name now
requires two types in the suffix per overloaded intrinsic naming rules.
The ctpop, cttz, and ctlz intrinsics were changed to always return i32.
llvm-svn: 35550
2007-04-01 08:04:23 +00:00
Reid Spencer
9ade28d260
Mention how to create overloaded intrinsics.
...
llvm-svn: 35549
2007-04-01 07:44:52 +00:00
Reid Spencer
c3d87685ad
For PR1297:
...
Update these test cases to use proper signatures for bswap which is now
and overloaded intrinsic. Its name must be of the form llvm.bswap.i32.i32
since both the parameter and the result or of type "iAny". Also, the
bit counting intrinsics changed to always return i32.
llvm-svn: 35548
2007-04-01 07:36:28 +00:00
Reid Spencer
6bba6c8143
For PR1297:
...
Support overloaded intrinsics bswap, ctpop, cttz, ctlz.
llvm-svn: 35547
2007-04-01 07:35:23 +00:00
Reid Spencer
3a0843e734
For PR1297:
...
Adjust for changes in the bit counting intrinsics. They all return i32
now so we have to trunc/zext the DAG node accordingly.
llvm-svn: 35546
2007-04-01 07:34:11 +00:00
Reid Spencer
a090ffb2ab
For PR1297:
...
Change getOperationName to return std::string instead of const char*
llvm-svn: 35545
2007-04-01 07:32:19 +00:00
Reid Spencer
eba021453b
For PR1297:
...
Implement bswap, ctpop, ctlz, and cttz utilizing the new overloaded
intrinsic feature of tblgen. By defining llvm_int_ty to have an ValueType
of iAny, any intrinsic using that type becomes an overloaded intrinsic.
This signals that a) any integer type could be used for that argument and
b) the intrinsic needs a suffix to match each such argument for the
actual intrinsic.
llvm-svn: 35544
2007-04-01 07:30:57 +00:00
Reid Spencer
c7c4880ab1
For PR1297:
...
Intrinsic functions might need to be generated (if they are overloaded) so
returning a const char* is no longer possible. Change getOperationName to
return a std::string instead.
llvm-svn: 35543
2007-04-01 07:28:37 +00:00
Reid Spencer
be23fb0370
For PR1297:
...
Change the interface to the getName, getType, getDeclaration methods to
include the "actual" types of the result/arguments. This is necessary to
support overloaded intrinsics.
llvm-svn: 35542
2007-04-01 07:26:35 +00:00
Reid Spencer
2a2117c82d
For PR1297:
...
Implement "actual" argument types for the Intrinsic member functions. This
involves changing the getName, getType, and getDeclaration methods to have
optional parameters for the actual types. These are necessary in order for
the type/name to be constructed properly for overloaded intrinsics. Only
the caller knows the actual argument types desired.
llvm-svn: 35541
2007-04-01 07:25:33 +00:00
Reid Spencer
7c57b88b27
For PR1297:
...
1. Clear up confusion between "GotBits" and "ExpectBits". GotBits is the
type actually provided. ExpectedBits is the type expected for the
intrinsics. Before this patch, it was reversed!
2. Implement checks for overloaded intrinsics. This involves computing the
suffix expected and making sure the suffix matches the function name. It
also includes some intrinsic-specific checks such as ensuring that the
bswap parameter and result are the same width and an even number of bytes.
llvm-svn: 35540
2007-04-01 07:22:57 +00:00
Reid Spencer
e67d0c226d
For PR1297:
...
Implement code generation for overloaded intrinsic functions. The basic
difference is that "actual" argument types must be provided when
constructing intrinsic names and types. Also, for recognition, only the
prefix is examined. If it matches, the suffix is assumed to match. The
suffix is checked by the Verifier, however.
llvm-svn: 35539
2007-04-01 07:20:02 +00:00
Reid Spencer
51455e00dc
For PR1297:
...
Add an "iAny" ValueType as a place holder for an integer type of any
bit width. This is used for intrinsics overloading on integer type.
llvm-svn: 35538
2007-04-01 07:17:45 +00:00
Chris Lattner
f517e9578d
not not!
...
llvm-svn: 35537
2007-04-01 06:19:41 +00:00
Chris Lattner
0427799531
Fix InstCombine/2007-03-31-InfiniteLoop.ll
...
llvm-svn: 35536
2007-04-01 05:36:37 +00:00
Chris Lattner
9729bdd8e3
New testcase
...
llvm-svn: 35535
2007-04-01 05:34:53 +00:00
Nick Lewycky
f22938af1b
Implement union of wrapped sets.
...
llvm-svn: 35534
2007-04-01 03:47:44 +00:00
Andrew Lenharth
427ec7fa51
Readme
...
llvm-svn: 35533
2007-03-31 15:05:44 +00:00
Anton Korobeynikov
a8cc1ebae1
Consistency with native compilers
...
llvm-svn: 35532
2007-03-31 13:11:52 +00:00
Bill Wendling
b72fcddd23
Fix comment.
...
llvm-svn: 35531
2007-03-31 09:36:12 +00:00
Chris Lattner
075b4db621
add a note
...
llvm-svn: 35530
2007-03-31 07:06:25 +00:00
Chris Lattner
f6a6d3c8b0
move a bunch of code out of the sdisel pass into its own opt pass "codegenprepare".
...
llvm-svn: 35529
2007-03-31 04:18:03 +00:00
Chris Lattner
f2836d17b6
Split the sdisel code munging stuff out into its own opt-pass, CodeGenPrepare.
...
llvm-svn: 35528
2007-03-31 04:06:36 +00:00
Chris Lattner
f2d71d49e2
switch TL::getValueType to use MVT::getValueType.
...
llvm-svn: 35527
2007-03-31 04:05:24 +00:00
Chris Lattner
516f38b35f
add a method to turn a type into a VT.
...
llvm-svn: 35526
2007-03-31 04:03:02 +00:00
Zhou Sheng
82c42284f4
Delete dead code.
...
llvm-svn: 35525
2007-03-31 02:50:26 +00:00
Zhou Sheng
4f16402e0d
Use APInt operators to calculate the carry bits, remove this loop.
...
llvm-svn: 35524
2007-03-31 02:38:39 +00:00
Bill Wendling
afddb2c6f8
Match GCC's MMX calling convention.
...
llvm-svn: 35523
2007-03-31 01:03:53 +00:00
Chris Lattner
bafc837c83
Add a -print-lsr-output option to LLC, to print the output of the LSR pass.
...
llvm-svn: 35522
2007-03-31 00:24:43 +00:00
Chris Lattner
1eb94d973a
implement the new addressing mode description hook.
...
llvm-svn: 35521
2007-03-30 23:15:24 +00:00
Chris Lattner
ac3f81508c
add one addressing mode description hook to rule them all.
...
llvm-svn: 35520
2007-03-30 23:14:50 +00:00
Evan Cheng
67a49736af
Missing '&&'
...
llvm-svn: 35519
2007-03-30 22:03:49 +00:00
Jeff Cohen
2cdce430e2
This is working again.
...
llvm-svn: 35518
2007-03-30 22:02:18 +00:00
Dale Johannesen
4bbd2eefba
Fix incorrect combination of different loads. Reenable zext-over-truncate
...
combination.
llvm-svn: 35517
2007-03-30 21:38:07 +00:00
Chris Lattner
d1440c429f
add a testcase for x86
...
llvm-svn: 35516
2007-03-30 21:22:46 +00:00
Evan Cheng
1d78d3deeb
New test case.
...
llvm-svn: 35515
2007-03-30 20:41:18 +00:00
Evan Cheng
9a2a7b174a
Don't add the same MI to register reuse "last def/use" twice if it reads the
...
register more than once.
llvm-svn: 35513
2007-03-30 20:21:35 +00:00
Evan Cheng
48dd5e7d44
Bug fix for PR1279. When isDead is propagate by copy coalescing, we keep length
...
of dead def live interval at 1 to avoid multiple def's targeting the same
register. The previous patch missed a case where the source operand is live-in.
In that case, remove the whole interval.
llvm-svn: 35512
2007-03-30 20:18:35 +00:00
Evan Cheng
9ca63d605c
Test case for PR1279 (part 2).
...
llvm-svn: 35511
2007-03-30 20:15:22 +00:00
Zhou Sheng
fd28a33031
Make sure the use of ConstantInt::getZExtValue() for shift amount safe.
...
llvm-svn: 35510
2007-03-30 17:20:39 +00:00
Zhou Sheng
02d3ac6895
Make sure this method just return value equal or less than Limit.
...
llvm-svn: 35509
2007-03-30 16:50:28 +00:00
Reid Spencer
8c3d3dce2b
For PR1293:
...
* Rename the FunctionType* parameter from M to FT on all the functions.
* Implement a fix for PR1293 by just asserting that library functions that
must return pointers should have pointer typed results. This just makes
sure that we don't attempt to use an uninitialized integer or something
later on.
llvm-svn: 35508
2007-03-30 16:41:50 +00:00
Duncan Sands
3bf01520eb
Remove reference to checkpoint.
...
llvm-svn: 35507
2007-03-30 16:09:58 +00:00
Duncan Sands
16f122e6ad
Various hopefully correct easy fixes.
...
llvm-svn: 35506
2007-03-30 12:22:09 +00:00
Zhou Sheng
b25806fa5f
1. Make sure the use of ConstantInt::getZExtValue() for getting shift
...
amount is safe.
2. Use new method on ConstantInt instead of (? :) operator.
3. Use new method uge() on ConstantInt to simplify codes.
llvm-svn: 35505
2007-03-30 09:29:48 +00:00
Duncan Sands
3dd14331ac
Correct typo.
...
llvm-svn: 35504
2007-03-30 06:39:42 +00:00
Zhou Sheng
5e60a4a6b0
Use APInt operation instead of ConstantExpr::getXX.
...
llvm-svn: 35503
2007-03-30 05:45:18 +00:00
Zhou Sheng
9737575772
Rename and correct the method "greaterOrEqual".
...
llvm-svn: 35502
2007-03-30 05:10:59 +00:00
Zhou Sheng
12b3549f5d
Add two utility methods into ConstantInt.
...
llvm-svn: 35501
2007-03-30 03:22:55 +00:00
Reid Spencer
ef01c47512
For PR1289: Regenerate
...
llvm-svn: 35500
2007-03-30 01:37:39 +00:00
Reid Spencer
cf2ccbff1a
For PR1289:
...
Check at the end of the parse that there are no unresolved types and no
undefined values. Issue errors if there are. This gets rid of the need
for implementation or checkpoint by ensuring you can't finish a parse with
undefined things.
llvm-svn: 35499
2007-03-30 01:37:13 +00:00
Reid Spencer
3c401f0613
For PR1289:
...
Remove an unneeded instance of "implementation" that soon won't be supported.
llvm-svn: 35498
2007-03-30 01:35:32 +00:00
Bill Wendling
2fbcbc16b4
Add MMX calling conventions.
...
llvm-svn: 35489
2007-03-30 00:35:22 +00:00
Evan Cheng
045414aa8e
New entry.
...
llvm-svn: 35480
2007-03-29 21:40:13 +00:00
Evan Cheng
cc44b1e743
Can't re-materialize mov r, imm in thumb since mov would clobber the condition code.
...
llvm-svn: 35479
2007-03-29 21:38:31 +00:00
Reid Spencer
d232f311cb
Remove some non-sensical logic that prevented llvm-nm from working on any
...
file other than one named "-".
llvm-svn: 35478
2007-03-29 19:49:07 +00:00
Reid Spencer
c7f485fd71
Use the stat information in the Path object, if it is already obtained. This
...
avoids a call to ::fstat by MappedFile when the file size information was
already obtained by the Path object.
llvm-svn: 35477
2007-03-29 19:11:22 +00:00
Reid Spencer
200c6f9c3d
For PR789:
...
Make the sys::Path::getFileStatus function more efficient by having it
return a pointer to the FileStatus structure rather than copy it. Adjust
uses of the function accordingly. Also, fix some memory issues in sys::Path.
llvm-svn: 35476
2007-03-29 19:05:44 +00:00
Chris Lattner
7c82675afa
the bytecode reader supports dematerializeFunction
...
llvm-svn: 35475
2007-03-29 18:58:08 +00:00
Reid Spencer
b9d7f2a3ba
checkpoint -> implementation. This really needs to just drop the need for
...
a keyword by having the assembler check for incomplete types and values
upon end-of-file.
llvm-svn: 35474
2007-03-29 18:56:58 +00:00
Reid Spencer
0833b81248
Regenerate.
...
llvm-svn: 35473
2007-03-29 18:50:01 +00:00
Reid Spencer
01a599a202
Give users a grace period on the implementation keyword. This *will* get
...
removed in a few days.
llvm-svn: 35472
2007-03-29 18:49:28 +00:00
Chris Lattner
c3f4d87c90
add a hook to demat functions.
...
llvm-svn: 35471
2007-03-29 18:30:26 +00:00
Chris Lattner
323a5137c6
don't build runtime for now, ever
...
llvm-svn: 35470
2007-03-29 18:14:00 +00:00
Jeff Cohen
68e93b7c44
MS C does have inlining after all, just uses _inline instead of inline.
...
llvm-svn: 35467
2007-03-29 17:42:21 +00:00
Jeff Cohen
54a781be7d
getFileStatus has a new parameter (caught by VC++).
...
llvm-svn: 35466
2007-03-29 17:29:59 +00:00
Jeff Cohen
73926a5fb5
uniqueID is a uint64_t (caught by VC++)
...
llvm-svn: 35465
2007-03-29 17:28:31 +00:00
Jeff Cohen
60c5522467
Determine absolute paths the correct way :)
...
llvm-svn: 35464
2007-03-29 17:27:38 +00:00
Reid Spencer
d394617a55
Add a uniqueID field to the FileStatus structure for Paths. This will map
...
to the inode number on Unix and something far less unique on Windows. The
windows case needs to be improved.
llvm-svn: 35461
2007-03-29 17:00:31 +00:00
Reid Spencer
858045e396
Don't forget to delete the FileStatus structure on destruction of Path.
...
llvm-svn: 35459
2007-03-29 16:50:49 +00:00
Reid Spencer
78b899f665
For PR789:
...
Updates for change in interface of getFileStatus method of sys::Path class.
llvm-svn: 35458
2007-03-29 16:48:16 +00:00
Reid Spencer
0f92f0e519
For PR789:
...
* Add a method: bool isAbsolute() const, which determines if the path name
is absolute or not.
* Implement caching of file status information in the Path object. Allow it
to be updated forcefully or lazily re-fetched from the cached value.
llvm-svn: 35456
2007-03-29 16:43:20 +00:00
Reid Spencer
908f777886
Regenerate for PR1283 fix.
...
llvm-svn: 35452
2007-03-29 15:38:33 +00:00
Reid Spencer
1a48abc2d4
For PR1283:
...
Change the llvm-gcc sanity check to look for "target datalayout" instead
of "implementation". The implementation keyword is no longer generated
by llvm or llvm-gcc.
llvm-svn: 35451
2007-03-29 15:37:57 +00:00
Zhou Sheng
b3a80b1d70
1. Make more use of APInt::getHighBitsSet/getLowBitsSet.
...
2. Let APInt variable do the binary operation stuff instead of using
ConstantExpr::getXXX.
llvm-svn: 35450
2007-03-29 08:15:12 +00:00
Evan Cheng
ccee35fd0d
Disable load width reduction xform of variant (zext (truncate load x)) for
...
big endian targets until llvm-gcc build issue has been resolved.
llvm-svn: 35449
2007-03-29 07:56:46 +00:00
Evan Cheng
8f592160c0
Add support for hidden visibility to darwin/arm.
...
llvm-svn: 35448
2007-03-29 07:49:34 +00:00
Zhou Sheng
444af49cc0
Clean up some codes in InstCombiner::SimplifyDemandedBits().
...
llvm-svn: 35446
2007-03-29 04:45:55 +00:00
Evan Cheng
86de3a009d
New entries.
...
llvm-svn: 35445
2007-03-29 02:48:56 +00:00
Zhou Sheng
a4475575c0
Clean up codes in InstCombiner::SimplifyDemandedBits():
...
1. Line out nested call of APInt::zext/trunc.
2. Make more use of APInt::getHighBitsSet/getLowBitsSet.
3. Use APInt[] operator instead of expression like "APIntVal & SignBit".
llvm-svn: 35444
2007-03-29 02:26:30 +00:00
Zhou Sheng
4961cf1c06
1. Make the APInt variable do the binary operation stuff if possible
...
instead of using ConstantExpr::getXX.
2. Use constant reference to APInt if possible instead of expensive
APInt copy.
llvm-svn: 35443
2007-03-29 01:57:21 +00:00
Jeff Cohen
cc560c93eb
Fix C Backend to generate code that works with Microsoft C for the benefit of
...
front ends that do not depend on the GCC runtime (someday...).
llvm-svn: 35441
2007-03-28 23:08:37 +00:00
Jeff Cohen
277a237520
Update to current situation.
...
llvm-svn: 35440
2007-03-28 20:27:51 +00:00
Bill Wendling
4ad38abd40
Made this into a bug report: PR1286
...
llvm-svn: 35439
2007-03-28 19:07:34 +00:00
Anton Korobeynikov
0ad22563b8
Oops :)
...
llvm-svn: 35438
2007-03-28 18:38:33 +00:00
Anton Korobeynikov
7522c9d8e1
Don't allow MatchAddress recurse too much. This trims exponential
...
behaviour in some cases.
llvm-svn: 35437
2007-03-28 18:36:33 +00:00
Chris Lattner
3d9c1bd9e2
Stop using the foo HTML tag :)
...
llvm-svn: 35436
2007-03-28 18:27:57 +00:00
Chris Lattner
2ba38c8711
add a note
...
llvm-svn: 35435
2007-03-28 18:17:19 +00:00
Chris Lattner
bcd38852f2
Compile CodeGen/X86/lea-3.ll:test2 to:
...
_test3:
leaq (,%rdi,4), %rax
orq %rdi, %rax
ret
instead of:
_test2:
movq %rdi, %rax
shlq $2, %rax
orq %rdi, %rax
ret
llvm-svn: 35434
2007-03-28 18:12:31 +00:00
Chris Lattner
17331da6bd
new testcases
...
llvm-svn: 35433
2007-03-28 18:11:17 +00:00
Chris Lattner
66cb5db76f
new testcase
...
llvm-svn: 35432
2007-03-28 18:03:14 +00:00
Zhou Sheng
117477e28b
Avoid unnecessary APInt construction.
...
llvm-svn: 35431
2007-03-28 17:38:21 +00:00
Chris Lattner
a6527d6a61
Dan pointed out that this is done, remove it!
...
llvm-svn: 35430
2007-03-28 17:26:52 +00:00
Scott Michel
734077b1f0
First test check-in.
...
llvm-svn: 35429
2007-03-28 17:04:43 +00:00
Zhou Sheng
23f7a1c947
1. Make more use of getLowBitsSet/getHighBitsSet.
...
2. Use APInt[] instead of "X & SignBit".
3. Clean up some codes.
4. Make the expression like "ShiftAmt = ShiftAmtC->getZExtValue()" safe.
llvm-svn: 35424
2007-03-28 15:02:20 +00:00
Devang Patel
0b013d578d
It is not possible to determine dominance between two PHI nodes
...
based on their ordering. This is applicable to ETForest::dominates() also.
llvm-svn: 35423
2007-03-28 14:57:43 +00:00
Zhou Sheng
2777a31850
1. Make more use of getLowBitsSet/getHighBitsSet.
...
2. Make the APInt value do the zext/trunc stuff instead of using
ConstantExpr::getZExt().
llvm-svn: 35422
2007-03-28 09:19:01 +00:00
Evan Cheng
d771485d89
Notes on re-materialization.
...
llvm-svn: 35420
2007-03-28 08:30:04 +00:00
Evan Cheng
603e49c6da
Move rematerialization out of beta.
...
llvm-svn: 35419
2007-03-28 08:26:40 +00:00
Zhou Sheng
c2d3309b99
Use UnknownBIts[BitWidth-1] instead of UnknownBIts & SignBits.
...
llvm-svn: 35418
2007-03-28 05:15:57 +00:00
Jeff Cohen
d578f1f87f
Fix problem with llvm-config that prevented JIT from being used on x86_64
...
systems.
llvm-svn: 35416
2007-03-28 04:45:02 +00:00
Reid Spencer
8cd7e8190b
Delete the remanant of an obsolete comment.
...
llvm-svn: 35415
2007-03-28 03:23:22 +00:00
Zhou Sheng
18570b1f14
Remove unused APInt variable.
...
llvm-svn: 35414
2007-03-28 03:02:21 +00:00
Reid Spencer
15316f9568
Undocument the implementation keyword
...
Docuemnt the checkpoint keyword
llvm-svn: 35413
2007-03-28 02:46:29 +00:00
Reid Spencer
44259a29c0
Remove use of implementation keyword.
...
llvm-svn: 35412
2007-03-28 02:38:26 +00:00
Reid Spencer
b7e45e705a
Regenerate.
...
llvm-svn: 35411
2007-03-28 02:37:40 +00:00
Reid Spencer
2e35a58838
Replace the "implementation" keyword with "checkpoint". This more accurately
...
describes its function as check against unresolved types and definitions.
This is handy for forcing error messages in assembly test cases or otherwise
ensuring that everything is resolved at that point in the assembly.
llvm-svn: 35410
2007-03-28 02:36:42 +00:00
Reid Spencer
bad2921deb
The implementation keyword was replaced with checkpoint.
...
llvm-svn: 35409
2007-03-28 02:34:53 +00:00