Investigate extending `/ALTERNATENAME` to the entire multiverse
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 11.1k
- Forks
- 1.7k
- Avg merge
- 4d 15h
- Merged PRs (30d)
- 22
Description
Currently, the /ALTERNATENAME technique introduced in #2381 isn't used for Clang and ARM64EC:
https://github.com/microsoft/STL/blob/0dc93fcf0e7f18d47fff4daccce729cc5ea9570b/stl/inc/mutex#L498-L505
https://github.com/microsoft/STL/blob/0dc93fcf0e7f18d47fff4daccce729cc5ea9570b/stl/src/xonce2.cpp#L33-L43
We should investigate extending this technique to them. We'll need to:
- File an internal issue to get this highly useful linker option documented.
- Report an issue upstream to Clang so they can handle it correctly (according to my vague understanding, they just need to pass it along to
link.exe, as we aren't using theirlld-link.exehere).
We also don't use it for CHPE and /clr, but we don't need to extend it to them.
Finally, as @AlexGuteniev noted in https://github.com/microsoft/STL/pull/2381#issuecomment-1007951468 , we could begin using this technique for shared_mutex and possibly elsewhere:
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the existing /ALTERNATENAME handling in stl/inc/mutex and stl/src/xonce2.cpp, then compare the shared_mutex code in stl/src/sharedmutex.cpp. Determine the feasibility for Clang and ARM64EC, file the requested internal and upstream Clang issues, and document whether shared_mutex should also use the technique.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- build-system, compilers
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100