diff --git a/patches/node.v18.14.1.cpp.patch b/patches/node.v18.14.1.cpp.patch index 8630297..5ba5040 100644 --- a/patches/node.v18.14.1.cpp.patch +++ b/patches/node.v18.14.1.cpp.patch @@ -1,3 +1,5 @@ +diff --git node/common.gypi node/common.gypi +index 5372c8d42d..4e2fb0ec2b 100644 --- node/common.gypi +++ node/common.gypi @@ -174,7 +174,7 @@ @@ -9,6 +11,22 @@ }, { 'lto': ' -flto ', # Clang }], +diff --git node/configure.py node/configure.py +index 62c01aaf6a..2913940692 100755 +--- node/configure.py ++++ node/configure.py +@@ -1288,9 +1288,7 @@ def configure_node(o): + + o['variables']['want_separate_host_toolset'] = int(cross_compiling) + +- # Enable branch protection for arm64 + if target_arch == 'arm64': +- o['cflags']+=['-msign-return-address=all'] + o['variables']['arm_fpu'] = options.arm_fpu or 'neon' + + if options.node_snapshot_main is not None: +diff --git node/deps/v8/include/v8-initialization.h node/deps/v8/include/v8-initialization.h +index 3d59c73f7c..00b2de4524 100644 --- node/deps/v8/include/v8-initialization.h +++ node/deps/v8/include/v8-initialization.h @@ -89,6 +89,10 @@ class V8_EXPORT V8 { @@ -22,6 +40,8 @@ /** Get the version string. */ static const char* GetVersion(); +diff --git node/deps/v8/src/api/api.cc node/deps/v8/src/api/api.cc +index 8d224bea2e..8402afc0fb 100644 --- node/deps/v8/src/api/api.cc +++ node/deps/v8/src/api/api.cc @@ -709,6 +709,29 @@ void V8::SetFlagsFromCommandLine(int* argc, char** argv, bool remove_flags) { @@ -54,6 +74,8 @@ RegisteredExtension* RegisteredExtension::first_extension_ = nullptr; RegisteredExtension::RegisteredExtension(std::unique_ptr extension) +diff --git node/deps/v8/src/codegen/compiler.cc node/deps/v8/src/codegen/compiler.cc +index a0d2e45ffc..3f29eb7cce 100644 --- node/deps/v8/src/codegen/compiler.cc +++ node/deps/v8/src/codegen/compiler.cc @@ -3026,7 +3026,7 @@ MaybeHandle GetSharedFunctionInfoForScriptImpl( @@ -65,6 +87,8 @@ compile_timer.set_hit_isolate_cache(); } else if (can_consume_code_cache) { compile_timer.set_consuming_code_cache(); +diff --git node/deps/v8/src/objects/js-function.cc node/deps/v8/src/objects/js-function.cc +index e8898a10eb..1ca40655cb 100644 --- node/deps/v8/src/objects/js-function.cc +++ node/deps/v8/src/objects/js-function.cc @@ -1207,6 +1207,9 @@ Handle JSFunction::ToString(Handle function) { @@ -77,6 +101,8 @@ ClassPositions class_positions = ClassPositions::cast(*maybe_class_positions); int start_position = class_positions.start(); +diff --git node/deps/v8/src/objects/shared-function-info-inl.h node/deps/v8/src/objects/shared-function-info-inl.h +index 6fffdf6b19..34cc72217b 100644 --- node/deps/v8/src/objects/shared-function-info-inl.h +++ node/deps/v8/src/objects/shared-function-info-inl.h @@ -636,6 +636,14 @@ bool SharedFunctionInfo::ShouldFlushCode( @@ -94,6 +120,8 @@ if (IsStressFlushingEnabled(code_flush_mode)) return true; BytecodeArray bytecode = BytecodeArray::cast(data); +diff --git node/deps/v8/src/parsing/parsing.cc node/deps/v8/src/parsing/parsing.cc +index add1f203f0..333a715ff0 100644 --- node/deps/v8/src/parsing/parsing.cc +++ node/deps/v8/src/parsing/parsing.cc @@ -42,6 +42,7 @@ bool ParseProgram(ParseInfo* info, Handle