Appendix C. Properties

Table of Contents
Properties Set by the User
Predefined properties

This appendix contains a list of all predefined properties in Jamaica

Properties Set by the User

The standard libraries that are delivered with JamaicaVM can be configured by setting specific Java properties. A property is a string value that has an assigned value. The property is passed to the Java code via the jamaicavm option -D<name>=<value> or, when using the Builder command jamaica, via option -XdefineProperty+=<name>=<value>.

Table C-1. Properties set by the user

PropertyMeaning
jamaica.cost_monitoring_accuracy = <num>This integer property specifies the resolution of the cost monitoring that is used for RTSJ's cost overrun handlers. The accuracy is given in nanoseconds, the default value is 5000000, i.e., and accuracy 5ms. The accuracy specifies the maximum value the actual cost may exceed the given cost budget before a cost overrun handler is fired. A high accuracy (a lower value) causes a higher runtime overhead since more frequent cost budget checking is required.
jamaica.cpu_mhz = <num>This integer option specifies the CPU speed of the system JamaicaVM executes on. This number is used on systems that have a CPU cycle counter to measure execution time during for RTSJ's cost monitoring functions. If the CPU speed is not set and it could not be determined from the system (e.g., on Linux via reading file /proc/cpuinfo), the CPU speed will be measured on VM startup and a warning will be printed. An example setting for a system running at 1.8GHz would be -Djamaica.cpu_mhz=1800.0.
jamaica.err_to_fileIf a file name is given, all output sent to System.err will be redirected to this file.
jamaica.err_to_nullIf set to true, all output sent to System.err will be ignored. This is useful for graphical applications if textual output is very slow. The default value for this property is false.
jamaica.fontproperties = <resource-file>This property specifies the name of a resource that instructs JamaicaVM which fonts to load. The default value is the file com/aicas/jamaica/awt/fonts/font.properties. This file may be replaced by a user defined file to change the set of supported fonts. The specified file itself is a property file that maps font names to BDF resource file names.
jamaica.gcthread_pri = <n>If set to an integer value larger than or equal to 0, this property instructs the virtual machine to launch a garbage collection thread at the given Java priority. A value of 0 will result in a Java priority 1 with micro adjustment -1, i.e., the scheduler will give preference to other threads running at priority 1. By default, a GC thread is not used. See the Section called Using a GC thread in Chapter 7for more details.
jamaica.jitReserved for future use.
jamaica.loadLibrary_ignore_errorThis property specifies whether every unsuccessful attempt to load a native library dynamically via System.loadLibrary() should be ignored by the VM at runtime. If set to true and System.loadLibrary() fails, no UnsatifiedLinkError will be thrown at runtime. The default value for this property is false.
jamaica.no_sig_int_handlerIf this boolean property is set, then no default handler for POSIX signal SIGINT (control+`c') will be created. The default handler that is used when this property is not set prints "*** break." to System.err and calls System.exit(130).
jamaica.no_sig_quit_handlerIf this boolean property is set, then no default handler for POSIX signal SIGQUIT (control+`\') will be created. The default handler that is used when this property is not set prints the current thread states via a call to com.aicas.jamaica.lang.Debug.dump ThreadStates().
jamaica.no_sig_term_handlerIf this boolean property is set, then no default handler for POSIX signal SIGTERM (default signal sent by kill) will be created. The default handler that is used when this property is not set prints "*** terminate.'" to System.err and calls System.exit(130).
jamaica.out_to_fileIf a file name is given, all output sent to System.out will be redirected to this file.
jamaica.out_to_nullIf set to true, all output sent to System.out will be ignored. This is useful for graphical applications if textual output is very slow. The default value for this property is false.
jamaica.profile_request_port = <port>

When using the profiling version of JamaicaVM (jamaicavmp or an application built with "-profile=true"), then this property may be set to an integer value larger than 0 to permit an external request to dump the profile information at any point in time.

Dumping the profiling data is done via the Java application com.aicas.jamaica.lang.Profile. First, execute your application setting this property to the requested network port number:

 > jamaicavmp -Djamaica.profile_re quest_port=<port #> Main

Then, dumping the profile can be requested from a remote system via the following command, giving the target systems IP address and the selected port number:

 > jamaicavm com.aicas.jamaica.lan g.Profile <IP-address> <port #>
      

Requests to print the profiling data might be sent repeatedly, e.g., to obtain accurate profiling information for a certain part of the execution of an application.

jamaica.reservation_thread_priority = <n>If set to an integer value larger than or equal to 0, this property instructs the virtual machine to run the memory reservation thread at the given Java priority. A value of 0 will result at a Java priority 1 with micro adjustment -1, i.e., the scheduler will give preference to other threads running at priority 1. By default, the priority of the reservation thread is set to 0 (i.e., Java priority 1 with micro adjustment -1). See the Section called Reserved memory in Chapter 7 for more details.
jamaica.scheduler_events_portThis property defines the port where the ThreadMonitor can connect to receive scheduler event notifications.
jamaica.scheduler_events_port_ blockingThis property defines the port where the ThreadMonitor can connect to receive scheduler event notifications. The Jamaica runtime system stops before entering the main method and waits for the ThreadMonitor to connect.
jamaica.softref.minfreeMinimum percentage of free memory for soft references to survive a GC cycle. If the amount of free memory drops below this threshold, soft references may be cleared. In JamaicaVM, the finalizer thread is responsible for clearing soft references. The default value for this property is 10%.
jamaica.weakref.minfreeMinimum percentage of free memory for weak references to survive a GC cycle. If the amount of free memory drops below this threshold, weak references may be cleared. In JamaicaVM, the finalizer thread is responsible for clearing weak references. The default value for this property is 20%.
jamaica.xprof = <n>If set to a integer value larger than 0 and less or equal to 1000, this property enables the jamaicavm's option -Xprof. If set, the property's value specifies the number of profiling samples to be taken per second, e.g., -Djamaica.xprof=100 causes the profiling to make 100 samples per second. See the Section called -Xprof in Chapter 5 for more details.