Commit 1af5bac4 authored by Patrick Thier's avatar Patrick Thier Committed by V8 LUCI CQ

[sparkplug] Batch compilation: Increase initial queue capacity

- Increase initial queue capacity from 4 to 32 to reduce growing/copying
of the queue.
- In addition remove the HandleScopes to reduce overhead.
The only caller (BytecodeBudgetInterruptFromBytecode) already
creates one.

Bug: v8:11790
Change-Id: I33cb9222706f9b349c56a7ea14142a930b8ecbf8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2982012Reviewed-by: 's avatarToon Verwaest <verwaest@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Cr-Commit-Position: refs/heads/master@{#75345}
parent c539f80e
......@@ -37,7 +37,6 @@ BaselineBatchCompiler::~BaselineBatchCompiler() {
}
bool BaselineBatchCompiler::EnqueueFunction(Handle<JSFunction> function) {
HandleScope scope(isolate_);
Handle<SharedFunctionInfo> shared(function->shared(), isolate_);
// Early return if the function is compiled with baseline already or it is not
// suitable for baseline compilation.
......@@ -102,7 +101,6 @@ void BaselineBatchCompiler::EnsureQueueCapacity() {
}
void BaselineBatchCompiler::CompileBatch(Handle<JSFunction> function) {
HandleScope scope(isolate_);
CodePageCollectionMemoryModificationScope batch_allocation(isolate_->heap());
{
IsCompiledScope is_compiled_scope(
......
......@@ -14,7 +14,7 @@ namespace baseline {
class BaselineBatchCompiler {
public:
static const int kInitialQueueSize = 4;
static const int kInitialQueueSize = 32;
explicit BaselineBatchCompiler(Isolate* isolate);
~BaselineBatchCompiler();
......
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