Received: from list by lists.gnu.org with archive (Exim 4.71) id 1h6E2A-0007zh-K0 for mharc-grub-devel@gnu.org; Tue, 19 Mar 2019 08:39:58 -0400 Received: from eggs.gnu.org ([209.51.188.92]:41267) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h6E26-0007wL-In for grub-devel@gnu.org; Tue, 19 Mar 2019 08:39:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h6E25-0007Yv-Sg for grub-devel@gnu.org; Tue, 19 Mar 2019 08:39:54 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:50826) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1h6E25-0007XH-Fx for grub-devel@gnu.org; Tue, 19 Mar 2019 08:39:53 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x2JCY7dh126922; Tue, 19 Mar 2019 12:39:52 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references; s=corp-2018-07-02; bh=SPGDRrLr+D2EhfrZYgYhOnIAohoZ+OoY44NdcjLd2WE=; b=o5Fs+ZpFLY1U5piprWstnqDcgNCxmoTv5W7U+Jsyo5GssntJcLJ3xVb74YMo0z6gi96t SXTEBlDNZ5MAoRoyFMc3TMA+3cG5qjNIcAyaSfRvpB5X/X9WEkqbEcZW/8P9RHOqK8IW 54pD3LUmOtPTU1bi6odWdfHBd47Q7Ibk07tYXzPT4qxdf1R4fypgU1ANphgzNRM6E9gO dHZye2Dp6w05B0YTLOUDWLEKL4NZXn++3eL3Y9Kc5NGDHx9Af2dOi/HeoyvGJ3Np67lp MuomQML79MIiGevqV1M5O7ufgpySsWsbscz6kVFcW13CceSzK5SJbyEp8c7Xu6CA6bnh YQ== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2120.oracle.com with ESMTP id 2r8ssrc80f-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 19 Mar 2019 12:39:51 +0000 Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id x2JCdk0K025828 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 19 Mar 2019 12:39:46 GMT Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x2JCdkMR004181; Tue, 19 Mar 2019 12:39:46 GMT Received: from tomti.i.net-space.pl (/10.175.211.126) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 19 Mar 2019 05:39:45 -0700 From: Daniel Kiper To: grub-devel@gnu.org Cc: alexander.burmashev@oracle.com, eric.snowberg@oracle.com, leif.lindholm@linaro.org, phcoder@gmail.com, ross.philipson@oracle.com Subject: [PATCH 5/5] sparc: Enable __clzsi2() and __clzdi2() Date: Tue, 19 Mar 2019 13:39:18 +0100 Message-Id: <20190319123918.19267-6-daniel.kiper@oracle.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190319123918.19267-1-daniel.kiper@oracle.com> References: <20190319123918.19267-1-daniel.kiper@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9199 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1903190093 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 156.151.31.85 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Mar 2019 12:39:57 -0000 This patch is similiar to commit e795b9011 (RISC-V: Add libgcc helpers for clz) but for SPARC target. Signed-off-by: Daniel Kiper --- grub-core/kern/compiler-rt.c | 4 ++-- include/grub/compiler-rt.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/grub-core/kern/compiler-rt.c b/grub-core/kern/compiler-rt.c index 33e08fe06..a464200c6 100644 --- a/grub-core/kern/compiler-rt.c +++ b/grub-core/kern/compiler-rt.c @@ -420,7 +420,7 @@ __aeabi_llsl (grub_uint64_t u, int b) #endif -#if defined(__mips__) || defined(__riscv) +#if defined(__mips__) || defined(__riscv) || defined(__sparc__) /* Based on libgcc from gcc suite. */ int __clzsi2 (grub_uint32_t val) @@ -448,7 +448,7 @@ __clzsi2 (grub_uint32_t val) } #endif -#ifdef __riscv +#if defined(__riscv) || defined(__sparc__) int __clzdi2 (grub_uint64_t val) { diff --git a/include/grub/compiler-rt.h b/include/grub/compiler-rt.h index 31c0fd750..7591980b4 100644 --- a/include/grub/compiler-rt.h +++ b/include/grub/compiler-rt.h @@ -110,12 +110,12 @@ EXPORT_FUNC (__aeabi_llsr) (grub_uint64_t u, int b); #endif -#if defined(__mips__) || defined(__riscv) +#if defined(__mips__) || defined(__riscv) || defined(__sparc__) int EXPORT_FUNC (__clzsi2) (grub_uint32_t val); #endif -#ifdef __riscv +#if defined(__riscv) || defined(__sparc__) int EXPORT_FUNC (__clzdi2) (grub_uint64_t val); #endif -- 2.11.0