| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 2251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2262 | 2262 |
| 2263 if (current_block() != NULL) { | 2263 if (current_block() != NULL) { |
| 2264 HReturn* instr = new(zone()) HReturn(graph()->GetConstantUndefined()); | 2264 HReturn* instr = new(zone()) HReturn(graph()->GetConstantUndefined()); |
| 2265 current_block()->FinishExit(instr); | 2265 current_block()->FinishExit(instr); |
| 2266 set_current_block(NULL); | 2266 set_current_block(NULL); |
| 2267 } | 2267 } |
| 2268 } | 2268 } |
| 2269 | 2269 |
| 2270 graph()->OrderBlocks(); | 2270 graph()->OrderBlocks(); |
| 2271 graph()->AssignDominators(); | 2271 graph()->AssignDominators(); |
| 2272 graph()->EliminateRedundantPhis(); |
| 2272 if (!graph()->CheckPhis()) { | 2273 if (!graph()->CheckPhis()) { |
| 2273 Bailout("Unsupported phi use of arguments object"); | 2274 Bailout("Unsupported phi use of arguments object"); |
| 2274 return NULL; | 2275 return NULL; |
| 2275 } | 2276 } |
| 2276 graph()->EliminateRedundantPhis(); | |
| 2277 if (FLAG_eliminate_dead_phis) graph()->EliminateUnreachablePhis(); | 2277 if (FLAG_eliminate_dead_phis) graph()->EliminateUnreachablePhis(); |
| 2278 if (!graph()->CollectPhis()) { | 2278 if (!graph()->CollectPhis()) { |
| 2279 Bailout("Unsupported phi use of uninitialized constant"); | 2279 Bailout("Unsupported phi use of uninitialized constant"); |
| 2280 return NULL; | 2280 return NULL; |
| 2281 } | 2281 } |
| 2282 | 2282 |
| 2283 HInferRepresentation rep(graph()); | 2283 HInferRepresentation rep(graph()); |
| 2284 rep.Analyze(); | 2284 rep.Analyze(); |
| 2285 | 2285 |
| 2286 if (FLAG_use_range) { | 2286 if (FLAG_use_range) { |
| (...skipping 4023 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6310 } | 6310 } |
| 6311 } | 6311 } |
| 6312 | 6312 |
| 6313 #ifdef DEBUG | 6313 #ifdef DEBUG |
| 6314 if (graph_ != NULL) graph_->Verify(); | 6314 if (graph_ != NULL) graph_->Verify(); |
| 6315 if (allocator_ != NULL) allocator_->Verify(); | 6315 if (allocator_ != NULL) allocator_->Verify(); |
| 6316 #endif | 6316 #endif |
| 6317 } | 6317 } |
| 6318 | 6318 |
| 6319 } } // namespace v8::internal | 6319 } } // namespace v8::internal |
| OLD | NEW |