←back to thread

462 points jakevoytko | 1 comments | | HN request time: 0.001s | source
Show context
gpvos ◴[] No.43491170[source]
It seems to me that V8 had very bad unit tests if this wasn't caught before release. Making sure all operators act the same way when optimized and not is a no-brainer.
replies(1): >>43493216 #
sgarland ◴[] No.43493216[source]
Maybe, but I can also understand someone rationalizing that they don’t need to test abs(), because what could possibly go wrong?
replies(2): >>43494040 #>>43495482 #
1. gpvos ◴[] No.43494040[source]
Fair enough, it's busywork and easy to postpone. But code optimization is something that needs this kind of double-checking, so in the end you should have it for all opcodes, and then including the easy ones like abs isn't much extra work.