Devang Patel
d0aabe5ce6
Use SmallVector instead of std::vector
...
llvm-svn: 54685
2008-08-12 15:44:31 +00:00
Duncan Sands
ceacf7d17b
Point people to ConstantExpr and ConstantFolding,
...
in case they get the wrong idea. Fit in 80 columns.
llvm-svn: 54676
2008-08-12 09:43:15 +00:00
Devang Patel
670f3a9e03
Use DenseMap to keep track of last users.
...
Use inversed map for faster queries.
llvm-svn: 54662
2008-08-12 00:26:16 +00:00
Chris Lattner
0e03352a9f
add a helper method to sys::Path for clang, patch by
...
Kovarththanan Rajaratnam!
llvm-svn: 54655
2008-08-11 23:39:47 +00:00
Devang Patel
404762f720
Keep track of analysis usage information for passes. Avoid invoking
...
getAnalysisUsage() repeatedly.
llvm-svn: 54650
2008-08-11 21:13:39 +00:00
Duncan Sands
cac74d2a10
Make it possible to use different constant
...
folding policies with IRBuilder. The default,
provided by ConstantFolder, is to do minimal
folding like now: what ConstantExpr provides.
An alternative is to use TargetFolder, which
uses target information to fold constants more.
llvm-svn: 54640
2008-08-11 15:29:30 +00:00
Chris Lattner
89120a8e63
"This patch adds a virtual call to AbstractLatticeFunction to derive a
...
type lattice value for an Argument*, giving clients the opportunity to
use something other than Top for it if they choose to."
Patch by John McCall!
llvm-svn: 54589
2008-08-09 17:23:35 +00:00
Duncan Sands
310343bae7
Unbreak the llvm-gcc build: recent changes to
...
IRBuilder are not expecting null names.
llvm-svn: 54581
2008-08-09 15:14:59 +00:00
Chris Lattner
270ee0cb58
Make 'Insert' set the name for Loads, instead of passing the name into the
...
LoadInst ctor, which causes std::string thrashing.
llvm-svn: 54577
2008-08-09 06:26:23 +00:00
Chris Lattner
64e06e8dac
comment update
...
llvm-svn: 54576
2008-08-09 06:25:46 +00:00
Gordon Henriksen
78a53c516d
Delete a redundant binding, LLVMHasInitializer.
...
Please use !LLVMIsDeclaration instead.
llvm-svn: 54572
2008-08-09 02:13:58 +00:00
Gordon Henriksen
b0ee2172b0
Fix the LLVMCreateJITCompiler C binding.
...
Evan broke it in r54523 by adding a parameter in the implementation without
updating the header correspondingly.
llvm-svn: 54555
2008-08-08 20:49:28 +00:00
Eric Christopher
dcd4752642
Have IRBuilder take a template argument on whether or not to preserve
...
names. This can save a lot of allocations if you aren't going to be
looking at the output.
llvm-svn: 54546
2008-08-08 19:39:37 +00:00
Anton Korobeynikov
8d77445753
Handle visibility printing with all generality. Remove bunch of duplicate code.
...
llvm-svn: 54540
2008-08-08 18:25:07 +00:00
Evan Cheng
804e157031
Undo most of r54519.
...
llvm-svn: 54534
2008-08-08 17:56:50 +00:00
Chris Lattner
a4e876cf8a
Don't call getAnalysisUsage unless -debug-pass is enabled. This speeds
...
up the passmgr by avoiding useless work.
llvm-svn: 54528
2008-08-08 15:14:09 +00:00
Evan Cheng
054bbb0dd8
Add new parameter Fast to createJIT to enable the fast codegen path.
...
llvm-svn: 54523
2008-08-08 08:11:34 +00:00
Evan Cheng
4708df4776
It's not legal to output a GV in a coalesced section if it's used in an ARM PIC relative constantpool.
...
llvm-svn: 54519
2008-08-08 06:56:16 +00:00
Chris Lattner
c1ca63307d
Speed up the passmgr by avoiding heap thrashing on vectors.
...
llvm-svn: 54515
2008-08-08 05:33:04 +00:00
Bruno Cardoso Lopes
2284374fcc
Add the remaining fp_round libcalls:
...
FPROUND_F80_F32, FPROUND_PPCF128_F32,
FPROUND_F80_F64, FPROUND_PPCF128_F64
Support for soften float fp_round operands is added, Mips
needs this to round f64->f32.
Also added support to soften float FABS result, Mips doesn't
support double fabs results while in 'single float only' mode.
llvm-svn: 54484
2008-08-07 19:01:24 +00:00
Matthijs Kooijman
2ba1b80c7f
Silence a warning.
...
llvm-svn: 54462
2008-08-07 13:36:30 +00:00
Anton Korobeynikov
d3009663dd
Provide convenient helpers
...
llvm-svn: 54451
2008-08-07 09:51:54 +00:00
Anton Korobeynikov
ebd773939c
Add hook for constant pool section selection for darwin.
...
llvm-svn: 54449
2008-08-07 09:51:02 +00:00
Anton Korobeynikov
d37daa2aeb
Select section for constant pool entries
...
llvm-svn: 54448
2008-08-07 09:50:34 +00:00
Matthijs Kooijman
7f69239612
Remove trailing spaces.
...
llvm-svn: 54447
2008-08-07 09:00:46 +00:00
Evan Cheng
f8a801a9b8
Factor code that finalize PHI nodes, jump tables, etc. out of SelectBasicBlock. No functionality changes.
...
llvm-svn: 54438
2008-08-07 00:43:25 +00:00
Dan Gohman
680de089b7
Clarify "node" vs. "value" in some comments.
...
llvm-svn: 54409
2008-08-06 15:18:10 +00:00
Dan Gohman
7323b8d744
Correct an assertion string.
...
llvm-svn: 54348
2008-08-05 14:42:28 +00:00
Owen Anderson
32ae9380f1
This option doesn't need to be a target option. It can be in SDISel instead.
...
llvm-svn: 54336
2008-08-05 00:27:28 +00:00
Owen Anderson
84fbc312d4
- Fix SelectionDAG to generate correct CFGs.
...
- Add a basic machine-level dead block eliminator.
These two have to go together, since many other parts of the code generator are unable to handle the unreachable blocks otherwise created.
llvm-svn: 54333
2008-08-04 23:54:43 +00:00
Bill Wendling
5aaf075b29
Removed unused parameters.
...
llvm-svn: 54262
2008-08-01 05:50:13 +00:00
Dale Johannesen
f669e7c14f
Add a flag to disable jump table generation (all
...
switches use the binary search algorithm) for
environments that don't support it. PPC64 JIT
is such an environment; turn the flag on for that.
llvm-svn: 54248
2008-07-31 18:13:12 +00:00
Dan Gohman
926a91d664
Move SelectionDAG::viewGraph() out of line; as an inline function
...
it isn't always visible to gdb.
llvm-svn: 54228
2008-07-30 18:48:53 +00:00
Matthijs Kooijman
782943a0ec
Document BasicBlock::Create.
...
llvm-svn: 54210
2008-07-30 12:53:14 +00:00
Mon P Wang
fb483982f5
Added support for overloading intrinsics (atomics) based on pointers
...
to different address spaces. This alters the naming scheme for those
intrinsics, e.g., atomic.load.add.i32 => atomic.load.add.i32.p0i32
llvm-svn: 54195
2008-07-30 04:36:53 +00:00
Matthijs Kooijman
6ef5a25c7f
Add a GetElementPtrInst::getIndexedType that accepts uint64_t's instead of just Value*'s.
...
llvm-svn: 54157
2008-07-29 08:46:11 +00:00
Dan Gohman
ebe629a4b2
Revert 54147.
...
llvm-svn: 54148
2008-07-29 01:02:18 +00:00
Dan Gohman
1816900fd1
Add x86 isel patterns to match what would be a ZERO_EXTEND_INREG operation,
...
which is represented in codegen as an 'and' operation. This matches them
with movz instructions, instead of leaving them to be matched by and
instructions with an immediate field.
llvm-svn: 54147
2008-07-28 22:18:25 +00:00
Dan Gohman
9653b21dc2
Fold the useful features of alist and alist_node into ilist, and
...
a new ilist_node class, and remove them. Unlike alist_node,
ilist_node doesn't attempt to manage storage itself, so it avoids
the associated problems, including being opaque in gdb.
Adjust the Recycler class so that it doesn't depend on alist_node.
Also, change it to use explicit Size and Align parameters, allowing
it to work when the largest-sized node doesn't have the greatest
alignment requirement.
Change MachineInstr's MachineMemOperand list from a pool-backed
alist to a std::list for now.
llvm-svn: 54146
2008-07-28 21:51:04 +00:00
Dan Gohman
f8f44b4837
Reword a comment to be less ambiguous.
...
llvm-svn: 54135
2008-07-28 18:42:57 +00:00
Dan Gohman
7ae5bf35a2
Don't use reinterpret_cast when it isn't needed.
...
llvm-svn: 54130
2008-07-27 23:12:19 +00:00
Dan Gohman
9742f7772d
Rename SDOperand to SDValue.
...
llvm-svn: 54128
2008-07-27 21:46:04 +00:00
Dan Gohman
47c5cdbc34
Tidy SDNode::use_iterator, and complete the transition to have it
...
parallel its analogue, Value::value_use_iterator. The operator* method
now returns the user, rather than the use.
llvm-svn: 54127
2008-07-27 20:43:25 +00:00
Dan Gohman
2a0bc8f6e1
Rename isOnlyUseOf to isOnlyUserOf.
...
llvm-svn: 54124
2008-07-27 18:06:42 +00:00
Dan Gohman
bdbaf4d128
Improve comments for SDNode use-count methods. No functionality change.
...
llvm-svn: 54123
2008-07-27 17:44:52 +00:00
Dan Gohman
c28f2265a4
Rename the version of CreateRet that's a convenience method for creating
...
multiple-valued return values, so that the name CreateRet is just for
creating plain ret statements.
llvm-svn: 54053
2008-07-25 20:36:15 +00:00
Duncan Sands
46a694af35
Fix error: ‘std::ostream’ has not been declared
...
when compiling with gcc 4.3.
llvm-svn: 54041
2008-07-25 19:29:14 +00:00
Nate Begeman
a6cdff50b0
Remove unnecessary implicit argument
...
llvm-svn: 54031
2008-07-25 17:56:27 +00:00
Nate Begeman
ce064348d9
Fix minor issues with VICmp/VFCmp constant expressions
...
llvm-svn: 54030
2008-07-25 17:35:37 +00:00
Nate Begeman
8757bedd41
Add predicate for GhostLinkage, used by the JIT
...
llvm-svn: 54027
2008-07-25 17:26:48 +00:00