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

config: remove SLJIT_EXEC_OFFSET from list of required macros for an external allocator #143

Merged
merged 1 commit into from
Dec 1, 2022

Conversation

carenas
Copy link
Contributor

@carenas carenas commented Nov 30, 2022

Since it is only required as part of "protexec", it shouldn't need to be provided also by external allocators.

Expand the fallback definition, so that the only two macros that are required are the ones that point to the external functions to allocate and free executable memory.

Keep using one if it is already provided for backward compatibility.

sljit_src/sljitConfig.h Outdated Show resolved Hide resolved
SLJIT_EXEC_OFFSET is a definition that is only implemented internally
by the allocator selected with SLJIT_PROT_EXECUTABLE_ALLOCATOR.

Expand the fallback definition also for cases when an external
allocator is in use, to simplify the interface, but continue using
it if already defined, for backward compatibility.
Copy link
Owner

@zherczeg zherczeg left a comment

Choose a reason for hiding this comment

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

LGTM

We could think about more consistent names, such as everything starts with SLJIT_EXEC_ or similar prefix.

@zherczeg zherczeg merged commit 4b8798e into zherczeg:master Dec 1, 2022
@carenas carenas deleted the noalloc branch December 1, 2022 07:30
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