Chris Lattner
595016d090
This is V9 specific, move it there.
...
llvm-svn: 17545
2004-11-07 00:39:26 +00:00
Chris Lattner
3dadadc837
Move this file from lib/Transforms/Scalar
...
llvm-svn: 17544
2004-11-07 00:39:09 +00:00
Reid Spencer
2e49204e0f
Add support for compressed bytecode
...
llvm-svn: 17535
2004-11-06 23:17:23 +00:00
Reid Spencer
c686a2b64b
Implement the GetBytecodeSymbols interface function to extract just the
...
externally visible defined symbols from a bytecode file.
llvm-svn: 17503
2004-11-06 08:56:40 +00:00
Reid Spencer
0f8359b061
Makefile for the LLVMArchive library.
...
llvm-svn: 17500
2004-11-06 08:52:36 +00:00
Reid Spencer
0cc653e59b
First kinda/sorta working version of the Archive library. Reading is not
...
yet supported but writing works. Way too early to review this. More to come
llvm-svn: 17499
2004-11-06 08:51:45 +00:00
Reid Spencer
0c6a283b2a
Stop propagating method names that violate the coding standard
...
llvm-svn: 17498
2004-11-05 22:15:36 +00:00
John Criswell
ab79288e37
Fix compilation problem; make the cast and the LHS be the same type.
...
llvm-svn: 17488
2004-11-05 16:17:06 +00:00
Chris Lattner
303bdd1e4b
Remove dead var
...
llvm-svn: 17485
2004-11-05 04:52:08 +00:00
Chris Lattner
429aaa5855
Quiet VC++ warnings
...
llvm-svn: 17484
2004-11-05 04:50:59 +00:00
Chris Lattner
c22ffc26b0
Do not make i have bigger scope that we need
...
llvm-svn: 17483
2004-11-05 04:47:37 +00:00
Chris Lattner
3c670cb65a
Remove dead vars
...
llvm-svn: 17482
2004-11-05 04:46:22 +00:00
Chris Lattner
33eb909939
Fix some warnings on VC++
...
llvm-svn: 17481
2004-11-05 04:45:43 +00:00
Nate Begeman
bff3d4abf0
Thanks to sabre for pointing out that we were incorrectly codegen'ing
...
int test(int x) { return 32768 - x; }
Fixed by teaching the function that checks a constant's validity to be used
as an immediate argument about subtract-from instructions.
llvm-svn: 17476
2004-11-04 19:43:18 +00:00
Brian Gaeke
0da246f535
Handle "call" operands of type long/ulong passed in registers.
...
llvm-svn: 17464
2004-11-04 00:27:04 +00:00
Chris Lattner
a67a030d9d
Don't call Constant::getNullValue when the argument could be VoidTy
...
llvm-svn: 17457
2004-11-03 18:51:26 +00:00
Chris Lattner
cff3b41e95
Fix this function to not say that longs have 8-byte alignment on X86/PPC.
...
This method is really a gross hack, but at least we can make it work on
the targets we support right now.
This bug fix stops a crash in a testcase reduced from 176.gcc
llvm-svn: 17443
2004-11-02 22:18:18 +00:00
Tanya Lattner
444be61ea6
Added gross hacks such as creating my own def-use map, and picking on Instruction that I can add all my TmpInstructions to its MCFI.
...
llvm-svn: 17441
2004-11-02 21:04:56 +00:00
Chris Lattner
99d7bb3378
Fix a warning
...
llvm-svn: 17431
2004-11-02 15:27:57 +00:00
Chris Lattner
96f6616479
* Rearrange code slightly
...
* Disable broken transforms for simplifying (setcc (cast X to larger), CI)
where CC is not != or ==
llvm-svn: 17422
2004-11-02 03:50:32 +00:00
Chris Lattner
720eb217a7
Add placeholder variable to make Win32 work, applied for Morten Ofstad
...
llvm-svn: 17406
2004-11-01 20:10:20 +00:00
Chris Lattner
8af7424920
Speed up the tail duplication pass on the testcase below from 68.2s to 1.23s:
...
#define CL0(a) case a: f(); goto c;
#define CL1(a) CL0(a##0) CL0(a##1) CL0(a##2) CL0(a##3) CL0(a##4) CL0(a##5) \
CL0(a##6) CL0(a##7) CL0(a##8) CL0(a##9)
#define CL2(a) CL1(a##0) CL1(a##1) CL1(a##2) CL1(a##3) CL1(a##4) CL1(a##5) \
CL1(a##6) CL1(a##7) CL1(a##8) CL1(a##9)
#define CL3(a) CL2(a##0) CL2(a##1) CL2(a##2) CL2(a##3) CL2(a##4) CL2(a##5) \
CL2(a##6) CL2(a##7) CL2(a##8) CL2(a##9)
#define CL4(a) CL3(a##0) CL3(a##1) CL3(a##2) CL3(a##3) CL3(a##4) CL3(a##5) \
CL3(a##6) CL3(a##7) CL3(a##8) CL3(a##9)
void f();
void a() {
int b;
c: switch (b) {
CL4(1)
}
}
This comes from GCC PR 15524
llvm-svn: 17390
2004-11-01 07:05:07 +00:00
Chris Lattner
93d1e39f3e
Do not compute the predecessor list for a block unless we need it.
...
This speeds up simplifycfg on this program, from 44.87s to 0.29s (with
a profiled build):
#define CL0(a) case a: goto c;
#define CL1(a) CL0(a##0) CL0(a##1) CL0(a##2) CL0(a##3) CL0(a##4) CL0(a##5) \
CL0(a##6) CL0(a##7) CL0(a##8) CL0(a##9)
#define CL2(a) CL1(a##0) CL1(a##1) CL1(a##2) CL1(a##3) CL1(a##4) CL1(a##5) \
CL1(a##6) CL1(a##7) CL1(a##8) CL1(a##9)
#define CL3(a) CL2(a##0) CL2(a##1) CL2(a##2) CL2(a##3) CL2(a##4) CL2(a##5) \
CL2(a##6) CL2(a##7) CL2(a##8) CL2(a##9)
#define CL4(a) CL3(a##0) CL3(a##1) CL3(a##2) CL3(a##3) CL3(a##4) CL3(a##5) \
CL3(a##6) CL3(a##7) CL3(a##8) CL3(a##9)
void f();
void a() {
int b;
c: switch (b) {
CL4(1)
}
}
This testcase is contrived to expose N^2 behavior, but this patch should speedup
simplifycfg on any programs that use large switch statements. This testcase
comes from GCC PR17895.
llvm-svn: 17389
2004-11-01 06:53:58 +00:00
Chris Lattner
e3c00e9eee
Fix comment
...
llvm-svn: 17377
2004-10-31 21:54:51 +00:00
Chris Lattner
70fdac83e3
Improve comment
...
llvm-svn: 17375
2004-10-31 19:57:43 +00:00
Chris Lattner
3f7dbfc898
Add more paranoid assertions :)
...
llvm-svn: 17367
2004-10-31 17:45:40 +00:00
Reid Spencer
f88808ae43
Internalize variable names to prevent recursive assignment. Cleanup docs.
...
llvm-svn: 17359
2004-10-30 09:19:36 +00:00
Chris Lattner
c76fef1248
Fix some more problems where we called getOffset before getNode()
...
llvm-svn: 17358
2004-10-30 07:21:19 +00:00
Chris Lattner
8aa0bafe1a
Fix three bugs:
...
1. Calls to external global VARIABLES should not be treated as a call to an
external function
2. Efficiently deleting an element from a vector by using std::swap with
the back, then pop_back is NOT a good way to keep the vector sorted.
3. Our hope of having stuff get deleted by making them redundant just won't
work. In particular, if we have three calls in sequence that should be
merged: A, B, C first we unify B into A. To be sure that they appeared
identical (so B would be erased) we set B = A. On the next step, we
unified C into A and set C = A. Unfortunately, this is no guarantee that
C = B, so we would fail to delete the dead call. Switch to a more
explicit scheme.
llvm-svn: 17357
2004-10-30 05:41:23 +00:00
Chris Lattner
bc740090a9
Fix more undefined behavior
...
llvm-svn: 17356
2004-10-30 04:22:45 +00:00
Chris Lattner
ba96f0fd83
* Add a method
...
* change some uses of NH.getNode() in a bool context to use !NH.isNull()
* Fix a bunch of places where we depended on the (undefined) order of
evaluation of arguments to function calls to ensure that getNode() was
called before getOffset(). In practice, this was NOT happening.
llvm-svn: 17354
2004-10-30 04:05:01 +00:00
Tanya Lattner
ddebd1eeaa
Fixed bug with infinite epilogues.
...
Fixed issue with generating the partial order. It now adds the nodes not in recurrences in sets for each connected component.
llvm-svn: 17351
2004-10-30 00:39:07 +00:00
Misha Brukman
c7c8d88804
* Fix compilation on AIX: GCC's fixincludes eliminates isinf() declaration
...
* Move file comment to the top of the header where it belongs
llvm-svn: 17349
2004-10-29 23:17:45 +00:00
Brian Gaeke
b87e08e0ef
Change name of target lib to conform to new naming scheme.
...
llvm-svn: 17347
2004-10-29 21:57:16 +00:00
Brian Gaeke
6254a798ca
Remove dependency on MRegisterInfo::getRegClass
...
llvm-svn: 17346
2004-10-29 21:42:27 +00:00
Misha Brukman
8d8fc6529e
The Alpha (tm) intrinsics have never been used anywhere
...
llvm-svn: 17340
2004-10-29 18:43:17 +00:00
Brian Gaeke
9a51b8ca7c
When emitting debug msgs for function stubs, don't truncate the
...
printed pointer value if sizeof(unsigned) != pointer size. Instead,
use uintptr_t.
llvm-svn: 17338
2004-10-29 18:22:45 +00:00
Alkis Evlogimenos
23e565484a
Gep indices must be of int, uint, long or ulong type.
...
llvm-svn: 17313
2004-10-28 06:43:38 +00:00
Reid Spencer
c833eddfe6
Fix library name.
...
llvm-svn: 17307
2004-10-28 05:37:24 +00:00
Alkis Evlogimenos
6bbc57ec12
Fix library name.
...
llvm-svn: 17306
2004-10-28 05:36:48 +00:00
Reid Spencer
49cc2cf279
Fix library name.
...
llvm-svn: 17305
2004-10-28 05:32:01 +00:00
Reid Spencer
37d45f6934
Fix name of library
...
llvm-svn: 17304
2004-10-28 05:30:54 +00:00
Reid Spencer
c9bbb35c6f
Make sure that the yacc and lex output are specified as BUILT_SOURCES.
...
Correct the dependency of the Lexer.o file on the constructed
llvmAsmParser.h header file. It is not the Lexer.cpp file that depends on
the header, its the output of compiling Lexer.cpp, Lexer.o
llvm-svn: 17289
2004-10-28 00:43:24 +00:00
Reid Spencer
57cbe39d1e
Change Library Names Not To Conflict With Others When Installed
...
llvm-svn: 17286
2004-10-27 23:18:45 +00:00
Reid Spencer
f9676539bb
Changes to support rand48 tests
...
llvm-svn: 17284
2004-10-27 23:03:44 +00:00
Chris Lattner
7dfc2d29ac
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
Nate Begeman
a2b117c68a
Move destructor out of line to avoid vtable emission in every file that includes the header. Thanks to sabre.
...
llvm-svn: 17278
2004-10-27 06:00:53 +00:00
Chris Lattner
70c2039b39
Hrm, this code was severely botched. As it turns out, this patch:
...
http://mail.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20041018/019708.html
exposed ANOTHER latent bug in this xform, which caused Prolangs-C/bison to fill
the zion nightly tester disk up and make the tester barf.
This is obviously not a good thing, so lets fix this bug shall we? :)
llvm-svn: 17276
2004-10-27 05:57:15 +00:00
Nate Begeman
c193790dbb
Fix the build by eliminating some more dead code. That'll learn me not to listen to Reid
...
llvm-svn: 17275
2004-10-27 05:44:23 +00:00
Chris Lattner
845afe9b20
Initialize with the correct constant type
...
llvm-svn: 17270
2004-10-27 03:55:24 +00:00