Commit 30cd2156 authored by Maya Lekova's avatar Maya Lekova Committed by Commit Bot

[async-await] Remove await optimization flag

This CL removes the await-optimization-flag, that is no longer needed,
since the feature is considered web compatible.

Bug: v8:8267, chromium:893469
Change-Id: I046f003f9ed6853d713b825c436fe5f0a1e5a0a9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1630677Reviewed-by: 's avatarBenedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61834}
parent 3f07c825
......@@ -190,15 +190,7 @@ Node* AsyncBuiltinsAssembler::Await(Node* context, Node* generator, Node* value,
Label if_old(this), if_new(this), done(this),
if_slow_constructor(this, Label::kDeferred);
STATIC_ASSERT(sizeof(FLAG_harmony_await_optimization) == 1);
TNode<Word32T> flag_value = UncheckedCast<Word32T>(Load(
MachineType::Uint8(),
ExternalConstant(
ExternalReference::address_of_harmony_await_optimization_flag())));
GotoIf(Word32Equal(flag_value, Int32Constant(0)), &if_old);
// We're running with --harmony-await-optimization enabled, which means
// we do the `PromiseResolve(%Promise%,value)` avoiding to unnecessarily
// We do the `PromiseResolve(%Promise%,value)` avoiding to unnecessarily
// create wrapper promises. Now if {value} is already a promise with the
// intrinsics %Promise% constructor as its "constructor", we don't need
// to allocate the wrapper promise and can just use the `AwaitOptimized`
......
......@@ -412,11 +412,6 @@ ExternalReference ExternalReference::address_of_pending_message_obj(
FUNCTION_REFERENCE(abort_with_reason, i::abort_with_reason)
ExternalReference
ExternalReference::address_of_harmony_await_optimization_flag() {
return ExternalReference(&FLAG_harmony_await_optimization);
}
ExternalReference ExternalReference::address_of_min_int() {
return ExternalReference(reinterpret_cast<Address>(&double_min_int_constant));
}
......
......@@ -89,8 +89,6 @@ class StatsCounter;
V(address_of_double_neg_constant, "double_negate_constant") \
V(address_of_float_abs_constant, "float_absolute_constant") \
V(address_of_float_neg_constant, "float_negate_constant") \
V(address_of_harmony_await_optimization_flag, \
"FLAG_harmony_await_optimization") \
V(address_of_min_int, "LDoubleConstant::min_int") \
V(address_of_mock_arraybuffer_allocator_flag, \
"FLAG_mock_arraybuffer_allocator") \
......
......@@ -238,7 +238,6 @@ DEFINE_IMPLICATION(harmony_import_meta, harmony_dynamic_import)
V(harmony_dynamic_import, "harmony dynamic import") \
V(harmony_global, "harmony global") \
V(harmony_object_from_entries, "harmony Object.fromEntries()") \
V(harmony_await_optimization, "harmony await taking 1 tick") \
V(harmony_hashbang, "harmony hashbang syntax") \
V(harmony_numeric_separator, "harmony numeric separator between digits") \
V(harmony_promise_all_settled, "harmony Promise.allSettled")
......@@ -1127,7 +1126,6 @@ DEFINE_BOOL(trace_sim_messages, false,
// isolate.cc
DEFINE_BOOL(async_stack_traces, true,
"include async stack traces in Error.stack")
DEFINE_IMPLICATION(async_stack_traces, harmony_await_optimization)
DEFINE_BOOL(stack_trace_on_illegal, false,
"print stack trace when an illegal exception is thrown")
DEFINE_BOOL(abort_on_uncaught_exception, false,
......
......@@ -4232,7 +4232,6 @@ EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_dynamic_import)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_import_meta)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_numeric_separator)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_regexp_sequence)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_await_optimization)
EMPTY_INITIALIZE_GLOBAL_FOR_FEATURE(harmony_hashbang)
#ifdef V8_INTL_SUPPORT
......
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