From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 97639 invoked by alias); 15 Oct 2019 12:23:38 -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 97625 invoked by uid 89); 15 Oct 2019 12:23:37 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-9.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.1 spammy=H*o:Research X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 15 Oct 2019 12:23:36 +0000 Received: from pps.filterd (m0098420.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x9FCHR37171343 for ; Tue, 15 Oct 2019 08:23:33 -0400 Received: from e06smtp05.uk.ibm.com (e06smtp05.uk.ibm.com [195.75.94.101]) by mx0b-001b2d01.pphosted.com with ESMTP id 2vndyyr6kh-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 15 Oct 2019 08:23:33 -0400 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 15 Oct 2019 13:23:31 +0100 Received: from b06avi18878370.portsmouth.uk.ibm.com (9.149.26.194) by e06smtp05.uk.ibm.com (192.168.101.135) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Tue, 15 Oct 2019 13:23:28 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06avi18878370.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x9FCNP0843188570 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 15 Oct 2019 12:23:25 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B2AFD11C04C; Tue, 15 Oct 2019 12:23:25 +0000 (GMT) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8B91F11C04A; Tue, 15 Oct 2019 12:23:25 +0000 (GMT) Received: from oc0404454431.ibm.com (unknown [9.152.222.110]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Tue, 15 Oct 2019 12:23:25 +0000 (GMT) From: Andreas Arnez To: Tom Tromey Cc: gdb-patches@sourceware.org, Ulrich Weigand Subject: Re: [PATCH] s390: Fix infcalls passing a single-field struct with static members References: <87wodb2n1h.fsf@tromey.com> Date: Tue, 15 Oct 2019 12:23:00 -0000 In-Reply-To: <87wodb2n1h.fsf@tromey.com> (Tom Tromey's message of "Fri, 11 Oct 2019 11:46:02 -0600") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain x-cbid: 19101512-0020-0000-0000-00000379403C X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19101512-0021-0000-0000-000021CF5EA7 Message-Id: X-SW-Source: 2019-10/txt/msg00409.txt.bz2 On Fri, Oct 11 2019, Tom Tromey wrote: >>>>>> "Andreas" == Andreas Arnez writes: > > Andreas> The infcall-nested-structs test case yields 36 FAILs on s390x because GCC > Andreas> and GDB disagree on how to pass a C++ struct like this as an argument to a > Andreas> function: > > Andreas> struct s { float x; static float y; }; > > Andreas> For the purpose of argument passing, GCC ignores static fields, while GDB > Andreas> does not. Thus GCC passes the argument in a floating-point register and > Andreas> GDB passes it via memory. > > Andreas> Fix this by explicitly ignoring static fields when detecting single-field > Andreas> structs. > > FWIW this looked reasonable to me. Thanks for having a look at this! Pushed as ba18312d8f2cecf88b6edcbc277f433a62131e58. -- Andreas