| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 #include "test/cctest/cctest.h" | 6 #include "test/cctest/cctest.h" |
| 7 | 7 |
| 8 #include "src/compiler/access-builder.h" | 8 #include "src/compiler/access-builder.h" |
| 9 #include "src/compiler/common-operator.h" | 9 #include "src/compiler/common-operator.h" |
| 10 #include "src/compiler/generic-node-inl.h" | 10 #include "src/compiler/generic-node-inl.h" |
| (...skipping 1937 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1948 loop->ReplaceInput(1, loop); // self loop, NTL. | 1948 loop->ReplaceInput(1, loop); // self loop, NTL. |
| 1949 | 1949 |
| 1950 Node* effect = graph.NewNode(common.EffectPhi(1), start, loop); | 1950 Node* effect = graph.NewNode(common.EffectPhi(1), start, loop); |
| 1951 effect->ReplaceInput(0, effect); | 1951 effect->ReplaceInput(0, effect); |
| 1952 | 1952 |
| 1953 Node* terminate = graph.NewNode(common.Terminate(1), effect, loop); | 1953 Node* terminate = graph.NewNode(common.Terminate(1), effect, loop); |
| 1954 Node* end = graph.NewNode(common.End(), terminate); | 1954 Node* end = graph.NewNode(common.End(), terminate); |
| 1955 | 1955 |
| 1956 graph.SetEnd(end); | 1956 graph.SetEnd(end); |
| 1957 | 1957 |
| 1958 Schedule* schedule = ComputeAndVerifySchedule(5, &graph); | 1958 Schedule* schedule = ComputeAndVerifySchedule(6, &graph); |
| 1959 BasicBlock* block = schedule->block(loop); | 1959 BasicBlock* block = schedule->block(loop); |
| 1960 CHECK_NE(NULL, loop); | 1960 CHECK_NE(NULL, loop); |
| 1961 CHECK_EQ(block, schedule->block(effect)); | 1961 CHECK_EQ(block, schedule->block(effect)); |
| 1962 CHECK_GE(block->rpo_number(), 0); | 1962 CHECK_GE(block->rpo_number(), 0); |
| 1963 } | 1963 } |
| 1964 | 1964 |
| 1965 #endif | 1965 #endif |
| OLD | NEW |