Reid Spencer
727f31b2cd
Add a #include to resolve IntegerType class.
...
llvm-svn: 33384
2007-01-19 22:45:05 +00:00
Evan Cheng
fec133d2d1
Add test case extracted from lencod. Spiller was infinite looping in GetRegForReload().
...
llvm-svn: 33383
2007-01-19 22:43:14 +00:00
Evan Cheng
fc74e2de26
GetRegForReload() now keeps track which registers have been considered and rejected during its quest to find a suitable reload register. This avoids an infinite loop in case like this:
...
t1 := op t2, t3
t2 <- assigned r0 for use by the reload but ended up reuse r1
t3 <- assigned r1 for use by the reload but ended up reuse r0
t1 <- desires r1
sees r1 is taken by t2, tries t2's reload register r0
sees r0 is taken by t3, tries t3's reload register r1
sees r1 is taken by t2, tries t2's reload register r0 ...
llvm-svn: 33382
2007-01-19 22:40:14 +00:00
Reid Spencer
9f900c1f92
Unbreak Darwin.
...
llvm-svn: 33375
2007-01-19 22:04:24 +00:00
Reid Spencer
a96084901c
Help the lli interpreter find the stderr/stdin/stdout symbols. These are
...
needed for output to be generated. On Linux these are both global vars and
macro definitions so we have to special case Linux.
llvm-svn: 33374
2007-01-19 21:41:04 +00:00
Reid Spencer
dcf6f90033
Handle each of stderr/stdin/stdout separately.
...
llvm-svn: 33373
2007-01-19 21:30:39 +00:00
Reid Spencer
adf4118a36
Remove dead methods in the ValTypes.
...
llvm-svn: 33372
2007-01-19 21:25:12 +00:00
Reid Spencer
e928a15c9e
For this transform: store V, (cast P) -> store (cast V), P
...
don't allow the transform if V and the pointer's element type are different
width integer types.
llvm-svn: 33371
2007-01-19 21:20:31 +00:00
Reid Spencer
a94d394ad2
For PR1043:
...
This is the final patch for this PR. It implements some minor cleanup
in the use of IntegerType, to wit:
1. Type::getIntegerTypeMask -> IntegerType::getBitMask
2. Type::Int*Ty changed to IntegerType* from Type*
3. ConstantInt::getType() returns IntegerType* now, not Type*
This also fixes PR1120.
Patch by Sheng Zhou.
llvm-svn: 33370
2007-01-19 21:13:56 +00:00
Reid Spencer
eaedf70eea
Make this test actually test what its supposed to test.
...
llvm-svn: 33369
2007-01-19 21:06:38 +00:00
Evan Cheng
77c15ded10
Code clean up. Use def : pat instead of defining new instructions.
...
llvm-svn: 33368
2007-01-19 20:27:35 +00:00
Andrew Lenharth
e082e2ac7f
fix build on amd64
...
llvm-svn: 33367
2007-01-19 20:17:59 +00:00
Evan Cheng
bf216c364f
isDarwin -> isTargetDarwin
...
llvm-svn: 33366
2007-01-19 19:28:01 +00:00
Evan Cheng
1199c2d653
Restructure code a bit to make use of continue (simplifying things). Generalize
...
the .zerofill directive emission to not be darwin-specific.
llvm-svn: 33365
2007-01-19 19:25:36 +00:00
Evan Cheng
023c7d667d
Darwin doesn't support .bss, but it does have .zerofill
...
llvm-svn: 33364
2007-01-19 19:23:47 +00:00
Evan Cheng
181fe36d6c
Introduce TargetType's ELF and Darwin.
...
llvm-svn: 33363
2007-01-19 19:22:40 +00:00
Evan Cheng
df62250cee
Modify emission of jump tables on darwin to emit an extra "l" label that
...
delimits the boundaries of jump tables. This lets the linker's dead code
stripping optimization do a better job.
llvm-svn: 33362
2007-01-19 18:59:56 +00:00
Evan Cheng
9201100b29
Remove this xform:
...
(shl (add x, c1), c2) -> (add (shl x, c2), c1<<c2)
Replace it with:
(add (shl (add x, c1), c2), ) -> (add (add (shl x, c2), c1<<c2), )
This fixes test/CodeGen/ARM/smul.ll
llvm-svn: 33361
2007-01-19 17:51:44 +00:00
Reid Spencer
e5f3de3896
Add the check for udis86 to support disassembly.
...
Regenerated for Anton Korobeynikov.
llvm-svn: 33360
2007-01-19 17:41:47 +00:00
Lauro Ramos Venancio
75aaf1fa6a
Fix section definition.
...
llvm-svn: 33359
2007-01-19 17:33:22 +00:00
Anton Korobeynikov
3e956974b3
Adding disassembler interface and external hook to udis86 library.
...
llvm-svn: 33358
2007-01-19 17:25:17 +00:00
Reid Spencer
49c6e09c7c
icmp doesn't support comparison of packed types.
...
llvm-svn: 33357
2007-01-19 17:11:12 +00:00
Zhou Sheng
ee187be5ca
Cover non-byte-width BATs situation.
...
llvm-svn: 33356
2007-01-19 14:30:59 +00:00
Zhou Sheng
a335d27e2b
Cover more arithmetics for arbitrary bitwidth integers.
...
llvm-svn: 33355
2007-01-19 14:26:57 +00:00
Evan Cheng
a5007faaa6
ARM test cases contributed by Apple.
...
llvm-svn: 33354
2007-01-19 09:20:23 +00:00
Evan Cheng
10043e215b
ARM backend contribution from Apple.
...
llvm-svn: 33353
2007-01-19 07:51:42 +00:00
Nick Lewycky
28c5b8618a
Needed to build on PPC Linux.
...
llvm-svn: 33352
2007-01-19 04:36:02 +00:00
Zhou Sheng
fb51713cef
Add one test case for Arbitrary BitWidth Integers.
...
llvm-svn: 33348
2007-01-19 01:35:08 +00:00
Reid Spencer
c043b437b3
Back out last changes for dataLayout. Much more work is needed.
...
llvm-svn: 33347
2007-01-19 00:07:16 +00:00
Reid Spencer
650d292f89
For PR761:
...
Implement reading and writing of the Module's data layout string.
llvm-svn: 33346
2007-01-18 23:24:24 +00:00
Evan Cheng
97057f37a5
- Target PIC style is no longer affected by relocation model.
...
- In x86-64 mode, symbols with external linkage (not just symbols which are
defined externally) requires GOT indirect reference.
- Stylistic code clean up.
llvm-svn: 33345
2007-01-18 22:27:12 +00:00
Chris Lattner
c8dc67c2da
remove an execution test from llvm/test
...
llvm-svn: 33344
2007-01-18 22:24:04 +00:00
Chris Lattner
120ab038eb
Fix InstCombine/2007-01-18-VectorInfLoop.ll, a case where instcombine
...
infinitely loops.
llvm-svn: 33343
2007-01-18 22:16:33 +00:00
Chris Lattner
bb4e2a547f
new testcase that causes instcombine to infinitely loop
...
llvm-svn: 33342
2007-01-18 22:16:03 +00:00
Reid Spencer
5cf93b411f
Update copyright for 2007.
...
llvm-svn: 33339
2007-01-18 21:33:56 +00:00
John Criswell
4a653fee80
Welcome 2007.
...
llvm-svn: 33338
2007-01-18 21:22:36 +00:00
Reid Spencer
c050af9126
Clean up some code around the store V, (cast P) -> store (cast V), P
...
transform. Change some variable names so it is clear what is source and
what is dest of the cast. Also, add an assert to ensure that the integer
to integer case is asserting if the bitwidths are different. This prevents
illegal casts from being formed and catches bitwidth bugs sooner.
llvm-svn: 33337
2007-01-18 18:54:33 +00:00
Reid Spencer
f15cd5637b
Use a cheaper computation.
...
llvm-svn: 33336
2007-01-18 18:14:49 +00:00
Reid Spencer
726b68bc6e
Fix a regression in the last patch. When constructing a BitMask, be careful
...
not to overflow 64-bits and end up with a 0 mask. This caused i64 values to
always be stored as 0 with lots of consequential damage to nightly test.
llvm-svn: 33335
2007-01-18 18:01:32 +00:00
Chris Lattner
889d934d00
move contents of PR587 to here.
...
llvm-svn: 33333
2007-01-18 07:34:57 +00:00
Reid Spencer
2867a1d466
Provide an isPowerOf2ByteWidth method for the IntegerType class. This will
...
mostly be used by back ends that wish to distinguish between integer types
that fit evenly within a natural integer type and those that don't.
llvm-svn: 33328
2007-01-18 02:59:54 +00:00
Bill Wendling
a341fab0af
The zerofill directive needs a newline after it.
...
llvm-svn: 33327
2007-01-18 02:30:19 +00:00
Reid Spencer
f854f95a17
Use the new maskToBitWidth function to ensure that the results of
...
computations do not overflow the intended bit width.
llvm-svn: 33326
2007-01-18 02:12:51 +00:00
Reid Spencer
10fe0e0d48
Add an inline helper function that masks a GenericValue to a specified
...
bit width.
llvm-svn: 33325
2007-01-18 02:12:10 +00:00
Evan Cheng
4b8d03e084
Minor code clean up.
...
llvm-svn: 33323
2007-01-18 01:49:58 +00:00
Reid Spencer
300e7fcb55
Make shl instruction mask its result to the correct bitsize. This is
...
sufficient to get llvm-test/SingleSource/UnitTests/Integer/general-test.ll
working with lli in interpreter mode.
llvm-svn: 33321
2007-01-18 01:32:46 +00:00
Reid Spencer
fab44b682e
Two changes:
...
1. Fix logic for executeGEP. Only 32-bit and 64-bit integer types are
acceptable as indices.
2. Ensure that all integer cast operations truncate their result to the
integer size of the operand.
llvm-svn: 33318
2007-01-18 01:25:42 +00:00
Reid Spencer
01f7e06d8f
Make sure we truncate stored values to their bit width.
...
llvm-svn: 33317
2007-01-18 01:24:02 +00:00
Bill Wendling
e750f61ac5
Have the OutputBuffer take the is64Bit and isLittleEndian booleans.
...
llvm-svn: 33316
2007-01-18 01:23:11 +00:00
Chris Lattner
c1ea85b4c4
Modify emission of jump tables on darwin to emit an extra "l" label that
...
delimits the boundaries of jump tables. This lets the linker's dead code
stripping optimization do a better job.
llvm-svn: 33315
2007-01-18 01:15:58 +00:00