PR27676, PowerPC missing extended dcbt, dcbtst mnemonics
authorAlan Modra <amodra@gmail.com>
Sun, 4 Apr 2021 22:47:06 +0000 (08:17 +0930)
committerAlan Modra <amodra@gmail.com>
Wed, 7 Apr 2021 22:58:11 +0000 (08:28 +0930)
commit97bf40d859ffe44892b3ad2c62f011fd26fca699
tree683ce48a3eb768ba21d6ad1127f5c12d597aa400
parente97007b64a388ece1789f6c2cd51d2768e3b4829
PR27676, PowerPC missing extended dcbt, dcbtst mnemonics

Note that this doesn't implement the ISA to the letter regarding
dcbtds (and dcbtstds), which says that the TH field may be zero.  That
doesn't make sense because allowing TH=0 would mean you no long have a
dcbtds but rather a dcbtct instruction.  I'm interpreting the ISA
wording about allowing TH=0 to mean that the TH field of dcbtds is
optional (in which case the TH value is 0b1000).

opcodes/
PR 27676
* ppc-opc.c (DCBT_EO): Move earlier.
(insert_thct, extract_thct, insert_thds, extract_thds): New functions.
(powerpc_operands): Add THCT and THDS entries.
(powerpc_opcodes): Add dcbtstct, dcbtstds, dcbna, dcbtct, dcbtds.
gas/
* testsuite/gas/ppc/pr27676.d,
* testsuite/gas/ppc/pr27676.s: New test.
* testsuite/gas/ppc/ppc.exp: Run it.
* testsuite/gas/ppc/dcbt.d: Update.
* testsuite/gas/ppc/power4_32.d: Update.
gas/ChangeLog
gas/testsuite/gas/ppc/dcbt.d
gas/testsuite/gas/ppc/power4_32.d
gas/testsuite/gas/ppc/ppc.exp
gas/testsuite/gas/ppc/pr27676.d [new file with mode: 0644]
gas/testsuite/gas/ppc/pr27676.s [new file with mode: 0644]
opcodes/ChangeLog
opcodes/ppc-opc.c