Anton Korobeynikov
ddb93e7a02
Turn StripPointerCast() into a method
...
llvm-svn: 50836
2008-05-07 22:54:15 +00:00
Anton Korobeynikov
90ee6d6616
Make StripPointerCast a common function (should we mak it method of Value instead?)
...
llvm-svn: 50775
2008-05-06 22:52:30 +00:00
Chris Lattner
710d05695f
add a method for comparing to see if a value has a specified name.
...
llvm-svn: 50465
2008-04-30 03:55:40 +00:00
Gabor Greif
6ff874e81c
move the Use destructor where it belongs to
...
llvm-svn: 48376
2008-03-14 22:03:02 +00:00
Dan Gohman
e2d3f86306
There is no killUse.
...
llvm-svn: 48034
2008-03-07 22:24:41 +00:00
Dan Gohman
f00842e086
Re-apply the memory operand changes, with a fix for the static
...
initializer problem, a minor tweak to the way the
DAGISelEmitter finds load/store nodes, and a renaming of the
new PseudoSourceValue objects.
llvm-svn: 46827
2008-02-06 22:27:42 +00:00
Evan Cheng
2a533e6894
Revert 46556 and 46585. Dan please fix the PseudoSourceValue problem and re-commit.
...
llvm-svn: 46623
2008-01-31 21:00:00 +00:00
Dan Gohman
dd9be7d05e
Add a new PseudoSourceValue class, which will be used to help track
...
memory reference information in the backend. Most of this was written by
Florian Brander, cleanup and updating to TOT by me.
llvm-svn: 46556
2008-01-30 16:35:31 +00:00
Chris Lattner
e0b1ee937a
Don't attribute in file headers anymore. See llvmdev for the
...
discussion of this change. Boy are my fingers tired. ;-)
llvm-svn: 45411
2007-12-29 19:59:42 +00:00
Gordon Henriksen
8430f1ff9a
Reverting dtor devirtualization patch.
...
_sabre_: it has a major problem: by the time ~Value is run, all of the "parts" of the derived classes have been destroyed
_sabre_: the vtable lives to fight another day
llvm-svn: 44760
2007-12-10 02:14:30 +00:00
Gordon Henriksen
a18a78e6e5
Devirtualizing Value destructor (PR889). Patch by Pawel Kunio!
...
llvm-svn: 44747
2007-12-09 22:46:10 +00:00
Chris Lattner
de900e3b6c
add Value::getNameStart/getNameLen() accessors.
...
llvm-svn: 40989
2007-08-10 15:34:35 +00:00
Anton Korobeynikov
25dc9a61cb
Implement aliases. This fixes PR1017 and it's dependent bugs. CFE part
...
will follow.
llvm-svn: 36435
2007-04-25 14:27:10 +00:00
Dan Gohman
2d4b1767ab
Rename Value::getValueType to getValueID, to avoid confusion with
...
other things named getValueType.
llvm-svn: 35964
2007-04-13 18:12:09 +00:00
Reid Spencer
5ecf7f6214
Document the use of getValueType() more accurately, specifically explain
...
that the instruction opcode is added to the InstructionVal value and the
consequences of that.
llvm-svn: 34937
2007-03-05 23:06:32 +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
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
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
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
e8dd3c90f1
add a helper method: Value::takeName
...
llvm-svn: 34171
2007-02-11 00:37:27 +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
Zhou Sheng
23d24526b2
For PR1043:
...
Merge ConstantIntegral and ConstantBool into ConstantInt.
Remove ConstantIntegral and ConstantBool from LLVM.
llvm-svn: 33073
2007-01-11 12:24:14 +00:00
Chris Lattner
29a821859e
Now that setcondinst has been eliminated, we can mark Value::SubclassID
...
const and remove the ugly mutator methods.
llvm-svn: 32860
2007-01-04 02:15:37 +00:00
Bill Wendling
7f6a73eb5c
Added an automatic cast to "std::ostream*" etc. from OStream. We then can
...
rework the hacks that had us passing OStream in. We pass in std::ostream*
instead, check for null, and then dispatch to the correct print() method.
llvm-svn: 32636
2006-12-17 05:15:13 +00:00
Bill Wendling
a3246c4272
Changed llvm_ostream et all to OStream. llvm_cerr, llvm_cout, llvm_null, are
...
now cerr, cout, and NullStream resp.
llvm-svn: 32298
2006-12-07 01:30:32 +00:00
Bill Wendling
4157840bd6
Added a temporary hack to get the llvm-streams to work for future checkins.
...
llvm-svn: 31978
2006-11-28 22:21:29 +00:00
Reid Spencer
d414793dbc
For PR950:
...
This patch implements the first increment for the Signless Types feature.
All changes pertain to removing the ConstantSInt and ConstantUInt classes
in favor of just using ConstantInt.
llvm-svn: 31063
2006-10-20 07:07:24 +00:00
Reid Spencer
370c74131e
For PR778:
...
Move file-scoped documentation to class-scoped so it is more readily
accessible.
llvm-svn: 28689
2006-06-05 16:29:06 +00:00
Chris Lattner
a3d00d1780
Allow use of isa<InlineAsm>(X) without #including InlineAsm.h
...
llvm-svn: 25632
2006-01-26 01:54:21 +00:00
Chris Lattner
50ba79e71b
Initial checkin of the InlineAsm class
...
llvm-svn: 25570
2006-01-24 04:13:11 +00:00
Reid Spencer
57db434426
Make ValueSymbolTable (temporarily) a friend of Value so it can mod the
...
Name of Value instances.
llvm-svn: 25174
2006-01-10 09:45:57 +00:00
Jeff Cohen
0998a3e70e
Fix VC++ level 4 warnings.
...
llvm-svn: 24750
2005-12-17 00:18:06 +00:00
Chris Lattner
2800856064
remove a comma to compile with pedantic gcc
...
llvm-svn: 23667
2005-10-08 01:24:19 +00:00
Chris Lattner
92616caa1a
Split SimpleConstantVal up into its components, so each Constant subclass gets
...
a different enum value. This allows 'classof' for these to be really simple,
not needing to call getType() anymore.
This speeds up isa/dyncast/etc for constants, and also makes them smaller.
For example, the text section of a release build of InstCombine.cpp shrinks
from 230037 bytes to 216363 bytes, a 6% reduction.
llvm-svn: 23466
2005-09-27 06:08:32 +00:00
Chris Lattner
9838157648
remove a dead enum value, making a comment above correct again
...
llvm-svn: 22810
2005-08-16 22:04:58 +00:00
Misha Brukman
3f0aa3dbf8
Remove trailing whitespace
...
llvm-svn: 21408
2005-04-21 20:19:05 +00:00
Misha Brukman
d5e8033d4a
Convert tabs to spaces
...
llvm-svn: 20634
2005-03-16 03:46:55 +00:00
Chris Lattner
60929fdff1
Add a new method, allow symtab to poke name.
...
llvm-svn: 20468
2005-03-06 02:10:40 +00:00
Chris Lattner
b177010d51
remove all of the various setName implementations, consolidating them into
...
Value::setName, which is no longer virtual.
llvm-svn: 20464
2005-03-05 19:51:50 +00:00
Chris Lattner
93642ede7d
Remove the second argument to Value::setName, it is never needed.
...
llvm-svn: 20457
2005-03-05 18:59:36 +00:00
Chris Lattner
fb1c36cdb3
Add new method.
...
llvm-svn: 20287
2005-02-23 16:50:59 +00:00
Chris Lattner
de2bf4ed11
SubclassID is really a small field. Split it into half and let subclasses
...
play with the unused part.
llvm-svn: 20043
2005-02-05 01:37:44 +00:00
Chris Lattner
fdbedbbb45
Switch from using an ilist for uses to using a custom doubly linked list.
...
This list does not provide the ability to go backwards in the list (its
more of an unordered collection, stored in the shape of a list).
This change means that use iterators are now only forward iterators, not
bidirectional.
This improves the memory usage of use lists from '5 + 4*#use' per value to
'1 + 4*#use'. While it would be better to reduce the multiplied factor,
I'm not smart enough to do so. This list also has slightly more efficient
operators for manipulating list nodes (a few less loads/stores), due to not
needing to be able to iterate backwards through the list.
This change reduces the memory footprint required to hold 176.gcc from
66.025M -> 57.687M, a 14% reduction. It also speeds up the compiler,
7.73% in the case of bytecode loading alone (release build loading 176.gcc).
llvm-svn: 19956
2005-02-01 01:22:06 +00:00
Chris Lattner
91422cffe4
Adjust to User.h changes.
...
llvm-svn: 19884
2005-01-29 00:30:52 +00:00
Reid Spencer
fe4882b78e
Added a size_type typedef to LLVM containers to make Visual Studio shut up
...
(and possibly to make LLVM more x86 64bit friendly).
llvm-svn: 18891
2004-12-13 16:28:53 +00:00
Chris Lattner
dd0094e4ed
Convert 'struct' to 'class' in various places to adhere to the coding standards
...
and work better with VC++. Patch contributed by Morten Ofstad!
llvm-svn: 17281
2004-10-27 16:14:51 +00:00
Chris Lattner
6dd0bb3d27
Add new UndefValueVal type
...
llvm-svn: 17038
2004-10-16 18:06:07 +00:00
Reid Spencer
67f6472f19
Change Value from a "struct" to a "class" so that VC 7.1 doesn't generate
...
missing symbols when its referenced as a class.
llvm-svn: 16496
2004-09-23 14:49:45 +00:00