From patchwork Fri Oct 4 13:38:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Beulich X-Patchwork-Id: 98388 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 BAD27385E011 for ; Fri, 4 Oct 2024 13:38:47 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) by sourceware.org (Postfix) with ESMTPS id C662D3848373 for ; Fri, 4 Oct 2024 13:38:14 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C662D3848373 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 C662D3848373 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::62d ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1728049097; cv=none; b=ofJy2bXK/5Hc78ZRN3frudcwLbFOG6XygismuXuJHkUHr9TCpidbYdB5v9mscVSqtBW97OiS0tAKyJySYtL6nswXV07CTgGkqxIhT8LNh0bo+ui8loFJAHy2QW5OEXs8DoJ8VYHRO4ZemrNyqCDDgRZgu3oer1pcl4H7sz1QUuI= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1728049097; c=relaxed/simple; bh=XcL+BRny/TY174GqECnJvQddLUYV5kGvKEmR8p24VDg=; h=DKIM-Signature:Message-ID:Date:MIME-Version:To:From:Subject; b=HF98DrSRDuvy6mjbs9KdJRde7tmqRb5480rqaMEb18jBX6dY1fBvCKzgjXH16dv6imzPQDrrDa+UXYxsnodFYbTcymtGhzQrc4/MK6JkUuYHrKnRJ6wT2u+g+NqZwVmc7Rme6eLQ2KCsP52FV4a8jYEKxOGBuaQDd15pIRSOhY4= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-a8d4093722bso304598066b.0 for ; Fri, 04 Oct 2024 06:38:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1728049093; x=1728653893; darn=sourceware.org; h=content-transfer-encoding:autocrypt:subject:from:cc:to :content-language:user-agent:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=93lc3lbuOorGQZbVs4XqnxAgzaoegrpqhgWS3dbNkZU=; b=OWu6RVlH5s65zjJvSr6037jI/N+mVGFWpyl6rBhSfYdj7hV5vDhEU39SgdnIkT5HYQ An9acYqqnsD0OyApkLspxZvjC0uda/bRDX3zm4sFEPzNBJbsoB826GZgU0Ivxu65z3Rf CMloKDNWci4h5MXnuJXW4sVESwz2c9jX/JYBJYZ2mD0/JHx9MYmyYOLXfN6MLxXmvBRn jMOE9yUC+txniAMVnsRB6BwRGRvr8KCiITzP+f5ILpk7Sv8gKXCV1893SE7uG/gn0Fu2 AVjR/yAntPjvJP2eh0pN1/YHkZo3LQBK0A1Vw0ZX78hP2PGefnqmGnMxAeBW1nelo+Wi GDXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728049093; x=1728653893; h=content-transfer-encoding:autocrypt:subject:from:cc:to :content-language:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=93lc3lbuOorGQZbVs4XqnxAgzaoegrpqhgWS3dbNkZU=; b=fl5fjWaLyJ7gw2R/KJFUdG8mxvX5pIFKKsKemIUvxuNpQpO3X22eGdz/mV0WkcRoHn EzPZGJiwwl73AmEUhYUm95lTB3WOFgoiV/MgEGClZo3EVV04853VXtLV+XIozvrBY6Ln IkutrLWxkyj9E/+e7D6hiDxFZwbK9+1vxgVj5F8mIlA0X8I1c0Nwkwb9rUjTGBfEMw9A D/WCb/gYqQ/DQJHlQTJWCbn22GU6OYphHLEEqdqtla4jrzy1B9g9XKVrWpwBF0CC61tz fqSw9NO+CAwSsMkHjuVkyTGfIcnPeJYRsQ39oaN2fb4/IgBDoLc38RiJc1gMT5s1T48m woRQ== X-Gm-Message-State: AOJu0YwEU4G+4qq2mXF3pWMRN/YiQQh8hOVDlcZSo+4+/tKa7quebAeH cKJ+lPpbJfkLHu4XeAx6FQNMPn3S30xAwENmnxmYZkpwkQKSIz7PyBEvz1my4BNfD72ygiYMypc = X-Google-Smtp-Source: AGHT+IHwQ/CJhttEV8vsOpg21Q93zjf3UL2SOIQWwUcYPiXdN+XQfld492tPDOA5leC1IP8wyB28JQ== X-Received: by 2002:a17:906:6a10:b0:a99:a89:47cd with SMTP id a640c23a62f3a-a991bd04e0bmr314139866b.3.1728049093253; Fri, 04 Oct 2024 06:38:13 -0700 (PDT) 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 a640c23a62f3a-a9910479fe4sm228590366b.158.2024.10.04.06.38.12 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 04 Oct 2024 06:38:13 -0700 (PDT) Message-ID: <9beb26a8-5cfe-4d14-8245-601c31eaea5e@suse.com> Date: Fri, 4 Oct 2024 15:38:12 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Binutils Cc: "H.J. Lu" From: Jan Beulich Subject: [PATCH] x86: bring 64-bit-only cmdline option handling in sync Autocrypt: addr=jbeulich@suse.com; keydata= xsDiBFk3nEQRBADAEaSw6zC/EJkiwGPXbWtPxl2xCdSoeepS07jW8UgcHNurfHvUzogEq5xk hu507c3BarVjyWCJOylMNR98Yd8VqD9UfmX0Hb8/BrA+Hl6/DB/eqGptrf4BSRwcZQM32aZK 7Pj2XbGWIUrZ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hlbM3gfDMs7MPMu8YQRFVdUvtSpaAs8OFfGQ0ia3LGZcjA6Ik2+xcqscEJzNH+qh8V m5jjp28yZgaqTaRbg3M/+MTbMpicpZuqF4rnB0AQD12/3BNWDR6bmh+EkYSMcEIpQmBM51qM EKYTQGybRCjpnKHGOxG0rfFY1085mBDZCH5Kx0cl0HVJuQKC+dV2ZY5AqjcKwAxpE75MLFkr wkkEGBECAAkFAlk3nEQCGwwACgkQoDSui/t3IH7nnwCfcJWUDUFKdCsBH/E5d+0ZnMQi+G0A nAuWpQkjM1ASeQwSHEeAWPgskBQL X-Spam-Status: No, score=-3023.3 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 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.30 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces~patchwork=sourceware.org@sourceware.org --64 and --x32 are already suppressed in --help output when BFD64 is not defined. Also avoid recognizing these options in such configurations. --- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -16799,11 +16799,14 @@ const char *md_shortopts = "qnO::"; struct option md_longopts[] = { {"32", no_argument, NULL, OPTION_32}, -#if (defined (OBJ_ELF) || defined (TE_PE) || defined (OBJ_MACH_O)) +#if (defined (OBJ_ELF) || defined (TE_PE) || defined (OBJ_MACH_O)) \ + && defined (BFD64) {"64", no_argument, NULL, OPTION_64}, #endif #ifdef OBJ_ELF +# ifdef BFD64 {"x32", no_argument, NULL, OPTION_X32}, +# endif {"mshared", no_argument, NULL, OPTION_MSHARED}, {"mx86-used-note", required_argument, NULL, OPTION_X86_USED_NOTE}, #endif @@ -16895,9 +16898,10 @@ md_parse_option (int c, const char *arg) else as_fatal (_("invalid -mx86-used-note= option: `%s'"), arg); break; +#endif +#ifdef BFD64 -#endif #if (defined (OBJ_ELF) || defined (TE_PE) || defined (OBJ_MACH_O)) case OPTION_64: { @@ -16940,6 +16944,8 @@ md_parse_option (int c, const char *arg) break; #endif +#endif /* BFD64 */ + case OPTION_32: { const char **list, **l;