From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by sourceware.org (Postfix) with ESMTPS id 1318B3858412 for ; Sun, 19 Mar 2023 15:11:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1318B3858412 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-x129.google.com with SMTP id j11so11986824lfg.13 for ; Sun, 19 Mar 2023 08:11:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1679238668; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ILCBwAsFi8P5MaTdztO1YgfHPGxdkYhYCnZ2ykKV0Cs=; b=qO4cRtKYTsp/jup3ujKXcofu98fdPNlrjnK/DOrj4gYy6M2GquZbubJJteLfKe2rja AkLU6+S3QwsOtf+7DHXpJU1ckSrY/ckCqhD6gCopV3F55bAUoiSlxT/s6XNebOAeQ98s tT3nvd0Cdc8KTVY1c8gwazvh9mR2BPzPdePYPkukiLdDKmECUuUQFxKsC6vJR9EYkuhY OJ8loRk6V4Bbu7uAQV6bLW/c2PS+C5IPGp1oBMYZTTIaLAPq5zhJBkbs+1+gVqpcFqSH Qk/DVoYw74+9KVh3vKjFhtOnrB99lZmEMJhxs1ae1KvpJ8L9EGl2MmpVUmsWmiVoE1iI B/Ew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679238668; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ILCBwAsFi8P5MaTdztO1YgfHPGxdkYhYCnZ2ykKV0Cs=; b=UHVjpC+bNNh1FHQTMjWuBsn9Mrh2RRa+z0x4LoigUJKXO/n/29vsZ1a2gN8sjqvbcP YioM5JSHIbZvLWR47cq4t/SyBjHvcsy8/wHJX9+jnpur/PZfub1ZTPUEc8H9mP4pOo7h l4hcieK4rIqSPX3noasd56GN9hYeGFJ68aC5Muv+kZBut8MXsLFvyFNs3hexNhjDik9o FkP/Nb6VRpOAVIb7XVsj/DrHLq9rIz8BhKeKwhmiPSOWp12xLpRELhar4yQcZMmEldng U1UOLo9vipaG/InMhFNTqc14CryDTvrkEcTuRZvjoOu3xQNTFLP9mlkKLIj+HqhMhRhg NriA== X-Gm-Message-State: AO0yUKWRM6Cvy+AiwbA1uDpdK2A/QPxTOQDBwDRceEUyP5pltFhyd8b9 4NLg+yTEV896TMGlM3x2Iw4FKtpSEfVlJg== X-Google-Smtp-Source: AK7set89Wjno1vcnsQhbzobXTgrVeaHxolNeC7jHrDH+YXeiM8jLHHYdJSeudX2TqgcMXSUJiQzoFA== X-Received: by 2002:a05:6512:952:b0:4dd:abb9:dae4 with SMTP id u18-20020a056512095200b004ddabb9dae4mr5616607lft.25.1679238668353; Sun, 19 Mar 2023 08:11:08 -0700 (PDT) Received: from surface-pro-6.. ([2a00:1370:818c:4a57:577a:76f4:df43:5e66]) by smtp.gmail.com with ESMTPSA id m19-20020ac24253000000b004e90dee5469sm1274089lfl.157.2023.03.19.08.11.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Mar 2023 08:11:08 -0700 (PDT) From: Sergey Bugaev To: libc-alpha@sourceware.org, bug-hurd@gnu.org Cc: Samuel Thibault , Sergey Bugaev Subject: [RFC PATCH glibc 13/34] x86-64: Disable prefer_map_32bit_exec tunable on non-Linux Date: Sun, 19 Mar 2023 18:09:56 +0300 Message-Id: <20230319151017.531737-14-bugaevc@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230319151017.531737-1-bugaevc@gmail.com> References: <20230319151017.531737-1-bugaevc@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-11.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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 List-Id: While we could/should implement MAP_32BIT for the Hurd port by setting all the high bits of mask in a vm_map () call, neither MAP_32BIT nor glibc.cpu.prefer_map_32bit_exec exist on the Hurd as of now. Compile this code out to fix build failures. Signed-off-by: Sergey Bugaev --- sysdeps/x86/cpu-features.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sysdeps/x86/cpu-features.c b/sysdeps/x86/cpu-features.c index 822688e2..78631d7a 100644 --- a/sysdeps/x86/cpu-features.c +++ b/sysdeps/x86/cpu-features.c @@ -27,7 +27,7 @@ extern void TUNABLE_CALLBACK (set_hwcaps) (tunable_val_t *) attribute_hidden; -# ifdef __LP64__ +# if defined (__LP64__) && defined (__linux__) static void TUNABLE_CALLBACK (set_prefer_map_32bit_exec) (tunable_val_t *valp) { @@ -715,7 +715,7 @@ no_cpuid: #if HAVE_TUNABLES TUNABLE_GET (hwcaps, tunable_val_t *, TUNABLE_CALLBACK (set_hwcaps)); -# ifdef __LP64__ +# if defined (__LP64__) && defined (__linux__) TUNABLE_GET (prefer_map_32bit_exec, tunable_val_t *, TUNABLE_CALLBACK (set_prefer_map_32bit_exec)); # endif -- 2.39.2