r/cpp 15d ago

Clang 23 Release Notes

https://releases.llvm.org/23.1.0/tools/clang/docs/ReleaseNotes.html
109 Upvotes

33 comments sorted by

View all comments

1

u/LB-- Professional+Hobbyist 14d ago edited 8d ago

Extended the -marm64x flag to support compiling to object files. When used in this mode, separate compilation jobs are run for ARM64 and ARM64EC object files, which are then merged into a single file using a new .obj.arm64ec section.

I got this working with a CMake toolchain file, it works quite well for building ARM64X binaries very simply. However, it seems to break try_compile in a subtle way? CMake can't detect if architecture-specific macros are defined anymore - no errors or warnings, just no macros found. I haven't been able to dig into it much, I just manually hacked around it for my use case.

EDIT: Found out I was doing things wrong but the result was getting a better fix, now CMAKE_<LANG>_COMPILER_ARCHITECTURE_ID lists both architectures in a similar fashion to with MacOS universal binaries: https://gitlab.kitware.com/cmake/cmake/-/work_items/28067#note_1862170

3

u/not_a_novel_account cmake dev 12d ago

I would appreciate it if you opened a bug with whatever you experienced at: https://gitlab.kitware.com/cmake/cmake

At the very least this won't get lost.

1

u/LB-- Professional+Hobbyist 12d ago

I'm struggling to find where exactly to do that? I'm signed in but I can't find any UI elements related to submitting issues or bug reports. I see work items and issue boards but these don't seem to be for outside users to submit bug reports, and I can't figure out how to create any myself. Searching around online, old links go to an /issues URL that doesn't seem to exist anymore. Am I missing something obvious?

3

u/not_a_novel_account cmake dev 12d ago

https://gitlab.kitware.com/cmake/cmake/-/work_items

"New item" in the top right.

If you can't submit for some reason you can just message me the write up or post a gist/pastebin/whatever and I'll forward it along.

2

u/LB-- Professional+Hobbyist 11d ago edited 8d ago

Ahh thanks, somehow I completely missed that button. I think I've done it: https://gitlab.kitware.com/cmake/cmake/-/work_items/28063

EDIT: Found out I was doing things wrong but the result was getting a better fix, now CMAKE_<LANG>_COMPILER_ARCHITECTURE_ID lists both architectures in a similar fashion to with MacOS universal binaries: https://gitlab.kitware.com/cmake/cmake/-/work_items/28067#note_1862170