Chris Lattner
7f20ea7d7b
Only functions with external linkage can be resolved to function declarations.
...
This change fixes programs that have multiple functions named the same thing,
where are least one of them is static/internal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2954 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 03:01:24 +00:00
Chris Lattner
e306d94782
* Rewrite loop to be slightly more efficient (arguably)
...
* Fix a MAJOR thinko that was causing bad links to happen on Spec
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2953 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 02:31:03 +00:00
Chris Lattner
d124c38993
The graph is more accurate when I don't completely ignore the return value.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2952 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 01:58:24 +00:00
Chris Lattner
0b5909e6ae
* Correctly get prototype for void*malloc(size_t)
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2951 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:18:01 +00:00
Chris Lattner
d6c68c417b
Fixes to be LP64 correct
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2950 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:15:29 +00:00
Chris Lattner
6183b92b2c
* ConstExpr::getelementptr now takes a vector of Constants not Values
...
* Assert things instead of printing an error and returning null.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2949 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:14:50 +00:00
Chris Lattner
cc4b6ec2b9
ConstExpr::getelementptr now takes a vector of Constants not Values
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2948 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:14:27 +00:00
Chris Lattner
3535c9b387
Add a hack to check for a subset of true dominance properties
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2947 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:13:42 +00:00
Chris Lattner
6cdf1971bd
Implement linking of ConstExprs
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2946 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:13:08 +00:00
Chris Lattner
0d9bab8bac
Lots of bug fixes, add BottomUpClosure, which has bugs, but is a start.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2945 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:12:30 +00:00
Chris Lattner
84428e1892
First cut at implementing bottom up analysis
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2944 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:11:28 +00:00
Chris Lattner
1aa7132700
Make getelementptr ConstExpr take a vector of constants not values
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2943 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-18 00:11:08 +00:00
Mehwish Nagda
e01166591f
added check for Function with 0 BB
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2942 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 23:40:33 +00:00
Guochun Shi
f4688a8079
*** empty log message ***
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2941 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 23:05:56 +00:00
Chris Lattner
e19292bd8e
New testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2940 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 22:19:30 +00:00
Chris Lattner
1416089f44
Fix prototype to make function.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2939 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 21:34:20 +00:00
Chris Lattner
e76c4f6edf
New testcase, unanalyzed.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2938 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 20:04:07 +00:00
Chris Lattner
260fc14568
Anand forgot to check in the makefile corresponding to his previous change
...
which eliminated the EmitFunctions directory
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2937 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 17:13:01 +00:00
Chris Lattner
b1b4262387
* Remove dead code from ExprTypeConvert.cpp
...
- I->use_empty() can never be true because of the IHolder's
* Fix bug: test/Regression/Transforms/LevelRaise/2002-07-16-SourceAndDestCrash.ll
- Add a new NewCasts member to VMC to keep track of casts that have been
created and to ensure there is always a reference to the cast.
- Extend ValueHandle a bit so it can be used in an STL container
- Make sure we destroy the ValueMapCache before verifying the function
in LevelRaise.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2936 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 17:11:33 +00:00
Chris Lattner
1ab8425c1c
New testcase finally identified!!
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2935 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-17 02:36:02 +00:00
Chris Lattner
3378a5b591
* Add a bunch of debugging features to LevelRaise
...
- Verify the function every time it is exprconverted if DEBUG is on
- Provide a way to start exprconversion AT a specific instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2934 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 23:49:24 +00:00
Chris Lattner
23014c9b00
Avoid !sized assertion failure if Ty is not a sized type
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2933 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 22:29:37 +00:00
Chris Lattner
3fb2ddd368
Fix bug: test/Regression/Transforms/LevelRaise/2002-07-16-RaiseCrash2.ll
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2932 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 21:41:31 +00:00
Chris Lattner
4069c8400b
New testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2931 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 21:33:27 +00:00
Chris Lattner
c2c5a6428d
Add testcase for raise opportunity missed.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2930 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 19:10:00 +00:00
Anand Shukla
b3ce2f99fc
Removed emitfuncs: now its part of instrument library
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2929 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:59:55 +00:00
Anand Shukla
e0b514259c
Moved over EmitFunctions to this library
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2928 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:58:08 +00:00
Anand Shukla
f080ec7dcd
removed this directory
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2927 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:56:29 +00:00
Anand Shukla
11870879ec
Moved EmitFunctions.cpp up to instrumentation directory
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2926 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:55:55 +00:00
Chris Lattner
8b1b4e20a9
* Make global variables with external linkage get emitted correctly
...
* Do NOT add a prefix to global variables that are external
* Add newline after emitting a constpointerref
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2925 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:35:16 +00:00
Chris Lattner
a66c7bfa51
Bugfix to previous checkin
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2924 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:12:55 +00:00
Chris Lattner
0af0dff8a0
Bug fix to RUN line
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2923 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 18:02:43 +00:00
Mehwish Nagda
3115540870
Now will profile all Basic Blocks
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2922 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 17:48:27 +00:00
Chris Lattner
9713c4ef46
* Cleanup pass
...
* The global variable cannot be internal or else we cannot use it!
* Always add a function to the table, even if it only has a single basic
block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2921 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 17:42:54 +00:00
Chris Lattner
131454e91d
* Add assertion to ExprTypeConvert to detect error earlier than without it
...
* Fix bug in LevelRaise.cpp, correcting this problem:
test/Regression/Transforms/LevelRaise/2002-07-16-RaiseCrash.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2920 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 17:33:13 +00:00
Chris Lattner
b39df57bf3
New testcase distilled from olden-tsp.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2919 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 17:32:17 +00:00
Chris Lattner
c5debd4337
New testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2918 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 05:38:33 +00:00
Anand Shukla
3edfb64902
added std:: to pair
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2917 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 00:04:57 +00:00
Anand Shukla
18be6fb716
added std:: to vector
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2916 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 00:04:15 +00:00
Anand Shukla
6c5ed410b2
added std:: to string
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2915 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 00:03:10 +00:00
Anand Shukla
4d2da0d7a7
added std:: to cerr and endl
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2914 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-16 00:02:17 +00:00
Mehwish Nagda
634cd1c4b4
Added the Mapping Pass to out put Mapping Info to .s file
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2913 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 23:58:21 +00:00
Mehwish Nagda
0226fdb6e7
*** empty log message ***
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2912 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 23:56:27 +00:00
Mehwish Nagda
b43086b4b7
Initial checking : Writes LLVM - MI mappiing to the .s file
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2911 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 23:08:49 +00:00
Vikram S. Adve
ab6317a1e5
Ensure ConstExpr constants are unique.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2910 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 18:20:50 +00:00
Vikram S. Adve
d0b1bb01f2
Ensure ConstExpr constants are unique using a
...
map of <opcode, operands> to ConstExpr.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2909 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 18:19:33 +00:00
Vikram S. Adve
0850978368
Added duplicate constant expressions to test uniqueness support.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2908 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 18:18:45 +00:00
Chris Lattner
5659dd1af8
Fix bug: test/Regression/Assembler/2002-07-14-InternalLossage.llx
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2907 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-15 00:10:33 +00:00
Chris Lattner
38c42725fe
Check in tests that have been in my tree for a long time
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2906 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-14 23:48:42 +00:00
Chris Lattner
98482c3ba7
Minor rename of output
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2905 91177308-0d34-0410-b5e6-96231b3b80d8
2002-07-14 23:25:23 +00:00