Chris Lattner
865b2f741a
remove dead methods
...
llvm-svn: 34419
2007-02-19 07:44:24 +00:00
Chris Lattner
dee1492159
temporarily revert Devang's most recent patch, which caused a large
...
compile-time regression in LLC.
llvm-svn: 34385
2007-02-17 23:14:24 +00:00
Devang Patel
953cadacbc
Use inverted map to speedup collectLastUses().
...
llvm-svn: 34364
2007-02-17 03:53:44 +00:00
Andrew Lenharth
d2c65176e6
fix build
...
llvm-svn: 34339
2007-02-16 02:25:55 +00:00
Chris Lattner
134ae17654
make mayWriteToMemory a non-virtual function
...
llvm-svn: 34334
2007-02-15 23:15:00 +00:00
Chris Lattner
9084bb5471
rewrite Value::takeName to take advantage of the new symtab stuff. This
...
causes it to require no allocations and no symtab lookups in the common
case. This speeds up instcombine 9.2% on 447.dealII.
llvm-svn: 34324
2007-02-15 20:01:43 +00:00
Chris Lattner
5d0b16f797
Implement Function::getIntrinsicID without it needing to call Value::getName,
...
which allocates a string. This speeds up instcombine on 447.dealII by 5%.
llvm-svn: 34318
2007-02-15 19:17:16 +00:00
Chris Lattner
fbd6928545
Add a new Value::getNameStr method, which is preferred over getName.
...
llvm-svn: 34310
2007-02-15 18:53:54 +00:00
Reid Spencer
e7ff3305d6
For PR1195:
...
Change use of "packed" term to "vector" in comments, strings, variable
names, etc.
llvm-svn: 34300
2007-02-15 03:39:18 +00:00
Reid Spencer
a0a2689760
For PR1195:
...
Change a comment: Packed Type -> Vector Type
llvm-svn: 34299
2007-02-15 03:11:50 +00:00
Reid Spencer
55e4e98a2a
For PR1195:
...
Rename PackedType -> VectorType, ConstantPacked -> ConstantVector, and
PackedTyID -> VectorTyID. No functional changes.
llvm-svn: 34293
2007-02-15 02:26:10 +00:00
Chris Lattner
48b7ed420c
better support for i128.
...
llvm-svn: 34258
2007-02-13 23:57:55 +00:00
Chris Lattner
4534d3fc6e
Switch UnaryOperators to default to passing names up by const char* when possible.
...
This speeds up bcreading by 1.5%.
llvm-svn: 34233
2007-02-13 07:54:42 +00:00
Chris Lattner
cc543b031e
add a setName variant that takes a null-terminated string. This can be
...
used to avoid std::string allocations in common cases.
llvm-svn: 34232
2007-02-13 07:53:34 +00:00
Chris Lattner
326271ee46
eliminate instruction ctors that take vectors.
...
llvm-svn: 34228
2007-02-13 06:22:32 +00:00
Chris Lattner
bc384d8d50
Add invokeinst and callinst ctors that don't take vectors.
...
llvm-svn: 34214
2007-02-13 01:04:01 +00:00
Chris Lattner
94ce3e4550
remove some dead methods.
...
llvm-svn: 34213
2007-02-13 00:58:44 +00:00
Chris Lattner
a48bf1bdbf
Add new setName accessor which doesn't require creating a string.
...
llvm-svn: 34197
2007-02-12 18:52:59 +00:00
Chris Lattner
5a58a65c10
Switch ValueSymbolTable to use StringMap<Value*> instead of std::map<std::string, Value*>
...
as its main datastructure. There are many improvements yet to be made, but
this speeds up opt --std-compile-opts on 447.dealII by 7.3%.
llvm-svn: 34193
2007-02-12 05:18:08 +00:00
Chris Lattner
676ffe699d
fix uninitialized variable
...
llvm-svn: 34182
2007-02-11 19:12:18 +00:00
Chris Lattner
50ea7bc913
add an optimization for the case where the src has no name
...
llvm-svn: 34174
2007-02-11 01:04:09 +00:00
Chris Lattner
e8dd3c90f1
add a helper method: Value::takeName
...
llvm-svn: 34171
2007-02-11 00:37:27 +00:00
Reid Spencer
8594672a45
Assert that elements of packed are pointer/float/opaque.
...
llvm-svn: 34165
2007-02-10 22:02:45 +00:00
Reid Spencer
b8c5bbce4b
Allow PackedType to be constructed with an abstract type.
...
llvm-svn: 34152
2007-02-10 19:03:01 +00:00
Chris Lattner
a7ed569db1
convert some vectors to smallvector.
...
llvm-svn: 34145
2007-02-10 08:33:11 +00:00
Chris Lattner
8eb2002881
speed up the verifier 8.5% by using a smallvector instead of vector.
...
llvm-svn: 34144
2007-02-10 08:30:29 +00:00
Chris Lattner
a0792c722e
Change an std::set to a SmallPtrSet. This speeds up the verifier on
...
447.dealII from 1.27s to 0.86s.
llvm-svn: 34143
2007-02-10 08:19:44 +00:00
Chris Lattner
27cff151e2
Fix clients like this:
...
delete ParseBytecodeFile(InputFilename, 0, &ErrorMessage);
llvm_shutdown();
delete ParseBytecodeFile(InputFilename, 0, &ErrorMessage);
The primitive type objects failed to ressurect themselves after shutdown, leading
to crashes in clients that used them after llvm_shutdown().
This solution isn't wonderful, because we clearly have static ctors. However,
the code it replaces was just as bad, so it's not a regression.
llvm-svn: 34106
2007-02-09 22:24:04 +00:00
Jim Laskey
c27aed3dc0
Automatically generating intrinsic declarations from Dan Gohman. Modified
...
to construct FunctionType in separate function, and, have getDeclaration
return a Function instead of a Constant.
llvm-svn: 34008
2007-02-07 20:38:26 +00:00
Devang Patel
a667307d74
Do not drop transferred last uses on the floor.
...
Use handleLastUserOverflow().
llvm-svn: 34006
2007-02-07 19:37:53 +00:00
Chris Lattner
940f9c8549
constants can't be in the symtab anymore
...
llvm-svn: 33993
2007-02-07 06:28:48 +00:00
Chris Lattner
3cbaee07ce
update comment.
...
llvm-svn: 33992
2007-02-07 06:25:36 +00:00
Chris Lattner
22fc4be632
shrink vmcore by moving symbol table stripping support out of VMCore into
...
the one IPO pass that uses it.
llvm-svn: 33990
2007-02-07 06:22:45 +00:00
Chris Lattner
a1455127ae
eliminate ValueSymbolTable::rename, it has no advantage over using remove+insert.
...
Make insert/remove assert if used incorrectly instead of returning a bool.
llvm-svn: 33988
2007-02-07 06:13:49 +00:00
Chris Lattner
c46811575d
speed up conflict handling.
...
llvm-svn: 33985
2007-02-07 05:52:51 +00:00
Chris Lattner
bdde131dac
Eliminate the O(n) version of TypeSymbolTable::remove, it is dead. When
...
inserting a type into the type symbol table, only compute unique name if not
in symtab already.
llvm-svn: 33983
2007-02-07 05:35:58 +00:00
Chris Lattner
bf91625f67
TypeSymbolTable::rename is dead, remove it
...
llvm-svn: 33982
2007-02-07 05:29:34 +00:00
Chris Lattner
d69c837c73
Eliminate a bunch of work from ValueSymbolTable::insert for the common case
...
where a symbol name doesn't conflict. This speeds up bc reading 16% on 176.gcc!
llvm-svn: 33981
2007-02-07 05:22:49 +00:00
Jim Laskey
7d5ddeb668
Support var arg intrinsics.
...
llvm-svn: 33962
2007-02-06 18:02:54 +00:00
Chris Lattner
83e39edf72
Fix Transforms/ConstProp/2007-02-05-BitCast.ll
...
llvm-svn: 33948
2007-02-06 02:22:56 +00:00
Reid Spencer
6da19310e3
A value of 64 or fewer bits is valid if the ConstantInt has more then 64 bits.
...
llvm-svn: 33942
2007-02-05 23:47:56 +00:00
Reid Spencer
83803ddedb
For PR411:
...
Adjust to changes in Module interface:
getMainFunction() -> getFunction("main")
getNamedFunction(X) -> getFunction(X)
llvm-svn: 33922
2007-02-05 21:19:13 +00:00
Reid Spencer
6af21b3029
For PR411:
...
This patch replaces the SymbolTable class with ValueSymbolTable which does
not support types planes. This means that all symbol names in LLVM must now
be unique. The patch addresses the necessary changes to deal with this and
removes code no longer needed as a result. This completes the bulk of the
changes for this PR. Some cleanup patches will follow.
llvm-svn: 33918
2007-02-05 20:47:22 +00:00
Devang Patel
a2287f3205
Fix PR1158
...
Do not insert Analysis pass, if it is already available.
llvm-svn: 33915
2007-02-05 19:34:17 +00:00
Reid Spencer
310b497b59
For PR1163:
...
Make the Module's dependent library use a std::vector instead of SetVector
adjust #includes in .cpp files because SetVector.h is no longer included.
llvm-svn: 33855
2007-02-04 00:40:42 +00:00
Reid Spencer
da848a64ce
Fix a comment that needed to change after SHIFT patch landed.
...
llvm-svn: 33781
2007-02-02 13:54:55 +00:00
Reid Spencer
591bfa1e0b
Changes to support making the shift instructions be true BinaryOperators.
...
This feature is needed in order to support shifts of more than 255 bits
on large integer types. This changes the syntax for llvm assembly to
make shl, ashr and lshr instructions look like a binary operator:
shl i32 %X, 1
instead of
shl i32 %X, i8 1
Additionally, this should help a few passes perform additional optimizations.
llvm-svn: 33776
2007-02-02 02:16:23 +00:00
Devang Patel
f178d112ce
cvs commit
...
llvm-svn: 33765
2007-02-01 22:08:25 +00:00
Chris Lattner
ca583c51b3
silence some warnings when assertions are disabled.
...
llvm-svn: 33747
2007-02-01 04:59:37 +00:00
Reid Spencer
a22881da40
Fix build breakage by using correct arguments to getIndexedType in the
...
GEP constructors.
llvm-svn: 33726
2007-01-31 22:30:26 +00:00