mirror of
https://github.com/dart-lang/sdk
synced 2024-09-15 23:39:48 +00:00
[vm] Speed-up the stack overflow check as used by reload stress testing.
Avoid calling Function::ToFullyQualifiedCString when it is not needed. Change-Id: I7d8ed879bb47e5e06c456bec73e4e00ae0181cd1 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134241 Reviewed-by: Alexander Aprelev <aam@google.com> Commit-Queue: Ryan Macnak <rmacnak@google.com>
This commit is contained in:
parent
a1d232a9b4
commit
7c472c396c
|
@ -2248,8 +2248,8 @@ static void HandleStackOverflowTestCases(Thread* thread) {
|
|||
}
|
||||
}
|
||||
}
|
||||
if (FLAG_deoptimize_filter != nullptr || FLAG_stacktrace_filter != nullptr ||
|
||||
(FLAG_reload_every != 0)) {
|
||||
if ((FLAG_deoptimize_filter != nullptr) ||
|
||||
(FLAG_stacktrace_filter != nullptr) || (FLAG_reload_every != 0)) {
|
||||
DartFrameIterator iterator(thread,
|
||||
StackFrameIterator::kNoCrossThreadIteration);
|
||||
StackFrame* frame = iterator.NextFrame();
|
||||
|
@ -2264,8 +2264,12 @@ static void HandleStackOverflowTestCases(Thread* thread) {
|
|||
function = code.function();
|
||||
}
|
||||
ASSERT(!function.IsNull());
|
||||
const char* function_name = function.ToFullyQualifiedCString();
|
||||
ASSERT(function_name != nullptr);
|
||||
const char* function_name = nullptr;
|
||||
if ((FLAG_deoptimize_filter != nullptr) ||
|
||||
(FLAG_stacktrace_filter != nullptr)) {
|
||||
function_name = function.ToFullyQualifiedCString();
|
||||
ASSERT(function_name != nullptr);
|
||||
}
|
||||
if (!code.IsNull()) {
|
||||
if (!code.is_optimized() && FLAG_reload_every_optimized) {
|
||||
// Don't do the reload if we aren't inside optimized code.
|
||||
|
|
Loading…
Reference in a new issue