Chris Lattner
463c4a1ae9
add newline at end of file
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31287 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 23:47:01 +00:00
Chris Lattner
23d7b36117
add a highly efficient hash table that is specialized for mapping C strings
...
to some other type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31286 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 23:42:03 +00:00
Chris Lattner
9f617d64c5
Add a new llvm::Allocator abstraction, which will be used by a container
...
I'm about to add. This is similar to, but necessarily different than, the
STL allocator class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31285 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 22:08:03 +00:00
Chris Lattner
120bc21576
Fix SimplifyCFG/2006-10-29-InvokeCrash.ll, a crash compiling QT.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31284 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 21:21:20 +00:00
Chris Lattner
7c94454c56
new testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31283 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 21:20:56 +00:00
Chris Lattner
6b0e3f8907
Make CanFallThrough more intelligent (so it can handle blocks with (e.g.) no
...
successors), and make island block movement more general.
This compiles CodeGen/X86/2006-04-27-ISelFoldingBug.ll to:
_loadAndRLEsource_no_exit_2E_1_label_2E_0:
subl $8, %esp
movl %esi, 4(%esp)
movl %ebx, (%esp)
movl 16(%esp), %eax
movl 12(%esp), %ecx
LBB1_3: #label.0
movl _last, %edx
movl %edx, %esi
incl %esi
movl %esi, _last
movl %ecx, %ebx
# TRUNCATE movb %bl, %bl
movl _block, %esi
movb %bl, 1(%esi,%edx)
cmpl %eax, _last
jge LBB1_2 #codeRepl5.exitStub
LBB1_4: #label.0
cmpl $257, %ecx
je LBB1_2 #codeRepl5.exitStub
LBB1_1: #label.0.no_exit.1_crit_edge.exitStub
movl $1, %eax
movl (%esp), %ebx
movl 4(%esp), %esi
addl $8, %esp
ret
LBB1_2: #codeRepl5.exitStub
xorl %eax, %eax
movl (%esp), %ebx
movl 4(%esp), %esi
addl $8, %esp
ret
instead of:
_loadAndRLEsource_no_exit_2E_1_label_2E_0:
subl $8, %esp
movl %esi, 4(%esp)
movl %ebx, (%esp)
movl 16(%esp), %eax
movl 12(%esp), %ecx
jmp LBB1_3 #label.0
LBB1_1: #label.0.no_exit.1_crit_edge.exitStub
movl $1, %eax
movl (%esp), %ebx
movl 4(%esp), %esi
addl $8, %esp
ret
LBB1_2: #codeRepl5.exitStub
xorl %eax, %eax
movl (%esp), %ebx
movl 4(%esp), %esi
addl $8, %esp
ret
LBB1_3: #label.0
movl _last, %edx
movl %edx, %esi
incl %esi
movl %esi, _last
movl %ecx, %ebx
# TRUNCATE movb %bl, %bl
movl _block, %esi
movb %bl, 1(%esi,%edx)
cmpl %eax, _last
jge LBB1_2 #codeRepl5.exitStub
LBB1_4: #label.0
cmpl $257, %ecx
jne LBB1_1 #label.0.no_exit.1_crit_edge.exitStub
jmp LBB1_2 #codeRepl5.exitStub
... which is much better layout :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31282 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 21:05:41 +00:00
Chris Lattner
6a586c8d9a
fix Generic/2006-10-29-Crash.ll
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31281 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 21:01:20 +00:00
Chris Lattner
1bc33f7c81
new testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31280 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 21:00:55 +00:00
Chris Lattner
5a145f0094
Fix a load folding issue that Evan noticed: there is no need to export values
...
used by comparisons in the main block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31279 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 18:23:37 +00:00
Jim Laskey
a97c67c866
Try again.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31278 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 09:19:59 +00:00
Jim Laskey
d8cb446aa2
Not handling zero length strings.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31277 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 08:27:07 +00:00
Evan Cheng
ba726ab3ec
VLOAD is not the LoadSDNode opcode.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31276 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 06:14:47 +00:00
Nick Lewycky
f6aaaaa39e
Remove spurious case. EXTLOAD is not one of the node opcodes.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31275 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-29 02:26:30 +00:00
Chris Lattner
bad7f48c70
split critical edges more carefully and intelligently. In particular, critical
...
edges whose destinations are not phi nodes don't bother us. Also, share
split edges, since the split edge can't have a phi. This significantly
reduces the complexity of generated code in some cases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31274 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 19:22:10 +00:00
Chris Lattner
6acfe12dd6
Teach branch folding to fold identical jump tables together and to delete
...
jump tables that are dead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31273 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:34:47 +00:00
Chris Lattner
c4aacac056
add an assertion
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31272 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:21:51 +00:00
Chris Lattner
5f8d61bbd8
remove dead method
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31271 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:21:29 +00:00
Chris Lattner
4976dfb4b9
add a method for hacking on JTIdx's
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31270 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:18:36 +00:00
Chris Lattner
a4eb44a285
const'ify jump table stuff
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31269 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:17:09 +00:00
Chris Lattner
95e4786a76
add a method for deleting dead jump tables.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31268 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:12:00 +00:00
Chris Lattner
e7251a0377
add an assert
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31267 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:11:20 +00:00
Chris Lattner
0737188220
don't print dead jump tables
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31266 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:10:06 +00:00
Chris Lattner
5bd0c00b80
determine whether a change was made
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31265 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 18:00:05 +00:00
Chris Lattner
ef13982aa7
implement the BlockHasNoFallThrough hook
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31264 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:35:02 +00:00
Chris Lattner
cf420cca57
improve deletion of blocks that just contain branches by knowing that
...
the pred block doesn't fall through into them if it's a jumptable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31263 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:32:47 +00:00
Chris Lattner
c24ff8ed12
add another target hook for branch folding.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31262 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:29:57 +00:00
Jim Laskey
1c6f01aaa5
Load and stores have not been uniqued properly.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31261 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:25:28 +00:00
Chris Lattner
47e32e6b83
Split *all* critical edges before isel. This resolves issues with spill code
...
being inserted on unsplit critical edges, which introduces (sometimes large
amounts of) partially dead spill code.
This also fixes PR925 + CodeGen/Generic/switch-crit-edge-constant.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31260 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:04:37 +00:00
Chris Lattner
49bb78ce9f
new testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31259 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 17:04:16 +00:00
Chris Lattner
b57de3328d
add option to isCriticalEdge
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31258 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 06:58:17 +00:00
Chris Lattner
0997fadc37
break edges more intelligently
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31257 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 06:45:33 +00:00
Chris Lattner
27e1f90d85
Expose a smarter way to break critical edges.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31256 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 06:44:56 +00:00
Chris Lattner
f6de8ad1a2
SplitCriticalEdge checks to see if an edge is critical, don't check twice
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31255 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 06:38:14 +00:00
Chris Lattner
6fb6ef4d65
Fix a serious bug that caused any x86 vector stuff to infinite loop
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31254 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 06:15:26 +00:00
Evan Cheng
31b6ddad31
Doh. Must check if GV is constant first before putting it in .cstring.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31253 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 05:56:51 +00:00
Evan Cheng
71aae62445
Doh. Must check if GV is constant first.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31252 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 05:56:06 +00:00
Nick Lewycky
7a2ed81f08
Emitting raw bytecode is awfully rude. Add -disable-output.
...
Clarify the test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31251 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 02:34:41 +00:00
Jim Laskey
1fb8e15424
Editorial clean up.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31250 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 01:34:21 +00:00
Chris Lattner
7466ebf045
add a method
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31249 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 01:24:05 +00:00
Chris Lattner
1b9c8e73b5
prepare for a change I'm about to make
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31248 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 00:59:20 +00:00
Chris Lattner
ae2650a9cf
don't dist internal readme
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31247 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 00:51:15 +00:00
Chris Lattner
985384c41d
don't dist internal readme's
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31246 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 00:49:54 +00:00
Chris Lattner
064fdccf98
don't distribute internal readme's
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31245 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 00:48:27 +00:00
Reid Spencer
b9112019de
Make sure all the readme files get distributed.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31244 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-28 00:11:39 +00:00
Jim Laskey
def69b92e7
Clean up.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31243 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 23:52:51 +00:00
Chris Lattner
8c494ab759
Fix a bug in merged condition handling (CodeGen/Generic/2006-10-27-CondFolding.ll).
...
Add many fewer CFG edges and PHI node entries. If there is a switch which has
the same block as multiple destinations, only add that block once as a successor/phi
node (in the jumptable case)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31242 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 23:50:33 +00:00
Chris Lattner
0d824c3fe1
new testcase
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31241 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 23:47:34 +00:00
Jim Laskey
583bd47f77
Switch over from SelectionNodeCSEMap to FoldingSet.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31240 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 23:46:08 +00:00
Devang Patel
682f675c86
Use doc_code class.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31239 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 23:06:27 +00:00
Jim Laskey
2f6d4c9766
Clean up
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31238 91177308-0d34-0410-b5e6-96231b3b80d8
2006-10-27 22:52:02 +00:00