Ronald Oussoren <ronaldousso...@mac.com> added the comment:

> If we want to respect sizeof(max_align_t) alignment, we can compute 
> sizeof(max_align_t) in configure and uses the result in obmalloc.c. I expect 
> that it's either 16 or 32, so we can maybe just hardcode ALIGNMENT_SHIFT 
> using something like: "if == 32 ... #elif == 16 ... #else #error ...".

This should be "alignof(max_align_t)" instead of "sizeof(...)". The size itself 
is not relevant.

BTW, on macOS/arm64 alignof(max_align_t) is 8, not 16 (as the code seems to 
expect given the pointer size). This is harmless of course.

----------
nosy: +ronaldoussoren

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue47179>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to