Agner`s CPU blog

Software optimization resources | E-mail subscription to this blog | www.agner.org

New idea: Re-linkable libraries in ForwardCom
Author:  Date: 2017-05-12 17:34
Agner wrote:
Good examples, Hubert.

I think the optimal solution for Java, C#, and script languages is just-in-time compiling. Actually, I don't understand why there are so many slow applications out there that don't use JIT compiling :-)

The code only has to be compiled the first time it is run. Or - why not distribute it in compiled form for ForwardCom? The compiled code is guaranteed to be forward compatible with future ForwardCom processors.

The compiled code can easily be linked to C/C++ code in the JIT process. The calling conventions of ForwardCom are standardized to work across different programming languages.

You are probably right that interprocess communication is a good solution for plug ins if you don't want the plug in to have access to mess with everything in the mother program.

To load in C++ objects, the Java code calls System.loadLibrary("name"), which on windows loads "name.dll" and on posix loads "libname.so", so you still need either dynamic linking or arbitrary on-the-fly recompilation phases on already running apps, because your Java code is already running when you learn that you have to load this library. Another similar mechanism in Java is ClassLoader, which dynamically loads in more Java code into an already running app from arbitrary jar files on the disk (it's basically the Java equivalent of loading DLLs).
 
thread New idea: Re-linkable libraries in ForwardCom new - Agner - 2017-04-27
last replythread New idea: Re-linkable libraries in ForwardCom new - Hubert Lamontagne - 2017-04-27
last replythread New idea: Re-linkable libraries in ForwardCom new - Agner - 2017-04-27
last replythread New idea: Re-linkable libraries in ForwardCom new - Hubert Lamontagne - 2017-05-10
last replythread New idea: Re-linkable libraries in ForwardCom new - Agner - 2017-05-11
last replythread New idea: Re-linkable libraries in ForwardCom - Hubert Lamontagne - 2017-05-12
last reply New idea: Re-linkable libraries in ForwardCom new - Agner - 2017-05-13