From patchwork Thu Apr 20 13:31:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: YunQiang Su X-Patchwork-Id: 85912 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp338034vqo; Thu, 20 Apr 2023 06:31:41 -0700 (PDT) X-Google-Smtp-Source: AKy350YLnXlp9+ASPewABZQdjathhqZG03VXilNNocEHHrvmoNBBjwbOxHre6nSqkqgNEWzXEfdD X-Received: by 2002:a17:906:4bc8:b0:94f:1a11:df56 with SMTP id x8-20020a1709064bc800b0094f1a11df56mr6141226ejv.35.1681997501186; Thu, 20 Apr 2023 06:31:41 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1681997501; cv=pass; d=google.com; s=arc-20160816; b=mi5/nLmIBYFxkbvR5XXFBhgmJVUmQFWbyOYaamXA8KvvOzDe9QH6LI+OUbZX3iDfbG E+lyOg7butmd0Czn8wzkPgLvN23I268JqGx0N4KLk8mVxcevqSwo95jgz1ymOA3ENvee tj8gHjWqxh1Expndo7dPhkTLlvKKE/hAC9YTxK1rtPAUja4/WsKifHqylYCfQykVsq5i yjlXxXT2kVfZIgP4cGUxmxkrqEnYyqEZAbGJNOcWVdQZcDeyfZoRrFmuQ5rP3vIQfEyl NA6uVeSCdeCxAivNJN1nbJxBl5wM5U/SRZuvyoJB4/9NUAza6OM/y3szg8REY0+4bF3f zjJg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:mime-version :content-transfer-encoding:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dmarc-filter:delivered-to; bh=A1KYNdpviDEdXRlhYJ/jNpDz0TKWx5d2AtdSGPPAXqo=; b=BzN8tWSV1c4Tu4S8leSL4fHiuh4rViWt+NBwQuGz2+FmHT/jv9M3h67uGjLEoQKVYD MjJyYzAlYYlTiu1mkeIHdc/fJDma1BpfC0yZZ3R3MlA/zhcjVNRqjqLR0BL+Lu1m2/t5 nSnz7Hg7LTmddWSejKv36OxDLP30baIKRg6nJ+qxw4o5RqQmFxSr8vwNJz+0+zmvKdHl KclwPFpn/v+UoPDgNEwpcGJwENyT7u/aBA5nUBaCnjZrGiOc73H0EUSTr/tUY+UDiA41 2tdsfHgK5znXeK3xUJOG+z4c5m6R8zbN4nGt/2HHJ+WBybn4xgp9z56JzePwrQZcd4IF AmZQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@cipunited.onmicrosoft.com header.s=selector1-cipunited-onmicrosoft-com header.b=dADK3iWp; arc=pass (i=1 spf=pass spfdomain=cipunited.com dkim=pass dkdomain=cipunited.com dmarc=pass fromdomain=cipunited.com); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org" Received: from sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id r12-20020aa7da0c000000b0050684678463si1845680eds.181.2023.04.20.06.31.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Apr 2023 06:31:41 -0700 (PDT) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@cipunited.onmicrosoft.com header.s=selector1-cipunited-onmicrosoft-com header.b=dADK3iWp; arc=pass (i=1 spf=pass spfdomain=cipunited.com dkim=pass dkdomain=cipunited.com dmarc=pass fromdomain=cipunited.com); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 79DA63858C33 for ; Thu, 20 Apr 2023 13:31:38 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2103.outbound.protection.outlook.com [40.107.117.103]) by sourceware.org (Postfix) with ESMTPS id 35BF23858D37 for ; Thu, 20 Apr 2023 13:31:31 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 35BF23858D37 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=cipunited.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=cipunited.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cPU7FM0suL5n0/c4jyv3CsC3VMGVKtlbJ/RY9rj7eSsXRI4rBWxDMVjEPTqMFkkwY9+2LnCIaN4p+htg7AFgqGzQwojEX86kbYxbJ1ZrJKMfzQ3bRqjPI1+RQkClM/LhrGIqHOD0Unc5Y8jt4drpn6L923sUdmjETqLWE/MKE2iIVaDKM6LQL5VH5Fep0VoRLsyg4JSmO4hh9ACx0y33svVjcadnsP9qe9Mr3q1IkAajg8x7f9RRX2xjLT91MNO82Y2QvpfcAq7foUNatJWmxF/hhv/PifsiDq1SLMcswXsV9wS3EpG0AJXuxpLUA5fX4Bz3xXfoAupN/B17b59F7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=A1KYNdpviDEdXRlhYJ/jNpDz0TKWx5d2AtdSGPPAXqo=; b=iTlPy5DVNI7s+q4A1FusexOXyIpcwijG7PXIjU/ZfnqKsxJePrsP9RFq3W9BcSN1G+2dQLipSYBReV1Y2ejwTNzKLTJHSkDf/4gdBmtDlAJxAgq1xHDKdHclb9peVngj7ULY2Vf7PgIF9Dbrzy0AzBKG6xA8f6fThj3a+EkU5ITBnb8eNAKfDVAiXpJ7/Kr9jZRs9h73R+Iq/jCGdVPheJWtWQFry+InFfAGrJCe7V2eLIaqaA8wLWGdu+BjYGGv3lgEXOMm8x5Vy9EMT0Mfxw/E4V8hp3c1M5sEtPy4XngfuBwPpbAElpzFRRnHP+gIP8xZ7EOzUzfrPHnS3FJa7A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=cipunited.com; dmarc=pass action=none header.from=cipunited.com; dkim=pass header.d=cipunited.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cipunited.onmicrosoft.com; s=selector1-cipunited-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=A1KYNdpviDEdXRlhYJ/jNpDz0TKWx5d2AtdSGPPAXqo=; b=dADK3iWpYrGHeL69BMueOfO1R3cLRZ7szEF5OFzskGLUq6Ijod0WNBdq2Lo78SaW4HMaBdGUMncvOZjbxeoUbcR/YGL9i8FMpdiBce4XqqWnjX6NTRDifRXLR/rf7wtsgU77UzOrtC9WcgmKJW2/BibMxXTLsb2ad9WWoFXy79w= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=cipunited.com; Received: from TYZPR04MB6117.apcprd04.prod.outlook.com (2603:1096:400:25a::9) by SEZPR04MB6172.apcprd04.prod.outlook.com (2603:1096:101:ce::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.22; Thu, 20 Apr 2023 13:31:25 +0000 Received: from TYZPR04MB6117.apcprd04.prod.outlook.com ([fe80::4016:87b:f0d1:b150]) by TYZPR04MB6117.apcprd04.prod.outlook.com ([fe80::4016:87b:f0d1:b150%6]) with mapi id 15.20.6319.022; Thu, 20 Apr 2023 13:31:24 +0000 From: YunQiang Su To: binutils@sourceware.org Cc: syq@debian.org, macro@orcam.me.uk, xry111@xry111.site, richard.sandiford@arm.com, jiaxun.yang@flygoat.com, YunQiang Su Subject: [PATCH v5 1/2] MIPS: support mips*64 as CPU and gnuabi64 as ABI Date: Thu, 20 Apr 2023 21:31:01 +0800 Message-Id: <20230420133102.2422583-1-yunqiang.su@cipunited.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230418140019.2195551-2-yunqiang.su@cipunited.com> References: <20230418140019.2195551-2-yunqiang.su@cipunited.com> X-ClientProxiedBy: TYCP301CA0017.JPNP301.PROD.OUTLOOK.COM (2603:1096:400:381::8) To TYZPR04MB6117.apcprd04.prod.outlook.com (2603:1096:400:25a::9) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYZPR04MB6117:EE_|SEZPR04MB6172:EE_ X-MS-Office365-Filtering-Correlation-Id: 048a6368-6683-4e61-1344-08db41a38911 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: iuTF4mrcnoTzr/N6s6FPDru0+oS/VfRT+I3K2PTQfJj84HknP9Rir0Qzgz7pobuE7iQn+SKBy3RF14NtKQrqre6zJEyhkyXJaund7BaktvtSE+Y46srHOlUzzL0NXwfLoYaH/wm1aqPw2ngWNrMD/WS9tR3aCNDO1PmKuyVO8DQLNzV+GcWEdhuYG1CDgXrU0vXnplyjQ+VwXoGi+/1BAbfAgGCCpem27/im+xsXJg5E3f5kNn0HFOoek48AVtgpyOgbdFjx2/YAvIfU4hwjqGMzHOYqpfZIE+CnO2OSeC3b/5aD3EX8Sf//q8eClKDycVczdIlnoznjNfdILKNBaOmAO9o5ZnSwrGE9Fs3w4DpPBF6Px7mUcSvBDVq33X9Zo5EvsUAZ5p0wfJFx+30gt4FECjB6lO4suvyAuESnpZz1u2G1TQQ2UX1bHZhZvC11f7h2a/Pi4T10mFl/8T9Hilt7/L0X5pH6eX0q3v1giwrBJhbRZG1bqmGj+1L/C4Ww7esiEmNZT2tF3Z3kkeXcwlxP3Fn0vKgrEXIlqymP9amxugckoJ2Y8hK4p6Pam2GKJTcuK+P+eDmlF721Lh+k5hqzk0BGj+51rnl0DrtJIc8CYsUtzJ9o/nLDeKylQTwn X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:TYZPR04MB6117.apcprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(366004)(346002)(39830400003)(136003)(376002)(396003)(451199021)(36756003)(4326008)(316002)(6916009)(66556008)(66476007)(66946007)(478600001)(52116002)(6666004)(6486002)(8936002)(5660300002)(41300700001)(8676002)(2906002)(86362001)(38100700002)(38350700002)(2616005)(1076003)(107886003)(6512007)(26005)(6506007)(83380400001)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: rNbJpsChNN8vTFRPVXQ5frRjYifY7hw4iM2VWOrlHRPV3PANK81NWkZE6Qj+r6kYo4AuGPX8Zn1XFhRvAZGdFTYVtMW0Mn6EG+jVAr5qplf2eH1anOii+QbZsRxrq172Iru1MMBPUDOC/ihuFiVda64M+3nqNW9bDKCUDMnFdFX2gwJ/WFiGPVwgb6BlxDtZeRnZShoAAv9uleRFG9y84ak83HcgDdTj8R75EuzcZOLIrWLPCWF6HBL1cKqcDqGWw8QX5P9IrVPNwNgNHp7F1gKFKktptQJ2/jiKsmchidmtGbw+TXvv2S8w2yh0UiZkLIEXtK2yyaaZD33g4oEnpTHT8IO1rXE6K9bOOLHD4Dl7BvrccIf4LGTUBlRPaJLYl7pOC9pW3TYArr/2mq6EpzcUVQzKpgKW8c/f8rsL0ZteOeVDUAYytFR8u6aLLv0G9PBV+PsqgQ0kROyXPRUESRgb/dtcQebT9sy6z7O9hDFP20HROP4XZsNxPmPnXppuNcYgNL+q9E+5ZkvW8jbtsE1zX+vPu0/wu+ePc+Mpz7s11IFO4IMckBm0lcpFdR7hCxBxgk1ZHukM2oTqnrINGrUEkS9kEpgljunXo304/keWRoZTO9h1sSYtTh4L/nk3kmSUs62+S5e0nQcxokbliPlToHdYyE1Y7rJkFv8EUEAkmD0MICjmGBw1LNyfJcA9Ikw3/g19zCIoaFpFU2m5vOnvNoms9o8p+i5Ba1ttn/Xy/MwmT2Yv2mew/rMbOe8KMsCk4WCCd7RTVra4L4sy99We+rpf2dmYRPmB4b2W/Sq5zyWtmyfr6Bwt7vSX2utIKDYWqlubh8QYTTYzFVMWKG6OlOdcCnwh27FrKZ3MZ9oG2X+Pi4MzL0VHNRZFkaUgf/yuwzqIQRdkD1vAllqwi7jStdPSPFE/bcLxJ35UIo/Oj9UnWBQLN/p39tc7idmvIelFWBTnR0T1PCilWk5imZX/RRAkFE12M6BrRoVZMvITpdTcyNHxtw0EXcFLezOp2piMFw/uoKYManAIV8P3qY5lxUs+R4abmSwrWLsckwGkXv+LOsug4LddyT9mNTk4SOSA/Fy2XE2p4X+6Qo9RRnGvGqE5dGIJwdPJGSn0iDEgB5Z7IWCtcpbmYri8VOjrKFQvnknwkr5hgjrIX7KINx8cHCLJylOrEe+lCvmrOPRlSIT9TeZQgHPFP6+5YY+9DGqnxWzNKvyiKHeTK7bRJQbDq2zcY7ykzvDMt88VGwKi06pSmulNw6Y/NlG7OrgKQbpHjlNywPHQAA8DkgaytSROog9aSc+c40qdLQzNK3X/PxTu4POq8SpxFyj6aaV7Kpbo5xmwOVstohoNd7nkK84MtZSivkdJ/GmhD1U+/w+OJUrC/CPTfgiXlo93bKHtRMtmp6zt2qYSN9cbl2foG78pA1aopNl2/t1nQMiD2+P59gxrsFMkqSne0riswKmDPq5FKlTrv3D4AOLjiJ2RFAgF5BHPYqTprYCR57goUOqrGqmqwS1XZ3H81EnR6KOhotlQfeZfJjD1usBvgbxYNlUjswTyiEgiTNp96L4CHYqMkAyNaDNBrfmPYYjrK3N5ybMVRBcdUNF+LMdSk1gPvg== X-OriginatorOrg: cipunited.com X-MS-Exchange-CrossTenant-Network-Message-Id: 048a6368-6683-4e61-1344-08db41a38911 X-MS-Exchange-CrossTenant-AuthSource: TYZPR04MB6117.apcprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Apr 2023 13:31:24.0284 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: e31cf5b5-ee69-4d5f-9c69-edeeda2458c0 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Oq9Y2Y0ZVD1Wjtqe0Tq3kyndONX3dc4o0PH7N/88/EetJQ1jyF9GyH6hNZW+XSTom1TaTAhZuk8OzWrTrDL4rOJ3nlRXhqWPqRZVOU9ENiI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEZPR04MB6172 X-Spam-Status: No, score=-13.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE 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: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org Sender: "Binutils" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763702211997460006?= X-GMAIL-MSGID: =?utf-8?q?1763702211997460006?= For MIPS64r6 ports, Debian as an example, `mipsisa64r6el` is used as the cpu name in triple. Let's recognize them by `mips*64*(el)`. For 64bit Ports, like Debian's mips64el and mips64r6el ports, `gnuabi64` is used as the abi section. Let's use N64 abi by default for the triple with gnuabi64. --- bfd/config.bfd | 14 ++++++++++++-- .../testsuite/binutils-all/mips/mips-note-2-n32.d | 1 + gas/configure | 5 ++++- gas/configure.ac | 5 ++++- gold/configure.tgt | 14 ++++++++++++++ ld/configure.tgt | 12 ++++++++++-- 6 files changed, 45 insertions(+), 6 deletions(-) diff --git a/bfd/config.bfd b/bfd/config.bfd index 7af481048db..1e4bea191dd 100644 --- a/bfd/config.bfd +++ b/bfd/config.bfd @@ -941,11 +941,21 @@ case "${targ}" in targ_defvec=mips_elf32_be_vec targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_be_vec mips_ecoff_le_vec" ;; - mips64*el-*-linux*) + mips*64*el-*-linux*-gnuabi64) + targ_defvec=mips_elf64_trad_le_vec + targ_selvecs="mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_be_vec" + want64=true + ;; + mips*64*-*-linux*-gnuabi64) + targ_defvec=mips_elf64_trad_be_vec + targ_selvecs="mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_le_vec" + want64=true + ;; + mips*64*el-*-linux*) targ_defvec=mips_elf32_ntrad_le_vec targ_selvecs="mips_elf32_ntrad_be_vec mips_elf32_trad_le_vec mips_elf32_trad_be_vec mips_elf64_trad_le_vec mips_elf64_trad_be_vec" ;; - mips64*-*-linux*) + mips*64*-*-linux*) targ_defvec=mips_elf32_ntrad_be_vec targ_selvecs="mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec" ;; diff --git a/binutils/testsuite/binutils-all/mips/mips-note-2-n32.d b/binutils/testsuite/binutils-all/mips/mips-note-2-n32.d index c2a581858ed..5e24e7a115e 100644 --- a/binutils/testsuite/binutils-all/mips/mips-note-2-n32.d +++ b/binutils/testsuite/binutils-all/mips/mips-note-2-n32.d @@ -1,4 +1,5 @@ #PROG: objcopy +#as: -n32 #readelf: --notes --wide #objcopy: --merge-notes #name: MIPS merge notes section (n32) diff --git a/gas/configure b/gas/configure index b56836998ef..868f4a911a9 100755 --- a/gas/configure +++ b/gas/configure @@ -12223,7 +12223,10 @@ _ACEOF esac # Decide which ABI to target by default. case ${target} in - mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \ + mips*64*-linux-gnuabi64) + mips_default_abi=N64_ABI + ;; + mips*64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \ | mips64*-kfreebsd*-gnu | mips64*-ps2-elf*) mips_default_abi=N32_ABI ;; diff --git a/gas/configure.ac b/gas/configure.ac index 6a68fd7c4e6..03728ffce4d 100644 --- a/gas/configure.ac +++ b/gas/configure.ac @@ -392,7 +392,10 @@ changequote([,])dnl esac # Decide which ABI to target by default. case ${target} in - mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \ + mips*64*-linux-gnuabi64) + mips_default_abi=N64_ABI + ;; + mips*64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \ | mips64*-kfreebsd*-gnu | mips64*-ps2-elf*) mips_default_abi=N32_ABI ;; diff --git a/gold/configure.tgt b/gold/configure.tgt index 4b54e08d27f..ef47ce079f1 100644 --- a/gold/configure.tgt +++ b/gold/configure.tgt @@ -153,6 +153,13 @@ aarch64*-*) targ_big_endian=false targ_extra_big_endian=true ;; +mips*64*el*-*-*|mips*64*le*-*-*) + targ_obj=mips + targ_machine=EM_MIPS_RS3_LE + targ_size=64 + targ_big_endian=false + targ_extra_big_endian=true + ;; mips*el*-*-*|mips*le*-*-*) targ_obj=mips targ_machine=EM_MIPS_RS3_LE @@ -160,6 +167,13 @@ mips*el*-*-*|mips*le*-*-*) targ_big_endian=false targ_extra_big_endian=true ;; +mips*64*-*-*) + targ_obj=mips + targ_machine=EM_MIPS + targ_size=64 + targ_big_endian=true + targ_extra_big_endian=false + ;; mips*-*-*) targ_obj=mips targ_machine=EM_MIPS diff --git a/ld/configure.tgt b/ld/configure.tgt index 34c9d67c365..4a71f679e29 100644 --- a/ld/configure.tgt +++ b/ld/configure.tgt @@ -580,11 +580,19 @@ mips*-*-vxworks*) targ_emul=elf32ebmipvxworks ;; mips*-*-windiss) targ_emul=elf32mipswindiss ;; -mips64*el-*-linux-*) targ_emul=elf32ltsmipn32 +mips*64*el-*-linux-gnuabi64) targ_emul=elf64ltsmip + targ_extra_emuls="elf32btsmipn32 elf32ltsmipn32 elf32ltsmip elf32btsmip elf64btsmip" + targ_extra_libpath=$targ_extra_emuls + ;; +mips*64*el-*-linux-*) targ_emul=elf32ltsmipn32 targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip" targ_extra_libpath=$targ_extra_emuls ;; -mips64*-*-linux-*) targ_emul=elf32btsmipn32 +mips*64*-*-linux-gnuabi64) targ_emul=elf64btsmip + targ_extra_emuls="elf32btsmipn32 elf32ltsmipn32 elf32btsmip elf32ltsmip elf64ltsmip" + targ_extra_libpath=$targ_extra_emuls + ;; +mips*64*-*-linux-*) targ_emul=elf32btsmipn32 targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip" targ_extra_libpath=$targ_extra_emuls ;; From patchwork Thu Apr 20 13:31:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: YunQiang Su X-Patchwork-Id: 85913 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp338167vqo; Thu, 20 Apr 2023 06:31:51 -0700 (PDT) X-Google-Smtp-Source: AKy350b5CFueTlSjUrNZOy1NpRrRv1fMmI96MTPxBRx6d/EE+HXm108r3XWDyZCv6vfSCnEqlPa3 X-Received: by 2002:aa7:d392:0:b0:4fe:ddf:8d8c with SMTP id x18-20020aa7d392000000b004fe0ddf8d8cmr1796036edq.13.1681997510803; Thu, 20 Apr 2023 06:31:50 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1681997510; cv=pass; d=google.com; s=arc-20160816; b=AEh1bgkKMB7HeRGs2NMVEDliEt3S3sl6bRfsjzgZ8ZcZpAZO/dgYzd6VZfBrefRn3v caJFc61wyOb8THGH6KFHY2CgOW8/VRZUN3t4MPwnTjnwdOoon7YmE4SHAyJeQxOJh0iR rwPZhIfHDPAlg4qEX2XM7LfOwFw6ZD7Bidf/d9SDAtkd2tKeLFI8nGSLxFr8ooft5AUG L7blRCIdBa8MvN/Nl42CcojaQ+166aroMTp7ymfwUoX0bu0wZ3TVcrj4LrD1Sr2M4qPu FnE4kg2O3HL5XKbw52Z1qzOlNvgQ5le1anqdZuXB7iIofLykTSoNqzoE3GgO1gTehFPY Khlg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:mime-version :content-transfer-encoding:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dmarc-filter:delivered-to; bh=TcwBvAi3oJ3qLtqfrePYUEbFnJO7WTL+HCTY1qYBIL4=; b=WbErtfqDvs1SONm4mteSTx32S0MG1h75KHKANVsOETs3+V1HDsuwcrkKUZc7Z70Q5U GSggTvd0LObIt/WdNKJ3cfRiiiWkRgz0UfrdhjZAaM/iuEJyTm3fGQmZ6Fbezdyxopvd CzmL7+m+zx8Ut5dBCfNJJ87l4ar/fTcHKI4MldMz6KZk2QgjHPsuU+earmqJHeDVE6Io yEcKKEIjvCYzas+T7CEIPDx1es6dBrbTAZWsXIi2+F+jVhcktmygkApA6Bl7une/R0Rq 0LB5jnNo1J1Ru0C81Z4hzwhWppgyIdGdOrP7L+m0MFsfHdTxUatsQJfDOwX9Hmtvf1hF kkCA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@cipunited.onmicrosoft.com header.s=selector1-cipunited-onmicrosoft-com header.b=SV91sq2a; arc=pass (i=1 spf=pass spfdomain=cipunited.com dkim=pass dkdomain=cipunited.com dmarc=pass fromdomain=cipunited.com); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org" Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id d11-20020a05640208cb00b0050698e7cb11si1915692edz.356.2023.04.20.06.31.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Apr 2023 06:31:50 -0700 (PDT) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@cipunited.onmicrosoft.com header.s=selector1-cipunited-onmicrosoft-com header.b=SV91sq2a; arc=pass (i=1 spf=pass spfdomain=cipunited.com dkim=pass dkdomain=cipunited.com dmarc=pass fromdomain=cipunited.com); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 3DD5F3858C20 for ; Thu, 20 Apr 2023 13:31:43 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from APC01-TYZ-obe.outbound.protection.outlook.com (mail-tyzapc01on2103.outbound.protection.outlook.com [40.107.117.103]) by sourceware.org (Postfix) with ESMTPS id A98393858C83 for ; Thu, 20 Apr 2023 13:31:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A98393858C83 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=cipunited.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=cipunited.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bEgfdP4ecfnKUTm5ALeMwuzpEjuukCG7GG82iQV81QsDLKTD7NIGFxk1wH8R66A+Cax5B9bbKCaccQScnF8JRigEmNBFoDE8tNW+uG854BvczJpb3mPhTOByaR1pXrAdEfMPPhIZzPoT+90BjKRuiFnuGoCTHcxuk8oVNBrI8AuYSZ/0abg36c0GEjccfeHU07d9SV1/rmRatVDMM+DKJ3Eo3TYOzvVwzvu23oq/wDMkl+fGOwmRns3mmVaHziNapSCnCe+X0/rpISDoxmryouHNFc/bP+wp+eO9PnS5nwmD+GxCgpgxgTItX1CEwibG/VxdH9dYLxHvSbI8XZe8Pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=TcwBvAi3oJ3qLtqfrePYUEbFnJO7WTL+HCTY1qYBIL4=; b=m1WlneeXl9f4ciHSrzcJeYLEJxHAgSCaLHsRb3bZoAFmHyUXhxp+OhgbaPgI9TNu4ISNJ9ImzGlehTdgDoW4m5y1/zB4P4vW7eG3A6Ohgfs/JzMavRihN9AYJnE7e+ibtVrAIrvjS1bDt8BLs7iYdbPz/KhVGSUj+idvlRlsbqgFBvwz67iC49g14D4b5pQivdfIvd63LrJ+m2dm/Y9u7XEudFpLkSUaIYQoy2VyKuMb8IJmWk+FjwghBxFIy2v2lrptfBBlno4EpcAXG7n2zUXcFJFy2aIH5W2L5O6a3izv9gyg9/YfHhOgJ/Dwh9hCmVPUrszwLbAowAy0B+2LmQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=cipunited.com; dmarc=pass action=none header.from=cipunited.com; dkim=pass header.d=cipunited.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cipunited.onmicrosoft.com; s=selector1-cipunited-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TcwBvAi3oJ3qLtqfrePYUEbFnJO7WTL+HCTY1qYBIL4=; b=SV91sq2a1lYLJRiWdSiEr7LpC6MFo4NaszUSLj6M71kFSwqNt17+L5ptx72UvdPbBirSwQilNYUV2u2oO/Hgm1ZYOjbs3PgzRgknatjrBiqB/1OkJEiGNFCXoKKTIK3q1xGe3M83pAkFOMxgtMAbZ3+LHMBvtZA5IB2Tzg9R+Oo= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=cipunited.com; Received: from TYZPR04MB6117.apcprd04.prod.outlook.com (2603:1096:400:25a::9) by SEZPR04MB6172.apcprd04.prod.outlook.com (2603:1096:101:ce::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.22; Thu, 20 Apr 2023 13:31:28 +0000 Received: from TYZPR04MB6117.apcprd04.prod.outlook.com ([fe80::4016:87b:f0d1:b150]) by TYZPR04MB6117.apcprd04.prod.outlook.com ([fe80::4016:87b:f0d1:b150%6]) with mapi id 15.20.6319.022; Thu, 20 Apr 2023 13:31:28 +0000 From: YunQiang Su To: binutils@sourceware.org Cc: syq@debian.org, macro@orcam.me.uk, xry111@xry111.site, richard.sandiford@arm.com, jiaxun.yang@flygoat.com, YunQiang Su Subject: [PATCH v5 2/2] MIPS: default output r6 obj if the triple is r6 Date: Thu, 20 Apr 2023 21:31:02 +0800 Message-Id: <20230420133102.2422583-2-yunqiang.su@cipunited.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230420133102.2422583-1-yunqiang.su@cipunited.com> References: <20230418140019.2195551-2-yunqiang.su@cipunited.com> <20230420133102.2422583-1-yunqiang.su@cipunited.com> X-ClientProxiedBy: TYCP301CA0017.JPNP301.PROD.OUTLOOK.COM (2603:1096:400:381::8) To TYZPR04MB6117.apcprd04.prod.outlook.com (2603:1096:400:25a::9) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TYZPR04MB6117:EE_|SEZPR04MB6172:EE_ X-MS-Office365-Filtering-Correlation-Id: a2d0f9be-b9bf-493e-2249-08db41a38baa X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: zGTwjZeaSvUeeJCR/sVEMQRB5tfKJX52oPLvl3WGVxg+8tkdWwqrpWUyZpF1yWFRWvSSnpYVpBhU7fcsczUigHzhX5KCwcGsGJuVnmfMLQ69I84uI+1oscZX+wcOI39A0FHh0b92n3YXziSLn34xusXvYp3nqpc+fu7jLhrZ6kG7JCu128fPL6M1X02CwrzKtxze6+3R7NykpK6Oom18lvHGPt/98Wh2ohJWaDp/i1XuUwtQ72Cw8SWCdbA5csYfE+5/X1vefeAR6IX65FL5EPLAQ0vuFmjtOqyiwj/XkFigliCqOcxpN6bx81tzi0QpQLqXZsGy0Wnx4SL12uylY6aEGsX1posgT1i3jDZ+Q9S8zsW860eNgi4Kge8+PVzjgJCa0GupW0WPUPyoq+bc2iTBlCswkOPmtvAD/Kulu8uSu4ynh2MNtCuamsHkH8Cy1wQf/C6zwUMbBTMbMCxFKUWVDf64PP/bK/90IaRiaNli9epss0dk1XFZ9ROYGnuulQxl9AJx+l0XkTuK8sJhMXNZZRy5KIk84+NGgYZ3FeG6VlOsDEqr6Wk3bHIdj8YJPZsTblqqpbkX68hXaSsd2kBUdghLxycPZUVrHEl8rzzngmU/m6XPor3IuChduFkJ X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:TYZPR04MB6117.apcprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(366004)(346002)(39830400003)(136003)(376002)(396003)(451199021)(36756003)(4326008)(316002)(6916009)(66556008)(66476007)(66946007)(478600001)(52116002)(6666004)(6486002)(8936002)(5660300002)(41300700001)(8676002)(2906002)(86362001)(38100700002)(38350700002)(2616005)(1076003)(107886003)(6512007)(26005)(6506007)(83380400001)(186003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Q+Vaimk93z60Awx/hCU5W0gUnoSuUaCH2Sa3xLWlQYr/qNWFQB3e0KMckqVOlkabFhNEblqijkVKKawH/JnE6RdPwX1kcHF+Js8Pk79FXnBymS/DS6SXK1fjpIWv3BLvchcT7eJ25KWsbtdM0N07mvJ6XQR41S1uEE4sigvNZ+AsWJjwdoo/UCksqQEeECMjZu41nT28UaJ4tLnT/8Ld2VtIqGc1udchtPgI1SYYNSLz1gqMq7BYocQYZVR3fBL7OxPkhRaZ3QcjQh1GAhAC2Vdk1ZjC0+FZkWZ41A42Y/y1E+lrnou3IdjB7FX/JYiZoWAsf3mCi1LAU7QtJV3oJrO+Zat6ISpXOaCT+MvShCp3M6GjSAAl4ykqVTBtNVWceOo5L85oKK494vGRi6kKTefqgFO3JnIT0Vf/368zYuB8wsgJKhPLfqj50qIWEwJ0+YEpBkqmAl3h6PRjglzQNR51CoXRfVnUi0qmP23bZJtr3JpVUsCV4fjK7z1RUnfHYLmSq/9wh761/+19A7pV6/ARmdYTTmvzyFSj/1/zpSukkKnDPi+UCG5Ingn7SS4utpDjm6KIOc9X9b3QR/hoN5xufGQ0T4NKo/4p26fz8QOief8M2Twt8iaDRIyC4T6tMklo5ai1AF4FErsZvTKLuC7Pqe14mQ59ZEHTzndM8RJMf8zL7wKvbdPpFM64KdMgKxP3VYS2iyVH71Uxqs9FES8/wM0fzioewAOQ4yWw8X+17w8i9H/PsfhgQKr/M+kC5T7Mv7fk0WXL3y1wt2ErohlHXqaWzYFmoeBoY9UlXJJQ6SjQQasvhmJkVTmvVLRu1getJLOo9rjXx/la8zfGDdd3RN4TTcNx6oC0L2wSyVKuWPaETvqG1xzcZeavdTCawjzjuuyPdYhFHzbD7ARLLEeITI6I365IgeaQZfLTH2FXY7+V1uudPz8QAyE7/rrbF/O4N5CVIcRO+qVfCJ0jqOiVZ7foB6o7moCJCgcfrlKo+7vLfjiqXY/efOR2Uekh3+5qKtO+r5gp4B5zqCWV2d7jTxkS8LV4wK5/PbrEokzXibdhSDf84F/xglqW9G78mTbIn+sf2YXrwV9JNzL3neSlE0ezsEMQdywFCNYEVYrWzHzNkTB/6PdUpBZsIJS0nIqv0ArfZDHxhe/ToL7K4HybZmnRidVmCyrdwdOm8nQeI0SB2cCp094v7V+0FuCEgBoXBU+thNKAG0IQ8p/d9VOa2ZYi0PQpGhibl18rbDDloL9X2S8gDevNe5yvEmy8LR0rB6oiLnDMaveOU5BKSkPuD3p9MMkLPe/rGw1HE3ut9TVEF79rI2NZkUOwlnYkS9ieOYSHq+UuJXXsXQv7SrB8Pg0jZwJqp2j+vrwryUgc4oKz1htktIUIZvLvIbkWDqaSGwEaOEelGGoU/omxE8HaOKTywmCqXI6AeO4x5nDqEWgl5NbZjyDSiiXkUvcTkwhbgJHwBFPfTgcT0JB4OPAaJZsUgYnWkdZC/hrb17BP4tSig9pCEC5psurrmLPdZMoPvYfntmwDOx++cULKGgYE8sewRyni4JdKGPWVC/vg4aYErX+2O1umKpffkqAafyj1n/57hMfuHR1o4FhGlA== X-OriginatorOrg: cipunited.com X-MS-Exchange-CrossTenant-Network-Message-Id: a2d0f9be-b9bf-493e-2249-08db41a38baa X-MS-Exchange-CrossTenant-AuthSource: TYZPR04MB6117.apcprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Apr 2023 13:31:28.4608 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: e31cf5b5-ee69-4d5f-9c69-edeeda2458c0 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: zA2nGuuYAcXSm9bp18WFV9rkfP0NzyshqsNQXr8ZNs1R2YCM3l9nHiEGHlgd8M9Ol81FX8l3YSiYBc54ZC156NOCoKv9E9mobNhU6aYXbJE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEZPR04MB6172 X-Spam-Status: No, score=-12.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE 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: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org Sender: "Binutils" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763523209248696759?= X-GMAIL-MSGID: =?utf-8?q?1763702222049436052?= If the triple is mipsisa32r6* or mipsisa64r6*, ld/as should output r6 objects by default. The triples with vendor `img` should do same. The examples include: as xx.s -o xx.o ld -r -b binary xx.dat -o xx.o --- bfd/config.bfd | 6 ++++++ bfd/elfxx-mips.c | 4 ++-- bfd/elfxx-mips.h | 4 ++++ gas/configure | 9 +++++++++ gas/configure.ac | 9 +++++++++ 5 files changed, 30 insertions(+), 2 deletions(-) diff --git a/bfd/config.bfd b/bfd/config.bfd index 1e4bea191dd..78752994456 100644 --- a/bfd/config.bfd +++ b/bfd/config.bfd @@ -1535,3 +1535,9 @@ case "${targ_defvec} ${targ_selvecs}" in targ_archs="$targ_archs bfd_iamcu_arch" ;; esac + +case "${targ}" in + mipsisa32r6* | mipsisa64r6* | mips*-img-*) + targ_cflags="$targ_cflags -DMIPS_DEFAULT_R6=1" + ;; +esac diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c index 13a89953293..c9cd2f8099f 100644 --- a/bfd/elfxx-mips.c +++ b/bfd/elfxx-mips.c @@ -12327,9 +12327,9 @@ mips_set_isa_flags (bfd *abfd) { default: if (ABI_N32_P (abfd) || ABI_64_P (abfd)) - val = E_MIPS_ARCH_3; + val = MIPS_DEFAULT_R6 ? E_MIPS_ARCH_64R6 : E_MIPS_ARCH_3; else - val = E_MIPS_ARCH_1; + val = MIPS_DEFAULT_R6 ? E_MIPS_ARCH_32R6 : E_MIPS_ARCH_1; break; case bfd_mach_mips3000: diff --git a/bfd/elfxx-mips.h b/bfd/elfxx-mips.h index 4addf6f5d1a..f15dceac48e 100644 --- a/bfd/elfxx-mips.h +++ b/bfd/elfxx-mips.h @@ -29,6 +29,10 @@ enum reloc_check check_shuffle }; +#ifndef MIPS_DEFAULT_R6 +#define MIPS_DEFAULT_R6 0 +#endif + extern bool _bfd_mips_elf_mkobject (bfd *); extern bool _bfd_mips_elf_close_and_cleanup diff --git a/gas/configure b/gas/configure index 868f4a911a9..0daa80d5b4c 100755 --- a/gas/configure +++ b/gas/configure @@ -12211,6 +12211,15 @@ _ACEOF use_e_mips_abi_o32=1 ;; esac + # If Vendor is IMG, then MIPSr6 is used + case ${target} in + mips*64*-img-*) + mips_cpu=mips64r6 + ;; + mips*-img-*) + mips_cpu=mips32r6 + ;; + esac # Decide whether to generate 32-bit or 64-bit code by default. # Used to resolve -march=from-abi when an embedded ABI is selected. case ${target} in diff --git a/gas/configure.ac b/gas/configure.ac index 03728ffce4d..2b91f9ec616 100644 --- a/gas/configure.ac +++ b/gas/configure.ac @@ -380,6 +380,15 @@ changequote([,])dnl use_e_mips_abi_o32=1 ;; esac + # If Vendor is IMG, then MIPSr6 is used + case ${target} in + mips*64*-img-*) + mips_cpu=mips64r6 + ;; + mips*-img-*) + mips_cpu=mips32r6 + ;; + esac # Decide whether to generate 32-bit or 64-bit code by default. # Used to resolve -march=from-abi when an embedded ABI is selected. case ${target} in