Closed thestr4ng3r closed 2 years ago
An alternative would be to just add an encoding field here, as part of code_exec
events:
https://github.com/BinaryAnalysisPlatform/bap/blob/5b1acc00804a8090c09f6785138e50a42cf00827/lib/bap_traces/bap_trace_event_types.ml#L11-L16
That would be much simpler and would mean "the encoding of this instruction" rather than "switch to a different encoding mode". Depends on what we actually want specifically...
An alternative would be to just add an encoding field here, as part of
code_exec
events:That would be much simpler and would mean "the encoding of this instruction" rather than "switch to a different encoding mode". Depends on what we actually want specifically...
The chunk representation is fixed, we do not want to break protocols and interfaces by changing it.
A mode event expresses a switch of some processor mode affecting the execution of all following instructions. The possible values and their meanings depend on the target. At the moment, the only one that uses modes is arm, where the mode indicates whether or not thumb mode is used.
In order to make use of it, it can be provided in
Mode.slot
ofTheory.program
, such that the computationTheory.Label.encoding
can access it, if available.