From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lj1-x230.google.com (mail-lj1-x230.google.com [IPv6:2a00:1450:4864:20::230]) by sourceware.org (Postfix) with ESMTPS id D8CD23858C2F for ; Mon, 22 Jan 2024 07:49:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D8CD23858C2F 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-Filter: OpenARC Filter v1.0.0 sourceware.org D8CD23858C2F Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::230 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705909791; cv=none; b=btesbeHWGbm9XXxK4TKwho8yzcdb0yZPPBELhUQaQm/CbXxBDVQwIv4PztT+sKUXFTEwtpZtEiESt/xkYk+tgbVbg8T3cvYTadMqyQ4FDvXNA66aUEdYcq25XMH9LkMbBqoyIFMbUJDdjhB7uThHrBUCTlunrNEkos5UFgI+/LU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1705909791; c=relaxed/simple; bh=r9DNEjyh8CVkfxezF6LuVnE9uk45SF2t1XIEF/j26II=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=EmlhhhIsQTJuM8BtCfQUWlQUiM7oyConsgp0ToCLXMSOabHpjHaKHpAyee37Pyz0l76/B0BGSAXXoj+55yAGBAFfAPiPxQhbCbip/gDsiCzUEn+7CicNOPiAQ3wYLbuRG3dX704+x5QESQTP5i3XRPMv4e14T/C/mkAL0MMiMR0= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-lj1-x230.google.com with SMTP id 38308e7fff4ca-2cef994d4e6so8763451fa.2 for ; Sun, 21 Jan 2024 23:49:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1705909788; x=1706514588; darn=sourceware.org; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=Pu+GUf+rAKyWGYSyAKB+B+2KRk7uNSoA3JQB5eq84+I=; b=SXGEmYnuwFI9nMsDYJW9mLRElj0DjoX5epqAq1dIxVU/fAjo+nSWupwzc+RRq/GW28 wSJ//wsto7Za7GTwR03OgWhDOgvo4+WCekx7tSgnC1DZfljqMX0wHAaIl6vERZfYp7n/ iPxPpM9CK35AOkR3KSfEGv6XD9AsCyArxff5CqQpKlHKuRaJteyYTfVLZNT3wwwrkk72 yOMfHohjsVbbCMNJs05ybidA25RmkDuP4b4vzg19Yffp4tc2wrS+OrkYvQYk3rHv8Fi+ aDz6V7P+XXmywivitHi7M3XTqetLTv8Em8YbmwazyjQtmi+pjtmm1pEs2YCfDK43H/vp DtGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705909788; x=1706514588; h=content-transfer-encoding:in-reply-to:autocrypt:from:references:cc :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Pu+GUf+rAKyWGYSyAKB+B+2KRk7uNSoA3JQB5eq84+I=; b=TkF2i53jUiuLxghXhYRLSryriPMqJxZ8+TjTu2xljqg1Bcia4YNDzpQ1kVD0ZlyBmu Cu7hJ+k45IVk9hKjtS9150OUER0Fxc3TGQN7br71rN836FOYRmSqiBTDq0Jtj3JGVNoT yXE+9Lj2toBwXJM8UCam5RMXggXcb06Fc/EcqX15uBuK2KNID/QHLSa0332dd9NrKmX4 ri5COIQQx2YjmrJg2w26YhRKCVOYN07hTCAGhh02mXOF2TeurclC8cd/fw131mjeV0xX 6vVguiNOGuc6oXT3jqGqoaCmiZMScT9LJXd9z3v4OcjfVeHXu4LxTBJiPXo1+6tHsfDf A4OA== X-Gm-Message-State: AOJu0YwTyJCP1otp6qdoE/acyj1CIy4whx5wjo3bEFMGPu79cTnumO4D KZP7BMFARgWUnMMl5dGNDPRQs2FfQIaCKOVZ/Bk7h/eGPhW6ZSBqcrNUQ5OfYmSAckDmFoC0Bzk = X-Google-Smtp-Source: AGHT+IERocDvo6IJXk/5/x5WX4fsuRo0Kk8enMw4YgQFEzorAuvLS+RKKH+EsnDuAZJ8Q4r7ZRFLsA== X-Received: by 2002:a2e:3515:0:b0:2cd:3141:5d65 with SMTP id z21-20020a2e3515000000b002cd31415d65mr1269776ljz.75.1705909788261; Sun, 21 Jan 2024 23:49:48 -0800 (PST) Received: from [10.156.60.236] (ip-037-024-206-209.um08.pools.vodafone-ip.de. [37.24.206.209]) by smtp.gmail.com with ESMTPSA id bs19-20020a056e02241300b00361b71f967asm1432727ilb.75.2024.01.21.23.49.46 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 21 Jan 2024 23:49:47 -0800 (PST) Message-ID: Date: Mon, 22 Jan 2024 08:49:47 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] opcodes: i386: fix dw2_regnum data type in reg_entry Content-Language: en-US To: Indu Bhagat Cc: "Kong, Lingling" , "binutils@sourceware.org" , "Cui, Lili" , "Hu, Lin1" , "H.J. Lu" References: <20240109011229.4191052-1-indu.bhagat@oracle.com> <1cf65034-171c-44e7-bb7d-022f35451cb0@suse.com> <341075aa-2e7b-4043-8239-fc912149b080@suse.com> <8476f39c-1a6e-44e2-a1b7-e8a0ee7b5754@suse.com> <81971ec0-152c-4776-b56a-7d113cc01668@oracle.com> From: Jan Beulich Autocrypt: addr=jbeulich@suse.com; keydata= xsDiBFk3nEQRBADAEaSw6zC/EJkiwGPXbWtPxl2xCdSoeepS07jW8UgcHNurfHvUzogEq5xk hu507c3BarVjyWCJOylMNR98Yd8VqD9UfmX0Hb8/BrA+Hl6/DB/eqGptrf4BSRwcZQM32aZK 7Pj2XbGWIUrZrd70x1eAP9QE3P79Y2oLrsCgbZJf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aAs8OFfGQ0ia3LGZcjA6Ik2+xcqscEJzNH+qh8V m5jjp28yZgaqTaRbg3M/+MTbMpicpZuqF4rnB0AQD12/3BNWDR6bmh+EkYSMcEIpQmBM51qM EKYTQGybRCjpnKHGOxG0rfFY1085mBDZCH5Kx0cl0HVJuQKC+dV2ZY5AqjcKwAxpE75MLFkr wkkEGBECAAkFAlk3nEQCGwwACgkQoDSui/t3IH7nnwCfcJWUDUFKdCsBH/E5d+0ZnMQi+G0A nAuWpQkjM1ASeQwSHEeAWPgskBQL In-Reply-To: <81971ec0-152c-4776-b56a-7d113cc01668@oracle.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3025.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,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 20.01.2024 01:45, Indu Bhagat wrote: > On 1/11/24 06:05, Jan Beulich wrote: >> On 11.01.2024 14:27, H.J. Lu wrote: >>> On Thu, Jan 11, 2024 at 12:05 AM Jan Beulich wrote: >>>> >>>> On 11.01.2024 08:59, Kong, Lingling wrote: >>>>> >>>>> >>>>>> -----Original Message----- >>>>>> From: Jan Beulich >>>>>> Sent: Thursday, January 11, 2024 3:43 PM >>>>>> To: Kong, Lingling >>>>>> Cc: binutils@sourceware.org; Indu Bhagat ; Cui, Lili >>>>>> ; H.J. Lu ; Hu, Lin1 >>>>>> >>>>>> Subject: Re: [PATCH] opcodes: i386: fix dw2_regnum data type in reg_entry >>>>>> >>>>>> On 11.01.2024 02:35, Kong, Lingling wrote: >>>>>>> >>>>>>> >>>>>>>> -----Original Message----- >>>>>>>> From: Jan Beulich >>>>>>>> Sent: Tuesday, January 9, 2024 4:25 PM >>>>>>>> To: Indu Bhagat ; Cui, Lili >>>>>>>> ; H.J. Lu ; Kong, Lingling >>>>>>>> ; Hu, Lin1 >>>>>>>> Cc: binutils@sourceware.org >>>>>>>> Subject: Re: [PATCH] opcodes: i386: fix dw2_regnum data type in >>>>>>>> reg_entry >>>>>>>> >>>>>>>> On 09.01.2024 02:12, Indu Bhagat wrote: >>>>>>>>> The DWARF register numbers for the APX EGRPs start with 130. The >>>>>>>>> data type holding the same currently is signed char. >>>>>>>>> >>>>>>>>> ChangeLog: >>>>>>>>> * opcodes/i386-opc.h (reg_entry): Bump to signed short. >>>>>>>> >>>>>>>> So yes, something needs doing. But there are further questions to be >>>>>>>> raised to the original authors: Was the code tested at all in this >>>>>>>> regard? Why do numbers start at 130, when according to i386-reg.tbl >>>>>>>> 128 and 129 are unused (and would hence be more natural to [also] use)? >>>>>>> >>>>>>> This is because for some historical reasons, some numbers(126-129) have been >>>>>> agreed to be reserved. >>>>>>> Details can be found in https://groups.google.com/g/x86-64- >>>>>> abi/c/GS8LZf5nQFk. >>>>>> >>>>>> I'm sorry, there are no details there. There's merely mention of these four being >>>>>> reserved, without supplying any reason (historical or not). >>>>> >>>>> Sorry, you could see https://gitlab.com/x86-psABIs/x86-64-ABI/-/commit/6207f9a2c0645f20a7ec591a09e4c382b1675784 >>>>> There are reserved for Intel MPX (Memory Protection Extensions) provides 4 128-bit wide bound registers (reg{bnd0} - reg{bnd3}). >>>> >>>> Then why aren't these marked that way? The commit introducing them to >>>> opcodes used Dw2Inval, and it was never changed from that (i.e. there >>>> wasn't even deliberate undoing with respective justification). >>> >>> Leave them as reserved. We have plenty. >> >> Hmm, the latter sentence doesn't fir what I meant: Why does / did >> i386-reg.tbl not / never have those numbers? I could have seen that >> they were there and then possibly have been purged, but even then >> I would expect there a comment to have been left. So minimally what >> I'd like to see / do is to add such comments. > > Is the patch (opcodes: i386: fix dw2_regnum data type in reg_entry) OK > to commit now ? To be honest - not sure. I'd like to look into avoiding the growth, by switching to "unsigned char" instead. But that requires changes elsewhere, because of the need to double-check uses of (and maybe further special- case) Dw2Inval. Jan