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

Extract precompile_inlinable_child_iseq to separate alloca for each iseq #4951

Merged
merged 1 commit into from
Oct 12, 2021

Conversation

nobu
Copy link
Member

@nobu nobu commented Oct 11, 2021

No description provided.

@nobu nobu requested a review from k0kubun October 11, 2021 13:27
@k0kubun
Copy link
Member

k0kubun commented Oct 11, 2021

separate alloca for each iseq

Could you elaborate more on this? Are you saying calling the same alloca multiple times in a single function call may cause problems? I'm not against carving out the function, but for future refactoring, I'd like to confirm whether it's mandatory or not.

@k0kubun
Copy link
Member

k0kubun commented Oct 12, 2021

Ah, I guess alloca continues to allocate another buffer instead of re-using the same buffer used by the previous alloca call, and the only way to release a buffer allocated by alloca is leaving a function that called it? Then this PR makes sense.

@nobu nobu merged commit 2143de2 into ruby:master Oct 12, 2021
@nobu nobu deleted the mjit-alloca branch October 12, 2021 08:12
@nobu
Copy link
Member Author

nobu commented Oct 12, 2021

Yes, that's right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants