3 ms·
Making your own ISA that works is easy. Making a GOOD one is hard -- most of the ones engineers in some company just made up on the spot (because they needed a
by brucehoult 2y ago
Making your own ISA that works is easy. Making a GOOD one is hard -- most of the ones engineers in some company just made up on the spot (because they needed a small CPU but didn't want to pay Arm or Cadence or Synopsys for one) are awful.
A prime example is FTDI's Vinculum-II (VNC2), which presumably was invisibly used internally in their chips, but then they made a chip designed to be customer-programmed. It is just AWFUL. You can debate whether RISC-V is better or worse than ARMv7 or ARMv8-A but at least it's close. VNX2 is not.
Getting all the world's software (or even just GCC, LLVM, Linux) ported to your ISA is the hardest of all.
A point often not noted is that RISC-V is very easy to emulate in software, whether interpretively or JIT, with minimal slowdown compared to native code. Not having condition codes and PC not being a GPR are major advantages here. This makes it also useful in WASM / JVM / CIL territory.
- brokenmachine 2y ago>Not having condition codes and PC not being a GPR are major advantages here. What's GPR?
- hakfoo 2y agoGeneral Purpose Register?
- brokenmachine 2y agoWhy is that an advantage?
- brucehoult 2y agoBecause instructions that change the PC have to be handled specially because if not correctly predicted taken/not taken, and the target address) then they cause a pipeline break, throwing away speculatively executed work etc. When the PC is a GPR then any instruction (with PC as the destination) can be a jump to different code. Even a subtract, for example. In fact I have many times written `sub pc,pc,#3` to switch an Arm CPU to running the next instruction in Thumb mode. Gross.
- brokenmachine 2y agoCool, makes sense. Thanks for the explanation.
- snvzz 2y agoBecause PC as GPR complicates implementations immensely, for virtually no benefit.
- phendrenad2 2y agoCan you elaborate on what makes an ISA good or bad? And how much it really matters? Most high-end consumers and high-end servers are still using x86-64 CPUs, and that isn't even RISC.