Index: test/cctest/test-cpu-profiler.cc |
diff --git a/test/cctest/test-cpu-profiler.cc b/test/cctest/test-cpu-profiler.cc |
index 6eb1f0bbac6cd320f1ea29f585c20001fc784479..be2a8945d836ad1214c85030374a355a601e30ae 100644 |
--- a/test/cctest/test-cpu-profiler.cc |
+++ b/test/cctest/test-cpu-profiler.cc |
@@ -63,8 +63,8 @@ static size_t offset(const char* src, const char* substring) { |
return static_cast<size_t>(it - src); |
} |
-static const char* reason(const i::Deoptimizer::DeoptReason reason) { |
- return i::Deoptimizer::GetDeoptReason(reason); |
+static const char* reason(const i::DeoptimizeReason reason) { |
+ return i::DeoptimizeReasonToString(reason); |
} |
TEST(StartStop) { |
@@ -1853,21 +1853,21 @@ TEST(CollectDeoptEvents) { |
{ |
const char* branch[] = {"", "opt_function0", "opt_function0"}; |
- CHECK_EQ(reason(i::Deoptimizer::kNotAHeapNumber), |
+ CHECK_EQ(reason(i::DeoptimizeReason::kNotAHeapNumber), |
GetBranchDeoptReason(env, iprofile, branch, arraysize(branch))); |
} |
{ |
const char* branch[] = {"", "opt_function1", "opt_function1"}; |
const char* deopt_reason = |
GetBranchDeoptReason(env, iprofile, branch, arraysize(branch)); |
- if (deopt_reason != reason(i::Deoptimizer::kNaN) && |
- deopt_reason != reason(i::Deoptimizer::kLostPrecisionOrNaN)) { |
+ if (deopt_reason != reason(i::DeoptimizeReason::kNaN) && |
+ deopt_reason != reason(i::DeoptimizeReason::kLostPrecisionOrNaN)) { |
FATAL(deopt_reason); |
} |
} |
{ |
const char* branch[] = {"", "opt_function2", "opt_function2"}; |
- CHECK_EQ(reason(i::Deoptimizer::kDivisionByZero), |
+ CHECK_EQ(reason(i::DeoptimizeReason::kDivisionByZero), |
GetBranchDeoptReason(env, iprofile, branch, arraysize(branch))); |
} |
iprofiler->DeleteProfile(iprofile); |
@@ -1957,7 +1957,7 @@ TEST(DeoptAtFirstLevelInlinedSource) { |
CHECK_EQ(1U, deopt_infos.size()); |
const v8::CpuProfileDeoptInfo& info = deopt_infos[0]; |
- CHECK_EQ(reason(i::Deoptimizer::kNotAHeapNumber), info.deopt_reason); |
+ CHECK_EQ(reason(i::DeoptimizeReason::kNotAHeapNumber), info.deopt_reason); |
CHECK_EQ(2U, info.stack.size()); |
CHECK_EQ(inlined_script_id, info.stack[0].script_id); |
CHECK_EQ(offset(inlined_source, "left /"), info.stack[0].position); |
@@ -2030,7 +2030,7 @@ TEST(DeoptAtSecondLevelInlinedSource) { |
CHECK_EQ(1U, deopt_infos.size()); |
const v8::CpuProfileDeoptInfo info = deopt_infos[0]; |
- CHECK_EQ(reason(i::Deoptimizer::kNotAHeapNumber), info.deopt_reason); |
+ CHECK_EQ(reason(i::DeoptimizeReason::kNotAHeapNumber), info.deopt_reason); |
CHECK_EQ(3U, info.stack.size()); |
CHECK_EQ(inlined_script_id, info.stack[0].script_id); |
CHECK_EQ(offset(inlined_source, "left /"), info.stack[0].position); |