News for hackers. Stuff that matters.
Re:More on x86 – The Chip Letter by phkahler on Thursday April 25, 2024 @10:17AM (#40157894)
>> 2) code density is not as important because memory is faster and cheaper — again, memory may be cheap, but keeping icache full more important for the performance than ever;

RISC-V achieves better code density than x86, so the same C-code when compiled takes less icache. IIRC it's not a lot smaller, just a little.

Re:More on x86 – The Chip Letter by hajile on Thursday April 25, 2024 @10:56AM (#40158351)
The difference is a lot when put into proper perspective.

Average x86 instruction length is 4.25 bytes. ARM64 is 32-bits. RISC-V compressed was a little under 3 bytes around 10 years ago when introduced.

So if RISC-V instruction length is 30% shorter than x86, why wasn't RISC-V density get a similar boost? x86 has some relatively common instructions that RISC-V didn't have even just a year or two ago. There are still some things that take 4-6 instructions in RISC-V, but just 1-2 instructions in x86 or ARM64.

Over time, the code density of RISC-V will increase. Meanwhile, stuff like APX seems to require very long instructions, so compilers will be playing an interesting game where more registers and 3-register instructions decrease MOVs, but the length of the instructions also shoots up a lot.

Re:More on x86 – The Chip Letter by klelatti on Thursday April 25, 2024 @12:58PM (#40160026)
> Over time, the code density of RISC-V will increase

Why given the push back against adding new instructions tang would achieve this?

Re:More on x86 – The Chip Letter by hajile on Thursday April 25, 2024 @03:22PM (#40161879)
There isn't a pushback against new instructions. Look at the large number of extensions being worked on at the moment let alone all the extensions already finalized and required for current profiles.

The only issue is adding bad extensions that bleed microarchitectural details to the consumer.

Re:More on x86 – The Chip Letter by Joker_vD on Friday April 26, 2024 @08:12AM (#40168417)
> RISC-V achieves better code density than x86

Maybe, but one of the original arguments for RISC, again, was that code density will no longer matter. Apparently, it still does.