3 ms·
For an ISA whose main use will be IoT (at least in the beginning), this isn't good.. Rust didn't put integer overflow checks in release mode because current CP
by renox 7y ago
For an ISA whose main use will be IoT (at least in the beginning), this isn't good..
Rust didn't put integer overflow checks in release mode because current CPU don't provide "free" integer overflow detection, RISC V is even a regression over MIPS here..
- deleted 7y ago[deleted]
- 0815test 7y ago> Rust didn't put integer overflow checks in release mode because current CPU don't provide "free" integer overflow detection Not really; the main performance drawback of obligate overflow checks is excessively-constrained semantics of the resulting code making optimization harder, not the direct CPU cost of checking. There are other ways of detecting possible overflows, and Rust does check for overflow in debug mode (this is specifically in order to ensure that most Rust code will work properly even when checks are enabled, and will not simply end up relying on underspecified semantics.)
- renox 7y agoInteresting, do you have studies on this topic? That said the 'CPU costs' of adding these branch are mostly ICache usage cost so benchmarks aren't very useful..