Commit Graph

32200 Commits

Author SHA1 Message Date
Chris Lattner ca3b44aa57 add a new code
llvm-svn: 36462
2007-04-26 03:26:26 +00:00
Chris Lattner 44c1707207 add bitcode alias support
llvm-svn: 36461
2007-04-26 02:46:40 +00:00
Chris Lattner 6337d7b7c7 add alias support to bitcode
llvm-svn: 36460
2007-04-26 02:46:23 +00:00
Chris Lattner d2747054b4 print aliases before functions
llvm-svn: 36459
2007-04-26 02:24:10 +00:00
Evan Cheng 43a17fe826 Be careful when to add implicit kill / dead operands. Don't add them during / post reg-allocation.
llvm-svn: 36458
2007-04-26 01:40:09 +00:00
Evan Cheng d3d914b9f8 PR1348 test case.
llvm-svn: 36457
2007-04-26 01:14:14 +00:00
Evan Cheng ce6e6db704 Fix for PR1348. If stack inc / dec amount is > 32-bits, issue a series of add / sub instructions.
llvm-svn: 36456
2007-04-26 01:09:28 +00:00
Evan Cheng 9f12bc480b New test case.
llvm-svn: 36455
2007-04-26 00:07:36 +00:00
Bill Wendling 0be6fc5fd7 Quiet a compiler warning about assignment in an if-then conditional.
llvm-svn: 36454
2007-04-25 23:52:02 +00:00
Chris Lattner 2a4853b424 && no longer needed
llvm-svn: 36453
2007-04-25 22:32:55 +00:00
Evan Cheng 0ba174534c Match MachineFunction::UsedPhysRegs changes.
llvm-svn: 36452
2007-04-25 22:13:27 +00:00
Evan Cheng d21968d11a Change UsedPhysRegs from array bool to BitVector to save some space. Setting / getting its states now go through MachineFunction.
llvm-svn: 36451
2007-04-25 22:10:09 +00:00
Bill Wendling 9b8d17db61 Testcase for codegen bug.
llvm-svn: 36450
2007-04-25 21:58:17 +00:00
Evan Cheng d4549c5527 Clean up.
llvm-svn: 36449
2007-04-25 21:34:08 +00:00
Bill Wendling 157d7ee7e5 Add SSSE3 as a feature of Core2. Add MMX registers to the list of registers
clobbered by a call.

llvm-svn: 36448
2007-04-25 21:31:48 +00:00
Evan Cheng 0fbe14ab87 Data structure change to improve compile time (especially in debug mode).
llvm-svn: 36447
2007-04-25 19:34:00 +00:00
Devang Patel 7f7b8985f8 Mem2Reg does not need TargetData.
llvm-svn: 36446
2007-04-25 18:41:11 +00:00
Evan Cheng 15f269afa3 This was lefted out. Fixed sumarray-dbl.
llvm-svn: 36445
2007-04-25 18:33:21 +00:00
Devang Patel d3ccc073a2 Mem2Reg does not need TargetData.
llvm-svn: 36444
2007-04-25 18:32:35 +00:00
Anton Korobeynikov 5e4e8f5e09 Add missed semicolon. Resotre compatibility with older bisons
llvm-svn: 36443
2007-04-25 18:07:40 +00:00
Chris Lattner d20cd6658a do the multiplication as signed, so that 2*-2 == -4 instead of 4294967292
when promoted to 64-bits

llvm-svn: 36442
2007-04-25 17:23:53 +00:00
Devang Patel 073be55d8e Remove unused function argument.
llvm-svn: 36441
2007-04-25 17:15:20 +00:00
Jeff Cohen c7f7b5162f Note new header file.
llvm-svn: 36440
2007-04-25 17:13:18 +00:00
Anton Korobeynikov cb5b13a0b8 Add missed file
llvm-svn: 36439
2007-04-25 16:42:39 +00:00
Lauro Ramos Venancio 4ae9425bb6 remember to emit weak reference in one more case.
llvm-svn: 36438
2007-04-25 14:50:40 +00:00
Anton Korobeynikov e9fcbefa9a Regenerate
llvm-svn: 36437
2007-04-25 14:29:12 +00:00
Anton Korobeynikov a97b694c82 Implement aliases. This fixes PR1017 and it's dependent bugs. CFE part
will follow.

llvm-svn: 36435
2007-04-25 14:27:10 +00:00
Evan Cheng 7818c03c6b Fix for PR1306.
- A register def / use now implicitly affects sub-register liveness but does
not affect liveness information of super-registers.
- Def of a larger register (if followed by a use later) is treated as
read/mod/write of a smaller register.

llvm-svn: 36434
2007-04-25 07:30:23 +00:00
Evan Cheng 93e3a2e6f7 Test if a register is sub- or super-register of another.
llvm-svn: 36433
2007-04-25 07:24:50 +00:00
Evan Cheng 559fae748c Minor speed tweak.
llvm-svn: 36432
2007-04-25 07:24:13 +00:00
Evan Cheng 11dc5abde1 Clean up.
llvm-svn: 36431
2007-04-25 07:18:20 +00:00
Evan Cheng 8cd224e81c Relex assertions to account for additional implicit def / use operands.
llvm-svn: 36430
2007-04-25 07:12:14 +00:00
Chris Lattner 827cb98a0a If an alloca only has two types of uses: 1) reads 2) a memcpy/memmove that
copies from a constant global, then we can change the reads to read from the
global instead of from the alloca.  This eliminates the alloca and the memcpy,
and promotes secondary optimizations (because the loads are now loads from
a constant global).

This is important for a common C idiom:

void foo() {
   int A[] = {1,2,3,4,5,6,7,8,9...};
   ... only reads of A ...
}

For some reason, people forget to mark the array static or const.

This triggers on these multisource benchmarks:
JM/ldecode: block_pos, [3 x [4 x [4 x i32]]]
FreeBench/mason: m, [18 x i32], inlined 4 times
MiBench/office-stringsearch: search_strings, [1332 x i8*]
MiBench/office-stringsearch: find_strings, [1333 x i8*]
Prolangs-C++/city: dirs, [9 x i8*], inlined 4 places

and these spec benchmarks:
177.mesa: message, [8 x [32 x i8]]
186.crafty: bias_rl45, [64 x i32]
186.crafty: diag_sq, [64 x i32]
186.crafty: empty, [9 x i8]
186.crafty: xlate, [15 x i8]
186.crafty: status, [13 x i8]
186.crafty: bdinfo, [25 x i8]
445.gobmk: routines, [16 x i8*]
458.sjeng: piece_rep, [14 x i8*]
458.sjeng: t, [13 x i32], inlined 4 places.
464.h264ref: block8x8_idx, [3 x [4 x [4 x i32]]]
464.h264ref: block_pos, [3 x [4 x [4 x i32]]]
464.h264ref: j_off_tab, [12 x i32]

This implements Transforms/ScalarRepl/memcpy-from-global.ll

llvm-svn: 36429
2007-04-25 06:40:51 +00:00
Chris Lattner 7ebda6ba37 new testcase, should be able to eliminate the alloca and memcpy
llvm-svn: 36428
2007-04-25 06:29:34 +00:00
Chris Lattner bbe9b8a12f simplify some code
llvm-svn: 36427
2007-04-25 05:49:09 +00:00
Chris Lattner 31e5addb67 refactor the SROA code out into its own method, no functionality change.
llvm-svn: 36426
2007-04-25 05:02:56 +00:00
Chris Lattner b975bebec1 support for >4G stack frames
llvm-svn: 36425
2007-04-25 04:30:24 +00:00
Chris Lattner 868d969081 support for >4G frames
llvm-svn: 36424
2007-04-25 04:29:06 +00:00
Chris Lattner 1ef35a2721 support >4G stack frames
llvm-svn: 36423
2007-04-25 04:25:10 +00:00
Chris Lattner 9bd98ea4c1 support > 4G stack objects
llvm-svn: 36422
2007-04-25 04:20:54 +00:00
Owen Anderson 510fefcd8a Undo my previous changes. Since my approach to this problem is being revised,
this approach is no longer appropriate.

llvm-svn: 36421
2007-04-25 04:18:54 +00:00
Chris Lattner cb0ed0cfbd allow support for 64-bit stack objects
llvm-svn: 36420
2007-04-25 04:08:28 +00:00
Chris Lattner 7bf18ba0a2 allow 64-bit stack objects
llvm-svn: 36419
2007-04-25 04:07:31 +00:00
Chris Lattner 5ec45c5b90 new testcase
llvm-svn: 36418
2007-04-25 01:51:33 +00:00
Devang Patel d3208523b2 Fix
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070423/048376.html

llvm-svn: 36417
2007-04-25 00:37:04 +00:00
Devang Patel 206baa4425 New test.
llvm-svn: 36416
2007-04-25 00:35:37 +00:00
Chris Lattner d7c51e5423 testcase for PR1352
llvm-svn: 36415
2007-04-25 00:26:05 +00:00
Dale Johannesen 78dd0b2d3c fix typo
llvm-svn: 36414
2007-04-25 00:14:49 +00:00
Chris Lattner 01a26c74ae Be more careful about folding op(x, undef) when we have vector operands.
This fixes CodeGen/X86/2007-04-24-VectorCrash.ll

llvm-svn: 36413
2007-04-25 00:00:45 +00:00
Chris Lattner 61e8297c44 new testcase that crashes llc
llvm-svn: 36412
2007-04-25 00:00:12 +00:00