Loongson unveils LoongArch CPU instruction set architecture for processors made in China

Loongson is a Chinese company better known for its MIPS processors, and we often see the company being mentioned in mainline Linux changelogs with regards to updated to Loongson MIPS SoC’s.

But with the MIPS architecture fading away, the company has decided to create its own CPU instruction set architecture (ISA) called LoongArch, short for Loongson Architecture, that is independent of x86, Arm, and even RISC-V architecture.

The reason for the move is that foreign CPU manufacturers use the instruction system as a means to control the ecology, and manufacturers like Loongsoon need to obtain “authorization” to develop compatible CPUs, meaning it’s impossible to develop an independent industrial ecosystem. Loongsoon further illustrates the point by saying “Chinese people can write novels in English, but it is impossible to form Chinese national culture based on English”.

That makes sense considering the trade sanctions regularly imposed by the United States that make it hard to plan ahead, and for instance, caused Huawei to stop making new Kirin processors.

LoongArch
Slide from a LoongArch/LoongISA presentation – Source: EET China

LoongArch includes extensions such as vector instructions, virtualization, and binary translation, with around 2500 instructions. EET China has more details about the “first self-developed ISA” in China.  Loongsoon notably designed binary translation tools for MIPS Linux, ARM Android, x86 Linux, and x86 Windows instructions into LoongISA so that existing software can be reused.  MIPS Linux to LoongISA performance is same to be the same, but there’s a noticeable performance hit for other architecture/OS combos with for instance, x86 Windows to LoongISA only achieving 70% of the native performance.

Loongson LS3A5000
Source: HKEPC

All new Loongson CPUs developed since 2020 are said to support the new LoongArch architecture, and one of the first LoongArch processors will be Loongsoon LS3C5000 16-core processor clocked at up to 2.5 GHz, manufactured using a 12nm process, and aiming to compete with AMD and Intel server processors.

Loongson said they’ve made sure LoongArch ISA does not infringe existing patents, and EET China says the company has released a LoongArch infrastructure instruction system manual with basic/limited information, and that a  more complete version will be released in the future. I could not find any link to the document, so it may not be public yet.

Via Liliputing and Tom’s Hardware

Share this:
FacebookTwitterHacker NewsSlashdotRedditLinkedInPinterestFlipboardMeWeLineEmailShare

Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress

ROCK Pi 4C Plus

25 Replies to “Loongson unveils LoongArch CPU instruction set architecture for processors made in China”

  1. 70% performance in binary translation is pretty good. You only need a CPU 40% faster to deliver the same raw performance, while often I/O and peripherals count for a great part of the user’s wait time.

    I’ve always considered that emulation is the right way to propose architecture evolution/changes. Limiting oneself to the least common denominator only deprives everyone from improvements until the oldest in the chain is not supported anymore. Focusing on the most recent and emulating it on older versions encourages migration. And when you do that you figure that there is not much difference with emulating other complete architectures. Emulating a different OS is a entire new problem.

    For sure, some applications will run poorly under emulation. But they are also the ones that will encourage their developers and users to migrate to a native port first. And progressively only legacy apps remain and they can stay emulated if nobody bothers to port them.

    What is surprising is the announce that processors of the past already support this architecture. This is very close to having a backdoor in products :-/

    Let’s see how it goes, how long it takes to see its support merge into standard toolchains then kernels and libs. It could be nice to have yet another arch to play with, especially when it comes to parallel programming. Let’s just hope they didn’t stay locked with an LL/SC design for atomics, and that they adopted the natural little endian as the default byte order!

    1. > 0% performance in binary translation is pretty good…

      Not to say it’s bad or anything, but keep in mind both Intel and AMD are already decoding from x86 to their internal RISC architectures and microarchitectures.

      > while often I/O and peripherals count for a great part of the user’s wait time.

      For desktop loads.

      Anyhow, considering how RISC-V is doing in China nowadays I doubt there’s a market for a new ISA that isn’t backed by a huge monopoly / government.

      1. hardware decoding for the same platform is not comparable to software decoding for a foreing platform that doesn’t have a 1:1 mapping of instructions nor registers.

        1. The mapping isn’t 1:1 with Intel either otherwise they wouldn’t have screwed up so often 😀

          But yeah you’re obviously right and it’s apples to oranges. Still, they started it 😀

    2. They are not talking about previous models here, but specifically about those “developed since 2020”, which fits the 3A5000 that was just taped out. https://www.zhihu.com/question/414069789 actually had a lot of information on this last year.

      I don’t think they actually expect Loongarch on its own to become a dominant player, but based on their existing products this seems like a smart move. Without committing to either RISC-V, Arm or x86, they can support all three of those as well as remain backwards compatible with their existing MIPS based products.

      Since they already supported emulating x86-64 and arm64 emulation in several previous generations, I don’t think it’s actually all that different from before. Adding RISC-V emulation is an obvious choice, and dropping native hardware compatibility with MIPS is probably a minor benefit both from the licensing perspective and to give them additional freedom for implementing efficient emulation.

      mips64r6, rv64g and aarch64 are already very closely related of course, and I would expect that supporting these in hardware isn’t any harder than supporting Arm aarch64+aarch32, though it sounds like their emulation requires an extra software layer anyway. At the very minimum, separating the instruction set emulation from the hardware implementations gives them a way to not have the chip itself require an architecture license.

  2. “The reason for the move is that foreign CPU manufacturers” … what is “foreign” on a website from Thailand … ? 😉

    Old story: on CNN, using the word “foreign” led to penalty of x USD for the journalist using that word. 😉

    1. This was written in the context of Loongson saying it. While I’m myself in Thailand, CNX Software is based in Hong Kong, which according to a recent contract I signed is part of the PRC, but this is getting a bit political here 🙂

  3. Great development … if & when Loongson takes care of mainline Linux support.
    Until then … mwoah.

  4. If they genuinely want to ensure Chinese culture, they should also make their own programming language, operating system, and software ecosystem as well. In addition, they should have their own peripheral bus, interconnect, memory interface, and network architecture. I really support the Chinese doing this, if there is a genuine push for it, however what Loongson is doing is simply marketing.

    Furthermore, the RISC-V foundation already, I feel it’s been over a year, legally relocated to Switzerland to be away from silly American stupidity. I think anyone is welcome to join if you pony up the renminbi.

    1. > Furthermore, the RISC-V foundation already, I feel it’s been over a year, legally relocated to Switzerland to be away from silly American stupidity. I think anyone is welcome to join if you pony up the renminbi.

      They’ve been working on this for way more than a year and the RISC-V patent pools still have US-led partners that might be sanctioned off of it altogether leaving RISC-V broken depending on the whims of Washington.

    2. Give them time, they are achieving in no time what only few counties managed to do so in more than 5 decades. In fact, nobody did this as fast as china is doing it. We are just asking them to create a new world and the crazy thing is that they evolve fast, faster than all predictions.

      As for open source, they are only the most important code contributor for linux kernel in 2021. Android itself introduced erofs from huawei.

      As for language, they just launched it (Cangjie huawei)
      They are clearly advancing, and they do it on their own (like the space station, after being banned from the iss)

      it is also highly probable they put a lot of ressources in futur computing instead of trying to catch. They switched into an innovative country. China has already two exascale supercomputers. They need to gain asml like machines and they seem to be heading to it
      They also patented an alternative way to chip packaging

  5. I’d be concerned about ChiCim back doors hidden in the microcode. Everything … EVERYTHING … in China is monitored and surveiled by the ChiComs. That’s what “Chinese Culture” means. No thanks.

    1. So, you not concerned about CIA back doors then?
      They are exist, clearly seen by anyone and we have bunch of public-available cases when those things used to get contracts by companies from USA.

    2. that’s not what open source among it geeks means; shared information or shared code relates to its purpose of why being distributed and that might not differ that much on western or eastern security authorities (if related to misuse of power by individuals opportunism or because of indoctrination or fanatism)?

      If Chinese geeks go open source with this ISA, people telling it has back doors like ‘many (?)’ other cpu’s microcode, its another independent ISA for cpus then. Interestingly increased variety.

  6. Loongson a scam and political stun to begin with, they virtually finished once, now making a comeback because Chinese government is desperate to hand out money for any chip firm, Nationalism is the Chinese version of political correctness. RISC-V is the Western verizon of Loongson on the other hand,

    1. @bkydcmpr said: “RISC-V is the Western verizon of Loongson on the other hand.”

      “verizon” > “version”, unless maybe you have a Verizon branded mobile phone with an over-aggressive spell checker.

    2. by today, The five foundation software Linux kernel、GCC、LLVM、Glibc、Binutils now all support Loongson loongarch.

Leave a Reply

Your email address will not be published. Required fields are marked *

Khadas VIM4 SBC
Khadas VIM4 SBC