Abstract

The article is devoted to the study of the mechanisms of interaction between the popular programming languages Java and JavaScript using a retrospective approach. The author consistently examines the development of tools of this kind, starting from LiveConnect technology and Java applets of the mid-1990s and ending with the interpreters of the last decade. Particular attention is paid to comparing the performance of the currently relevant tools Nashorn and Graal.js. The latter is an implementation of the JavaScript language based on the Truffle framework and Context API, which is a Polyglot context for executing all supported guest languages with the Graal JIT compiler, ensuring their optimal performance. The author gives a definition to the term "warm-up", which is recommended by the GraalVM developers to achieve the highest performance. This is a kind of pre-compilation mode, the process of repeated preliminary execution of JavaScript code by the interpreter before its actual usage in order to obtain information about the most frequently utilized fragments of the program, its functions, types and data structures, alongside with their subsequent caching and optimization. The results of testing based on a project from Oracle and the authors application made it possible to verify the results declared by the GraalVM developers and can be used to optimize and improve the performance of multilingual projects using a unified technology stack, as well as when migrating the server code base from Java to JavaScript.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call