Excelsior Logo Excelsior Logo
Company Products Services Resources Contact
Store Buy    Download Download    Support Support    Forum  Forum    Blog  Blog   
Search
 Search   
Sitemap
 Sitemap   
Request a Call  Request a Call   

Excelsior JET Technical FAQ List

This page contains answers to the most frequently asked technical questions about the Excelsior JET product and its usage. If your question is not answered here, please submit it to Excelsior Technical Support. or directly to the JET team.

Note: We are currently migrating this list to the Knowledge Base. Please do not bookmark this page as it will eventually become a list of pointers to KB articles.

Installation Problems

  1. New profile creation takes a lot of time due to slow compilation of Java 2 classes

Compilation Problems

  1. During compilation of my project, JC issues an "out of memory" message and then terminates
  2. During compilation of my project, intensive memory paging occurs
  3. Class, method, or field not found when compiling a third-party JAR or ZIP

Run-Time Problems

  1. How do I suppress the console window in my AWT/Swing application?
  2. How do I set Java properties at the very startup of my application?
  3. How do I control my application's memory consumption?
  4. The compiled application cannot find resources (images, etc.)
  5. Stack overflow occurs during execution
  6. Stack backtrace does not work

Application Performance

  1. Which objects are allocated on the stack when I enable the option GENSTACKALLOC?
  2. My application takes much more RAM if I split it into DLLs than when it was a single EXE

Interoperability

  1. How do I use a JET-compiled DLL from my C/C++/Delphi/VB6/VBA program?
  2. How do I call a function that resides in a C DLL from my JET-compiled Java program?

Deployment

  1. The EXE created by JET does not work on other computers due to missing DLLs.
  2. How do I attach an icon to my JET-compiled executable?


New profile creation takes a lot of time due to slow compilation of Java 2 classes

Possible Cause: Your system does not meet the minimum requirements. You should have at least 384MB of physical RAM for creating a profile.

Resolution: Add more RAM to your system.

Possible Cause: Processes running in the background occupy too much memory.

Resolution: Add more RAM to your system or stop the processes you do not absolutely need running during JET installation.

Possible Cause: There is an antivirus monitor running, which checks JRE jar files for viruses each time they are accessed by JET.

Resolution: Disable the antivirus monitor before installing JET and re-enable it after the installation ends.

Back to top

During compilation of my project, JC issues an "out of memory" message and then terminates

Reason: The current setting of memory usage limit is too small for compilation of your program.

Resolution: Increase the value of COMPILERHEAP in your project file or on the command line, for instance:

jc MyApp.jar -compilerheap=90000000 The default value of COMPILERHEAP may be inspected by running jc in the EQUATIONS submode: jc =e

Back to top

During compilation of my project, a lot of memory paging occurs

Reason: The current setting of memory usage limit is too large for your system.

Resolution: Close all applications that you do not need at the moment. If it does not help, reduce the value of COMPILERHEAP specified in your project file or on the command line, for instance:

jc MyApp.jar -compilerheap=20000000 The default value of COMPILERHEAP may be inspected by running jc in the EQUATIONS submode: jc =e

Back to top

Class, method, or field not found when compiling a third-party JAR or ZIP

See Knowledge Base article 000011.

Back to top

How do I suppress the console window in my AWT/Swing application?

See Knowledge Base article 000013.

Back to top

How do I set Java properties at the very startup of my application?

Properties may be set in a batch file using the JETVMPROP environment variable:

SET JETVMPROP=-Dp1name -Dp2name:p2value Notice that the colon character has to be used whereas Java launcher command line syntax for defining properties includes the equals sign after property name. The reason is that many Windows command interpreters, including standard Windows 95/98 ones, do not permit more than one equals sign in a SET statement.

Back to top

How do I control my application's memory consumption?

See Knowledge Base article 000002.

Back to top

The compiled application cannot find resources (images, etc.)

See Knowledge Base article 000014.

Back to top

Stack overflow occurs during execution

The default size of a thread's stack is 900,000 bytes, which is sufficient for most applications. However, a recursive algorithm may require a larger stack. If your application crashes on a stack overflow, use the STACKLIMIT equation in your project file or on the commmand line to adjust the size of threads' stacks:

-stacklimit=1200000

Back to top

Stack backtrace does not work

See Knowledge Base article 000015.

Back to top

Which objects are allocated on the stack when I enable the option GENSTACKALLOC?

According to the Java standard, all objects are allocated on the heap. However, a particular object that is never assigned to a static field or a field of a heap object may be safely allocated on the stack. Typically, these are temporary objects local to a particular method. Stack allocation works much faster and also reduces GC impact on performance.

For a detailed description of this optimization, refer to the respective research paper.

Back to top

My application takes much more RAM if I split it into DLLs than when it was a single EXE

Reason: By default, a DLL is mapped onto the same base address as EXEs (0x400000). The operating system resolves this conflict by relocating each DLL to another base address during load. For relocation, the entire code and data segments of the DLL are loaded into memory. Without relocation, code and data are loaded on demand in 4KB pages.

Resolution: For each DLL (and, optionally, EXE) that constitute your application, specify a different image base address in its project file, so that their binary images do not overlap in the address space:

-imagebase=0x12D00000 You may use EXE and DLL sizes to determine the proper base addresses. For instance, if you app cosists of one EXE and one DLL, and the size of EXE is 1MB (0x100000), use: % In EXE.PRJ:
-imagebase=0x400000

% In DLL.PRJ:
-imagebase=0x500000

Back to top

How do I use a JET-compiled DLL from my C/C++/Delphi/VB6/VBA program?

In C, C++, and Delphi, use the standard Invocation API. See sample programs in the SAMPLES\Invocation subdirectory of your JET installation.

In VB6/VBA, interfacing to Java is only possible via COM. Excelsior JET 3.0 and above comes with COM-based sample programs in both VB6 and VBA. Note that there is a flaw in versions prior to 3.0 that makes those samples work incorrectly.

Back to top

How do I call a function that resides in a C DLL from my JET-compiled Java program?

JET fully supports Java Native Interface (JNI), which is the only standard way to call a native code function from Java. However, direct usage of JNI is very inconvenient and error prone. We recommend you to use xFunction - our Java library for calling native code functions from Java without using JNI and C programming at all.

xFunction itself is implemented using JNI and reflection and therefore is 100% Java 2 Runtime compatible.

Back to top

The resulting EXE does not work on other computers due to missing DLLs

See Knowledge Base article 000012 and this item from the main JET FAQ.

Back to top

How do I attach an icon to my JET-compiled executable?

See Article 000003 in the Knowledge Base.

Back to top

Home | Company | Products | Services | Resources | Blog | Contact | Request a Call

Site: Search | Sitemap | Forum | Credits

© 1999-2007 Excelsior LLC. All Rights Reserved.