Open-source high-performance RISC-V processor
github.com
github.com
As of the latest update in the blog, they are at 10.3 DMips/MHz.
I understand Dhrystone isn't everything, but that's pretty impressive, and up there with high performance CPUs from the established players.
Though there's way more a modern high performance CPU needs to do. It doesn't do anything meaningful to stress the memory system for instance. Hitting good Drystone numbers is stage 1 in a long process to building a modern high performance CPU.
Also, VROOM works in FPGA not only in verilator.
Amazing work. And it's talked about!! We can see learn & follow that. One of the most unique singular experiences in the modern world, creating a high performance core, and we can read about it, see the process unfold, see the team iterate. Gobsmackingly amazing.
Part of this rise to power is due to US companies investing there, buying and giving know-how in the process, but the huge part is they've built some of the world best learning systems, the state is massively investing in education, they invest more than any other country in research. And, perhaps one of the biggest factors, unthinkable in the West, is that Chinese economic entities are cooperating instead of being secretive. If one Chinese company will develop something, you can bet the rest will learn that fast and will use it in the next economic cycle. In China all knowledge is in fact a big open source scheme. Every new startup can benefit from the know how, experience and research done by others. This accelerates accomplishments like crazy.
So, to recap: CCP makes good plans for very large time scales, they have one of best education systems, they try to educate as much people as possible, they invest heavily in research, companies are more likely to cooperate instead of competing, knowledge is shared.
It's a perfect recipe for success. And I just wonder why other countries can't apply the same recipe.
Because in capitalistic market economies you need to compete. This is a law of nature! Or something like that… /s
I would indeed like to see how this works in reality on side in China. But China has one big issue: Its written language. This is something that makes me really fear the idea to go there. If they would just manage to finally switch to some proper writing system, so even dumb boys like me could learn it, I would invest some time and try to learn the language. But as long as you need to memorize thousands of signs (and can't even use a dictionary…) this is really off-putting. I'm dyslexic and have already problems to write correctly in my mother tongue (German), and had a very hard time to learn English. The second most useful language to put effort in would be Chinese, sure. But this writing system, oh boy…
The Chines are smart and have a powerful government. Why can't they make this Pinyin finally happen? It would make learning reading and writing likely even easier for the still illiterate people on the Chines country side. (And no, I don't buy the argument that you need the signs to distinguish meaning for things that sound alike. The spoken language has no signs and it still works fine. And the whole language is anyway very context depended, so you need to think about the meanings of words or phrases quite precisely anyway.)
The more I think about your comment the more I suspect you’re trolling, though. Good work!
And no, I don't believe in the "more efficient" argument. I was told that before, and I've played with quite some translations, and came to the conclusion that written Chinese isn't "more efficient" than say English or German. It's maybe ~20% to max. ~25% more concise. That's not a big win.
In the end that's not even surprising to me. To get some amount of information over you need some encoding that can be processed and understood by human brains, and I guess there is more or less some kind of natural limit to how "compressed" information can be before it gets incomprehensible for the average human. If you compare translations of longer texts in different languages and writing systems you will notice that all of them are more or less the same in length. Some are a little bit longer, some are a little bit shorter, but all in all it's the same magnitude. It's not like the same content can be expressed in one language a few times more concise than in another.
-- A quick test with the help of deepl.com | Chinese translation --
不,我不是在开玩笑。这确实是我的真实想法。
不,我不相信 "更有效 "的说法。我以前被告知,我已经玩了很多翻译,得出的结论是,中文书写并不比英语或德语 "更有效"。它可能比英语或德语 "更有效",最多也就20%。~这不是一个大的胜利。这并不是一个大的胜利。
最后,这对我来说甚至都不令人惊讶。为了获得一定数量的信息,你需要一些可以被人类大脑处理和理解的编码,我想在普通人无法理解之前,信息的 "压缩 "程度或多或少有一些自然限制。如果你比较不同语言和书写系统中较长文本的翻译,你会发现所有这些文本的长度或多或少都是一样的。有的长一点,有的短一点,但总的来说都是一样的幅度。这并不是说同样的内容在一种语言中可以比另一种语言表达得更简洁几倍。
-- German translation | by deepl.com as I'm lazy --
Nein, ich scherze nicht. Dies ist ehrlich meine wahre Meinung.
Und nein, ich glaube nicht an das Argument "effizienter". Das hat man mir schon mal gesagt, und ich habe mit einigen Übersetzungen gespielt und bin zu dem Schluss gekommen, dass Chinesisch nicht "effizienter" ist als etwa Englisch oder Deutsch. Es ist vielleicht ~20% bis maximal. ~25% prägnanter. Das ist kein großer Gewinn.
Letztendlich ist das für mich nicht einmal überraschend. Um eine gewisse Menge an Informationen zu erhalten, braucht man eine Kodierung, die von menschlichen Gehirnen verarbeitet und verstanden werden kann, und ich schätze, es gibt mehr oder weniger eine Art natürliche Grenze dafür, wie "komprimiert" Informationen sein können, bevor sie für den Durchschnittsmenschen unverständlich werden. Wenn Sie Übersetzungen längerer Texte in verschiedenen Sprachen und Schriftsystemen vergleichen, werden Sie feststellen, dass sie alle mehr oder weniger gleich lang sind. Manche sind etwas länger, manche etwas kürzer, aber alles in allem sind sie gleich lang. Es ist nicht so, dass derselbe Inhalt in einer Sprache ein paar Mal prägnanter ausgedrückt werden kann als in einer anderen.
-- Korean translation by deepl.com | just to try out some other "compact" signs --
아니요, 트롤링이 아닙니다. 이것은 솔직히 제 진심입니다.
그리고 저는 "더 효율적"이라는 주장을 믿지 않습니다. 저도 그런 말을 들은 적이 있고, 꽤 많은 번역을 해본 결과 중국어 문장이 영어나 독일어보다 '더 효율적'이지 않다는 결론에 도달했습니다. 적게는 20%에서 최대. 최대 ~25% 더 간결합니다. 이는 큰 이득이 아닙니다.
결국 그다지 놀랍지도 않습니다. 어느 정도의 정보를 전달하려면 인간의 두뇌가 처리하고 이해할 수 있는 인코딩이 필요하며, 일반인이 이해할 수 없을 정도로 정보를 '압축'하는 데에는 어느 정도 자연적인 한계가 있다고 생각합니다. 다른 언어와 문자 체계로 된 긴 텍스트의 번역본을 비교해 보면 모든 번역본의 길이가 거의 같다는 것을 알 수 있습니다. 어떤 것은 조금 더 길고 어떤 것은 조금 더 짧지만 대체로 같은 크기입니다. 같은 내용을 한 언어가 다른 언어보다 몇 배 더 간결하게 표현할 수 있는 것은 아닙니다.
-- Russian translation by deepl.com | trying out some alternative western script in a different language family --
Нет, я не троллю. Это мое искреннее мнение.
И нет, я не верю в аргумент "эффективнее". Мне говорили это раньше, и я играл с некоторыми переводами, и пришел к выводу, что китайский язык не "более эффективен", чем, скажем, английский или немецкий. Он, может быть, на ~20% максимум. ~25% более лаконично. Это не большая победа.
В конце концов, меня это даже не удивляет. Для того чтобы передать какое-то количество информации, вам нужна кодировка, которая может быть обработана и понята человеческим мозгом, и я полагаю, что существует более или менее естественный предел того, насколько "сжатой" может быть информация, прежде чем она станет непонятной для среднего человека. Если вы сравните переводы длинных текстов на разные языки и системы письма, вы заметите, что все они примерно одинаковы по длине. Некоторые немного длиннее, некоторые немного короче, но в целом это одна и та же величина. Не то чтобы одно и то же содержание можно было выразить на одном языке в несколько раз лаконичнее, чем на другом.
-- Japanese translation by deepl.com | another eastern language with sings --
いや、荒らしているわけではありません。これは正直に私の本当の意見です。
そして、私は「より効率的な」議論を信じていません。以前、そのように言われたことがありますが、私はかなりの数の翻訳で遊んでみて、中国語の文章は英語やドイツ語よりも「効率的」ではない、という結論に達しました。20%から最大で25%程度です。~25%程度です。それは大きな勝利ではありません。
結局のところ、それは私にとって驚くべきことでもないのです。ある程度の情報量を得るには、人間の脳が処理し理解できるエンコーディングが必要で、平均的な人間にとって理解不能になる前に情報を「圧縮」できる自然な限界というものが多かれ少なかれあるのでしょう。異なる言語や文字体系で書かれた長い文章の翻訳を比較すると、どの文章も多かれ少なかれ同じ長さであることに気づきます。少し長いものもあれば、少し短いものもありますが、全体として同じ大きさなのです。同じ内容でも、ある言語では別の言語より数倍簡潔に表現できるわけではないのです。
----
My conclusion: Yes, Chinese is the most compact one. But like I've said, it's the typical ~25% less, so not a big difference. To my surprise Japanese is almost as "chatty" as German. (But OK, their writing system—or better said their three mixed writing systems—is even more crazy than Chinese, which is at least somehow consequent, even that's historically not true). It's also interesting to see that Korean seems to strive a very good balance. It's quite concise, but the writing system is much much simpler than the Chinese or Japanese one.
The other thing is how long it would take to read the text aloud in all the different languages. Chinese is quite concise when written, yes, but it's actually not when spoken out. Reading even a few signs aloud takes some time…
My point is: I would really like to learn the language. But the writing system is just off-putting.
This is imho an unnecessary high barrier to entry. OTOH I can understand why it isn't an issue for China. They don't "need" any foreigners. They have enough people.
Of course it requires work, it's a language that's very different from English.
Also, the ROI (in terms of new potential conversation partners) is probably larger for mandarin than for any other language just because of its sheer size and non-overlap with English speakers.
いいえ。トロールではありません。本当の意見です。
24 characters compared to 35 in translation posted above. I think it is a better translation but not because of the written language. I think it is more idiomatic of how a native person would speak, though I am not a native speaker and others more knowledgeable may disagree.
My point is that you should not judge from the alphabet or dictionary how concise a language is. And you certainly should not go off a saas translation (although I think deepl is very good).
Now back to the topic of high performance CPUs...
it's not like you need more materials of any sort to deal with a 400% increase in the space occupied by text
It takes a while to learn for sure, but it's not that hard. The relationship between the written and spoken language isn't that much worse than in English. And at least the grammar is trivial.
Innovating is not done in polite company in China. If you come up with a clever new way of doing something, there is an extremely high possibility that your superiors will suppress it on the off chance that it could embarrass them (“lose face“).
These big long term plans you’re referring to exist, but in the plane of reality you imagine. There is nothing like a meritocracy in the CCP. That is even more true now than 10 years ago, because Xi has systematically removed dissenting voices in what you have heard is an anti-corruption campaign. Companies like Blackrock and Boeing are breathtakingly corrupt and are taking us taxpayers for a huge ride. But they can usually do a pretty competent job of getting the job done. They are run by technocrats, who often have an engineering background.
Imagine if the top 10 levels or so of any of these companies were nothing but connected people and their friends and children. That’s what happens to all of these projects in China. China can’t build a 5m chip or a new type of wing or a useful new programming language. Most of the people who could even do that job are either out of the country or unable to be recognized for their work.
https://www.npr.org/2023/03/26/1164832694/to-help-new-studen...
You are saying this in a reply to the post to open source RTL of high performance CPU from China?
China also can demonstrably build a competitive distributed database like TiDB. I think PL vs DB boils down to that it is hard to create a profitable business building PL, compared to a profitable business building DB.
I'm asking because your comment reads like culture essentialist bullshit that doesn't match my experience.
I don't know what "culture essentialist" means, sorry. And it's good to hear your experience is unusual. I'm quite surprised. But the simple fact is conformity is treasured in China, and has been for untold generations.
It is not like Washington is going to stop fighting culture wars and stabbing each other in the back.
You’d be surprised how relatively recently most of the skilled immigrant groups have been in the US. In 1990 there were 781,000 Indian Americans. Today there are 2,800,000. The non-Hispanic white population grew 8% over that time (and birth rates aren’t any higher among Indian Americans). The other 1.95 million or so are immigrants and their kids who came here after 1990.
This is not strictly true. Witness anyone trying to get a Chinese company to produce GPL source code or contribute back. Open source is something to be taken for free and we don't need to worry about silly obligations, moral or otherwise.
I think a more accurate statement is "patents and copyrights do not functionally exist in China" so open source is synonymous with "public domain". Some try to protect their work through encryption or DRM, to give them a head start on the clones that will inevitably follow but that's not the same thing at all.
Where exactly is an incentive for a Chinese private company to share its knowledge with other private or state companies?
"Approximately 500 million people in China, or 70% of the labor force, do not have a high school education. By this metric, China is the least educated middle-income economy in the world"
https://sccei.fsi.stanford.edu/china-briefs/invisible-china-...
from standford 2021
How do you know China is successful because if its investing in education and research. Maybe it was investment in housing. Or transportation. Or whatever. Economists do not agree on the relative importance in those things.
> they invest more than any other country in research
Is that true in per-captia terms, because I don't think so.
> If one Chinese company will develop something, you can bet the rest will learn that fast
This is like cooperating companies here. They might talk a big game but we all no that there is a huge amount of internal infighting.
The same kind of things were said about the Soviet Union. "Oh look at the cooperation" but when we actually got the documents, what it showed was bitter infighting.
So I would be careful with claims that all these companies are just perfectly willing to share all their technology even if you assume the all belong to CPP memebers.
> In China all knowledge is in fact a big open source scheme.
That sound like you are projecting. I have seen no evidence that this is the case.
Maybe China isn't that special. Maybe its just late to the party and is really fucking damn big with a huge amounts of people and resources. Once the US was reasonably poor and then it grew as fast as anybody ever had in history, and it didn't have massive state driven education and industrial policy and yet by the 1910s it was matching Britain and Germany in many things.
Before that Britain was matched an partly overtaken by Germany. And it looked like Germany was magic because its companies were organized by the state in corporatism fashion. Yes they also invested in education, infrastructure and research. But its not a magic pill and the companies in Germany were just as competitive against each other as those in Britain.
https://github.com/tenstorrent/riscv-ocelot
Its basically the evolved BOOM Core from Berkley but with a full RISC-V Vector Unit attached.
I had really hoped more people put more investment in BOOM.
https://carrv.github.io/2020/papers/CARRV2020_paper_15_Zhao....
Taking this precept down, they don't care about IP. If one Chinese company makes a product, in a few weeks you can find lots of different Chinese companies selling the same product on Aliexpress. Some of better quality, some cheaper, some with added functionality some with less functionality.
If you are to give your hardware design to a Chinese company and order a heavy lot you might have a good deal. But if your product is kind of successful, you shouldn't wonder if you see a lot of alternatives offered on Aliexpress by seemingly increasing unknown companies for a good rebate.
They notably seem to be validating & simulating C/C++ targets for a lot of this.
They have a great breakdown of the tools they've used & build. Chisel, out of Berkeley, lies at the heart of almost everything. But they have reams of new tools they've madd. There's over a dozen simulators or tester pieces they said they've made. Which is epic, and makes total sense.
Great paper thanks for sharing. I quickly scanned their gitbub repos. A lot of these tools probably arent iterated on as much & I just haven't got to them yet. The paper claims the overarching development structure is embodied on a tool MinJie, which the paper says is open source. Fantastic, fingers crossed 50%+ of the tooling here is available.
I also feel like the US's OpenROAD deserves some shout out as related, relying on extremely good design checking/validators to be so agile at chipmaking that ML can spit out designs en mass & then we can run loss checks to find out how working the various designs are. Millions of monkeys on typewriters style ultra agile.
Would it be a viable idea to buy shares in China based tech companies now? The thinking is that if CCP pushes something real hard by investing large amounts of resources in it, the chances are higher that they will succeed. Not tomorrow but in 10 or 20 years. Conversely, if US based tech companies will have competition, it is likely that their value will go down a bit at one point.
Also, it's possible that if China builds domestic silicon tech we will see a race to the bottom if they will want to aggressively price their products and try to undercut their competitors. Then it might be a bad idea to own any shares in tech companies, no matter where they are located.
The SEC has this to say: https://www.sec.gov/corpfin/disclosure-considerations-china-...
> Current regulations in China limit or prohibit foreign investment in Chinese companies operating in certain industries. For example, there are restrictions on foreign ownership of telecommunications companies and prohibitions on ownership of educational institutions.[7] To circumvent these restrictions, many China-based Issuers form non-Chinese holding companies that enter into contractual arrangements, intended to mimic direct ownership, with Chinese operating companies. Through these contractual arrangements, the China-based Issuer is generally able to consolidate the Chinese operating company, commonly referred to as a variable interest entity or VIE, in its financial statements, although whether the China-based Issuer maintains legal control of the Chinese operating company is a matter of Chinese law. Under this structure, the Chinese operating company, in which the China-based Issuer cannot hold an equity interest, typically holds licenses and other assets that the China-based Issuer cannot hold directly.
> These China-based Issuer VIE structures pose risks to U.S. investors that are not present in other organizational structures. For example, exerting control through contractual arrangements may be less effective than direct equity ownership, and a company may incur substantial costs to enforce the terms of the arrangements, including those relating to the distribution of funds among the entities. Further, the Chinese government could determine that the agreements establishing the VIE structure do not comply with Chinese law and regulations, including those related to restrictions on foreign ownership, which could subject a China-based Issuer to penalties, revocation of business and operating licenses, or forfeiture of ownership interests.
> Legal claims, including federal securities law claims, against China-based Issuers, or their officers, directors, and gatekeepers, may be difficult or impossible for investors to pursue in U.S. courts. Even if an investor obtains a judgment in a U.S. court, the investor may be unable to enforce such judgment, particularly in the case of a China-based Issuer, where the related assets or persons are typically located outside of the United States and in jurisdictions that may not recognize or enforce U.S. judgments.
And of course, see Levine on the subject:
https://www.bloomberg.com/news/newsletters/2021-07-07/money-...
https://www.bloomberg.com/opinion/articles/2021-08-02/chines...
Keep thinking. If US tech firms don't have much competition right now, they are not incentived to innovate or improve their products. If they had more competition, they would need to put up or shut up, rather than reaping profits from money they might otherwise spend on R&D.
Personally, I think that if you put competitive pressure on a large and lazy incumbent, they will either increase in value or fold outright. (Or convince politicians to bail them out, write protectionist legislation, etc.)
China’s ASML is Years and Years Behind: https://www.youtube.com/watch?v=DtOyW-JpJjM
tl;dw - Nope. Can't just throw money at this problem.
By the time SMEE is hitting 5nm, processes for 3d will be mature. I wouldn't discount any of this at this point.
I guess China will crack EUV in some time.
Chinese Academy of Sciences will (a spinoff company for commercialization), they publish research papers on EUV and so on.
Multiple project are being developed in parallel.
Right now they've made bets on a large scale of different technologies. Many of them failed already. Probably they will focus on a few and succeed in a not very long time scale.
I was more interested in terms of investment.
My best guess currently would be that the US will try to outlaw the competing market should one arise: The US will just forbid its people and the people in the allied countries to make business with China, like they do with a lot of other countries, like Russia or Iran.
It's unlikely this would happen immediately as the US is currently still depended on China. But as the economic war intensives walling-off will happen at some point. There are already "sanctions" in place against Chinese companies in some market areas. This will likely only worsen over time.
You can still invest in China, sure. But you will be forced to move there at some point, or loss everything over there, I guess.
* Intel i7-4600U CPU DMips/Mhz (I found about 10 DMips/Mhz)
* RISC-V VRoom = 10.3 DMips/MHz (still in development)
* RISC-V XiangShan = ?
* RISC-V others ?
Better "benchmark" real stuff: CPU bound AAA games, etc.
But I bet pytorch has been, and also openCV and other compute-heavy stuff. (And Doom, of course.)
One of the best "real" Benchmarks is compiling the Linux kernel, the issue is that on an emulator/verilog simulator that could take a very long time.
There is a sixty four core OoO RISC-V chip (SG2042) being demoed on a dev board in the last weeks. It runs at 2.0 GHz and has quite a bit of aggregate performance, at lower energy usage than an 8 core i9 running at 6 GHz.
I am afraid, but the GHz of RISC-V core for high performance desktop will have to go significantly higher.
That said, for self-hosted servers, and even some servers, RISC-V may already be ready for prime time.
Best x86 and ARM are around there.
I was more talking about the government though, which isn't otherwise famous for it's love of openness. I'm not aware of any government currently promoting FOSS/FOSH as much as China's is.
That being said, RISC-V is gaining a lot of traction. I wouldn't be surprised if it starts to become a real challenge to ARM in the next five years. You just need mature tooling and better cores. Probably also need a wider variety of smaller cores for embedded applications available at the right price points.
Open Source Chips to Benefit the World
There is no EN on any deeper, direct linked url. But once chosen from the top it sticks.
Unfortunately, documentation for Micro-ISA is in Chinese only :-(
Fwiw, this is the relevant link: https://xiangshan-doc.readthedocs.io/zh_CN/latest/frontend/d...
The specs themselves come with a lot of rationale for decisions taken.
But, as a starting point (from zero), I recommend the "RISC-V Reader" book, by the main authors of the ISA, as it makes a great introduction to the design of RISC-V.
https://raw.githubusercontent.com/riscv/riscv-bitmanip/maste...
If you do instruction fusion, you might be able to transform the typical pairs that would create a short branch and simply convert them into a cmov micro-instruction. That it does not make the branch predictor much more complex.
The ternary instructions didn't pass the test for utility vs cost and were not ratified.
For example `cmix` only replaces three other instructions, two of which can be done in parallel. Emulating `cmov` is slightly more expensive: generate an all-1s or all-0s mask from your condition (e.g. `slt mask,a,b; neg mask,mask` and then do a `cmix`.
Applications that want `cmov` for constant execution time for security reasons can cope with it using a couple of extra instructions. Applications that want `cmov` for average performance because the condition is unpredictable are mostly mistaken with modern branch prediction :-)
There is a fairly strong possibility that a pair of instructions might be added to put `cmov` emulation on the same footing as `cmix`:
Rd = Rs2 ? Rs1 : 0
Rd = Rs2 ? 0 : Rs1
These instructions only need two register inputs.https://wiki.riscv.org/display/HOME/Recently+Ratified+Extens...
But there are good guys everywhere (and bad too), and anything pushing a world-wide royalty free modern ISA toward "real-life" usage does its part.
I hope one day I'll buy a AAA game, with a noscript/basic (x)html browser and play it on highly performant RISC-V CPU.
Don't forget, the bad guys hate simple but able to do a good enough job, stable in time standards.
What a dream! I'd add the game would be open source; don't care about the art though.
I wasn't aware of any other big players doing this... I suspect it will limit the impact this project can have if industry can't adopt it easily into existing processes.
Other HDL based on scala includes SpinalHDL.
These two HDL are pretty welcomed because of opensource and usability. You can find lots of projects in them. Notably rocket-chip, which is also in chisel. https://github.com/chipsalliance/rocket-chip
They're around for a while but still young and some people are pushing for adoption.
There, solved it once and for all. :)
It was created and used by the same group that created RISC-V so it makes perfect sense.
SiFive, arguably the biggest player in RISC-V, use Chisel to design their processors.
Why? (I know nothing about hardware design, but know a thing or two about Scala. All the languages better than Scala are used even less than Scala.)
Scala has actually some stand in HW development and high-performance computing. See also https://spatial-lang.org/ which is another Scala DSL, this time for accelerators.
Scala in general is a much underrated language. One of the most powerful high level languages, but with a concise and very clean core. Since the new syntax was introduced in version 3 it even looks amazingly beautiful.
I know, people (frankly especially here on HN) are repeating some FUD about this language, but this are usually issues solved a decade ago.
People should really reconsider trying out Scala. Especially the new major version 3.
https://virtuslab.com/blog/the-most-common-scala-myths-debun...