Evan Cheng
b720f37282
Fix divmod libcall lowering. Convert to {S|U}DIVREM first and then expand the node to a libcall. rdar://9280991
...
llvm-svn: 129633
2011-04-16 03:08:26 +00:00
Rafael Espindola
b9bb29267f
Fix cmake build.
...
llvm-svn: 129632
2011-04-16 02:06:46 +00:00
Nick Lewycky
a2958ced1e
Move the re-stemming function up top and use it where it's currently inlined.
...
Break the arc-profile code out to a function like the notes emission code is,
and reorder the functions in the file.
The only functionality change is that we no longer modify the Module when the
Module has no debug info to use.
llvm-svn: 129631
2011-04-16 02:05:18 +00:00
Nick Lewycky
9aeaafc27a
Rename LineProfiling to GCOVProfiling to more accurately represent what it
...
does. Also mostly implement it. Still a work-in-progress, but generates legal
output on crafted test cases.
llvm-svn: 129630
2011-04-16 01:20:23 +00:00
Devang Patel
eddab1d186
Introduce support to encode Objective-C property information in debugging information generated for an interface.
...
llvm-svn: 129624
2011-04-16 00:11:51 +00:00
Johnny Chen
d7a6b974bc
Thumb2 BFC was insufficiently encoded.
...
rdar://problem/9292717
llvm-svn: 129619
2011-04-15 22:52:15 +00:00
Johnny Chen
2a183b813d
A8.6.315 VLD3 (single 3-element structure to all lanes)
...
The a bit must be encoded as 0.
rdar://problem/9292625
llvm-svn: 129618
2011-04-15 22:49:08 +00:00
Akira Hatanaka
ee5ee33cfc
Re-enable test o32_cc_vararg.ll.
...
llvm-svn: 129616
2011-04-15 22:23:09 +00:00
Douglas Gregor
2bebd9880d
Initial work to improve documentation for Clang's diagnostics, from Matthieu Monrocq
...
llvm-svn: 129613
2011-04-15 22:04:07 +00:00
Akira Hatanaka
74d45b54f1
Reverse unnecessary changes made in r129606 and r129608. There is no change in functionality.
...
llvm-svn: 129612
2011-04-15 21:51:11 +00:00
Cameron Zwarich
5e9c2506d8
Add ORR and EOR to the CMP peephole optimizer. It's hard to get isel to generate
...
a case involving EOR, so I only added a test for ORR.
llvm-svn: 129610
2011-04-15 21:24:38 +00:00
Douglas Gregor
054dd418ca
Fix some broken links, from Matthieu Monrocq
...
llvm-svn: 129609
2011-04-15 21:21:31 +00:00
Akira Hatanaka
d4fd6b478e
Fix lines that exceed 80 columns. There is no change in functionality.
...
llvm-svn: 129608
2011-04-15 21:06:38 +00:00
Rafael Espindola
2723cb649f
Add this test back for Darwin.
...
llvm-svn: 129607
2011-04-15 21:06:27 +00:00
Akira Hatanaka
6f900185ed
Fix lines that have incorrect indentation or exceed 80 columns. There is no change in functionality.
...
llvm-svn: 129606
2011-04-15 21:00:26 +00:00
Cameron Zwarich
05fb4f0c81
The AND instruction leaves the V flag unmodified, so it falls victim to the same
...
problem as all of the other instructions we fold with CMPs.
llvm-svn: 129602
2011-04-15 20:45:00 +00:00
Rafael Espindola
4daf38357c
Fix cmake build.
...
llvm-svn: 129601
2011-04-15 20:34:45 +00:00
Rafael Espindola
694ad2f25c
Some refactoring suggested by Anton Korobeynikov.
...
llvm-svn: 129600
2011-04-15 20:32:03 +00:00
Cameron Zwarich
ddbf79c32b
Add missing register forms of instructions to the ARM CMP-folding code. This
...
fixes <rdar://problem/9287901>.
llvm-svn: 129599
2011-04-15 20:28:28 +00:00
Akira Hatanaka
025720d06f
Add pass that expands pseudo instructions into target instructions after register allocation. Define pseudos that get expanded into mtc1 or mfc1 instructions.
...
llvm-svn: 129594
2011-04-15 19:52:08 +00:00
Evan Cheng
e33e4028a6
Increase SubtargetFeatureKV Value and Implies fields to 64 bits since some targets are getting very close to 32 subtarget features. Also teach tablegen to error when there are more than 64 features to guard against undefined behavior. rdar://9282332
...
llvm-svn: 129590
2011-04-15 19:35:46 +00:00
Joerg Sonnenberger
42c3063de0
Add encoding tests for flds/filds
...
llvm-svn: 129589
2011-04-15 19:25:31 +00:00
Lenny Maiorani
dfae65d305
Implements StringRef::compare with bounds. It is behaves similarly to strncmp(). Unit tests also included.
...
llvm-svn: 129582
2011-04-15 17:56:50 +00:00
Jakob Stoklund Olesen
bdd6204582
Teach the SplitKit blitter to handle multiply defined values as well.
...
The transferValues() function can now handle both singly and multiply defined
values, as long as the resulting live range is known. Only rematerialized values
have their live range recomputed by extendRange().
The updateSSA() function can now insert PHI values in bulk across multiple
values in multiple target registers in one pass. The list of blocks received
from transferValues() is in layout order which seems to work well for the
iterative algorithm. Blocks from extendRange() are still in reverse BFS order,
but this function is used so rarely now that it doesn't matter.
llvm-svn: 129580
2011-04-15 17:24:49 +00:00
Jakob Stoklund Olesen
ea8581b792
Remember to set flag.
...
llvm-svn: 129579
2011-04-15 17:24:46 +00:00
Rafael Espindola
99831068c8
Add 129518 back with a fix for when we are producing eh just because of debug info.
...
Change ELF systems to use CFI for producing the EH tables. This reduces the
size of the clang binary in Debug builds from 690MB to 679MB.
llvm-svn: 129571
2011-04-15 15:11:06 +00:00
Chris Lattner
0304b82f80
Fix a ton of comment typos found by codespell. Patch by
...
Luis Felipe Strano Moraes!
llvm-svn: 129558
2011-04-15 05:18:47 +00:00
NAKAMURA Takumi
7aed456653
Revert r129518, "Change ELF systems to use CFI for producing the EH tables. This reduces the"
...
It broke several builds.
llvm-svn: 129557
2011-04-15 03:35:57 +00:00
Evan Cheng
f33f509d45
Fix another fcopysign lowering bug. If src is f64 and destination is f32, don't
...
forget to right shift the source by 32 first. rdar://9287902
llvm-svn: 129556
2011-04-15 01:31:00 +00:00
Johnny Chen
f268f057f4
For t2BFI, both Inst{26} and Inst{5} "should" be 0.
...
Ref: I.1 Instruction encoding diagrams and pseudocode
llvm-svn: 129552
2011-04-15 00:35:08 +00:00
Michael J. Spencer
05b07faeaf
Add 3DNow! intrinsics.
...
llvm-svn: 129551
2011-04-15 00:32:41 +00:00
Johnny Chen
197d67a987
The ARM disassembler did not handle the alignment correctly for VLD*DUP* instructions
...
(single element or n-element structure to all lanes).
llvm-svn: 129550
2011-04-15 00:10:45 +00:00
Evan Cheng
d01345fcc4
Follow up on r127913. Fix Thumb revsh isel. rdar://9286766
...
llvm-svn: 129548
2011-04-14 23:27:44 +00:00
Eli Friedman
198c39a4fe
Add an instcombine for constructs like a | -(b != c); a select is more
...
canonical, and generally leads to better code. Found while looking at
an article about saturating arithmetic.
llvm-svn: 129545
2011-04-14 22:41:27 +00:00
Owen Anderson
268d8f22f8
Fix an infinite alternation in JumpThreading where two transforms would repeatedly undo each other. The solution is to perform more aggressive constant folding to make one of the edges just folded away rather than trying to thread it.
...
Fixes <rdar://problem/9284786>.
Discovered with CSmith.
llvm-svn: 129538
2011-04-14 21:35:50 +00:00
Mon P Wang
f9b26f115c
Cleanup r129509 based on comments by Chris
...
llvm-svn: 129532
2011-04-14 19:20:42 +00:00
Johnny Chen
d58c6d4730
Add sanity checkings for Thumb2 Load/Store Register Exclusive family of operations.
...
llvm-svn: 129531
2011-04-14 19:13:28 +00:00
Chris Lattner
0f6423cf23
move PR9661 out to here.
...
llvm-svn: 129527
2011-04-14 18:47:18 +00:00
Owen Anderson
0ce6c0f86e
Fix another instance of the DAG combiner not using the correct type for the RHS of a shift.
...
llvm-svn: 129522
2011-04-14 17:30:49 +00:00
Daniel Dunbar
6f91b732fb
tests: Remove a FrontendC test which is no longer valid.
...
llvm-svn: 129519
2011-04-14 15:21:16 +00:00
Rafael Espindola
d5eed657e2
Change ELF systems to use CFI for producing the EH tables. This reduces the
...
size of the clang binary in Debug builds from 690MB to 679MB.
llvm-svn: 129518
2011-04-14 15:18:53 +00:00
Michael J. Spencer
9c5e660612
Fix whitespace and tabs.
...
llvm-svn: 129517
2011-04-14 14:33:36 +00:00
Mon P Wang
8b09087f46
Cleanup r129472 by using a utility routine as suggested by Eli.
...
llvm-svn: 129509
2011-04-14 08:04:01 +00:00
Andrew Trick
e89c19ab7b
In the pre-RA scheduler, maintain cmp+br proximity.
...
This is done by pushing physical register definitions close to their
use, which happens to handle flag definitions if they're not glued to
the branch. This seems to be generally a good thing though, so I
didn't need to add a target hook yet.
The primary motivation is to generate code closer to what people
expect and rule out missed opportunity from enabling macro-op
fusion. As a side benefit, we get several 2-5% gains on x86
benchmarks. There is one regression:
SingleSource/Benchmarks/Shootout/lists slows down be -10%. But this is
an independent scheduler bug that will be tracked separately.
See rdar://problem/9283108.
Incidentally, pre-RA scheduling is only half the solution. Fixing the
later passes is tracked by:
<rdar://problem/8932804> [pre-RA-sched] on x86, attempt to schedule CMP/TEST adjacent with condition jump
Fixes:
<rdar://problem/9262453> Scheduler unnecessary break of cmp/jump fusion
llvm-svn: 129508
2011-04-14 05:15:06 +00:00
Andrew Trick
85a4af977a
Documented bugpoint --compile-custom --compile-command.
...
I've used it a few times to reduce unit tests and gotten one request for information on it. It's not easy to use correctly because bugpoint doesn't tell you when you're doing it wrong.
llvm-svn: 129507
2011-04-14 05:05:36 +00:00
Chris Lattner
5fa2544086
add a minor missed dag combine that is blocking mid-level optimization
...
improvements, that will lead to fixing PR6627.
llvm-svn: 129504
2011-04-14 04:21:42 +00:00
Chris Lattner
d4ba43dc76
sink a call into its only use.
...
llvm-svn: 129503
2011-04-14 04:12:47 +00:00
Chris Lattner
88e2acc24c
rework FoldBranchToCommonDest to exit earlier when there is a bonus
...
instruction around, reducing work.
Greatly simplify handling of debug instructions. There is no need to
build up a vector of them and then move them into the one predecessor
if we're processing a block. Instead just rescan the block and *copy*
them into the pred. If a block gets merged into multiple preds, this
will retain more debug info.
llvm-svn: 129502
2011-04-14 02:44:53 +00:00
Chris Lattner
e9409fb80a
fix a couple -Wsign-compare warnings.
...
llvm-svn: 129501
2011-04-14 02:27:25 +00:00
Bill Wendling
0b9c16295a
As Dan pointed out, movzbl, movsbl, and friends are nicer than their alias
...
(movzx/movsx) because they give more information. Revert that part of the patch.
llvm-svn: 129498
2011-04-14 01:46:37 +00:00