Wrong ABI aliases of RISC-V integer registers under EABI

In current LLVM implementation, the ABI aliases under EABI are the same as that under UABI, but that’s not really the case. For example, s3 will be matched as x19 (and then rejected because it is greater than 15), but under EABI, s3 is actually an alias for x6. How should I fix this?
I did not find an example for reference at the moment, because in this problem a set of registers has different aliases in different cases, not a new set of registers.