Changes

Jump to navigation Jump to search
666 bytes added ,  14:48, 15 April 2020
no edit summary
Line 1: Line 1: −
JIT is a sysmodule for run-time code generation on development kits (allowing for overlapping R-X and RW- views of memory). This system module is not present in retail units.
+
JIT is a sysmodule for run-time code generation (allowing for overlapping R-X and RW- views of memory). This was added to retail with [10.0.0+]. This was also supported in sdknso for a number of versions prior.
 +
 
 +
nnMain just initializes [[RO_services|ro:1]], then starts hosting the service from the main-thread with max_sessions=1 (threads are not created for service-hosting).
 +
 
 +
This is intended to only be used by Applications. The initialization in sdknso uses [[Applet_Manager_services#PrepareForJit|PrepareForJit]] at the start. sdknso later uses [[SVC|svcCreateCodeMemory]].
 +
 
 +
This loads the user-specified [[NRO]] into sysmodule-context ("DllPlugin"), and calls various symbols from that NRO. It seems the code writing (in cmd GenerateCode) is done via symbol-calling, allowing the NRO to handle input_buffer->code translation+writing.
    
= jit:u =
 
= jit:u =

Navigation menu