Dan Gohman
7ca77f37db
Delete a redundant variable.
...
llvm-svn: 77774
2009-08-01 04:18:29 +00:00
Dan Gohman
c0b1c0e18d
Minor code simplifications.
...
llvm-svn: 77769
2009-08-01 03:51:09 +00:00
Dan Gohman
2e5fd769b6
Minor code simplifications.
...
llvm-svn: 77768
2009-08-01 03:42:59 +00:00
Evan Cheng
c165700a7f
Split t2MOVCCs since some assemblers do not recognize mov shifted register alias with predicate.
...
llvm-svn: 77764
2009-08-01 01:43:45 +00:00
Dan Gohman
e8685de233
SelectionDAGISel no longer needs to check hasAvailableExternallyLinkage,
...
as it is now a MachineFunctionPass, and MachineFunctionPass now handles
this.
llvm-svn: 77760
2009-08-01 00:42:23 +00:00
Dan Gohman
c1dc8ac240
Make UnreachableMachineBlockElim preserve MachineDominatorTree and
...
MachineLoopInfo.
llc now runs MachineLoopInfo and MachineDominatorTree only twice, instead
of three times.
llvm-svn: 77759
2009-08-01 00:34:30 +00:00
Dan Gohman
e05a157134
The X86 maximal stack alignment calculator preserves the CFG. Also,
...
be more careful about the return value of runOnMachineFunction.
llvm-svn: 77758
2009-08-01 00:31:02 +00:00
Dan Gohman
db8c4b62b4
X86 floating-point passes don't modify the CFG.
...
llvm-svn: 77757
2009-08-01 00:26:16 +00:00
Evan Cheng
5ef6928dff
Fix Thumb2 function call isel. Thumb1 and Thumb2 should share the same
...
instructions for calls since BL and BLX are always 32-bit long and BX is always
16-bit long.
Also, we should be using BLX to call external function stubs.
llvm-svn: 77756
2009-08-01 00:16:10 +00:00
Dan Gohman
bbd7d54b39
Use setPreservesAll in X86CodeEmitter.
...
llvm-svn: 77755
2009-07-31 23:44:16 +00:00
Dan Gohman
4529d71681
Use setPreservesAll and setPreservesCFG in CodeGen passes.
...
llvm-svn: 77754
2009-07-31 23:37:33 +00:00
Dan Gohman
8dbc245f9b
SelectionDAGISel does not "preserve all", since it makes lots of changes
...
to the MachineFunction.
llvm-svn: 77753
2009-07-31 23:36:22 +00:00
Dan Gohman
76ed822935
Use a range insert instead of an explicit loop.
...
llvm-svn: 77752
2009-07-31 23:36:06 +00:00
Daniel Dunbar
a848745eb4
llvm-mc: Fix .s output to quote section & symbol names when necessary.
...
llvm-svn: 77749
2009-07-31 23:04:32 +00:00
Owen Anderson
5370346117
Privatize all but one of the remaining constant tables.
...
llvm-svn: 77748
2009-07-31 22:45:43 +00:00
Bob Wilson
7634460f6a
Allow target intrinsics that return multiple values, i.e., struct types,
...
in SelectionDAGLowering::visitTargetIntrinsic.
This removes a bit of special-case code for vector types. After staring
at it for a while, I managed to convince myself that it is not necessary.
The only case where TLI.getValueType() differs from MVT::getMVT is for iPTR,
so this code could potentially make a difference for a vector of pointers.
But, it looks like that is not supported. Calling TLI.getValueType() on
a vector of pointers leads to the following sequence of calls:
TargetLowering::getValueType
MVT::getMVT
MVT::getVectorVT(iPTR, num elements)
MVT::getExtendedVectorVT
MVT::getTypeForMVT for iPTR
assertion fails "Type is not extended!"
So, unless I'm really missing something, this bit of code is irrelevant to
the current version of LLVM, which is consistent with the fact that I don't
see this code in other similar places.
llvm-svn: 77747
2009-07-31 22:41:21 +00:00
Daniel Dunbar
99d279978e
llvm-mc: A few more parsing / match tweaks.
...
- Operands which are just a label should be parsed as immediates, not memory
operands (from the assembler perspective).
- Match a few more flavors of immediates.
- Distinguish match functions for memory operands which don't take a segment
register.
- We match the .s for "hello world" now!
llvm-svn: 77745
2009-07-31 22:22:54 +00:00
Evan Cheng
cb1704f904
t2BR_JT is mov pc, it's 2 byte long, not 4.
...
llvm-svn: 77744
2009-07-31 22:22:22 +00:00
Evan Cheng
88a27caaaf
Thumb2 movcc need .w suffix.
...
llvm-svn: 77743
2009-07-31 22:21:55 +00:00
Chris Lattner
e84531b18d
add some comments on how this is *supposed* to work. We don't
...
need the PreferredEHDataFormat hook, but I have yet-more refactoring to
do before I can zap it.
llvm-svn: 77742
2009-07-31 22:18:14 +00:00
Chris Lattner
907f114dd3
rearrange a conditional. Even if this weren't #if 0'd out, this would
...
have no functionality change.
llvm-svn: 77741
2009-07-31 22:03:47 +00:00
David Greene
543296ed84
Simplify operand padding by keying off tabs in the asm stream. If
...
padding is disabled, tabs get replaced by spaces except in the case of
the first operand, where the tab is output to line up the operands after
the mnemonics.
Add some better comments and eliminate redundant code.
Fix some testcases to not assume tabs.
llvm-svn: 77740
2009-07-31 21:57:10 +00:00
Chris Lattner
882b1208e1
PreferredEHDataFormat is always call with data and global, but this whole
...
thing is #if0'd out anyway. Just simplify the code by reducing the interface.
Not deleting this is essential for Bill's continuing happiness.
llvm-svn: 77736
2009-07-31 21:39:55 +00:00
Owen Anderson
034ab4f8b1
Move the metadata constructors back to 2.5 syntax.
...
llvm-svn: 77733
2009-07-31 21:35:40 +00:00
Dan Gohman
40e39492e8
LibCallAliasAnalysis doesn't use TargetData.
...
llvm-svn: 77729
2009-07-31 20:56:29 +00:00
Daniel Dunbar
3c72ed6449
llvm-mc/X86: Sketch match functions for immediates and memory operands.
...
Also, change scale value to always be 1 when unspecified to machine MachineInst
encoding.
llvm-svn: 77728
2009-07-31 20:53:16 +00:00
Dan Gohman
5e41986999
Make TargetData optional in MemoryDependenceAnalysis.
...
llvm-svn: 77727
2009-07-31 20:53:12 +00:00
Chris Lattner
48bdeff884
move emitUsedDirectiveFor to TargetLoweringObjectFile and rename it to
...
indicate that it is a predicate, not an emitter. This eliminates TAI
dependencies on Mangler and GlobalValue.
llvm-svn: 77726
2009-07-31 20:52:39 +00:00
Dan Gohman
9c6c4d57be
Remove an unnecessary header.
...
llvm-svn: 77725
2009-07-31 20:47:45 +00:00
Chris Lattner
70c133d1d9
remove the PPCLinuxTargetAsmInfo implementation of PreferredEHDataFormat,
...
because it just calls the default impl.
Remove the PPCDarwinTargetAsmInfo version of PreferredEHDataFormat because
it just returns DW_EH_PE_absptr unless on 10.6. However, 10.6 doesn't support
PPC, so the default impl is just fine.
llvm-svn: 77724
2009-07-31 20:43:26 +00:00
Chris Lattner
4bf345e8e2
remove a pointless override.
...
llvm-svn: 77723
2009-07-31 20:36:15 +00:00
Owen Anderson
1dc40e205b
Move a few more APIs back to 2.5 forms. The only remaining ones left to change back are
...
metadata related, which I'm waiting on to avoid conflicting with Devang.
llvm-svn: 77721
2009-07-31 20:28:14 +00:00
Dan Gohman
0831bdef1d
Fix GVN's debug output, now that operator<< on Value* doesn't print
...
a trailing newline.
llvm-svn: 77719
2009-07-31 20:24:18 +00:00
Eric Christopher
ad07d18432
Whitespace and 80-col cleanup.
...
llvm-svn: 77718
2009-07-31 20:07:27 +00:00
Bill Wendling
6920c80ab6
- Convert the rest of the DOUTs to DEBUG+errs().
...
- One formatting change.
No intended functionality change.
llvm-svn: 77717
2009-07-31 19:52:24 +00:00
Eli Friedman
7bb0485237
PR4662: Fix a crash introduced by the recent LLVMContext changes.
...
llvm-svn: 77716
2009-07-31 19:36:47 +00:00
Ted Kremenek
3b2c07bc88
Update CMake files.
...
llvm-svn: 77709
2009-07-31 18:50:22 +00:00
Chris Lattner
75b7692e66
switch off of 'Section' onto MCSection. We're not properly using
...
MCSection subclasses yet, but this is a step in the right direction.
llvm-svn: 77708
2009-07-31 18:48:30 +00:00
Dan Gohman
c4f0d838a9
Remove Annotation.h, which is no longer used in the LLVM tree.
...
llvm-svn: 77706
2009-07-31 18:36:25 +00:00
Evan Cheng
0c9705feed
Until we have a "ALIGN" pseudo instruction, have asm printer emitted a .align
...
to ensure the instruction that follows a TBB (when the number of table entries
is odd) is 2-byte aligned.
Patch by Sandeep Patel.
llvm-svn: 77705
2009-07-31 18:35:56 +00:00
Dan Gohman
dcc00a2e5c
MachineFunction no longer needs Annotation.
...
llvm-svn: 77704
2009-07-31 18:35:51 +00:00
Evan Cheng
038a564156
- Teach TBB / TBH offset limits are 510 and 131070 respectively since the offset
...
is scaled by two.
- Teach GetInstSizeInBytes about TBB and TBH.
llvm-svn: 77701
2009-07-31 18:28:05 +00:00
Dan Gohman
6bec53e39d
Fix printing of Alloca instructions with null operands.
...
llvm-svn: 77697
2009-07-31 18:23:24 +00:00
Dan Gohman
173cfdc02f
Fix some problems with ASTCallbackVH in its use as a DenseMap key.
...
llvm-svn: 77696
2009-07-31 18:21:48 +00:00
Devang Patel
34cec19943
Process DbgDeclareInst.
...
llvm-svn: 77694
2009-07-31 18:18:52 +00:00
Daniel Dunbar
23baa6b4ad
Normalize target registration code.
...
llvm-svn: 77692
2009-07-31 18:16:53 +00:00
Dan Gohman
f28b3bb262
Reapply r77654 with a fix: MachineFunctionPass's getAnalysisUsage
...
shouldn't do AU.setPreservesCFG(), because even though CodeGen passes
don't modify the LLVM IR CFG, they may modify the MachineFunction CFG,
and passes like MachineLoop are registered with isCFGOnly set to true.
llvm-svn: 77691
2009-07-31 18:16:33 +00:00
Chris Lattner
c156a00641
refactor section construction in TLOF to be through an explicit
...
initialize method, which can be called when an MCContext is available.
llvm-svn: 77687
2009-07-31 17:42:42 +00:00
Owen Anderson
d0e6352c97
Move getTrue() and getFalse() to 2.5-like APIs.
...
llvm-svn: 77685
2009-07-31 17:39:07 +00:00
Chris Lattner
a682cb61e7
split MCSection stuff out to its own .cpp file, add a new
...
MCSectionWithKind subclass of MCSection.
llvm-svn: 77684
2009-07-31 17:02:00 +00:00