From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 50944 invoked by alias); 10 Sep 2018 06:25:12 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 50905 invoked by uid 89); 10 Sep 2018 06:25:07 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-11.4 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=familiar, invest, learn X-HELO: prv1-mh.provo.novell.com Received: from prv1-mh.provo.novell.com (HELO prv1-mh.provo.novell.com) (137.65.248.33) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 10 Sep 2018 06:25:06 +0000 Received: from INET-PRV1-MTA by prv1-mh.provo.novell.com with Novell_GroupWise; Mon, 10 Sep 2018 00:25:04 -0600 Message-Id: <5B960E3D020000780013C85E@prv1-mh.provo.novell.com> Date: Mon, 10 Sep 2018 06:25:00 -0000 From: "Jan Beulich" To: Cc: , Subject: Re: [PATCH] x86-64: fix ZMM register state tracking References: <5B8FD8B302000078001E5940@prv1-mh.provo.novell.com> <369f9b84-77e3-3fa4-f363-a89ee503cff4@ericsson.com> In-Reply-To: <369f9b84-77e3-3fa4-f363-a89ee503cff4@ericsson.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-SW-Source: 2018-09/txt/msg00249.txt.bz2 >>> Simon Marchi 09/08/18 1:13 AM >>> >Would it be possible to update or create a test to exercise that? >arch-specific tests are in testsuite/gdb.arch. I'm sure it would be possible, but while I was happy to invest the time to fix the actual bug (because it affects work I'm doing), I'm afraid I don't = have the time to learn how gdb test cases are to be constructed (I'm familiar only with the binutils / gas side of things). >On 2018-09-05 02:22 PM, Jan Beulich wrote: >> --- a/gdb/i387-tdep.c >> +++ b/gdb/i387-tdep.c >> @@ -923,7 +923,8 @@ i387_supply_xsave (struct regcache *regc >> enum bfd_endian byte_order =3D gdbarch_byte_order (gdbarch); >> struct gdbarch_tdep *tdep =3D gdbarch_tdep (gdbarch); >> const gdb_byte *regs =3D (const gdb_byte *) xsave; >> - int i; >> + int i, zmm_endlo_regnum =3D I387_ZMM0H_REGNUM (tdep) >> + + std::min (tdep->num_zmm_regs, 16); > >The GNU standard requires to parenthesis when breaking lines: > >int i, zmm_endlo_regnum =3D (I387_ZMM0H_REGNUM (tdep) >+ std::min (tdep->num_zmm_regs, 16)); This is easy enough to fix (perhaps even without the need to send a v2, but just before/while committing?); I don't think this is a rule being enforced on the binutils side, so I simply wasn't aware. Jan