Even hello world programs tend to show different performance characteristics on different OS/platforms. The idea of write once, run everywhere is over. In a moderately complex software, changing the OS/platform is a non trivial problem. Recompiling the code (which is mostly automated) is the least problematic part of it.
Are you familiar with the joys of autoconf, cmake and friends? Have you tried writing a non-trivial application that simply compiles on different flavors of Linux and Windows? Compiling on different platforms is also a non-trivial problem. Having a virtualised platform that abstracts away differences between OS makes it vastly easier to write portable applications.
For many applications running on a VM on different platforms Just Works. The idea is most definitely not over, in fact it is becoming ever more popular. Just look at the rise of abominations like Electron.
Those joys are only enjoyed for those that insist into using C with POSIX APIs covering for lack of a rich standard library.
We don't need VMs, what we need is rich libraries and there are plenty of languages with support for AOT compilation to native code with such libraries.
Something that even C++ is finally adopting.
Regarding Electron, I hope it joins MSHTML in a couple of years.