Commit 9ee6ca75 authored by mstarzinger's avatar mstarzinger Committed by Commit bot

[turbofan] Switch inlining tests to global scope.

This switches our inlining tests (i.e. cctest/test-run-inlining) to rely
on global object instead of function context specialization, which is
more in sync with what we are actually shipping. It will also allow us
to test inlining with the BytecodeGraphBuilder without having to add
support for function context specialization just for testing purposes.

R=bmeurer@chromium.org
TEST=cctest/test-run-inlining
BUG=v8:5251

Review-Url: https://codereview.chromium.org/2200673002
Cr-Commit-Position: refs/heads/master@{#38209}
parent 061d082d
...@@ -405,9 +405,7 @@ ...@@ -405,9 +405,7 @@
############################################################################## ##############################################################################
['ignition_turbofan', { ['ignition_turbofan', {
# TODO(rmcilroy,4837): Inlining is currently disabled for the BytecodeGraphBuilder # TODO(5251): Inlining is currently disabled for the BytecodeGraphBuilder.
# (see InliningPhase::Run). Also, we don't set a LoadContextSlot for a function as
# immutable in the BytecodeGraphBuilder, therefore no inlining happens.
'test-run-inlining/InlineLoopGuardedTwice': [FAIL], 'test-run-inlining/InlineLoopGuardedTwice': [FAIL],
'test-run-inlining/InlineSurplusArgumentsDeopt': [FAIL], 'test-run-inlining/InlineSurplusArgumentsDeopt': [FAIL],
'test-run-inlining/InlineTwice': [FAIL], 'test-run-inlining/InlineTwice': [FAIL],
......
...@@ -30,7 +30,7 @@ class FunctionTester : public InitializedHandleScope { ...@@ -30,7 +30,7 @@ class FunctionTester : public InitializedHandleScope {
flags_(flags) { flags_(flags) {
Compile(function); Compile(function);
const uint32_t supported_flags = const uint32_t supported_flags =
CompilationInfo::kFunctionContextSpecializing | CompilationInfo::kNativeContextSpecializing |
CompilationInfo::kInliningEnabled; CompilationInfo::kInliningEnabled;
CHECK_EQ(0u, flags_ & ~supported_flags); CHECK_EQ(0u, flags_ & ~supported_flags);
} }
...@@ -212,8 +212,8 @@ class FunctionTester : public InitializedHandleScope { ...@@ -212,8 +212,8 @@ class FunctionTester : public InitializedHandleScope {
CHECK(Parser::ParseStatic(info.parse_info())); CHECK(Parser::ParseStatic(info.parse_info()));
} }
info.SetOptimizing(); info.SetOptimizing();
if (flags_ & CompilationInfo::kFunctionContextSpecializing) { if (flags_ & CompilationInfo::kNativeContextSpecializing) {
info.MarkAsFunctionContextSpecializing(); info.MarkAsNativeContextSpecializing();
} }
if (flags_ & CompilationInfo::kInliningEnabled) { if (flags_ & CompilationInfo::kInliningEnabled) {
info.MarkAsInliningEnabled(); info.MarkAsInliningEnabled();
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment