Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: restore initial heap limit automatically #220

Merged
merged 1 commit into from
Jan 12, 2023

Conversation

legendecas
Copy link
Member

No description provided.

Copy link
Member

@hyj1991 hyj1991 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGTM

@codecov
Copy link

codecov bot commented Jan 12, 2023

Codecov Report

Merging #220 (223ee1d) into master (623b0d2) will not change coverage.
The diff coverage is n/a.

❗ Current head 223ee1d differs from pull request most recent head f2c3de8. Consider uploading reports for the commit f2c3de8 to get more accurate results

@@            Coverage Diff            @@
##            master      #220   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           10        10           
  Lines          318       318           
=========================================
  Hits           318       318           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@hyj1991 hyj1991 merged commit 2fbfea0 into X-Profiler:master Jan 12, 2023
isolate->AddNearHeapLimitCallback(NearHeapLimitCallback,
static_cast<void*>(&thread_id));
static_cast<void*>(env_data));
isolate->AutomaticallyRestoreInitialHeapLimit();
Copy link
Member

@hyj1991 hyj1991 Jan 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cc @barretlee 这里当 heap 实际使用小于初始 limit size * 0.5 后,会自动重设回 initial heap limit,下个版本即可支持

@legendecas legendecas deleted the restore-initial-heap-limit branch January 12, 2023 07:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants