Skip to content

Commit

Permalink
Address Brandt's feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
diegorusso committed Nov 9, 2024
1 parent 507e662 commit 138525d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Improve JIT performance by 1.4% on macOS Apple Silicon. Patch by Diego Russo.
Improve JIT performance by 1.4% on macOS Apple Silicon by using platform-specific memory protection APIs. Patch by Diego Russo.
4 changes: 2 additions & 2 deletions Python/jit.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,9 @@ mark_executable(unsigned char *memory, size_t size)
#else
int failed = 0;
__builtin___clear_cache((char *)memory, (char *)memory + size);
# ifndef MAP_JIT
#ifndef MAP_JIT
failed = mprotect(memory, size, PROT_EXEC | PROT_READ);
# endif
#endif
#endif
if (failed) {
jit_error("unable to protect executable memory");
Expand Down

0 comments on commit 138525d

Please sign in to comment.