public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH 0/2] aarch64: add Branch Record Buffer extension instructions
@ 2024-06-07 13:59 Claudio Bantaloukas
  2024-06-07 13:59 ` [PATCH 1/2] " Claudio Bantaloukas
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Claudio Bantaloukas @ 2024-06-07 13:59 UTC (permalink / raw)
  To: binutils; +Cc: Claudio Bantaloukas


The FEAT_BRBE extension provides two aliases of sys:
- brb iall (Invalidates all Branch records in the Branch Record Buffer)
- brb inj (Injects the Branch Record held in BRBINFINJ_EL1,
  BRBSRCINJ_EL1, and BRBTGTINJ_EL1 into the Branch Record Buffer)

This patch adds:
- the feature option "brbe" that must be added for the aliases to be available
- a new operand flag AARCH64_OPND_Rt_IN_SYS_ALIASES that warns in a comment
  when Rt is set to the non default value 0b11111 (it is constrained
  unpredictable whether the instruction is undefined or behaves as if the Rt
  field is set to 0b11111).
- a new operand flag AARCH64_OPND_BRBOP that encodes and decodes Op2 values
  from bit 5
- support for the two brb aliases above

See:
- https://developer.arm.com/documentation/ddi0602/2024-03/Base-Instructions/BRB--Branch-Record-Buffer--an-alias-of-SYS-?lang=en
- https://developer.arm.com/documentation/ddi0601/2024-03/AArch64-Instructions/BRB-INJ--Branch-Record-Injection-into-the-Branch-Record-Buffer?lang=en
- https://developer.arm.com/documentation/ddi0601/2024-03/AArch64-Instructions/BRB-IALL--Invalidate-the-Branch-Record-Buffer?lang=en

---

Hi,

is this ok for master? I don't have commit rights, could someone merge this for me please?

Tested on aarch64-none-elf and aarch64-unknown-linux-gnu

Thanks,
Claudio


Claudio Bantaloukas (2):
  aarch64: add Branch Record Buffer extension instructions
  aarch64: add Branch Record Buffer extension instructions

 gas/config/tc-aarch64.c                      |    8 +
 gas/doc/c-aarch64.texi                       |    2 +
 gas/testsuite/gas/aarch64/brbe-brb-bad.d     |    2 +
 gas/testsuite/gas/aarch64/brbe-brb-bad.l     |    4 +
 gas/testsuite/gas/aarch64/brbe-brb-bad.s     |    6 +
 gas/testsuite/gas/aarch64/brbe-brb-inst.d    |   14 +
 gas/testsuite/gas/aarch64/brbe-brb-inst.s    |    5 +
 gas/testsuite/gas/aarch64/brbe-brb-invalid.d |    3 +
 gas/testsuite/gas/aarch64/brbe-brb-invalid.l |    3 +
 gas/testsuite/gas/aarch64/brbe-brb.d         |   12 +
 gas/testsuite/gas/aarch64/brbe-brb.s         |    5 +
 include/opcode/aarch64.h                     |    7 +-
 opcodes/aarch64-asm-2.c                      |  363 +-
 opcodes/aarch64-dis-2.c                      | 4523 +++++++++---------
 opcodes/aarch64-opc-2.c                      |   18 +-
 opcodes/aarch64-opc.c                        |   24 +
 opcodes/aarch64-opc.h                        |    1 +
 opcodes/aarch64-tbl.h                        |   15 +
 18 files changed, 2566 insertions(+), 2449 deletions(-)
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-bad.d
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-bad.l
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-bad.s
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-inst.d
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-inst.s
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-invalid.d
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb-invalid.l
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb.d
 create mode 100644 gas/testsuite/gas/aarch64/brbe-brb.s

-- 
2.43.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2024-06-25 17:00 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-07 13:59 [PATCH 0/2] aarch64: add Branch Record Buffer extension instructions Claudio Bantaloukas
2024-06-07 13:59 ` [PATCH 1/2] " Claudio Bantaloukas
2024-06-10  6:58   ` Jan Beulich
2024-06-10 11:00     ` Claudio Bantaloukas
2024-06-25 17:00       ` Richard Earnshaw (lists)
2024-06-12 13:52     ` Richard Earnshaw (lists)
2024-06-07 13:59 ` [PATCH 2/2] " Claudio Bantaloukas
2024-06-12 13:59 ` [PATCH 0/2] " Richard Earnshaw (lists)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).