From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-he1eur01on2041.outbound.protection.outlook.com [40.107.13.41]) by sourceware.org (Postfix) with ESMTPS id 50A833858D33 for ; Fri, 28 Jul 2023 06:13:37 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 50A833858D33 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=suse.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Id2T+v1k7E9btK3uuq6eRfpUrzbFTqCGHKM2zwbSiEjEIjUUHLYh3CBODo0CyQgcEKjAiRtENYd/GLj5MHlTVgS31sqKfvM4lbozujKmD3RxK+broa7F0jWjSgL0FOV4QfDjLiLr6ZQFkNulab9v2Xc+aoGSKaodSM1OhZEIYjUKXKKRWpyPE8JnmMvVe6uslbJT60YSI5k9v/KMtfmaGrgwCBcQznk47CenIMEPNU99ibIQQfM4HWcfa0Xt7AcCRwwawk5ku4TSMBkXGmbuv53reCzMyBhPzhOMwOBSzBM8AT98/0/Ncmyf1fi1lYp6D+HkUjvkP+p5jxc/KAv67Q== 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=4FQn9ymjnfT68CsEDqdgy2VFVT/7WP9wvBNNgr6Z0/Q=; b=Qej2ZI8EJAG7URNR92EvmnM4CHtorPUGZ5cnbrUFnBze+oy6WL3iqvZefxSKiV9LtOcRY6EUI58BWU/KJ0RbnlIiXmVcUBPjPjsI9p/gxjAsKbPnG5aEZ4WFg6x3Q2kqmK7whf5R7sDk4c2HYgfeZxPvh2EDklBfF1HDfpG9J0hBtPRWezqWLJmn0iECyL94J96ln9udxxtz8Hx1f0X+HmTYtdDWmZfxlHq2pXsAOw7k6qHgOUtkinS59iVzYW/x+Qwi0bmNf8IRFfzYNSLy55nOSmWrVbilPf0pLKMQD4q0hhyUdrlwQbmLcTbNgenWQPO4JS87QQF6fYgQkG8xjQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=4FQn9ymjnfT68CsEDqdgy2VFVT/7WP9wvBNNgr6Z0/Q=; b=aLHOuHV5a2/TvLd3GPltemgSqCSw4FtjVBxVzO3LP3gjF4wyfoV3hDOwVNRzE8PA/8SU7OWVSVzbZ5MMdcuZiyQVtxoeKU4qKCFNEujei/2OknisnWfN0gik93ur0m64bOVlz+NShwjmPNX+sLq5pEyiHiyKcZZ6IC8c+nyplKpo1wEW/elAyIH8F+a8MiDFMJqcqcinT1qYJT4x4Qt8G7wEuLzRDggbWHrCz/MJ+Z2lsUxOAblYZZfcHG3+blKG7rkR5mjtbN3SWxu+7bXvty2ryuzk/Kecgk57sOQmthWbnLagFECw1aQOSrThV4sx1YQN+bkYZGzb0FyHNdGZEg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com; Received: from DU2PR04MB8790.eurprd04.prod.outlook.com (2603:10a6:10:2e1::23) by AM7PR04MB6997.eurprd04.prod.outlook.com (2603:10a6:20b:10d::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6631.29; Fri, 28 Jul 2023 06:13:34 +0000 Received: from DU2PR04MB8790.eurprd04.prod.outlook.com ([fe80::e5cf:5743:ab60:b14e]) by DU2PR04MB8790.eurprd04.prod.outlook.com ([fe80::e5cf:5743:ab60:b14e%5]) with mapi id 15.20.6631.026; Fri, 28 Jul 2023 06:13:34 +0000 Message-ID: Date: Fri, 28 Jul 2023 08:13:31 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: non-conformant ELF symbol table on MIPS? Content-Language: en-US To: "Maciej W. Rozycki" Cc: Chenghua Xu , Binutils References: From: Jan Beulich In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FR0P281CA0090.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:1e::15) To DU2PR04MB8790.eurprd04.prod.outlook.com (2603:10a6:10:2e1::23) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU2PR04MB8790:EE_|AM7PR04MB6997:EE_ X-MS-Office365-Filtering-Correlation-Id: db1c6684-de57-4be8-0578-08db8f31c5e4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: P4GvDzthMb/iRiRRlbnam+T1vOMPrMMNapeWlK2UlDIQ7KCUEgH9VeIlah6l8yN2Bm4xcUaxKCrDHLMYl4GoKiKar4p21h0eretNsAX6Ih1ICsdUipQwybl9RDVfmkAmKYW7Lhu+P3yExOe6btdVWD03Q1umSwmwX9tmE+bV8mgScTT7SlOWCPOI2Vd4eVv2LEje2ax1nc467Kins00ZCFJ68oyYXvL8mkAjTf7qR5Ct+GTuYVp9gtPBTtb9uZR+b3lPpdsXQwnuAeCYKBndhtCGNSCTuBfKjT7ExCNILsMOP6K6fMyyQFIXyFfTTJsDDW3Vr6OLcK7wFKfdbvg58UbMRnwNfT1kwA/w14G+RVp7ak7CgL4RriLQa7ai37b40sv6PB5ahSQYamowsA+MfugkapVR+r7G0S1x1sO+ktpBaCi1wjgaNCyCUjBgjqQ24PmJ0cQ+qXu6hgfPBnarzYw066oVa6cPtY8YmeGlGO+Y7DHwSX4/h/raCUyVqPsM6vqyRVlXmbfaV3nnuAKCmbv6dzZTal0V1rSWZHhwhSAs+Md7nS9+7WXaIRnjXHuo2Zk3AnBqT8N5ogqb1bW+JzVDwIsNoDe5ZbohR/zelWT5cZ1gJskhNSdHEYDos11QDe9CStBFc93qsRT0Lw2Nkw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DU2PR04MB8790.eurprd04.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(396003)(346002)(39860400002)(136003)(376002)(366004)(451199021)(31696002)(86362001)(36756003)(31686004)(38100700002)(2906002)(54906003)(478600001)(6666004)(2616005)(6506007)(186003)(26005)(66476007)(53546011)(8936002)(6512007)(6486002)(5660300002)(41300700001)(83380400001)(8676002)(4326008)(66946007)(316002)(6916009)(66556008)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?WjdTRzhLektsQzBCUHFZVFRXUU5JbllOOXhIV2JCSkhGbFZKbGprUSs2S3dl?= =?utf-8?B?Qk9SdzNtMlloTzZSL0g0eUN3WlNwK1AzWE1BT0Rrbm84T1dyaVErRmdpU2VV?= =?utf-8?B?dSs5TFdBaGRKOStpSkY5Rk9FOFJ6Z29ZUTVORmhXSXZTVFpPTDVSMUxYeS9G?= =?utf-8?B?YUNhcnZqOTA2ZXlieGltWkxWUmJHcW1WZm5uK2llVXlPUVU0WFlrTE1KdHF1?= =?utf-8?B?R0xrVFRXTnh0MGhtNkFEbHA1NjFpY2JaZUxTRzV1SVM1U3VXUm04cDU0d0t3?= =?utf-8?B?OGx1Zit2b1AyQ2huVkR2UmVwMDJYN2wyYlBlMmkzQjBoeE9UQkxoUWhFNU5T?= =?utf-8?B?VkI5YjhuR09FU1pmOUMrV1FtZ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network-Message-Id: db1c6684-de57-4be8-0578-08db8f31c5e4 X-MS-Exchange-CrossTenant-AuthSource: DU2PR04MB8790.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Jul 2023 06:13:34.0506 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: fkiRTf/XOTry6fI/JO7usbqaeCQsCDeQ9PzXqsxrtvN9DF5KfnWXp6i6MjPIRAhkr+1SyFKo5fkKhH6Nlm0gKg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR04MB6997 X-Spam-Status: No, score=-3027.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,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 List-Id: On 27.07.2023 21:28, Maciej W. Rozycki wrote: > On Thu, 27 Jul 2023, Jan Beulich wrote: > >> extending the gas elf/common3.s testcase (in the context of trying to fix >> PR gas/30688) to >> >> .comm foobar,30,4 >> .comm buf1, 5-1, 8 >> .comm buf2, 4, 9-1 >> .lcomm lbuf, 9-1 >> >> I notice a violation of the ELF spec on most (all?) MIPS targets I would >> routinely test for common code changes: "lbuf" is emitted last in the >> symbol table. The spec is quite clear: "In each symbol table, all >> symbols with STB_LOCAL binding precede the weak and global symbols." I >> guess I want/need to xfail that test for mips*-*-* for the time being, >> but it would be nice if you could shed some light on this behavior. > > Which specific MIPS target is it? Among the 9 I test, it's mips-unknown-elf, mipsisa32r2el-unknown-elf, mips-sgi-irix6, and mipstx39-unknown-elf. > There are two kinds of MIPS targets, ones that use the older IRIX symbol > sorting rules and ones that use the newer "traditional" symbol sorting > rules. The IRIX symbol sorting rules mandate that section symbols precede > all other symbols, see e.g. bfd/elf32-mips.c:mips_elf_sym_is_global. > Mind that SGI was an early adopter of the ELF standard and things weren't > as settled as they are nowadays, hence e.g. the odd solution for composed > relocations with the n64 psABI (later n32 uses standard ELF gABI ones) and > other peculiarities here and there. > > Determining whether a MIPS target uses the IRIX emulation is complex, see > e.g. how binutils/testsuite/binutils-all/mips/mips.exp sets `irixemul'. > If you provide me with test case details (input and output), then I may be > able to give you further advice, I've provided you the input (see context above), and you'll be able to generate the object file from it yourself. But I don't see what this would bring, when you already indicate that this is "expected" behavior. > but otherwise you may want to mark the > test case with `notarget' or suchlike rather than `xfail', because that's > not a bug with the backend that the symbol ordering varies. I'm okay making mips*-*-irix* "notarget", but I don't view this as appropriate for e.g. mips*-unknown-elf. Instead I would prefer leaving further tweaking (if so needed) to you. The immediate goal is to get a regression fix (with an accompanying extension to a testcase) in quickly, such that hopefully Nick would still be able to pick it up for 2.41 (as in principle it affects most if not all targets). Jan