Commit Graph

554 Commits

Author SHA1 Message Date
Chris Lattner
25f5009d06 New file for new pass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2012 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-28 18:01:22 +00:00
Chris Lattner
1d8ec6194a * Define some operators on PointerVal and PVS's
* Nodes can determine whether they are foldable with another node
* Rename NewDSNode to AllocDSNode
* The Function graph breaks up all of the node types into individual
  vectors to alloc fast access when you are looking for a particular type
  of node.  Simplifies much code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2009 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-28 17:48:41 +00:00
Cameron Buschardt
5758eec1e0 Rename constructor function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2006 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-27 23:27:45 +00:00
Chris Lattner
b3ebdadb2c * Add a nice utility method to DSNode
* Export interface to tell whether an alloc node represent a malloc or alloca
* Add the concept of a "critical" shadow node


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2000 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-27 19:41:45 +00:00
Chris Lattner
26f8a40b51 Allow isa<DSNode>(..)
Simplification routines return true on change


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1996 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-27 00:52:57 +00:00
Chris Lattner
d9ddf05014 New header file for datastructure analysis
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1993 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-26 22:38:45 +00:00
Chris Lattner
0fc0c1d3e1 Change uses of Method to Function
Change uses of methodArgument to FunctionArgument


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1988 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-26 17:49:55 +00:00
Chris Lattner
b277d1d0e0 Remove unneccesary forward declarations for classes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1987 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-26 17:49:00 +00:00
Chris Lattner
19b0411c95 Transform uses of Method into uses of Function.
Rename MethodArgument to FunctionArgument
Fix some _really_ out of date comments


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1986 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-26 17:48:08 +00:00
Chris Lattner
7797946c5e Allow clients to use FunctionType as well as MethodType for now
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1985 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-26 17:46:41 +00:00
Vikram S. Adve
dfe412dc8b Refix bug: Add back method MachineCodeForInstruction::dropAllReferences.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1980 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-24 03:58:02 +00:00
Vikram S. Adve
4cbd55062d Fix padding when allocating local variables on stack.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1979 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-24 03:57:38 +00:00
Vikram S. Adve
4fad513704 Add methods to support type inquiry. Rename TmpInstruction values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1978 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-24 03:56:55 +00:00
Vikram S. Adve
6be4ebe1eb Change treeRoots data structure to make enumeration deterministic.
Also, add a flag to marked nodes that do not need code because they
have been folded into the user (parent in the BURG tree).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1963 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-24 03:25:17 +00:00
Vikram S. Adve
98d64f8d51 Major overhaul to support arbitrary mixed array and structure indices.
Also moved to the Scalar/ directory and renamed to "MultiDim".


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1961 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-24 03:21:18 +00:00
Chris Lattner
e7506a366e Rename Method to Function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1957 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:51:58 +00:00
Chris Lattner
bcd8e03138 Remove extranous forward decl
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1956 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:48:21 +00:00
Chris Lattner
a4d63bc60e Remove unneccesary forward definitions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1955 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:48:07 +00:00
Chris Lattner
ff9ffa9866 Add transition header file
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1954 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:47:43 +00:00
Chris Lattner
79cc5bc912 Update documentation, rename Method to Function, move typedef to Value.h for now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1953 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:47:28 +00:00
Chris Lattner
b6e0c852a8 Change Method to Function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1952 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 22:46:51 +00:00
Chris Lattner
1b139b4060 Add transition typedef to Function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1951 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 21:59:53 +00:00
Vikram S. Adve
c8394f63cb New pass to convert Convert multi-dimensional
array references into 1-D references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1950 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 20:46:18 +00:00
Vikram S. Adve
c7b439d2f9 Moved to Scalar/ directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1949 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-23 20:44:37 +00:00
Chris Lattner
05c0e9e562 * Make AllocationInst ctor protected
* Move AllocationInst ctor to iMemory.cpp
* AllocationInst's always have one operand, even if it is a uint 1


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1938 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-21 22:37:01 +00:00
Chris Lattner
af2d701e12 Remove a misguided API extension
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1926 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-21 05:46:43 +00:00
Chris Lattner
99584c69b6 Allow implementation of all HANDLE_*_INST macros at once by defining HANDLE_INST
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1919 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-19 05:51:18 +00:00
Vikram S. Adve
07fb6e603f New pass to convert Convert multi-dimensional
array references into 1-D references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1918 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-19 02:10:34 +00:00
Vikram S. Adve
06fa17c1c2 Big bug fix: killed uses were being inserted instead of erased!
Also added a set of debug options.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1917 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-19 00:59:08 +00:00
Chris Lattner
b4c5f83eac Initial checkin of InstVisitor class
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1916 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 19:07:42 +00:00
Chris Lattner
4e390f6199 Add isa,cast,dyncast support for AllocationInst.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1915 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 05:00:51 +00:00
Vikram S. Adve
ce0845aeba Added function computeOffsetforLocalVar to check how big the
offset-from-FP will be before allocating space for a local variable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1900 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 03:23:29 +00:00
Vikram S. Adve
f1a51be375 Use vector for machine instructions in GetInstructionsByRule.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1899 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 03:20:46 +00:00
Vikram S. Adve
851597c3b3 Added machine-independent value for INVALID_MACHINE_OPCODE.
Just cosmetic changes otherwise.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1898 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 03:19:38 +00:00
Vikram S. Adve
80347ecb14 Add function getRegClassIDOfType.
getRegClassIDOfValue is now just a wrapper around this.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1897 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 03:18:28 +00:00
Vikram S. Adve
9558b4a292 Bug fix in setting CC register.
Also use distinct names for the three types of SetMachineOperand
to avoid painful overloading problems and errors.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1894 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-18 03:10:17 +00:00
Chris Lattner
a1f0021a67 Convert the top line of the header from .cpp style to .h style.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1884 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-17 21:16:22 +00:00
Chris Lattner
0fce76a009 Fix bug: test/Regression/Other/2002-03-11-ConstPropCrash.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1858 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-11 22:11:07 +00:00
Chris Lattner
e82f1c6cb7 * Add new method localLookup
* SymbolTable::remove(Value *N) checks to see if we are internally
  inconsistent before looking for a type plane (caused a crash)
* insertEntry now does a local lookup instead of a global lookup, which was
  causing an infinite loop in the renamer logic.
* Added assertions to make sure stuff stays happy
* Now the linker correctly links the SPECINT2000 mcf benchmark


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1840 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-08 20:26:17 +00:00
Chris Lattner
fad83694a2 Fix typo in comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1834 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-08 18:38:08 +00:00
Chris Lattner
d4d427baa9 Clean up call graph, add comments, and fix test/Regression/Other/2002-01-31-CallGraph.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1828 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-06 20:19:35 +00:00
Chris Lattner
bf4bf53dfd Move callgraph printing out of writer.h into callgraph.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1824 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-06 17:59:45 +00:00
Chris Lattner
e1755d39c0 Pull Callgraph out of the cfg namespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1821 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-06 17:39:28 +00:00
Chris Lattner
4ce0f8aa9e Take CallGraph out of the CFG namespace. It has nothing to do with CFGs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1820 91177308-0d34-0410-b5e6-96231b3b80d8
2002-03-06 17:16:43 +00:00
Chris Lattner
bd0ef77cde Change over to use new style pass mechanism, now passes only expose small
creation functions in their public header file, unless they can help it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1816 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-26 21:46:54 +00:00
Chris Lattner
9039ba9939 Expose verifier for method and module, and accept constant structures
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1814 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-26 21:38:48 +00:00
Chris Lattner
eded4916d6 Move ProfilePaths class into ProfilePaths library, only expose a creation function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1812 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-26 20:04:59 +00:00
Anand Shukla
c8e6b10c2c Initial check in of header file for profile-paths pass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1801 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-26 18:43:03 +00:00
Chris Lattner
1ddf664f74 Make it compile with GCC 3.0.4
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1786 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-24 23:01:21 +00:00
Chris Lattner
04bb837cc0 Genericize the ReversePostOrderIterator.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1785 91177308-0d34-0410-b5e6-96231b3b80d8
2002-02-24 21:48:59 +00:00