aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2022-03-16 10:05:37 +1030
committerAlan Modra <amodra@gmail.com>2022-03-16 10:05:37 +1030
commitf304c63d24ef12f3c01b978929ed026b1ec85f56 (patch)
treee9c07556d20437ddd0ae62c8d76c4f7494bdecfa /gas
parent42952a9605b00e4b1d6514de9b30e56d4dcb8bbe (diff)
downloadgdb-f304c63d24ef12f3c01b978929ed026b1ec85f56.zip
gdb-f304c63d24ef12f3c01b978929ed026b1ec85f56.tar.gz
gdb-f304c63d24ef12f3c01b978929ed026b1ec85f56.tar.bz2
PowerPC32 extended instructions in powerpc_macros
As for PowerPC64, move instructions to the main opcode table. opcodes/ * ppc-opc.c (insert_crwn, extract_crwn, insert_elwn, extract_elwn), (insert_erwn, extract_erwn, insert_erwb, extract_erwb), (insert_cslwn, extract_cslwb, insert_ilwb, extract_ilwn), (insert_irwb, extract_irwn, insert_rrwn, extract_rrwn), (insert_slwn, extract_slwn, insert_srwn, extract_srwn): New functions. (CRWn, ELWn, ERWn, ERWb, CSLWb, CSLWn, ILWn, ILWb, IRWn, IRWb), (RRWn, SLWn, SRWn): Define and add powerpc_operands entries. (MMB_MASK, MME_MASK, MSHMB_MASK): Define. (powerpc_opcodes): Add "inslwi", "insrwi", "rotrwi", "clrrwi", "slwi", "srwi", "extlwi", "extrwi", "sli", "sri" and corresponding record (ie. dot suffix) forms. (powerpc_macros): Delete same. gas/ * testsuite/gas/ppc/476.d: Update. * testsuite/gas/ppc/simpshft.d: Update.
Diffstat (limited to 'gas')
-rw-r--r--gas/testsuite/gas/ppc/476.d10
-rw-r--r--gas/testsuite/gas/ppc/simpshft.d24
2 files changed, 17 insertions, 17 deletions
diff --git a/gas/testsuite/gas/ppc/476.d b/gas/testsuite/gas/ppc/476.d
index 0b75d75..70ea88d 100644
--- a/gas/testsuite/gas/ppc/476.d
+++ b/gas/testsuite/gas/ppc/476.d
@@ -59,7 +59,7 @@ Disassembly of section \.text:
.*: (4c 86 00 21|21 00 86 4c) bnelrl cr1
.*: (48 00 00 00|00 00 00 48) b c8 <ppc476\+0xc8>
.*: (48 00 00 01|01 00 00 48) bl cc <ppc476\+0xcc>
-.*: (54 83 00 36|36 00 83 54) rlwinm r3,r4,0,0,27
+.*: (54 83 00 36|36 00 83 54) clrrwi r3,r4,4
.*: (7c 03 20 00|00 20 03 7c) cmpw r3,r4
.*: (7f 83 20 00|00 20 83 7f) cmpw cr7,r3,r4
.*: (7c 83 2b f8|f8 2b 83 7c) cmpb r3,r4,r5
@@ -401,10 +401,10 @@ Disassembly of section \.text:
.*: (4c 00 00 4c|4c 00 00 4c) rfmci
.*: (50 83 65 36|36 65 83 50) rlwimi r3,r4,12,20,27
.*: (50 83 65 37|37 65 83 50) rlwimi\. r3,r4,12,20,27
-.*: (54 83 00 36|36 00 83 54) rlwinm r3,r4,0,0,27
-.*: (54 83 d1 be|be d1 83 54) rlwinm r3,r4,26,6,31
+.*: (54 83 00 36|36 00 83 54) clrrwi r3,r4,4
+.*: (54 83 d1 be|be d1 83 54) srwi r3,r4,6
.*: (54 83 20 26|26 20 83 54) rlwinm r3,r4,4,0,19
-.*: (54 83 00 37|37 00 83 54) rlwinm\. r3,r4,0,0,27
+.*: (54 83 00 37|37 00 83 54) clrrwi\. r3,r4,4
.*: (5c 83 28 3e|3e 28 83 5c) rotlw r3,r4,r5
.*: (5c 83 28 3f|3f 28 83 5c) rotlw\. r3,r4,r5
.*: (5c 83 28 3e|3e 28 83 5c) rotlw r3,r4,r5
@@ -418,7 +418,7 @@ Disassembly of section \.text:
.*: (7c 83 86 71|71 86 83 7c) srawi\. r3,r4,16
.*: (7c 83 2c 30|30 2c 83 7c) srw r3,r4,r5
.*: (7c 83 2c 31|31 2c 83 7c) srw\. r3,r4,r5
-.*: (54 83 d1 be|be d1 83 54) rlwinm r3,r4,26,6,31
+.*: (54 83 d1 be|be d1 83 54) srwi r3,r4,6
.*: (99 61 00 02|02 00 61 99) stb r11,2\(r1\)
.*: (9d 81 00 03|03 00 81 9d) stbu r12,3\(r1\)
.*: (7d ae 79 ee|ee 79 ae 7d) stbux r13,r14,r15
diff --git a/gas/testsuite/gas/ppc/simpshft.d b/gas/testsuite/gas/ppc/simpshft.d
index b88752c8..70b8e02 100644
--- a/gas/testsuite/gas/ppc/simpshft.d
+++ b/gas/testsuite/gas/ppc/simpshft.d
@@ -11,9 +11,9 @@ Disassembly of section .text:
4: (0e f8 83 78|78 83 f8 0e) rldimi r3,r4,63,0
8: (e4 45 a5 78|78 a5 45 e4) sldi r5,r5,8
c: (20 00 64 78|78 64 00 20) clrldi r4,r3,32
- 10: (fe 0f 64 54|54 64 0f fe) rlwinm r4,r3,1,31,31
+ 10: (fe 0f 64 54|54 64 0f fe) srwi r4,r3,31
14: (00 f8 83 50|50 83 f8 00) rlwimi r3,r4,31,0,0
- 18: (2e 40 a5 54|54 a5 40 2e) rlwinm r5,r5,8,0,23
+ 18: (2e 40 a5 54|54 a5 40 2e) slwi r5,r5,8
1c: (3e 04 64 54|54 64 04 3e) clrlwi r4,r3,16
20: (04 00 64 78|78 64 00 04) clrrdi r4,r3,63
24: (e4 07 64 78|78 64 07 e4) clrrdi r4,r3,0
@@ -48,11 +48,11 @@ Disassembly of section .text:
98: (e8 07 64 78|78 64 07 e8) rldic r4,r3,0,63
9c: (a8 0f 64 78|78 64 0f a8) rldic r4,r3,1,62
a0: (0a f8 64 78|78 64 f8 0a) rldic r4,r3,63,0
- a4: (00 00 64 54|54 64 00 00) rlwinm r4,r3,0,0,0
+ a4: (00 00 64 54|54 64 00 00) clrrwi r4,r3,31
a8: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
- ac: (00 f8 64 54|54 64 f8 00) rlwinm r4,r3,31,0,0
+ ac: (00 f8 64 54|54 64 f8 00) slwi r4,r3,31
b0: (3e f8 64 54|54 64 f8 3e) rotlwi r4,r3,31
- b4: (7e f8 64 54|54 64 f8 7e) rlwinm r4,r3,31,1,31
+ b4: (7e f8 64 54|54 64 f8 7e) srwi r4,r3,1
b8: (fe ff 64 54|54 64 ff fe) rlwinm r4,r3,31,31,31
bc: (00 00 64 50|50 64 00 00) rlwimi r4,r3,0,0,0
c0: (3e 00 64 50|50 64 00 3e) rlwimi r4,r3,0,0,31
@@ -68,20 +68,20 @@ Disassembly of section .text:
e8: (3e 08 64 54|54 64 08 3e) rotlwi r4,r3,1
ec: (3e 20 65 5c|5c 65 20 3e) rotlw r5,r3,r4
f0: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
- f4: (3c 08 64 54|54 64 08 3c) rlwinm r4,r3,1,0,30
- f8: (00 f8 64 54|54 64 f8 00) rlwinm r4,r3,31,0,0
+ f4: (3c 08 64 54|54 64 08 3c) slwi r4,r3,1
+ f8: (00 f8 64 54|54 64 f8 00) slwi r4,r3,31
fc: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
- 100: (7e f8 64 54|54 64 f8 7e) rlwinm r4,r3,31,1,31
- 104: (fe 0f 64 54|54 64 0f fe) rlwinm r4,r3,1,31,31
+ 100: (7e f8 64 54|54 64 f8 7e) srwi r4,r3,1
+ 104: (fe 0f 64 54|54 64 0f fe) srwi r4,r3,31
108: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
10c: (7e 00 64 54|54 64 00 7e) clrlwi r4,r3,1
110: (fe 07 64 54|54 64 07 fe) clrlwi r4,r3,31
114: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
- 118: (3c 00 64 54|54 64 00 3c) rlwinm r4,r3,0,0,30
- 11c: (00 00 64 54|54 64 00 00) rlwinm r4,r3,0,0,0
+ 118: (3c 00 64 54|54 64 00 3c) clrrwi r4,r3,1
+ 11c: (00 00 64 54|54 64 00 00) clrrwi r4,r3,31
120: (3e 00 64 54|54 64 00 3e) rotlwi r4,r3,0
124: (7e 00 64 54|54 64 00 7e) clrlwi r4,r3,1
128: (fe 07 64 54|54 64 07 fe) clrlwi r4,r3,31
12c: (bc 0f 64 54|54 64 0f bc) rlwinm r4,r3,1,30,30
- 130: (00 f8 64 54|54 64 f8 00) rlwinm r4,r3,31,0,0
+ 130: (00 f8 64 54|54 64 f8 00) slwi r4,r3,31
#pass