Commit Graph

856 Commits

Author SHA1 Message Date
Ruchira Sasanka
4f3eb22e1f Added destructors and comments.
Added correct spill candidate selection logic.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1493 91177308-0d34-0410-b5e6-96231b3b80d8
2002-01-07 19:19:18 +00:00
Ruchira Sasanka
42bd177eae Added comments, destructors where necessary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1491 91177308-0d34-0410-b5e6-96231b3b80d8
2002-01-07 19:16:26 +00:00
Vikram S. Adve
34ca7efbe6 Eliminate function getIndicesBROKEN().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1486 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-15 00:37:12 +00:00
Vikram S. Adve
fa24897f9f Eliminate all uses of memInst->getIndicesBROKEN().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1485 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-15 00:36:32 +00:00
Vikram S. Adve
dd08e32deb getIndexedOffset() shd take vector of Values, not of Constants!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1484 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-15 00:35:48 +00:00
Vikram S. Adve
cee9d1c3fa Remove int hack to allow unsigned numbers greater than 2^63 - 1...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1483 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-15 00:33:36 +00:00
Chris Lattner
8a2a311939 initial checkin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1480 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:52:21 +00:00
Chris Lattner
f23eb85de8 * Support the new -q flag for automated tests
* Remove unsized array support
* Add pointer indexing support


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1477 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:49:29 +00:00
Chris Lattner
6158d8bc73 * Assert that indices are valid for an indexing instruction.
* Add support for indexing into pointers
* Remove support for unsized arrays


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1472 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:43:26 +00:00
Chris Lattner
e917eaec6a Rename ConstPoolVals.cpp to Constants.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1471 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:42:30 +00:00
Chris Lattner
6c42c310c6 Remove unsized array support
Add new SequentialType class


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1470 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:41:56 +00:00
Chris Lattner
a2644f60ce Make strings SByte* arrays instead of UByte * arrays
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1469 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:41:18 +00:00
Chris Lattner
c933344f1e * isFirstClassType is now provided by the Type class
* Add ReplaceInstWithInst


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1468 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:39:22 +00:00
Chris Lattner
7991c281c5 * add ReplaceInstWithInst
* Add support for pointer indexing
* Fix minor bugs that are majorly annoying


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1467 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:38:59 +00:00
Chris Lattner
38ac81cbbc Remove unsized array support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1466 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:38:04 +00:00
Chris Lattner
d554380850 * Support pointer indexing
* Unsized arrays are a thing of the past, remove DoInsertArrayCast family
* Remove cases were we would get into infinite loops because we would insert a cast
  which would then be removed, inserting a different cast, ad infinitum...
* Remove some code that should be redundant with ExprTypeConvert code


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1465 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:37:52 +00:00
Chris Lattner
97ac4ee02e Many many changes and bugfixes:
* Remove support for unsized arrays
* Add pointer indexing support
* Allow more arbitrary malloc type changes (which are too generous currently
  and should be fixed in the future)
* Allow more and better conversions


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1464 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:35:53 +00:00
Chris Lattner
206ad80ef9 The proper prototype for malloc returns a pointer, not an unsized array
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1463 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:32:20 +00:00
Chris Lattner
5618cb60c2 Allow pointer indexing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1462 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:31:26 +00:00
Chris Lattner
90865150e4 Remove unsized array support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1461 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:30:51 +00:00
Chris Lattner
b024ef5e62 Add pointer indexing support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1460 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:30:09 +00:00
Chris Lattner
f7a551fd92 Don't waste as much horizontal space on #uses flag when printing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1459 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:29:12 +00:00
Chris Lattner
72e002564e * Fix cases where we were calling Type->getName() instead of Type->getDescription()
* Remove unsized array support
* Malloc/alloca do not require that the first element be an unsized array to be an
  array allocation


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1458 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:28:42 +00:00
Chris Lattner
29c147302f * Refactor trace values to work as a proper pass. Before it used to add
methods while the pass was running which was a no no.  Now it adds the
  printf method at pass initialization
* Revamp code to use printf calls instead of the old style print_<type>
  calls.
* Simplify code


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1457 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-14 16:26:05 +00:00
Ruchira Sasanka
545cc35b82 added a section on how to modify live variable code to use LLVM instructions
instead of machine instructions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1451 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 21:25:46 +00:00
Chris Lattner
f59ce92763 Not just arrays are unsized
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1450 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:46:11 +00:00
Chris Lattner
9102aee528 Assertion could never fail because another one would in it's place. :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1449 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:45:40 +00:00
Chris Lattner
481fafe67d Some programs are using BB's as values, until we resolve this. Disable the assert
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1448 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:45:06 +00:00
Chris Lattner
e20bcd81eb Build runtime library with local GCCAS
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1447 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:44:23 +00:00
Chris Lattner
e7c6f726c8 Implement sprintf
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1445 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:43:47 +00:00
Chris Lattner
9a49b210c1 Swap operands now preserves the semantics of the binary operator by changing
the opcode of the instruction if possible.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1444 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:43:03 +00:00
Chris Lattner
82d18aa0e4 Add debugging to make a more useful message if a value gets constructed with a null type
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1443 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-13 00:41:27 +00:00
Ruchira Sasanka
789cebb908 Added more comments. Added code to destructor in MethodLiveVarInfo to delete
LiveVarSet caches.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1435 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-08 21:05:27 +00:00
Ruchira Sasanka
b720a8bc1d Added comments are more documentation info
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1434 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-08 21:04:22 +00:00
Chris Lattner
036efec1ec Implement more general conversions for getelementptr instructions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1432 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-07 04:40:30 +00:00
Chris Lattner
44480b52b9 Remove code that is superceeded by code in ExprTypeConvert.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1431 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-07 04:39:01 +00:00
Chris Lattner
7c3f415d99 Don't insert scales of 1 :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1430 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-07 04:26:02 +00:00
Chris Lattner
7026107b70 Do not pessimize users of this function. Fix logic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1428 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-06 18:06:37 +00:00
Chris Lattner
f17a09d878 We can do cast-add elimination even on casts that reinterpret
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1427 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-06 18:06:13 +00:00
Chris Lattner
26a408ab9a Fix bug that caused invalid transformations to be applied
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1426 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-06 18:05:55 +00:00
Chris Lattner
4753bf21a4 Actually return true when a change has been made
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1425 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 19:41:33 +00:00
Chris Lattner
2dc48bd788 Handle more complex array indexing expressions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1424 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 19:41:16 +00:00
Chris Lattner
8da5d426d1 Fix pessimizations on sized arrays
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1423 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 19:40:32 +00:00
Chris Lattner
ac0077e143 Fix a few bugs. Fix pessimization handling sized arrays
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1422 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 19:39:15 +00:00
Chris Lattner
0da29c8ec1 "fix" problems processing floating point expressions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1421 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 19:38:29 +00:00
Chris Lattner
f1d6521412 Hrm, don't do debugging output when debugging is off. :(
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1420 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 06:40:17 +00:00
Chris Lattner
a8b6d43f2a Fixes to type conversion stuff to match induction variables more frequently
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1417 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 06:34:00 +00:00
Chris Lattner
6de230aca8 Fix a bug that clobbered the step value on some inputs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1416 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-05 06:32:30 +00:00
Chris Lattner
ed4feac757 Fix a bug introduced by "internal linkage" work.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1415 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-04 18:01:49 +00:00
Chris Lattner
3bf915f2a2 Fix bugs, don't do external methods which causes segv.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1414 91177308-0d34-0410-b5e6-96231b3b80d8
2001-12-04 08:13:06 +00:00