aboutsummaryrefslogtreecommitdiff
path: root/include/opcode
diff options
context:
space:
mode:
authorDimitar Dimitrov <dimitar@dinux.eu>2026-03-06 23:40:23 +0200
committerDimitar Dimitrov <dimitar@dinux.eu>2026-03-15 09:44:02 +0200
commit77cb5ee0f268dfb77b4cbd3a675b56fe5f5ae234 (patch)
treef657832e8918fc12520e8f0ec23abc1684b6dfcb /include/opcode
parentfc9ff2750b1710f9eba1504b04f9c7a65f6d37be (diff)
downloadfsf-binutils-gdb-77cb5ee0f268dfb77b4cbd3a675b56fe5f5ae234.tar.gz
fsf-binutils-gdb-77cb5ee0f268dfb77b4cbd3a675b56fe5f5ae234.tar.bz2
fsf-binutils-gdb-77cb5ee0f268dfb77b4cbd3a675b56fe5f5ae234.zip
gas: pru: Add flag to select core revision
Add new command line option to select PRU core revision to assemble for. This new option is used to limit the available opcodes to what the selected revision supports. References: - https://www.ti.com/lit/ug/spruij2/spruij2.pdf Table 3. PRU Core Revision Comparison - https://github.com/TexasInstruments/open-pru/blob/3cffcaae73c708ce15337a9880ec91dc9b03aaa5/docs/PRU%20Assembly%20Instruction%20Cheat%20Sheet.md#core-revision-differences Core Revision Differences Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
Diffstat (limited to 'include/opcode')
-rw-r--r--include/opcode/pru.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/opcode/pru.h b/include/opcode/pru.h
index 379b11e56a7..dccd0c8305a 100644
--- a/include/opcode/pru.h
+++ b/include/opcode/pru.h
@@ -30,6 +30,15 @@
* access various opcode fields.
****************************************************************************/
+/* PRU core revision, as defined by TI. */
+enum pru_core_revision
+{
+ REV_V1 = 1,
+ REV_V2,
+ REV_V3,
+ REV_V4,
+};
+
/* Identify different overflow situations for error messages. */
enum overflow_type
{
@@ -115,6 +124,8 @@ enum pru_instr_type
struct pru_opcode
{
const char *name; /* The name of the instruction. */
+ enum pru_core_revision core_rev; /* First PRU core revision supporting
+ this instruction. */
enum pru_instr_type type; /* Instruction type. Used for fast indexing
by the simulator. */
const char *args; /* A string describing the arguments for this