void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
This hap is triggered on every word sent on a arinc429_bus object. In the hap handler, the last_word attribute can be read or modified. Setting it to -1 will drop the packet.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *command_name);
Triggered when a CLI command is defined.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Internal: Similar to Component_Hierarchy_Change but also triggered for components that are not part of any complete hierarchy including non-instantiated components.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *top_level_component);
Internal: Triggered when an instantiated component hierarchy is modified. The hap is associated with the top-level component of the modified hierarchy.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *break_string);
break_id
Triggered when the output matches a string set to break on. The break_id is the number associated with the string breakpoint.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 physical_address,
int64 access_type,
int64 size);
Triggered when an access to a memory-space has no target and the access does not match any entry in the outside_memory_whitelist CPU attribute. The default handler for this hap will signal an error and stop the simulation.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 trap_number);
trap_number
SPARC: Triggered when an asynchronous trap occurs. This is either an external interrupt trap number == 0x60 or interrupt level n trap number 0x41 - 0x4F, or an asynchronous trap initiated by the user calling trap_cpu in the sparc-interrupt interface. The Core_External_Interrupt can also be used to catch interrupts, the difference is that Core_Asynchronous_Trap is only triggered if interrupts are enabled.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered, typically by SIM_quit, when Simics exits. The Simics API is not allowed to be used in the hap callbacks (see the Core_Clean_At_Exit hap description if access to the Simics API is needed).
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered on an object when breakpoints attached to that object are inserted, deleted or changed in any way.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 breakpoint_number,
generic_transaction_t *memop);
breakpoint_number
Triggered when a breakpoint is triggered. breakpoint_number is the breakpoint number (as returned by SIM_breakpoint). If there are multiple breakpoints on an instruction then all installed haps will be run before control is transferred to the frontend (when applicable). The supplied memop can be used to figure out details about the transaction.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered, typically by SIM_quit, if Simics exits cleanly, i.e. in Global Context. The Simics API is available. Cleanup code should typically run in the Core_At_Exit hap callbacks instead if possible.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *class_name);
Triggered when a new configuration class has been registered. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *class_name);
Triggered when a configuration class has been unregistered. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *old_cell,
conf_object_t *new_cell);
Triggered when a clock object changes cell
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *old_clock,
conf_object_t *new_clock);
Triggered when an object's reference clock is changed
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when a new configuration object's init_object method returns successfully, but before the object's attributes are set and before the object's finalize_instance method is called. Since the object is not fully created hap callbacks must not access any of the object's attributes or call any methods on the object's interfaces. Callbacks are called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when a configuration object has been created and finalized. This hap will always be followed by a Core_Conf_Objects_Created hap, but this hap can be triggered for more than one object before the Core_Conf_Objects_Created hap.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *object_name);
Triggered after a configuration object has been deleted. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered just before a configuration object is deleted. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *old_name);
Triggered after an object's name has changed. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered if and only if at least one Core_Conf_Object_Created hap has been triggered.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when one or more objects have been deleted from the configuration after the Core_Conf_Object_Delete hap has been triggered for all of the objects. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when a configuration has been loaded. This hap can be triggered several times during a session since it is possible to append a new configuration to the existing one. In most cases it is better to use the finalize_instance function in the class_data_t instead. That function is called when the object creation is finished. Callbacks are called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *other_ctx,
conf_object_t *cpu);
Triggered when this context replaces another context as the current context of a processor.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *cpu);
Triggered when the context is set to the current context for a processor.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
conf_object_t *other_ctx,
conf_object_t *cpu);
Triggered when another context replaces this context as the current context of a processor.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when the context is updated in some way.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered at the (re)start of the simulation. The Core_Simulation_Stopped hap is called when the simulation is stopped. Callbacks are called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 register_number);
register_number
Triggered when a control register is read. The hap is called before the read is performed; thus no registers have been modified.
Note that if the callback routine breaks to the frontend by raising an exception, the instruction will be replayed possibly causing repeated memory operations.
For x86 processors, this hap is triggered when a control register is read using a mov or smsw instruction (i.e. only explicit reads). Also the hap is triggered when MSRs are read with rdmsr, rdtsc or rdtscp instructions.
For PowerPC processors, this hap is triggered by the mfspr, mfmsr mfsr and mfsrin instructions (i.e. only explicit reads).
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 register_number,
int64 value);
register_number
Triggered when a control register is written. Note that value is not (necessarily) the final contents in the register. When the callback is called, the processor register has not yet been updated with the new value.
If the callback routine breaks to the frontend by raising an exception, the instruction will be replayed possibly causing repeated memory operations.
For x86 processors, this hap is triggered by clts, lmsw, and mov. Also the hap is triggered when MSRs are written with wrmsr instruction. Page fault updates of CR2 should be caught with the Core_Exception hap.
For PowerPC processors, this hap is triggered by the mtspr, mtmsr, mtsr and mtsrin instructions (i.e. only explicit writes).
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 type,
int64 virtual_address,
int64 physical_address,
int64 counter);
Triggered when the DSTC flushes a line's hit counter. It reports how many hits the STC recorded since the line was inserted.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
generic_transaction_t *memop);
Triggered when a device access is performed.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 exception_number);
exception_number
Triggered when an exception/trap is taken by a processor. The hap occurs before side-effects, control transfers included, have taken place.
Interrupting the simulation by calling SIM_break_simulation inside the hap will cause the simulation to stop right before the exception (and the trapping instruction, if any). The simulation state will then be as it was prior to the execution of the instruction or exception. Continuing the simulation will then re-run the exception, this time without calling hap functions.
Depending on the processor model, some state may actually have changed in an idempotent way when the hap occurs, but this should not be relied upon.
The exact meaning of the exception number depends on the simulated processor architecture. The exception interface can be used to translate the number to an exception name.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 exception_number);
exception_number
Triggered when an exception/trap handler finishes execution. The hap is triggered before any processor state has changed.
The following instructions trigger this hap (by processor class):
MIPS: eret and deret
PowerPC (32): rfi and rfci
PowerPC (64): rfi, rfid and hrfid
SH: rte
SPARC: done and retry
x86/x86-64: The iret family.
The exception_number parameter is only valid for SPARC processors.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 source_mid);
source_mid
(SPARC only) Triggered when a processor receives an external interrupt. The trigger object is the receiving cpu, and source_mid is the mid of the sending cpu/device. The hap will be triggered even if interrupts are disabled, but not if the interrupt logic is busy.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 old_freq,
int64 new_freq);
Triggered when the frequency of a cycle queue has changed. Parameters are the old and new frequencies in Hz.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 hap_number,
int64 range_low,
int64 range_high);
hap_number
Triggered before a callback is installed. The callback called by this hap is not allowed to install any hap callbacks.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 hap_number,
int64 range_low,
int64 range_high);
hap_number
Triggered after a callback has been unregistered. The callback called by this hap is not allowed to remove any hap callbacks.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *hap_name);
Triggered when a new hap type is added to the simulator. The hap is not triggered for the initial set of core haps. Callbacks called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int type,
int onoff);
Triggered on I/O activity in an image object.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int log_group_mask);
Triggered when the active log groups of an object changes
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int new_log_level);
Triggered when the log level of an object changes
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int type,
char *message);
log type
Triggered when a log message is registered that is supposed to be logged, i.e. with matching type and group(s) and level.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int type,
char *message,
int level,
int64 group);
Triggered always when a log message is registered regardless of the current log level
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int type,
char *message,
int level,
int64 group);
Triggered when a log message is registered that is supposed to be logged according to the log level.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int type,
char *message,
int level,
int64 group);
Triggered when a log message is registered that is supposed to be logged, i.e. with matching type and group(s) and level.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 parameter);
parameter
Triggered when Simics executes a magic instruction. The parameter is taken from the instruction and is architecture-dependent.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Experimental
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 old_mode,
int64 new_mode);
Triggered when a processor changes privilege mode for whatever reason; usually an exception or return from an exception. The hap occurs after the processor has changed mode but before any instructions have been executed in the new mode.
For x86 processors, the modes are Sim_CPU_Mode_User for CPL 3, and Sim_CPU_Mode_Supervisor for CPL 0-2.
For other processors, the modes are Sim_CPU_Mode_User or Sim_CPU_Mode_Supervisor. Some processors also has the Sim_CPU_Mode_Hypervisor mode.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *module_name);
Triggered when a module is loaded into Simics. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int on/off);
Triggered when the multicore-accelerator feature is enabled or disabled.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int on/off);
Triggered when multithreaded simulation is enabled or disabled.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int line,
char *file,
char *rcsid,
char *message,
int64 data);
Triggered when the simulator encounters unimplemented functionality.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when an attribute in the prefs object is written. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when the scheduling order of the processors has changed. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when a new Simics project directory is selected. Called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int simulation_mode);
simulation_mode
Triggered when the simulation mode for the processor has changed.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 exception,
char *error_string);
exception
Triggered when the simulation stops. The exception argument will always be SimExc_No_Exception, and error_string will always be NULL. After this hap, simulation will not advance (triggering Core_Continuation) until SIM_continue is called again. Callbacks are called in Global Context.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 type);
type
Triggered when an synchronizing instruction is executed. The type parameter describe what kind of instruction is executing. Its encoding is specific to each architecture.
For SH, this hap is triggered when a synco instruction is executed. The type contains 0.
For SPARC-V9, this hap is triggered when a membar or stbar instruction is executed. For membar, the type contains the 7-bit field cmask|mmask specified in the instruction. For stbar, the type is 8 (equivalent to membar #StoreStore).
For x86, this hap is triggered when a fence instruction is executed. The type is set from the list provided by the x86_sync_instruction_type_t enum.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered on an object when a timing model or snoop device is inserted, deleted, or changed.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when the list of user comments for a session has changed
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *pcap_file,
int num_injected,
int pcap_num_pkgs,
int auto_restart);
Triggered by the eth_injector object when all contents of the pcap file has been sent. The callback function will have the pcap file name, next packet index, total number of packets in the pcap file, and auto-restart as arguments.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when the bus is reset. It is invoked after calculating the default topology. During the hap the self_ids attribute can be used to change the self id packets sent to the devices on the bus. The connected_devices attribute can also be changed to modify the mapping from physical id to device.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered when an packet travels through a firewire bus. During the hap handler the current_transfer attribute of the bus can be used to inspect and/or change the current transfer. If you set it to NULL the transfer is aborted and Firewire_V2_Ack_No_Ack is returned to the initiator of the transfer.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 gfx_break);
break_id
Triggered when a graphical breakpoint matches the screen. break_id is the number returned when a breakpoint is set.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int break-id);
Simics internal. Triggered on a break-io access.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
generic_transaction_t *memop,
char *port,
int idx,
int func,
int64 offset);
Simics internal. Triggered on an access to a device register traced with trace-io command.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
id
Simics internal
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Simics internal. Triggered when the time quantum has changed. The hap is supported in Simics 5 even though it is marked as internal.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 index,
int64 old_value,
int64 new_value);
index
This hap is triggered when the DS12887-c NVRAM memory is changed.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int enabled);
Internal: Notifies change of realtime enabled status
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 command_number,
int64 start,
int64 len);
command_number
Triggered when a SCSI command is received by a SCSI device. The parameters start and len are only used for read and write commands.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int enabled);
Triggered when NAPT is enabled or disabled in a service-node.The argument is 0 when disabled and 1 when enabled.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
Triggered when a TLB entry is filled after a table walk. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
Triggered when a TLB entry is filled after a table walk. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
Triggered when a TLB entry is invalidated. The invalidation can be caused by an INVLPG instruction, a write to CR3, or by changes to paging bits in CR0 and CR4. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
Triggered when a TLB entry is invalidated. The invalidation can be caused by an INVLPG instruction, a write to CR3, or by changes to paging bits in CR0 and CR4. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear_address);
linear_address
Triggered when a DTLB miss occurs.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear_address);
linear_address
Triggered when an ITLB miss occurs.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
This hap is triggered when a TLB entry is replaced by another. The parameters relate to the old entry, and the insertion of the new entry will trigger a fill hap. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
int64 linear,
int64 physical,
int64 page_size);
page_size
This hap is triggered when a TLB entry is replaced by another. The parameters relate to the old entry, and the insertion of the new entry will trigger a fill hap. Page size encoding: 0==4k, 1==2M, 2==4M, 3==1G.
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj,
char *state);
Triggered when the run state changes; not triggered in batch mode. The argument is one of:- "Stopped"
- simulation stopped and may not run
- "Stopped_Fwd"
- stopped and may run forward
- "Forwarding"
- simulation is running forward
void (*) (lang_void *callback_data,
conf_object_t *trigger_obj);
Triggered before picture on screen is updated