| 
							
							
								 Evan Cheng | 93a8e5ea0c | Typo git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37566 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-13 00:04:00 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | cc8fb46cdc | Now if-converting all 4 variants of triangles. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37565 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-12 23:54:05 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 9618bcaf7d | Restructure code to reduce ifcvt compile time cost. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37543 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-11 22:26:22 +00:00 |  | 
			
				
					| 
							
							
								 Reid Spencer | a9bf49c7e3 | Fix the build. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37537 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-10 00:19:17 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 1c9f91d7b2 | Don't change CFG during analysis stage. Do so during ifcvt and invalidate predecessors accordingly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37531 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-09 01:03:43 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 7e75ba802e | Carefully remove extraneous CFG edges after each ifcvt. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37529 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-08 22:01:07 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 2acdbcccd8 | Correct transfer predicate information. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37524 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-08 19:17:12 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | edf4896a14 | Hidden options to help debugging ifcvt issues. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37523 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-08 19:10:51 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | ac5f142b9f | Allow more cmp / bcc to be predicated; clean up triangle ifcvt checking code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37518 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-08 09:36:04 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 27af5c414b | Only remove the edge from entry to false if false block is merged. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37503 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-07 22:31:28 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | f476961ae6 | ifcvt a triangle: don't merge ifcvt block with rejoin block if it can fall through to it. If merged, the resulting block is not a candidate for iterative ifcvting since it contains both predicated and non-predicated code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37487 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-07 08:13:00 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | d4de6d91b2 | Lots of bug fixes. Now finally in a reasonable state. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37485 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-07 02:12:15 +00:00 |  | 
			
				
					| 
							
							
								 Owen Anderson | 96dd9a8b1b | Quick patch to fix the build, based on what it appears Evan meant to write. Evan, please check that this is in fact correct.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37471 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-06 16:22:00 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 7a655479ae | Lots of bug fixes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37467 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-06 10:16:17 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 3d6f60ec19 | If a unconditional branch is added to branch to the false path during ifcvt, the predicated block cannot be iteratively ifcvted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37456 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-06 02:08:52 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | cb78d67a1a | Minor statistics counting bug. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37451 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-06 01:12:44 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | e705213b67 | Fix a couple of typos and be smarter about order of blocks when ifcvt a diamond. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37449 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-06 00:57:55 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 993fc9594e | Fix diamond shape ifcvt bugs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37444 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 23:46:14 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | a1a9f408da | ReplaceUsesOfBlockWith() can modify the predecessors list. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37441 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 22:03:53 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | e004317c66 | Do not ifcvt if either true / false path is a backedge. Not profitable in almost all cases. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37440 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 20:38:42 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | c53ef58a35 | I had a senior moment. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37433 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 07:05:25 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 8ed680cce3 | If the predicated block requires an early exit, end the block there and add a unconditional branch to false block. AnalyzeBranch() does not understand early exits. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37430 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 01:31:40 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | f5305f9cc7 | Fix some subtle bugs: bug during succeessor copying; incorrectly updating states of ifcvted blocks. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37429 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-05 00:07:37 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 3ec425470f | Forgot to check for if iterator reached the end. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37420 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-04 20:33:36 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | b6665f62c5 | Let IfConverter loose. Allow more aggressive subsumptions; reorder basic blocks to expose more ifcvt opportunities; code clean up and fixes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37409 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-04 06:47:22 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | b5a0690788 | Correctly mark early-exit on the false path. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37387 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-01 20:29:21 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 8c52938e44 | Ifcvt triangle: don't ifcvt 'true' BB if it has other predecessors; don't merge 'false' BB if it has other predecessors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37382 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-01 07:41:07 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | fe57a7e4df | Remove a bogus check. Even terminators in a ifcvt need to be predicated. Unconditional branches can usually be converted to conditional ones. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37380 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-01 00:55:26 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 5f70218c75 | Allow multiple ifcvt candidates to share children blocks; add some debugging code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37379 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-06-01 00:12:12 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | f15d44cc10 | Fix a typo. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37374 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-31 20:53:33 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 8258210ed4 | Change traversal order to bottom up in preparation for more aggressive if-conversion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37365 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-30 19:49:19 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 58fbb9f5ba | Don't merge in tail block of a diamond if it has more than one predecessors after if-conversion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37353 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-29 23:37:20 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | c8ed9badfa | If there is an empty block between a source and its successor block, it still requires a unconditional branch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37344 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-29 22:31:16 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 4bec8ae694 | Silly boog. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37328 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-25 00:59:01 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | a13aa95bc8 | Preliminary iterative if-conversion support. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37309 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-23 07:23:16 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | a6b4f43eaa | If-convert early exit blocks (returns, etc.); bug fixes, etc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37270 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-21 22:22:58 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 7f8ff8af1a | Clean up. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37237 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 19:32:08 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 36489bbbac | Change to depth-first traversal. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37236 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 19:26:33 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | cf6cc112d5 | Some restructuring in preparation for most aggressive if-conversion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37231 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 18:14:37 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 6092ca1556 | Watch out for blocks that end with a return. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37227 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 17:06:53 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 47d2502072 | If true / false blocks fallthrough before ifcvt, add unconditional branches to ifcvt'd block. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37200 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 01:55:58 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 86cbfea33b | Make use of target specific block size limits; bug fixes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37195 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-18 00:20:58 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | d6ddc308f0 | isBlockPredicable() always ignore terminal instructions; add comments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37126 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-16 21:54:37 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | c3a289c4b5 | Rename M_PREDICATED to M_PREDICABLE; Moved isPredicable() to MachineInstr. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37121 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-16 20:56:08 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | c5d05ef357 | Devang points out that we need an assertion here. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37097 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-16 05:11:10 +00:00 |  | 
			
				
					| 
							
							
								 Evan Cheng | 4e654852f1 | Initial commit of (very basic) if converter. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37092 91177308-0d34-0410-b5e6-96231b3b80d8 | 2007-05-16 02:00:57 +00:00 |  |