Re: riscv: llvm-compiler: calling convention violation: temporary register $t2 is used to pass the ninth function parameter

From: Alex Bradbury
Date: Thu May 12 2022 - 04:35:29 EST


On Thu, 12 May 2022 at 09:30, Changbin Du <changbin.du@xxxxxxxxxx> wrote:
>
> On Wed, May 11, 2022 at 01:07:14PM -0700, Craig Topper wrote:
> > I’m guessing that because the function is static, the calling convention was changed to fastcall which allows us to ignore the ABI.
> >
> I think so. But the mcount function assumes the ABI is not changed.

It feels like this is a problem that would be encountered on other
architectures with clangbuiltlinux as well, due to dropping the ABI
requirements for local functions. Have you seen something similar
elsewhere Nick?

Best,

Alex