Re:Why I Don't Want to Learn Go
by cageface on Monday March 19, 2012 @08:10AM
(#3723517)
Objective C message passing is much, much faster than function dispatch in a typical scripting language but still too slow for inner loops. C++ virtual functions and, of course, inlined C/C++ functions are much faster.
[ Parent
| on HN ]
Obligatory link benchmarking various Objective-C operations:
http://www.mikeash.com/pyblog/performance-comparisons-of-com...
I'm a bit concerned about at least one measurement:
Read 16-byte file 100000 iterations 2.1s for 100k reads 21219.3ns per read
This appears to be testing... the filesystem cache? It's certainly not seeking on a rotational disk, "SSD" isn't on the page, so... not sure where he's getting 21 microsecond reads from.
It's measuring the overhead of a set of open()/read()/close() syscalls - exactly the situation where you would want to use the cache to avoid physical disk latencies swamping the language variation.