================
@@ -807,7 +807,7 @@ ArrayRef<TargetInfo::GCCRegAlias>
PPCTargetInfo::getGCCRegAliases() const {
// PPC ELFABIv2 DWARF Definitoin "Table 2.26. Mappings of Common Registers".
// vs0 ~ vs31 is mapping to 32 - 63,
// vs32 ~ vs63 is mapping to 77 - 108.
----------------
chenzheng1030 wrote:
@hubert-reinterpretcast I think you are right. There is a legacy issue in the
function `getNormalizedGCCRegisterName()`. Once `ReturnCanonical` is true for
that function, current clang(without this patch) will use name f0 ~ f31 and v0
~ v31 for vs0 ~ vs63 on ELFABIV2. And this patch extends this "issue" to AIX.
The `ReturnCanonical` was introduced in https://reviews.llvm.org/D15075 which
was targeted for X86. Seems for X86, physically overlapping registers have
canonical names, for example X86 ([eax|rax|al|ah] -> ax). But targets like PPC
and SystemZ do not have such canonical register names, for example, PPC (vs0 ->
f0), SystemZ(v0 -> f0) which are not right.
I prefer to solve this in another patch with solution: for targets that have no
canonical name for physically overlapping registers, `ReturnCanonical` should
always be false.
What do you think?
https://github.com/llvm/llvm-project/pull/68476
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits