- 18.01 (released) ...
Melting Ice Technology
- Types of compilation provided by Melting Ice
- Additional detail
Types of compilation provided by Melting Ice
EiffelStudio relies on Melting Ice Technology, the proprietary compilation mechanism of Eiffel Software, which offers three forms of compilation: melting, freezing, and finalizing.
Melting is used for making a few changes during typical development activity. The fastest of the mechanisms, typically taking a few seconds after small changes. Melting time is proportional to the size of the changed parts and affected classes, while the time needed to freeze or finalize is partly proportional to the size of the whole system. As long as you do not include new external C/C++ code, a C/C++ compiler is not required. However, execution speed is not optimal. The generated executable is debuggable.
Freezing generates C code from the active system, and then compiles it into machine code; you must have a C/C++ compiler installed. You need to use this option if you add new agents or external C/C++ calls. Unless you add external code, you can re-freeze every couple of days. The rest of the time, you can melt your software to receive immediate feedback. The speed is still slower than when finalizing, but the generated executable is still debuggable.
Finalizing delivers a production version (intermediate or final) of your software. It can be used to measure its performance in operational conditions. Finalization performs extensive time and space optimizations that enable Eiffel to match the efficiency of C/C++; it also creates a stand-alone C package that you can use for cross-platform development. Because of all the optimizations involved, finalizing takes the most time, and the generated executable is not debuggable.
Precompilation allows you to create a library in which the classes are already compiled, so when it is used, compile times are decreased. EiffelStudio comes with optional precompiled forms of commonly used libraries. For example, in the Microsoft Windows distribution you can opt for precompiled EiffelBase, or WEL + EiffelBase, or EiffelVision 2 + WEL + EiffelBase. As indicated by these options, the precompilation of a library must also include any other library upon which the target library depends. In other words, it would not be possible to precompile EiffelVision 2 without also including WEL and EiffelBase, too.
Melting and freezing generate an executable in the EIFGENs|target_name|W_code subdirectory of the project directory. The executable is composed of a standard executable file named after the system, and of a < system name>.melted file, which is called the Eiffel update file. Although it is recommended to finalize the system when running it from outside EiffelStudio (since the performance is better), it is possible to launch a melted/frozen executable. However, the Eiffel update file is necessary, the executable alone will not run.
Basically, the Eiffel update file incorporates the changes that have been made to the system since it was last frozen. Therefore, it is very small when the system has just been frozen, and progressively becomes bigger each time the system is melted. On the contrary, the executable is only modified when the system is frozen, never when it is melted.
The contents of the Eiffel update file are in a byte code representation which is dynamically interpreted at run-time.