It is somewhat performance, but there are three other more important factors. (Java performance, not counting startup overhead, is fairly close to C++ now.)
One factor is determinism. GC introduces unpredictable (non-deterministic) time latency, making GC languages generally unsuitable for real time programming.
Another is size efficiency, Java programs have a well-deserved rep for using lots of memory. That isn't a good mix for smaller/embedded systems. Java also carries along a large runtime, although Graal and other efforts are addressing this.
The final factor is that C++ is perceived (rightly or wrongly) to be an "improved C". As the heir apparent to C, C++ has a ton of mindshare and momentum. Rust is now providing a major challenge, one I hope it wins! (Honorable mention to D, which is a nice language as well.)
One factor is determinism. GC introduces unpredictable (non-deterministic) time latency, making GC languages generally unsuitable for real time programming.
Another is size efficiency, Java programs have a well-deserved rep for using lots of memory. That isn't a good mix for smaller/embedded systems. Java also carries along a large runtime, although Graal and other efforts are addressing this.
The final factor is that C++ is perceived (rightly or wrongly) to be an "improved C". As the heir apparent to C, C++ has a ton of mindshare and momentum. Rust is now providing a major challenge, one I hope it wins! (Honorable mention to D, which is a nice language as well.)