1 Preface Some time ago, I was involved in locating a problem with Tomcat that involved a sendfile system call. I suddenly thought of some of my previous experience with Java, and knew that there was a lot of open source software in the Java space that applied zero-copy to improve its performance, so I came up with this article. Look at these familiar software, have you ever understood the technical points behind their application:
Introduction In modern computer systems, there can be multiple CPUs, and each CPU can have multiple cores. In order to take full advantage of the capabilities of modern CPUs, JAVA introduced multithreading, where different threads can run on different CPUs or different CPU cores at the same time. However, for JAVA programmers it is possible to control how many threads are created, but which CPU the threads are running on is generally difficult to know.