Skip to content

gh-140421: Fix perf trampoline on older macOS#140422

Closed
jmroot wants to merge 2 commits into
python:mainfrom
jmroot:macos-perf
Closed

gh-140421: Fix perf trampoline on older macOS#140422
jmroot wants to merge 2 commits into
python:mainfrom
jmroot:macos-perf

Conversation

@jmroot

@jmroot jmroot commented Oct 21, 2025

Copy link
Copy Markdown
Contributor
  • Use mach_absolute_time() when clock_gettime() is not available.
  • Define MAP_ANONYMOUS to MAP_ANON if the latter is defined and the former is not. This matches what is done elsewhere in the code base in this situation, e.g. mmapmodule.c.
  • Don't build perf trampoline on ppc systems, where getting this to work would be a lot more effort.

* Use mach_absolute_time() when clock_gettime() is not available.
* Define MAP_ANONYMOUS to MAP_ANON if the latter is defined and the
  former is not. This matches what is done elsewhere in the code base
  in this situation, e.g. mmapmodule.c.
* Don't build perf trampoline on ppc systems, where getting this to
  work would be a lot more effort.
@hugovk

hugovk commented Nov 11, 2025

Copy link
Copy Markdown
Member

Closing, see #140421 (comment).

@barracuda156

Copy link
Copy Markdown

@hugovk A lack of support from Apple doesn’t really mean that open-source projects should pro-actively sabotage the code which could otherwise work perfectly fine.

@barracuda156

Copy link
Copy Markdown

@jmroot This is closed anyway, but could you remind what was the issue specifically on ppc (as opposed to old x86)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants