Issue 148146
Summary RISC-V backend does not support PreserveMost calling convention
Labels new issue
Assignees
Reporter CaiWeiran
    The RISC-V backend currently does **not support** the `PreserveMost` calling convention. Attempting to compile code that uses it results in a fatal backend error:

```

fatal error: error in backend: Unsupported calling convention

```

**Minimal example (on Compiler Explorer):**  
https://godbolt.org/z/h7e5WT7eM

---

### Questions

- Should the RISC-V backend **implement support** for `PreserveMost`, similar to backends like x86, ARM, and AArch64?
- Or should the frontend or mid-end **automatically lower** unsupported calling conventions like `PreserveMost` to a more compatible one, such as `C`?

---

It would be helpful to clarify whether this is a planned feature, or if `PreserveMost` should be explicitly avoided on RISC-V targets.

Thanks!
```
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to