preface

Java is the software development technology with the largest number of users and the widest range of use at present. The technical system of Java is mainly composed of virtual machine supporting the running of Java programs, Java API providing interface support for various development fields, Java programming language and many third-party Java frameworks (such as Spring and Struts, etc.).

When it comes to the Java Virtual Machine (JVM), most people’s first impression may be “difficult”, but when we step into the “JVM world”, we find that the problem is not as complicated as we imagined.

The JVM’s memory model and garbage collection mechanism have always been a hot topic in the Java industry (practical tuning, interview). The JVM is an important part of the knowledge of Java, and it is also one of the most frequently asked questions in the interview. After the interview, she cried. Today special share Ali architect organized JVM actual combat document, take you to understand the Java virtual machine!

Java of actual combat

The first part goes into Java

The first part establishes a good foundation for the explanation of the following text. Although knowing the ins and outs of Java technology and compiling your own OpenJDK are not necessary for the reader to understand the Java Virtual machine, these preparations can provide a good introduction to Java technology and the Java Virtual machine.

The second part automatic memory management mechanism

Because programmers put memory control power to the Java virtual machine, so you can enjoy when coding automatic memory management of many advantages, but also because of this reason, once appear, memory leaks and overflow problem, if you don’t know how to use the memory of the virtual machine is, so screen error will be a difficult task.

The third part is virtual machine execution subsystem

The execution subsystem is an essential part of the virtual machine. If you understand how the virtual machine executes programs, you can write better code.

The fourth part is program compilation and code optimization

The process of compiling a Java program from source to bytecode and from bytecode to native machine code is, taken together, equivalent to the compilation process performed by a traditional compiler.

Part v Efficient concurrency

The Java language and virtual machine provide native, full-fledged multithreading support, making it a natural fit for developing multithreaded, concurrent applications. However, we can’t expect the system to do all the processing related to concurrency, and understanding the inside of concurrency is an essential lesson for advanced programmers.

Total directory

PDF document