Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 330374d

Browse files
committedOct 22, 2024
src,lib: reducing C++ calls of esm legacy main resolve
nodejs/node#48325
1 parent eec2141 commit 330374d

2 files changed

+9
-9
lines changed
 

‎patches/node/fix_revert_src_lb_reducing_c_calls_of_esm_legacy_main_resolve.patch

+7-7
Original file line numberDiff line numberDiff line change
@@ -133,25 +133,25 @@ index f3dad958b2ec275992554477b9344214c8c1e2c8..870af88c7dfb3174816a933912fee737
133133

134134
const encodedSepRegEx = /%2F|%5C/i;
135135
diff --git a/src/node_file.cc b/src/node_file.cc
136-
index 0bb70eb0fcd42ddf4d5e585065cf1ad8e74faab3..e4b8bc27390013d1374f454c200f4e7607210f58 100644
136+
index 0bb70eb0fcd42ddf4d5e585065cf1ad8e74faab3..b565beae625d970ba92ab667a145d8897d4e8a6e 100644
137137
--- a/src/node_file.cc
138138
+++ b/src/node_file.cc
139-
@@ -19,14 +19,11 @@
139+
@@ -19,14 +19,12 @@
140140
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
141141
// USE OR OTHER DEALINGS IN THE SOFTWARE.
142142
#include "node_file.h" // NOLINT(build/include_inline)
143143
-#include "ada.h"
144144
#include "aliased_buffer-inl.h"
145145
#include "memory_tracker-inl.h"
146146
#include "node_buffer.h"
147-
-#include "node_errors.h"
147+
#include "node_errors.h"
148148
#include "node_external_reference.h"
149149
#include "node_file-inl.h"
150150
-#include "node_metadata.h"
151151
#include "node_process-inl.h"
152152
#include "node_stat_watcher.h"
153153
#include "node_url.h"
154-
@@ -3208,146 +3205,6 @@ constexpr std::array<std::string_view, 10> legacy_main_extensions = {
154+
@@ -3208,146 +3206,6 @@ constexpr std::array<std::string_view, 10> legacy_main_extensions = {
155155

156156
} // namespace
157157

@@ -298,7 +298,7 @@ index 0bb70eb0fcd42ddf4d5e585065cf1ad8e74faab3..e4b8bc27390013d1374f454c200f4e76
298298

299299
void BindingData::MemoryInfo(MemoryTracker* tracker) const {
300300
tracker->TrackField("stats_field_array", stats_field_array);
301-
@@ -3448,19 +3305,6 @@ InternalFieldInfoBase* BindingData::Serialize(int index) {
301+
@@ -3448,19 +3306,6 @@ InternalFieldInfoBase* BindingData::Serialize(int index) {
302302
return info;
303303
}
304304

@@ -318,15 +318,15 @@ index 0bb70eb0fcd42ddf4d5e585065cf1ad8e74faab3..e4b8bc27390013d1374f454c200f4e76
318318
static void CreatePerIsolateProperties(IsolateData* isolate_data,
319319
Local<ObjectTemplate> target) {
320320
Isolate* isolate = isolate_data->isolate();
321-
@@ -3520,7 +3364,6 @@ static void CreatePerIsolateProperties(IsolateData* isolate_data,
321+
@@ -3520,7 +3365,6 @@ static void CreatePerIsolateProperties(IsolateData* isolate_data,
322322
SetMethod(isolate, target, "cpSyncCheckPaths", CpSyncCheckPaths);
323323

324324
StatWatcher::CreatePerIsolateProperties(isolate_data, target);
325325
- BindingData::CreatePerIsolateProperties(isolate_data, target);
326326

327327
target->Set(
328328
FIXED_ONE_BYTE_STRING(isolate, "kFsStatsFieldsNumber"),
329-
@@ -3593,7 +3436,6 @@ BindingData* FSReqBase::binding_data() {
329+
@@ -3593,7 +3437,6 @@ BindingData* FSReqBase::binding_data() {
330330
void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
331331
registry->Register(Access);
332332
StatWatcher::RegisterExternalReferences(registry);

‎patches/node/src_stop_using_deprecated_fields_of_fastapicallbackoptions.patch

+2-2
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@ index 4dbdea9be5721486d71a9dda77311b4919d450a3..4aacaa2a5d12533a039b4b96cb7f1fd7
4040
}
4141
HistogramBase* histogram;
4242
diff --git a/src/node_file.cc b/src/node_file.cc
43-
index b565beae625d970ba92ab667a145d8897d4e8a6e..31c2fe82299d6905855c4efffeea4a4d161a88d5 100644
43+
index b565beae625d970ba92ab667a145d8897d4e8a6e..b61f3ef87d6095fc2d4c015df2af32bfba697e76 100644
4444
--- a/src/node_file.cc
4545
+++ b/src/node_file.cc
46-
@@ -1049,23 +1049,10 @@ static int32_t FastInternalModuleStat(
46+
@@ -1049,22 +1049,8 @@ static int32_t FastInternalModuleStat(
4747
const FastOneByteString& input,
4848
// NOLINTNEXTLINE(runtime/references) This is V8 api.
4949
FastApiCallbackOptions& options) {

0 commit comments

Comments
 (0)
Please sign in to comment.