[binutils-gdb] PowerPC: Add support for RFC02660 - Context Switch Instruction

Abhay Kandpal abhay@sourceware.org
Thu Nov 13 17:58:52 GMT 2025


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=fd3b1c4f4c111444dfe6ff9c3f00a5469e7cd8a6

commit fd3b1c4f4c111444dfe6ff9c3f00a5469e7cd8a6
Author: Abhay Kandpal <abhay@linux.ibm.com>
Date:   Thu Nov 13 12:44:42 2025 -0500

    PowerPC: Add support for RFC02660 - Context Switch Instruction
    
    opcodes/
        * ppc-opc.c: (powerpc_opcodes): Add mtlpl.
    
    gas/
        * testsuite/gas/ppc/future.s: New test.
        * testsuite/gas/ppc/future.d: Likewise.

Diff:
---
 gas/testsuite/gas/ppc/future.d | 1 +
 gas/testsuite/gas/ppc/future.s | 1 +
 opcodes/ppc-opc.c              | 1 +
 3 files changed, 3 insertions(+)

diff --git a/gas/testsuite/gas/ppc/future.d b/gas/testsuite/gas/ppc/future.d
index ed45983366a..efb3ee8428d 100644
--- a/gas/testsuite/gas/ppc/future.d
+++ b/gas/testsuite/gas/ppc/future.d
@@ -108,4 +108,5 @@ Disassembly of section \.text:
 .*:	(da af 74 7c|7c 74 af da) 	stxvpb32x vs34,r20,r21
 .*:	(4c 06 00 7c|7c 00 06 4c) 	ccmclean
 .*:	(cc 06 00 7c|7c 00 06 cc) 	ccmrl
+.*:	(26 22 40 7c|7c 40 22 26) 	mtlpl   r4,r2
 #pass
diff --git a/gas/testsuite/gas/ppc/future.s b/gas/testsuite/gas/ppc/future.s
index 64d883ecb82..e66465a7418 100644
--- a/gas/testsuite/gas/ppc/future.s
+++ b/gas/testsuite/gas/ppc/future.s
@@ -82,4 +82,5 @@ _start:
 	stxvpb32x 34, 20, 21
 	ccmclean
 	ccmrl
+	mtlpl 4, 2
 
diff --git a/opcodes/ppc-opc.c b/opcodes/ppc-opc.c
index 2228b0c60c1..867801a83d2 100644
--- a/opcodes/ppc-opc.c
+++ b/opcodes/ppc-opc.c
@@ -7658,6 +7658,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
 {"tlbiel",	X(31,274),	X_MASK|1<<20,POWER9,	0,		{RB, RSO, RIC, PRS, X_R}},
 {"tlbiel",	X(31,274),	XRTLRA_MASK, POWER4,	POWER9|PPC476,	{RB, LOPT}},
 
+{"mtlpl",	X(31,275),	XRA_MASK,    FUTURE,	0,		{RB, RS}},
 {"mfapidi",	X(31,275),	X_MASK,	     BOOKE,	E500|TITAN,	{RT, RA}},
 
 {"lqarx",	X(31,276),  XEH_MASK|Q_MASK, POWER8,	0,		{RTQ, RAX, RBX, EH}},


More information about the Binutils-cvs mailing list