[PATCH] D118804: Revert "[Clang] Propagate guaranteed alignment for malloc and others"
Aaron Ballman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 8 07:40:33 PST 2022
aaron.ballman added a comment.
In D118804#3304337 <https://reviews.llvm.org/D118804#3304337>, @urnathan wrote:
> In D118804#3304280 <https://reviews.llvm.org/D118804#3304280>, @aaron.ballman wrote:
>> In D118804#3304261 <https://reviews.llvm.org/D118804#3304261>, @urnathan wrote:
>>> While C2X has blessed such smaller alignments, the x86_64 ABI (in particular), has not. However, using that ABI to justify 'It. Is. 16. Bytes.', is really an exercise in reality denial at this point. just thought I'd make it clear we have conflicting standards and practicality to attend to.
>> Do we want me to report back to WG14 with information that N2293 might not suitable for adoption into C2x?
> I think N2293 is fine for C2x. It is blessing an implementation of lower alignment allocations. Putting the programmer on notice that they can no longer assume some things.
Okay, that's good to know, thank you! If the consensus changes and we want me to take feedback to WG14, please let me know.
> As a compiler I think we need to deal with the reality that there are non-ABI conforming [system-dependent] allocators out there, and not simply say 'But the ABI says ...'
> There is already at least one thing the ABI says that is not valid on some systems [sret return behaviour and Swift], for equally good reasons. The compiler deals with that.
> FWIW, although gcc's code generation has a similar bug, its C++ library is already cognizant of lower-alignment allocators -- I convinced Mr Wakely a few years ago :)
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
More information about the cfe-commits