From patchwork Wed Apr 8 16:29:32 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Arnez X-Patchwork-Id: 6087 Received: (qmail 63690 invoked by alias); 8 Apr 2015 16:29:41 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 63673 invoked by uid 89); 8 Apr 2015 16:29:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.4 required=5.0 tests=AWL, BAYES_00, KAM_LAZY_DOMAIN_SECURITY, T_RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: e06smtp11.uk.ibm.com Received: from e06smtp11.uk.ibm.com (HELO e06smtp11.uk.ibm.com) (195.75.94.107) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Wed, 08 Apr 2015 16:29:40 +0000 Received: from /spool/local by e06smtp11.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 8 Apr 2015 17:29:36 +0100 Received: from d06dlp02.portsmouth.uk.ibm.com (9.149.20.14) by e06smtp11.uk.ibm.com (192.168.101.141) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Wed, 8 Apr 2015 17:29:34 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (d06relay09.portsmouth.uk.ibm.com [9.149.109.194]) by d06dlp02.portsmouth.uk.ibm.com (Postfix) with ESMTP id 77A3B219005C for ; Wed, 8 Apr 2015 17:29:20 +0100 (BST) Received: from d06av10.portsmouth.uk.ibm.com (d06av10.portsmouth.uk.ibm.com [9.149.37.251]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t38GTYmB6619518 for ; Wed, 8 Apr 2015 16:29:34 GMT Received: from d06av10.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t38GTXu0004587 for ; Wed, 8 Apr 2015 10:29:33 -0600 Received: from br87z6lw.de.ibm.com (sig-9-81-113-56.evts.de.ibm.com [9.81.113.56]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id t38GTWsl004582; Wed, 8 Apr 2015 10:29:33 -0600 From: Andreas Arnez To: gdb-patches@sourceware.org Cc: Ulrich Weigand Subject: [PATCH] s390-vregs.exp: Avoid compile errors with older GCCs and on 31-bit targets Date: Wed, 08 Apr 2015 18:29:32 +0200 Message-ID: <87pp7eshw3.fsf@br87z6lw.de.ibm.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) MIME-Version: 1.0 X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15040816-0041-0000-0000-000003FE22AF X-IsSubscribed: yes The test case s390-vregs.exp yields compile errors on 31-bit targets as well as when using a GCC that defaults to an older "-march=". This patch fixes these issues. gdb/testsuite/ChangeLog: * gdb.arch/s390-vregs.S (change_vrs): Replace exrl by an appropriate .insn, such that an older assembler can be used. * gdb.arch/s390-vregs.exp: Add the compile flag -mzarch, to enable the z/Architecture instruction set on 31-bit targets as well. --- gdb/testsuite/gdb.arch/s390-vregs.S | 4 ++-- gdb/testsuite/gdb.arch/s390-vregs.exp | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/gdb/testsuite/gdb.arch/s390-vregs.S b/gdb/testsuite/gdb.arch/s390-vregs.S index 4b48a83..7388e7d 100644 --- a/gdb/testsuite/gdb.arch/s390-vregs.S +++ b/gdb/testsuite/gdb.arch/s390-vregs.S @@ -56,8 +56,8 @@ change_vrs: .cfi_startproc lghi %r1,16 lghi %r3,0xff -1: exrl %r3,2f - exrl %r3,1f +1: .insn ril,0xc60000000000,%r3,2f /* exrl */ + .insn ril,0xc60000000000,%r3,1f /* exrl */ aghi %r3,-0x11 brctg %r1,1b br %r14 diff --git a/gdb/testsuite/gdb.arch/s390-vregs.exp b/gdb/testsuite/gdb.arch/s390-vregs.exp index 8333c32..7d3c9bb 100644 --- a/gdb/testsuite/gdb.arch/s390-vregs.exp +++ b/gdb/testsuite/gdb.arch/s390-vregs.exp @@ -29,7 +29,8 @@ if [isnative] { remote_exec build "mkdir $coredir" } -if { [prepare_for_testing ${testfile}.exp $testfile $srcfile] } { +if { [prepare_for_testing ${testfile}.exp $testfile $srcfile \ + [list "additional_flags=-mzarch"]] } { return -1 }