Chris Lattner
8b952fa7ae
Cleanup #includes, expose module
...
llvm-svn: 4021
2002-10-02 21:11:16 +00:00
Chris Lattner
dabbf17b47
Expose TD to ExternalFunctions.cpp
...
llvm-svn: 4020
2002-10-02 21:10:48 +00:00
Chris Lattner
58185f2df9
- Print the predecessors of a basic block instead of the number of uses of
...
the block in the AsmWriter
llvm-svn: 4019
2002-10-02 19:38:55 +00:00
Chris Lattner
0f5346d743
Fix bug: 2002-10-02-SignExtensionProblem.ll
...
llvm-svn: 4017
2002-10-02 18:53:14 +00:00
Nick Hildenbrandt
bff2adb2a4
Removed unneeded reference and dereferences.
...
llvm-svn: 4016
2002-10-02 18:34:51 +00:00
Chris Lattner
6ee87ef090
New testcase for a problem discovered in the SPECINT gzip benchmark.
...
llvm-svn: 4015
2002-10-02 18:32:38 +00:00
Nick Hildenbrandt
e07698b492
Cleaned up my last check-in.
...
llvm-svn: 4014
2002-10-02 18:32:35 +00:00
Nick Hildenbrandt
e0ba1f25b6
No longer include malloc.h. If protoypes are needed for memory functions they will be present in the byte code and the generated c as well.
...
llvm-svn: 4013
2002-10-02 18:20:18 +00:00
Chris Lattner
c4d2ad21bf
* Implement fully general merging of array subscripts on demand! This
...
does not handle the initial pointer index case yet though.
llvm-svn: 4012
2002-10-02 06:24:36 +00:00
Chris Lattner
be9f70e342
* Implement fully general merging of array subscripts on demand! This
...
does not handle the initial pointer index case yet though.
llvm-svn: 4011
2002-10-02 06:24:29 +00:00
Chris Lattner
4e37455a69
When printing DS nodes, print the mergemap index as well to allow easier
...
debugging of merging process.
llvm-svn: 4010
2002-10-02 05:17:55 +00:00
Chris Lattner
c2222c8077
Checkin the "meat" of the Data structure graph itself. I forgot to check
...
this in before. :(
llvm-svn: 4009
2002-10-02 04:58:12 +00:00
Chris Lattner
0b2a6e00d1
* Significant rework of DSNode to support arbitrary aliasing due to merging
...
* Now all and any bytes of a DSNode can be merged together individually. This
is neccesary to support the full generality of C and support aliasing
correctly.
llvm-svn: 4008
2002-10-02 04:57:39 +00:00
Chris Lattner
06f9532c8a
- Remove the User::eraseOperand method which is never used, really
...
dangerous, and not something we want to expose.
llvm-svn: 4007
2002-10-01 23:41:17 +00:00
Chris Lattner
3e55b86821
Do some cleanups to the Type and Constant section to remove latex stuff
...
There is still a lot of cleanup and fleshing out required here, but at least
it gets rid of the flagrantly bad parts.
llvm-svn: 4006
2002-10-01 23:17:09 +00:00
Chris Lattner
e6e375e704
Temporary change to make datastructure stuff link in right
...
llvm-svn: 4005
2002-10-01 22:41:01 +00:00
Chris Lattner
c2996d9a8b
Changes to work with Statistics rework
...
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
* Broke constructor to take two const char * arguments instead of one, so
that indendation can be taken care of automatically.
* Sort the list by pass name when printing
* Make sure to print all statistics as a group, instead of randomly when
the statistics dtors are called.
* Updated ProgrammersManual with new semantics.
llvm-svn: 4004
2002-10-01 22:40:31 +00:00
Chris Lattner
3dfd3b5a3d
Update manual to reflect recent changes in the Statistic class.
...
llvm-svn: 4003
2002-10-01 22:39:41 +00:00
Chris Lattner
bf3a099a62
Updates to work with recent Statistic's changes:
...
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
* Broke constructor to take two const char * arguments instead of one, so
that indendation can be taken care of automatically.
* Sort the list by pass name when printing
* Make sure to print all statistics as a group, instead of randomly when
the statistics dtors are called.
* Updated ProgrammersManual with new semantics.
llvm-svn: 4002
2002-10-01 22:38:41 +00:00
Chris Lattner
3cf3782bc0
Updates to work with recent Statistic's changes:
...
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
* Broke constructor to take two const char * arguments instead of one, so
that indendation can be taken care of automatically.
* Sort the list by pass name when printing
* Make sure to print all statistics as a group, instead of randomly when
the statistics dtors are called.
* Updated ProgrammersManual with new semantics.
llvm-svn: 4001
2002-10-01 22:38:37 +00:00
Chris Lattner
f242bec91b
Build subdirs in parallel
...
llvm-svn: 4000
2002-10-01 22:36:35 +00:00
Chris Lattner
c758fe6b72
- Rework Statistics:
...
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
* Broke constructor to take two const char * arguments instead of one, so
that indendation can be taken care of automatically.
* Sort the list by pass name when printing
* Make sure to print all statistics as a group, instead of randomly when
the statistics dtors are called.
llvm-svn: 3999
2002-10-01 22:35:45 +00:00
Chris Lattner
7c91242aef
Check in DataStructure rewrite so far.
...
llvm-svn: 3998
2002-10-01 22:34:45 +00:00
Chris Lattner
d3121eb8cb
Initial checkin of Steensgaards context insensitive flow insensitive
...
alias analysis
llvm-svn: 3997
2002-10-01 22:34:12 +00:00
Chris Lattner
193e6924ca
Checkin some major reworks of data structure analysis. This is not done,
...
nor does it work very well, but I need to get it checked in before I break
the tree unintentionally.
llvm-svn: 3996
2002-10-01 22:33:50 +00:00
Chris Lattner
52db271374
Make sure to use the TimerGroup that we created!
...
llvm-svn: 3995
2002-10-01 20:12:06 +00:00
Chris Lattner
d5fc9023a8
Make sure not to count the PassManager wrapers
...
llvm-svn: 3994
2002-10-01 20:08:11 +00:00
Chris Lattner
af751b8e72
Factor timer code out of PassManager implementation, into a generic interface
...
exposed by Support/Timer.h.
llvm-svn: 3993
2002-10-01 19:54:07 +00:00
Chris Lattner
6dad11f6c0
Checkin generic interval timer support
...
llvm-svn: 3992
2002-10-01 19:36:54 +00:00
Nick Hildenbrandt
386834b2f1
Fixed to properly escape quotes in strings.
...
llvm-svn: 3991
2002-09-30 21:11:55 +00:00
Chris Lattner
fd400215d5
Allow production of -stats output for benchmarks by specifying
...
ENABLE_STATS=1 on the make command line.
llvm-svn: 3989
2002-09-30 19:24:07 +00:00
Chris Lattner
ce6b87be98
Allow production of -stats output for benchmarks by specifying
...
ENABLE_STATS=1 on the make command line.
llvm-svn: 3988
2002-09-30 19:23:55 +00:00
Vikram S. Adve
2b099a2419
On this code, llc did not pass the sixth argument (%reg321) to printf.
...
llvm-svn: 3986
2002-09-30 16:14:14 +00:00
Chris Lattner
1931788143
Minor tweak
...
llvm-svn: 3985
2002-09-29 22:59:29 +00:00
Chris Lattner
36fb08ee53
Enable buidling of programs on Linux again
...
llvm-svn: 3984
2002-09-29 22:58:51 +00:00
Vikram S. Adve
6be99c4f23
Added several more helper functions for construction MachineInstrs.
...
llvm-svn: 3983
2002-09-29 22:55:45 +00:00
Vikram S. Adve
75b4a29613
Bug fix in folding getElementPtr instructions: don't fold one into
...
a predecessor if it has a non-zero first index and the predecessor
ends with a struct index.
llvm-svn: 3982
2002-09-29 22:55:05 +00:00
Chris Lattner
6b6f540959
Fix a problem that was caused by stale analyses being in CurrentAnalyses
...
llvm-svn: 3981
2002-09-29 22:50:22 +00:00
Chris Lattner
05e86302f4
Fix bug in LICM that caused the previous big win. :(
...
llvm-svn: 3980
2002-09-29 22:26:07 +00:00
Vikram S. Adve
5b5dd671b2
Minor change to interface for Create{Zero,Sign}ExtensionsInstructions.
...
llvm-svn: 3979
2002-09-29 21:53:31 +00:00
Chris Lattner
6443769b34
Hoist the contents of Loops in depth first order in the dominator tree,
...
rather than in random order. This causes LICM to be DRAMATICALLY more
effective. For example, on bzip2.c, it is able to hoist 302 loads and
2380 total instructions, as opposed to 44/338 before. This obviously
makes other transformations much more powerful as well!
llvm-svn: 3978
2002-09-29 21:46:09 +00:00
Chris Lattner
467a9e84c4
Fix printing of loop information
...
llvm-svn: 3977
2002-09-29 21:43:04 +00:00
Chris Lattner
ae3ac7e1c9
Improve printing of dominator sets
...
llvm-svn: 3976
2002-09-29 21:42:42 +00:00
Chris Lattner
03a9e15a9f
Fix major bugs in dominator set & tree information updating
...
llvm-svn: 3975
2002-09-29 21:41:38 +00:00
Chris Lattner
85dd58c2cb
Simplify code a bit, add an assertion
...
llvm-svn: 3974
2002-09-29 21:37:08 +00:00
Joel Stanley
fc2aac7f8f
Fixed errors in ReplaceInstWithValue/ReplaceInstWithInst examples.
...
llvm-svn: 3973
2002-09-29 17:31:54 +00:00
Vikram S. Adve
be55f2dd2c
Convert DIRS to PARALLEL_DIRS. They can be built independently.
...
llvm-svn: 3972
2002-09-29 11:52:14 +00:00
Vikram S. Adve
009dac7ab4
Regression test for llc bug that was folding two getelementptrs illegally.
...
llvm-svn: 3971
2002-09-28 18:09:05 +00:00
Vikram S. Adve
9011903ee2
Added a couple of helper methods for live range construction.
...
llvm-svn: 3970
2002-09-28 17:05:43 +00:00
Vikram S. Adve
ed2df3ecf8
Live ranges for Return value and return address of a Call are now
...
created here, simply by handling all implicit operands (which should
have been done anyway).
llvm-svn: 3969
2002-09-28 17:05:22 +00:00
Vikram S. Adve
8076fe87b7
Fixed method getReturnValue(): it should return NULL if the
...
callee does not return a value.
llvm-svn: 3968
2002-09-28 17:03:54 +00:00
Vikram S. Adve
8fef3b8033
Fixed incorrect assertion: spill code for function ptr should be
...
handled like normal operands, not like other call arguments.
llvm-svn: 3967
2002-09-28 17:02:40 +00:00
Vikram S. Adve
d76d82b40f
Return address register should be marked as "result" for the JMPL instruction
...
since it is defined by the instruction.
llvm-svn: 3966
2002-09-28 17:00:15 +00:00
Vikram S. Adve
6d1036d41b
Live ranges for Return value and return address of a Call are no longer
...
created here. Instead they are created in LiveRangeInfo.cpp. This
simplifies the code here quite a bit.
llvm-svn: 3965
2002-09-28 16:59:05 +00:00
Vikram S. Adve
cce628aeaf
Simplified code that handles call args and rets, so it no longer
...
needs the RegClass list to be passed in.
llvm-svn: 3964
2002-09-28 16:56:59 +00:00
Vikram S. Adve
4bb9866dc5
Simplify Call translation slightly.
...
llvm-svn: 3963
2002-09-28 16:55:41 +00:00
Vikram S. Adve
d92bd6f951
Regression test for live range bug for call arguments.
...
llvm-svn: 3962
2002-09-28 16:51:47 +00:00
Vikram S. Adve
34d16d64b0
Overhaul integer conversions to match C++ ISO standard.
...
Don't allow direct FP-to-uint conversion (must be eliminated by preselection).
Address arithmetic for arrays is now entirely 64-bit so no sign-ext needed.
llvm-svn: 3961
2002-09-27 14:33:08 +00:00
Vikram S. Adve
40e2347b90
Modify operand order for Create{Sign,Zero}ExtensionInstructions.
...
llvm-svn: 3960
2002-09-27 14:29:45 +00:00
Vikram S. Adve
d238de02c7
Bug fix: some redundant copies were not being deleted after detection :-|.
...
llvm-svn: 3959
2002-09-27 14:27:37 +00:00
Vikram S. Adve
66303bb9a5
Sign-extend integer constants from original type size to 64 bits!
...
llvm-svn: 3958
2002-09-27 14:26:20 +00:00
Vikram S. Adve
46aeb8c7c2
Decompose FP-to-UInt casts into FP-to-ULong-toUInt.
...
llvm-svn: 3957
2002-09-27 14:24:45 +00:00
Vikram S. Adve
2a351d54a0
Simple test for constant expressions constructed from global addresses.
...
llvm-svn: 3956
2002-09-27 13:27:14 +00:00
Vikram S. Adve
9cf9da9642
Overhauled completely.
...
llvm-svn: 3955
2002-09-27 13:26:36 +00:00
Chris Lattner
647df647e1
First try at implementing the AliasSetTracker class. I'm sure it will need
...
revision as I start to use it though.
llvm-svn: 3954
2002-09-26 21:49:07 +00:00
Chris Lattner
ed06af34b6
* Run preheaders pass tests
...
* Linearize list of directories so I don't have to keep dealing with
wrapping problems.
llvm-svn: 3953
2002-09-26 19:53:02 +00:00
Chris Lattner
b009ceaa9d
Checkin the simple features tests for the preheader insertion pass.
...
llvm-svn: 3952
2002-09-26 19:50:11 +00:00
Chris Lattner
d57f3f5073
- Further cleanups of LICM pass, remove extra work from previous implementation
...
- Do not clone instructions then insert clone outside of loop. Just move them.
llvm-svn: 3951
2002-09-26 19:40:25 +00:00
Chris Lattner
f64f2d3fb3
Improve comments, doxygenize more
...
llvm-svn: 3950
2002-09-26 16:52:07 +00:00
Chris Lattner
7b1dcc39c3
Don't hardcode path to dot in the doxygen config file. Let doxygen search the PATH
...
llvm-svn: 3949
2002-09-26 16:45:59 +00:00
Chris Lattner
c293224214
Don't hardcode path to doxygen
...
llvm-svn: 3948
2002-09-26 16:38:42 +00:00
Chris Lattner
718b221ff8
Clean up LICM significantly now that it is guaranteed to have loop preheaders
...
llvm-svn: 3947
2002-09-26 16:38:03 +00:00
Chris Lattner
ca056914c6
Change pass name to something sane
...
llvm-svn: 3946
2002-09-26 16:37:37 +00:00
Chris Lattner
d771fdfd75
Loop invariant code motion now depends on the LoopPreheader pass. Dead code
...
has not yet been removed.
llvm-svn: 3945
2002-09-26 16:19:31 +00:00
Chris Lattner
bedbd6bc16
- Cleanup break-crit-edges pass by making SplitCriticalEdge a member method.
...
- break-crit-edges pass does not invalidate loop-preheader pass.
llvm-svn: 3944
2002-09-26 16:18:51 +00:00
Chris Lattner
9b4c1aa389
Checkin new loop-preheader insertion pass.
...
llvm-svn: 3943
2002-09-26 16:17:33 +00:00
Chris Lattner
61992f66d8
Checkin new loop-preheader insertion pass.
...
llvm-svn: 3942
2002-09-26 16:17:31 +00:00
Chris Lattner
3524f58309
Fix printing of loop information
...
llvm-svn: 3941
2002-09-26 16:15:54 +00:00
Chris Lattner
0fcb61f2b7
- Fix bug in LoopInfo causing ParentLoop to be garbage
...
llvm-svn: 3940
2002-09-26 16:15:19 +00:00
Chris Lattner
98ae0f1897
- Add methods to ImmediateDominators & DominatorTree to allow updates
...
- Make DominatorTree::Node not inherit from std::vector
llvm-svn: 3939
2002-09-26 16:14:41 +00:00
Chris Lattner
6561db0c12
- Add methods to ImmediateDominators & DominatorTree to allow updates
...
- Make DominatorTree::Node not inherit from std::vector
llvm-svn: 3938
2002-09-26 16:14:37 +00:00
Chris Lattner
9ff37c5265
Add a new "DominatorSet::addDominator" method to allow updates
...
llvm-svn: 3937
2002-09-26 05:42:47 +00:00
Chris Lattner
08373d1c9c
- Add new methods to LoopInfo: getLoopPreheader, addBasicBlockToLoop.
...
These allow extra information to be easily gathered, and loopinfo to be
updated.
llvm-svn: 3936
2002-09-26 05:32:50 +00:00
Chris Lattner
0a96a521eb
- Add new methods to LoopInfo: getLoopPreheader, addBasicBlockToLoop.
...
These allow extra information to be easily gathered, and loopinfo to be
updated.
llvm-svn: 3935
2002-09-26 05:32:43 +00:00
Chris Lattner
4dfede8070
- Add new ctor to BasicBlock to allow insertion before any BB, not just at
...
the end of the function.
llvm-svn: 3934
2002-09-26 05:03:22 +00:00
Chris Lattner
506389a37f
- Add new ctor to BasicBlock to allow insertion before any BB, not just at
...
the end of the function.
llvm-svn: 3933
2002-09-26 05:03:17 +00:00
Chris Lattner
870a4a5bb4
Converted SimpleStructMutation to take TargetData as a required pass.
...
llvm-svn: 3932
2002-09-26 00:17:21 +00:00
Chris Lattner
7b5746bfcf
Converted SimpleStructMutation to take TargetData as a required pass.
...
llvm-svn: 3931
2002-09-26 00:17:18 +00:00
Chris Lattner
79efacbb19
Change LowerAllocations pass to 'require' TargetData instead of it being
...
passed in.
llvm-svn: 3930
2002-09-25 23:47:49 +00:00
Chris Lattner
3cab9f0396
Change LowerAllocations pass to 'require' TargetData instead of it being
...
passed in.
llvm-svn: 3929
2002-09-25 23:47:47 +00:00
Chris Lattner
fec6850f90
Convert TargetData to be an ImmutablePass
...
llvm-svn: 3928
2002-09-25 23:46:56 +00:00
Chris Lattner
09cfdcb1a3
Convert TargetData to be an ImmutablePass
...
llvm-svn: 3927
2002-09-25 23:46:55 +00:00
Chris Lattner
9720dda185
Add documentation for ImmutablePass's
...
llvm-svn: 3926
2002-09-25 22:31:38 +00:00
Chris Lattner
635d8919a7
ImmutablePass's don't need a runOnFunction, nor do they need to explicitly say
...
that they preserve all xforms
llvm-svn: 3925
2002-09-25 22:27:54 +00:00
Chris Lattner
ceae380b2c
Convert BasicVN to be an ImmutablePass
...
llvm-svn: 3924
2002-09-25 22:27:25 +00:00
Chris Lattner
480b37d479
* Fix ugly bug in previous checkin where I reused the name 'i' one too many times
...
* Print out immutable passes in the -debug-pass=Structure report.
llvm-svn: 3923
2002-09-25 22:26:52 +00:00
Chris Lattner
81f4eaab04
Convert BasicAA to be an immutable pass instead of a FunctionPass
...
llvm-svn: 3922
2002-09-25 22:00:18 +00:00
Chris Lattner
ee0788d42d
Add support for ImmutablePasses, which are not run, and cannot be
...
invalidated.
llvm-svn: 3921
2002-09-25 21:59:11 +00:00
Nick Hildenbrandt
88e87783b8
Strings now handled correctly.
...
llvm-svn: 3920
2002-09-25 20:29:26 +00:00
Chris Lattner
7a6ce5a28c
Checkin stub for Misha to implement
...
llvm-svn: 3919
2002-09-25 19:10:06 +00:00