Line for line Go will be faster it is compiled. It is the only thing that matters line for line.
No, it's not the only thing that matters. Java's compiled too and was included here, but Go still beat it out. It's likely that C or Rust or C++ would be much faster than Java or Go since they have large runtime overheads; it turns out having a runtime and how heavy it is matter too, not just if it's compiled. There are also cases where non-compiled languages can beat out compiled ones. For example, lua with LuaJIT i…
Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
31–40 of 59 posts
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#32I visited the post fully expecting the author would benchmark the latest PHP 7.2. To my surprise, he wasn't even benchmarking 7.0, but the old 5.6. I can't take this test seriously.
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#33Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#34Earlier quoted context omitted.
https://nikhilm.github.io/uvbook/filesystem.html > The libuv filesystem operations are different from socket operations. Socket operations use the non-blocking operations provided by the operating system. Filesystem operations use blocking functions internally, but invoke these functions in a thread pool and notify watchers registered with the event loop when application interaction is required.
I'm not familiar with libuv but is there a dedicated "watcher" thread in a thread pool that the kernel wakes up when when the disk driver has completed that I/O that it was sleeping on? If so is there a dedicated "watcher" thread for each non-blocking I/O request handled by libuv?
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#35Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#36So he acknowledges that has not benchmarked the best options for Java and then selects Go as a winner, what a joke.
Same with Php, using really old versions of it. This is a waste of time article, nothing is learned from it appart the bias of the author.
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#37https://www.nearform.com/blog/node-js-is-getting-a-new-v8-wi...
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#38Pet peeve: tech articles/blogs which do not prominently display when the article was written. This is the single most important fact I search for before reading time sensitive tech info. I can't tell when this was written, am I missing something?
Re: Server-Side I/O Performance: Node vs. PHP vs. Java vs. Go
#39So he acknowledges that has not benchmarked the best options for Java and then selects Go as a winner, what a joke.
The author used a query along the lines of:
SELECT * FROM table ORDER BY RAND() LIMIT 1
Except for the language they wanted to win, which was basically written like: SELECT * FROM table WHERE id = RAND()
Which, of course, resulted in it their favorite being the clear winner.