From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29674 invoked by alias); 14 Oct 2013 00:53:38 -0000 Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org Received: (qmail 29661 invoked by uid 89); 14 Oct 2013 00:53:37 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 14 Oct 2013 00:53:36 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1VVWPc-0004NN-Is from Sandra_Loosemore@mentor.com for binutils@sourceware.org; Sun, 13 Oct 2013 17:53:32 -0700 Received: from SVR-ORW-FEM-05.mgc.mentorg.com ([147.34.97.43]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Sun, 13 Oct 2013 17:53:32 -0700 Received: from [IPv6:::1] (147.34.91.1) by svr-orw-fem-05.mgc.mentorg.com (147.34.97.43) with Microsoft SMTP Server id 14.2.247.3; Sun, 13 Oct 2013 17:53:31 -0700 Message-ID: <525B406F.40904@codesourcery.com> Date: Mon, 14 Oct 2013 00:53:00 -0000 From: Sandra Loosemore User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 MIME-Version: 1.0 To: "binutils@sourceware.org" Subject: [patch, nios2] use "sstatus" as primary name of r30 Content-Type: multipart/mixed; boundary="------------010808060109040908040303" X-SW-Source: 2013-10/txt/msg00211.txt.bz2 --------------010808060109040908040303 Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit Content-length: 347 Altera has requested that the register r30 disassemble using the symbolic name "sstatus" rather than "ba". Both names are documented in the Nios II processor reference handbook. I've checked in this patch to update the list of register names, a warning message that formerly used only the "ba" name, and the associated test cases. -Sandra --------------010808060109040908040303 Content-Type: text/x-log; name="binutils-fsf.log" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="binutils-fsf.log" Content-length: 497 2013-10-13 Sandra Loosemore opcodes/ * nios2-opc.c (nios2_builtin_reg): Use "sstatus" rather than "ba" as the primary name of r30. gas/ * config/tc-nios2.c (nios2_consume_arg): Make the "ba" warning also test/refer to "sstatus". Reformat the warning message. gas/testsuite/ * gas/nios2/warn_nobreak.l: Update text of warning messages. * gas/nios2/registers.s: Use "sstatus" rather than "ba" as the primary name of r30. * gas/nios2/registers.d: Likewise. --------------010808060109040908040303 Content-Type: text/x-patch; name="binutils-fsf.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="binutils-fsf.patch" Content-length: 5682 Index: opcodes/nios2-opc.c =================================================================== RCS file: /cvs/src/src/opcodes/nios2-opc.c,v retrieving revision 1.6 diff -u -p -r1.6 nios2-opc.c --- opcodes/nios2-opc.c 10 Jun 2013 01:04:42 -0000 1.6 +++ opcodes/nios2-opc.c 14 Oct 2013 00:24:26 -0000 @@ -58,7 +58,7 @@ const struct nios2_reg nios2_builtin_reg {"sp", 27}, /* stack pointer */ {"fp", 28}, /* frame pointer */ {"ea", 29}, /* exception return address */ - {"ba", 30}, /* breakpoint return address */ + {"sstatus", 30}, /* saved processor status */ {"ra", 31}, /* return address */ /* Alternative names for special registers. */ @@ -71,7 +71,7 @@ const struct nios2_reg nios2_builtin_reg {"r28", 28}, {"r29", 29}, {"r30", 30}, - {"sstatus", 30}, + {"ba", 30}, /* breakpoint return address */ {"r31", 31}, /* Control register names. */ Index: gas/config/tc-nios2.c =================================================================== RCS file: /cvs/src/src/gas/config/tc-nios2.c,v retrieving revision 1.6 diff -u -p -r1.6 tc-nios2.c --- gas/config/tc-nios2.c 12 Jun 2013 23:11:57 -0000 1.6 +++ gas/config/tc-nios2.c 14 Oct 2013 00:24:25 -0000 @@ -1951,15 +1951,17 @@ nios2_consume_arg (nios2_insn_infoS *ins /* And whether we are using oci registers. */ if (!nios2_as_options.nobreak && (regno == 25 || strprefix (argstr, "bt"))) - as_warn (_("The debugger will corrupt bt (r25). If you don't need to " - "debug this\n" - "code then use .set nobreak to turn off this warning.")); + as_warn (_("The debugger will corrupt bt (r25).\n" + "If you don't need to debug this " + "code use .set nobreak to turn off this warning.")); if (!nios2_as_options.nobreak - && (regno == 30 || strprefix (argstr, "ba"))) - as_warn (_("The debugger will corrupt ba (r30). If you don't need to " - "debug this\n" - "code then use .set nobreak to turn off this warning.")); + && (regno == 30 + || strprefix (argstr, "ba") + || strprefix (argstr, "sstatus"))) + as_warn (_("The debugger will corrupt sstatus/ba (r30).\n" + "If you don't need to debug this " + "code use .set nobreak to turn off this warning.")); break; case 'i': case 'u': Index: gas/testsuite/gas/nios2/warn_nobreak.l =================================================================== RCS file: /cvs/src/src/gas/testsuite/gas/nios2/warn_nobreak.l,v retrieving revision 1.1 diff -u -p -r1.1 warn_nobreak.l --- gas/testsuite/gas/nios2/warn_nobreak.l 6 Feb 2013 23:22:16 -0000 1.1 +++ gas/testsuite/gas/nios2/warn_nobreak.l 14 Oct 2013 00:24:25 -0000 @@ -1,9 +1,9 @@ .*warn_nobreak.s: Assembler messages: -.*warn_nobreak.s:2: Warning: The debugger will corrupt ba \(r30\). If you don't need to debug this -code then use .set nobreak to turn off this warning. -.*warn_nobreak.s:3: Warning: The debugger will corrupt bt \(r25\). If you don't need to debug this -code then use .set nobreak to turn off this warning. -.*warn_nobreak.s:11: Warning: The debugger will corrupt ba \(r30\). If you don't need to debug this -code then use .set nobreak to turn off this warning. -.*warn_nobreak.s:12: Warning: The debugger will corrupt bt \(r25\). If you don't need to debug this -code then use .set nobreak to turn off this warning. +.*warn_nobreak.s:2: Warning: The debugger will corrupt sstatus/ba \(r30\). +If you don't need to debug this code use .set nobreak to turn off this warning. +.*warn_nobreak.s:3: Warning: The debugger will corrupt bt \(r25\). +If you don't need to debug this code use .set nobreak to turn off this warning. +.*warn_nobreak.s:11: Warning: The debugger will corrupt sstatus/ba \(r30\). +If you don't need to debug this code use .set nobreak to turn off this warning. +.*warn_nobreak.s:12: Warning: The debugger will corrupt bt \(r25\). +If you don't need to debug this code use .set nobreak to turn off this warning. Index: gas/testsuite/gas/nios2/registers.s =================================================================== RCS file: /cvs/src/src/gas/testsuite/gas/nios2/registers.s,v retrieving revision 1.1 diff -u -p -r1.1 registers.s --- gas/testsuite/gas/nios2/registers.s 12 Mar 2013 01:41:41 -0000 1.1 +++ gas/testsuite/gas/nios2/registers.s 14 Oct 2013 00:24:25 -0000 @@ -35,7 +35,7 @@ foo: movi sp, 123 movi fp, 123 movi ea, 123 - movi ba, 123 + movi sstatus, 123 movi ra, 123 # Alternative names for special registers movi r0, 123 @@ -47,5 +47,5 @@ foo: movi r28, 123 movi r29, 123 movi r30, 123 - movi sstatus, 123 + movi ba, 123 movi r31, 123 Index: gas/testsuite/gas/nios2/registers.d =================================================================== RCS file: /cvs/src/src/gas/testsuite/gas/nios2/registers.d,v retrieving revision 1.2 diff -u -p -r1.2 registers.d --- gas/testsuite/gas/nios2/registers.d 12 Mar 2013 21:34:58 -0000 1.2 +++ gas/testsuite/gas/nios2/registers.d 14 Oct 2013 00:24:25 -0000 @@ -36,7 +36,7 @@ Disassembly of section .text: 0+006c <[^>]*> 06c01ec4 movi sp,123 0+0070 <[^>]*> 07001ec4 movi fp,123 0+0074 <[^>]*> 07401ec4 movi ea,123 -0+0078 <[^>]*> 07801ec4 movi ba,123 +0+0078 <[^>]*> 07801ec4 movi sstatus,123 0+007c <[^>]*> 07c01ec4 movi ra,123 0+0080 <[^>]*> 00001ec4 movi zero,123 0+0084 <[^>]*> 00401ec4 movi at,123 @@ -46,6 +46,6 @@ Disassembly of section .text: 0+0094 <[^>]*> 06c01ec4 movi sp,123 0+0098 <[^>]*> 07001ec4 movi fp,123 0+009c <[^>]*> 07401ec4 movi ea,123 -0+00a0 <[^>]*> 07801ec4 movi ba,123 -0+00a4 <[^>]*> 07801ec4 movi ba,123 +0+00a0 <[^>]*> 07801ec4 movi sstatus,123 +0+00a4 <[^>]*> 07801ec4 movi sstatus,123 0+00a8 <[^>]*> 07c01ec4 movi ra,123 --------------010808060109040908040303--