Re: RFC: LoongArch backend for SBCL

Stas Boukarev <[email protected]>
Newsgroups gmane.lisp.steel-bank.devel
Message-ID <CAF63=13WzoGxxDfK==+5SO6zzt-BUpxy53aToHYdTuE_cV3L_w@mail.gmail.com>
The changes to the shared parts should be in separate commits.
Anything else that's restricted to src/compiler/arch or arch-specific
src/runtime files can be formatted in any way you wish, even just a
single commit.

On Mon, Jan 12, 2026 at 5:36 AM 王子龙 <[email protected]> wrote:
>
> Hello,
>
>
> I am working on adding support for the LoongArch architecture to SBCL
> and would like to ask for early feedback before submitting patches.
>
>
> Target:
> - Architecture: LoongArch64
> - OS: Linux
> - ABI: LoongArch ELF psABI
>
>
> Current status:
> - Backend skeleton is in place
> - Register set and calling convention are defined
> - Basic VOPs are implemented
> - Runtime context handling (sigcontext, PC/GPR access) is implemented
> - SBCL can be built natively on LoongArch Linux
> - Basic tests run; some failures remain
>
>
> Tested on:
> - LoongArch64, Linux kernel 6.3+, glibc 2.36
> - GCC 14.2.1, native build
> - SBCL bootstraps successfully
>
>
> Implementation approach:
> - Backend structure follows the existing MIPS and RISC-V ports
> - Instruction selection and ABI closely follow the official LoongArch ABI
> - Runtime support is implemented in src/runtime/
>
>
> Next steps:
> - Clean up the backend and split changes into logical patches
> - Submit the port incrementally (backend skeleton, ABI, codegen, runtime)
> - Address remaining test failures
>
>
> Before sending patches, I would appreciate any guidance on:
> - Preferred patch ordering
> - Any architectural concerns specific to SBCL backends
>
>
> Thank you for your time and feedback.
>
>
> Best regards,
> ZiLong Wang
>
>
> 本邮件及其附件含有龙芯中科的商业秘密信息,仅限于发送给上面地址中列出的个人或群组。禁止任何其他人以任何形式使用(包括但不限于全部或部分地泄露、复制或散发)本邮件及其附件中的信息。如果您错收本邮件,请您立即电话或邮件通知发件人并删除本邮件。
> This email and its attachments contain confidential information from Loongson Technology , which is intended only for the person or entity whose address is listed above. Any use of the information contained herein in any way (including, but not limited to, total or partial disclosure, reproduction or dissemination) by persons other than the intended recipient(s) is prohibited. If you receive this email in error, please notify the sender by phone or email immediately and delete it.  _______________________________________________
> Sbcl-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/sbcl-devel


_______________________________________________
Sbcl-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sbcl-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.