Conversation
`k` was selected for `f16` and `q` for `f128`. These are different from LLVM's defaults.
|
The f16 & f128 RFC was merged so I think it is OK to decide on mangling. Marking it as ready for review @Mark-Simulacrum |
|
I think we probably don't need different mangling for PowerPC that LLVM seems to have but could use confirmation https://github.com/llvm/llvm-project/blob/fdef7952cbc26fd31d0d92a4f14dde58bc461fe9/clang/lib/Basic/Targets/PPC.h#L351 patch llvm/llvm-project@0461534 |
|
@rcvalle / @michaelwoerister, we need this mangling at some point - any guidance on how to proceed? Itanium uses |
|
We'll need to take a look at what the grammar allows. Is this implemented in the compiler already? Will these types be primitive types in Rust? |
|
I just saw the links in the PR message. Will read those 🙂 |
The primitives exist in the compiler but not yet fully exposed (rust-lang/rust#121926 coming soon). Currently it does the itanium mangling and just ICEs with v0 mangling. |
|
@ehuss suggested here that we extend the mangling scheme by updating the official docs. I think that is a good idea. Would you mind opening a PR that adds the two cases to the basic types section and then we can do a compiler team FCP to sign off on the change. |
|
I added a comment at rust-lang/rust#121728 (comment), but this is for CFI encoding and cross-language CFI compatibility and independent/dissociated to Rust mangling/demangling and a different encoding can be used for it. |
|
Thanks for the pointers, I opened rust-lang/rust#122106 to follow up |
|
I think this can be closed now, right @tgross35? |
|
Totally forgot abut this, thanks! |
kwas selected forf16/halfandqforf128/quad.These are different from LLVM's defaults which are
Dhfor half (link) andgfor quad (link). I don't know if there is any reason to mirror LLVM here because it would mean adding multi character tags for primitives. I just usedqbecause it it's more obviously in line withfforfloat/f32anddfordouble/f64.Part of rust-lang/rust#114607