From 1b759f40bd2f6bb72b2a353f0d9856fcbdbb981c Mon Sep 17 00:00:00 2001 From: Mike Duminy <4092035+mikeduminy@users.noreply.github.com> Date: Tue, 28 Feb 2023 18:22:43 -0800 Subject: [PATCH] Increase default max stack size (#923) Summary: As discussed in https://github.com/facebook/hermes/issues/135, the default stack size doesn't work for all use cases. In particular, when very large and complex bundles are loaded in dev mode. This PR bumps the default stack size from `64*1024` (512kB) to `128*1024` (1MB). As suggested by tmikov in this comment - https://github.com/facebook/hermes/issues/135#issuecomment-1444984528. Pull Request resolved: https://github.com/facebook/hermes/pull/923 Reviewed By: tmikov Differential Revision: D43630032 Pulled By: neildhar fbshipit-source-id: 5f8cff91a5f01b6507870c61efa1ce507de67940 --- public/hermes/Public/RuntimeConfig.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/hermes/Public/RuntimeConfig.h b/public/hermes/Public/RuntimeConfig.h index a61a37d7f12..7c2e0177923 100644 --- a/public/hermes/Public/RuntimeConfig.h +++ b/public/hermes/Public/RuntimeConfig.h @@ -35,7 +35,7 @@ class PinnedHermesValue; F(constexpr, PinnedHermesValue *, RegisterStack, nullptr) \ \ /* Register Stack Size */ \ - F(constexpr, unsigned, MaxNumRegisters, 64 * 1024) \ + F(constexpr, unsigned, MaxNumRegisters, 128 * 1024) \ \ /* Whether to allow eval and Function ctor */ \ F(constexpr, bool, EnableEval, true) \