SERVER-100429 Upgrade MozJS to ESR 115.20 (#33515)

GitOrigin-RevId: afd51a82954b7bcec9b1cc43a6cc6dbf6e1e7966
This commit is contained in:
Mariano Shaar 2025-03-13 15:09:22 -04:00 committed by MongoDB Bot
parent dacf51c50a
commit 6f5be50231
27 changed files with 71 additions and 63 deletions

View File

@ -51,7 +51,7 @@ a notice will be included in
| [libunwind/libunwind] | MIT | v1.8.1 | | ✗ | | [libunwind/libunwind] | MIT | v1.8.1 | | ✗ |
| [linenoise] | BSD-2-Clause | Unknown | | ✗ | | [linenoise] | BSD-2-Clause | Unknown | | ✗ |
| [MongoDB C Driver] | Apache-2.0 | 1.27.6 | ✗ | ✗ | | [MongoDB C Driver] | Apache-2.0 | 1.27.6 | ✗ | ✗ |
| [Mozilla Firefox] | MPL-2.0 | 115.19.0esr | unknown | ✗ | | [Mozilla Firefox] | MPL-2.0 | 115.20.0esr | unknown | ✗ |
| [nlohmann.json.decomposed] | MIT | 3.10.5 | unknown | | | [nlohmann.json.decomposed] | MIT | 3.10.5 | unknown | |
| [node] | ISC | 22.1.0 | unknown | | | [node] | ISC | 22.1.0 | unknown | |
| [ocspbuilder] | MIT | 0.10.2 | | | | [ocspbuilder] | MIT | 0.10.2 | | |

View File

@ -1234,7 +1234,7 @@
"name": "Organization: debian" "name": "Organization: debian"
}, },
"name": "Mozilla Firefox", "name": "Mozilla Firefox",
"version": "115.19.0esr", "version": "115.20.0esr",
"licenses": [ "licenses": [
{ {
"license": { "license": {
@ -1242,7 +1242,7 @@
} }
} }
], ],
"purl": "pkg:deb/debian/firefox-esr@115.19.0esr-1", "purl": "pkg:deb/debian/firefox-esr@115.20.0esr-1",
"properties": [ "properties": [
{ {
"name": "internal:team_responsible", "name": "internal:team_responsible",

View File

@ -1268,6 +1268,9 @@ class Label {
#define v8_flags js::jit::JitOptions #define v8_flags js::jit::JitOptions
// MONGODB MODIFICATION: Fall back to switch-based interpreters in MSVC.
// For more information, read the comment in
// https://github.com/mongodb-forks/spidermonkey/commit/880a295fe2b219b5488529ce7ac01364678f6a4b.
#ifndef NO_COMPUTED_GOTO #ifndef NO_COMPUTED_GOTO
# define V8_USE_COMPUTED_GOTO 1 # define V8_USE_COMPUTED_GOTO 1
#else #else

View File

@ -1223,11 +1223,16 @@ ScriptSource::PinnedUnits<Unit>::PinnedUnits(
: PinnedUnitsBase(source) { : PinnedUnitsBase(source) {
MOZ_ASSERT(source->hasSourceType<Unit>(), "must pin units of source's type"); MOZ_ASSERT(source->hasSourceType<Unit>(), "must pin units of source's type");
units_ = source->units<Unit>(cx, holder, begin, len); {
if (units_) {
auto guard = source->readers_.lock(); auto guard = source->readers_.lock();
guard->count++; guard->count++;
} }
units_ = source->units<Unit>(cx, holder, begin, len);
if (!units_) {
auto guard = source->readers_.lock();
guard->count--;
}
} }
template class ScriptSource::PinnedUnits<Utf8Unit>; template class ScriptSource::PinnedUnits<Utf8Unit>;

View File

@ -8,9 +8,9 @@ set -vx
NAME=spidermonkey NAME=spidermonkey
VERSION="115.19.0esr" VERSION="115.20.0esr"
LIB_GIT_BRANCH=spidermonkey-esr115.19-cpp-only LIB_GIT_BRANCH=spidermonkey-esr115.20-cpp-only
LIB_GIT_REVISION=4c197344dfc48dfbbd242333878f17f0379e6205 LIB_GIT_REVISION=505753091ba01adc1d640039a4bfee3493efb026
LIB_GIT_REPO=git@github.com:mongodb-forks/spidermonkey.git LIB_GIT_REPO=git@github.com:mongodb-forks/spidermonkey.git
DEST_DIR=$(git rev-parse --show-toplevel)/src/third_party/mozjs DEST_DIR=$(git rev-parse --show-toplevel)/src/third_party/mozjs

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

View File

@ -7,7 +7,7 @@
#define js_confdefs_h #define js_confdefs_h
// Expands to all the defines from configure. // Expands to all the defines from configure.
#define CROSS_COMPILE #define CROSS_COMPILE
#define ENABLE_SHARED_MEMORY 1 #define ENABLE_SHARED_MEMORY 1
#define ENABLE_WASM_EXTENDED_CONST 1 #define ENABLE_WASM_EXTENDED_CONST 1
#define HAVE_64BIT_BUILD 1 #define HAVE_64BIT_BUILD 1
@ -55,10 +55,10 @@
#define MALLOC_H <malloc/malloc.h> #define MALLOC_H <malloc/malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 1 #define MOZ_AARCH64_JSCVT 1
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -7,7 +7,7 @@
#define js_confdefs_h #define js_confdefs_h
// Expands to all the defines from configure. // Expands to all the defines from configure.
#define CROSS_COMPILE #define CROSS_COMPILE
#define ENABLE_SHARED_MEMORY 1 #define ENABLE_SHARED_MEMORY 1
#define ENABLE_WASM_EXTENDED_CONST 1 #define ENABLE_WASM_EXTENDED_CONST 1
#define HAVE_64BIT_BUILD 1 #define HAVE_64BIT_BUILD 1
@ -55,10 +55,10 @@
#define MALLOC_H <malloc/malloc.h> #define MALLOC_H <malloc/malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 1 #define MOZ_AARCH64_JSCVT 1
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -71,10 +71,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

File diff suppressed because one or more lines are too long

View File

@ -72,10 +72,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,10 +72,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR #define MALLOC_USABLE_SIZE_CONST_PTR
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

View File

@ -7,7 +7,7 @@
#define js_confdefs_h #define js_confdefs_h
// Expands to all the defines from configure. // Expands to all the defines from configure.
#define CROSS_COMPILE #define CROSS_COMPILE
#define ENABLE_SHARED_MEMORY 1 #define ENABLE_SHARED_MEMORY 1
#define ENABLE_WASM_EXTENDED_CONST 1 #define ENABLE_WASM_EXTENDED_CONST 1
#define HAVE_64BIT_BUILD 1 #define HAVE_64BIT_BUILD 1
@ -56,10 +56,10 @@
#define MALLOC_H <malloc/malloc.h> #define MALLOC_H <malloc/malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -7,7 +7,7 @@
#define js_confdefs_h #define js_confdefs_h
// Expands to all the defines from configure. // Expands to all the defines from configure.
#define CROSS_COMPILE #define CROSS_COMPILE
#define ENABLE_SHARED_MEMORY 1 #define ENABLE_SHARED_MEMORY 1
#define ENABLE_WASM_EXTENDED_CONST 1 #define ENABLE_WASM_EXTENDED_CONST 1
#define HAVE_64BIT_BUILD 1 #define HAVE_64BIT_BUILD 1
@ -56,10 +56,10 @@
#define MALLOC_H <malloc/malloc.h> #define MALLOC_H <malloc/malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "lib" #define MOZ_DLL_PREFIX "lib"

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */

View File

@ -30,10 +30,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "" #define MOZ_DLL_PREFIX ""

View File

@ -30,10 +30,10 @@
#define MALLOC_H <malloc.h> #define MALLOC_H <malloc.h>
#define MALLOC_USABLE_SIZE_CONST_PTR const #define MALLOC_USABLE_SIZE_CONST_PTR const
#define MOZILLA_UAVERSION "115.0" #define MOZILLA_UAVERSION "115.0"
#define MOZILLA_VERSION "115.20.0" #define MOZILLA_VERSION "115.21.0"
#define MOZILLA_VERSION_U 115.20.0 #define MOZILLA_VERSION_U 115.21.0
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#define MOZ_AARCH64_JSCVT 0 #define MOZ_AARCH64_JSCVT 0
#define MOZ_BUILD_APP js #define MOZ_BUILD_APP js
#define MOZ_DLL_PREFIX "" #define MOZ_DLL_PREFIX ""

View File

@ -72,6 +72,6 @@
/* MOZILLA JSAPI version number components */ /* MOZILLA JSAPI version number components */
#define MOZJS_MAJOR_VERSION 115 #define MOZJS_MAJOR_VERSION 115
#define MOZJS_MINOR_VERSION 20 #define MOZJS_MINOR_VERSION 21
#endif /* js_config_h */ #endif /* js_config_h */