From patchwork Tue Feb 28 12:48:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Arnez X-Patchwork-Id: 65764 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 3D00D3858401 for ; Tue, 28 Feb 2023 12:48:59 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3D00D3858401 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1677588539; bh=IbahSsoG/gmTQ3HHkaDu8sxOOZVjw/so7jbEy3DuiYc=; h=To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=vvoSifzZha5f8drgWFCKICbFb1KWSaofyyvlIndBhXousX2xiFlL+RHc+vQhkFt4h Rr7py/00lKQTDAnqHh0gQCQls85LPVhEcF12EFl5YACx1U8Re6iH1NZm+bTzXHxPy/ OIWsx9p4aaZuytgNiscajPvBrJJwGeKmwhvjRtEc= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by sourceware.org (Postfix) with ESMTPS id D28253858D33 for ; Tue, 28 Feb 2023 12:48:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D28253858D33 Received: from pps.filterd (m0127361.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 31SBkMgM008352 for ; Tue, 28 Feb 2023 12:48:36 GMT Received: from ppma03ams.nl.ibm.com (62.31.33a9.ip4.static.sl-reverse.com [169.51.49.98]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3p1h1k1h5r-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 28 Feb 2023 12:48:36 +0000 Received: from pps.filterd (ppma03ams.nl.ibm.com [127.0.0.1]) by ppma03ams.nl.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 31RJOw6i032007 for ; Tue, 28 Feb 2023 12:48:34 GMT Received: from smtprelay04.fra02v.mail.ibm.com ([9.218.2.228]) by ppma03ams.nl.ibm.com (PPS) with ESMTPS id 3nybcub3ec-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 28 Feb 2023 12:48:34 +0000 Received: from smtpav06.fra02v.mail.ibm.com (smtpav06.fra02v.mail.ibm.com [10.20.54.105]) by smtprelay04.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 31SCmUSI28049930 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 28 Feb 2023 12:48:30 GMT Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A27FF2004B; Tue, 28 Feb 2023 12:48:30 +0000 (GMT) Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 87AD320049; Tue, 28 Feb 2023 12:48:30 +0000 (GMT) Received: from li-07e5db4c-3052-11b2-a85c-815382633c95.ibm.com (unknown [9.152.222.236]) by smtpav06.fra02v.mail.ibm.com (Postfix) with ESMTPS; Tue, 28 Feb 2023 12:48:30 +0000 (GMT) To: libc-alpha@sourceware.org Cc: Stefan Liebler Subject: [PATCH] S390: Fix _FPU_SETCW/GETCW when compiling with Clang [BZ #30130] Organization: IBM Deutschland Research & Development GmbH Date: Tue, 28 Feb 2023 13:48:06 +0100 Message-ID: <877cw2rm61.fsf@li-07e5db4c-3052-11b2-a85c-815382633c95.ibm.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: RThvs5Uyf8ZAftnA1iV1f_9tq-P5sRoW X-Proofpoint-ORIG-GUID: RThvs5Uyf8ZAftnA1iV1f_9tq-P5sRoW X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.930,Hydra:6.0.573,FMLib:17.11.170.22 definitions=2023-02-28_08,2023-02-28_02,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 adultscore=0 mlxlogscore=632 malwarescore=0 suspectscore=0 spamscore=0 priorityscore=1501 impostorscore=0 lowpriorityscore=0 mlxscore=0 bulkscore=0 clxscore=1011 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2212070000 definitions=main-2302280101 X-Spam-Status: No, score=-11.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Andreas Arnez via Libc-alpha From: Andreas Arnez Reply-To: Andreas Arnez Errors-To: libc-alpha-bounces+patchwork=sourceware.org@sourceware.org Sender: "Libc-alpha" The _FPU_SETCW and _FPU_GETCW macros are defined with inline assemblies. They use the sfpc and efpc instructions, respectively. But both contain a spurious second operand that leads to a compile error with Clang. Removing this operand works both with gcc/gas (since binutils 2.18) as well as with clang/llvm. --- sysdeps/s390/fpu/fpu_control.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sysdeps/s390/fpu/fpu_control.h b/sysdeps/s390/fpu/fpu_control.h index e00d7775f4..567b180034 100644 --- a/sysdeps/s390/fpu/fpu_control.h +++ b/sysdeps/s390/fpu/fpu_control.h @@ -32,8 +32,8 @@ typedef unsigned int fpu_control_t; /* Macros for accessing the hardware control word. */ -#define _FPU_GETCW(cw) __asm__ __volatile__ ("efpc %0,0" : "=d" (cw)) -#define _FPU_SETCW(cw) __asm__ __volatile__ ("sfpc %0,0" : : "d" (cw)) +#define _FPU_GETCW(cw) __asm__ __volatile__ ("efpc %0" : "=d" (cw)) +#define _FPU_SETCW(cw) __asm__ __volatile__ ("sfpc %0" : : "d" (cw)) /* Default control word set at startup. */ extern fpu_control_t __fpu_control;