Commit 8a659d38 authored by Hannes Payer's avatar Hannes Payer Committed by Commit Bot

Derive kMaximumSlots in ConstructorBuiltins from kMaxRegularHeapObjectSize.

Bug: chromium:852420
Change-Id: I348dbf52bc43078861e40e8377257c8f9a2bc920
Reviewed-on: https://chromium-review.googlesource.com/c/1349242Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57791}
parent ca086a49
......@@ -31,7 +31,9 @@ class ConstructorBuiltins {
NameDictionary::kMaxRegularCapacity / 3 * 2;
private:
static const int kMaximumSlots = 0x8000;
static const int kMaximumSlots =
(kMaxRegularHeapObjectSize - FixedArray::kHeaderSize) / kPointerSize -
Context::MIN_CONTEXT_SLOTS - 1;
static const int kSmallMaximumSlots = 10;
// FastNewFunctionContext can only allocate closures which fit in the
......
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