Hacker News new | ask | show | jobs
by philosophus 4211 days ago
I don't believe he said it makes no difference.
1 comments

»But in todays CPUs there is no advantage using the short thing. You can add 64 bits or 8 bits, takes the same amount of time. And you look up what is the cash value of having saved seven bytes on a number. When you add that up it is zero. So there is no benefit.« [1]

As long as you are concerned with adding a bit of eye candy and interactivity to a web page this may be true enough to get away with the JavaScript way of making every number a double precision floating point number but there a other domains where this will not fly. And even in the world of JavaScript asm.js is trying hard to overcome this limitation.

[1] http://www.youtube.com/watch?v=bo36MrBfTk4&t=42m17s

>but there a other domains where this will not fly.

Sure, and I believe everybody, including Doug, knows this not so subtle distinction. He wasn't talking about programming HPC for NASA.

He is comparing Java and JavaScript and implies that it is a bad choice of Java to offer several options. And given the broad range of applications Java is used for I don't think this is a justifiable opinion.
But in java (64-bit JVM) this statement is true: "You can add 64 bits or 8 bits, takes the same amount of time."