From patchwork Thu Apr 19 11:51:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Szabolcs Nagy X-Patchwork-Id: 900798 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-91698-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="S0gCn0sZ"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40Rcm34MFgz9s1v for ; Thu, 19 Apr 2018 21:52:03 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:cc:to:from:subject:message-id:date :mime-version:content-type; q=dns; s=default; b=jXHTJclf3V3t7d2P ypkjTCSlRTGwS5vCOhmWpbN4H26XspMwQH4I+Z+oUkCuK4xUyLjwi2tsURItNJ85 /YopzIdoQ2zNqjharkiUN4geVTMUHN0rub3rUeM8TyU9MLbRxn2q3EMS6H783K8v MmUPvTECSPPMAlYoZJRC7fMACdY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:cc:to:from:subject:message-id:date :mime-version:content-type; s=default; bh=8gU3UfE549D2KoieOBU998 /H/qY=; b=S0gCn0sZKWGoQmyhgZmvlcQ3CQohqr30XX9UqLegkUlVZnHgFdC0/L K29ZsByvuO23YCN2ws/CAnaBFmZbXG2AG5vdQxhxM6ls88Gn3MYLcRwZollDnCt8 ouSvzaFSGVx33dQzEXvXoEqhknJ3RU1K15Mz0NQTTVJjWWEI4F3lQ= Received: (qmail 125613 invoked by alias); 19 Apr 2018 11:51:55 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 125603 invoked by uid 89); 19 Apr 2018 11:51:54 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_PASS autolearn=ham version=3.3.2 spammy=sk:szabolc, Szabolcs, U*szabolcs.nagy, szabolcs.nagy@arm.com X-HELO: EUR01-DB5-obe.outbound.protection.outlook.com Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Szabolcs.Nagy@arm.com; Cc: nd@arm.com To: GNU C Library From: Szabolcs Nagy Subject: aarch64: add HWCAP_ATOMICS to HWCAP_IMPORTANT Message-ID: <1d8eb765-e147-534e-ed1e-daa8deb8d5a7@arm.com> Date: Thu, 19 Apr 2018 12:51:46 +0100 User-Agent: Mozilla/5.0 (X11; Linux aarch64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 X-ClientProxiedBy: AM4PR0701CA0042.eurprd07.prod.outlook.com (2603:10a6:200:42::52) To VI1PR08MB3295.eurprd08.prod.outlook.com (2603:10a6:803:3e::12) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(48565401081)(2017052603328)(7153060)(49563074)(7193020); SRVR:VI1PR08MB3295; X-Microsoft-Exchange-Diagnostics: 1; VI1PR08MB3295; 3:WSQ5wvcTIC5jPeXtnntmSGe3LtZ+57RaCzOj1WZAnvyBHkqm2CW1l4OaZq+OxlOiDR1R9JAWCzDDxniOSXk89lwx2LsMTTLwgWg33cgIT02vcLUIi6lsinApAohacs8IURq/kSayICs88DL3HpphvvSYwwlUtDh31yvuZv4DKiEyOopD7SNDV4SHRA3EArn6gUKZ6mPf47i3LvyN7BYg8p9o4cYrS9it9lORTT1+nftDuaDy9iSRyOcm7xoHJryA; 25:UMhYA2n1SdoU/xXP7p5vlC9LPKDKL3/9wfGGbjf2L22jMpAiOju5922ybOJ/nPszY1dq1SxBTwsXKIrC4dD7/wTJOaYbdlNrUTmOXcYoE+s9TShb+P26cp5fKjd4qE4A11X1XVB1m0Drrq44w2KkpZm3u5hVM+yQ6oNEOXNhw+S5og3dGHkPq5paR9qvOb302ePPojY9FNbXKOJyRKcltwlXTtHg070N4ZAW9R6CpnhOz6t00tVG2brUOfDdskmRLciD6L++uwaPI2Jnqej99iyhAiWQu6VzH8ibwQRXbl7NTz1lny7mwCZhZBbYSRMf9YFQ2+6l/XPIy7T8GWdR4Q==; 31:sMB8yMdKqHQfudmpfM8V/7ilUXjWIA9VxYajH//GPkOXL9GNmzE4DpXwTMecn1aQu6lXrThGxu4Q2Ln2y6JAp3hhPIsnmIne/lKmWzWtxQwMp/M1eKZMBorVCkZOwwwZQiWg91M4J2mSdC1s8udlLqIb/U54fSJVyeVidhC6L3viNWp/2HHO+ecZRqyI72lCgv1mZo9EvVMIfDH7YxE1x+6Sk00SCabft8XF8LzQJyc= X-MS-TrafficTypeDiagnostic: VI1PR08MB3295: NoDisclaimer: True X-Microsoft-Exchange-Diagnostics: 1; VI1PR08MB3295; 20:UTbQeF/Vm9IbSxzVGZln7GbhxnnOT2L5ZcsKW+FyhJ4NSFnLju8lAKi/4NuDbuuxsdLoo9+dTRKKtbUZzCslPMwFl30CqNn4lPDYetAht63ccydbPbgkBtruULFhBFTLn9mpXnFr62FV6C54IrBytwK2R4/jJ8WtY2t7DOwWCtNYM1nAgk1s29BNQBkyn9ovQcU6rIU49v0UKg/ywCvG2Q7wvChpRzpOYRMZCalC5U60jJZQCo9Pt5p4M9j5BPKx; 4:LCXX2GoAvpQlQLRGPtSscTglmF/CdOZ7/S9r2QNSvv9R3k0n0OfZFkMKwo/yj0JIvNu26kJ6N4PFnESfwV1YXN243gEDYJjO/QQQ9Ty8j49tqsalBJ9T3/QNfGXMsC3gExmXEx6SHH0eJfaiIlIk7FCrQrAPzeCtUhRm+6EeqoNM+5TU8ok5T/EdhoTmspcVDd/Y7krWAXMuA939KL0GR5uOzKB+7pVGNDjC40mXS7EbbBEXkgi0k0zmFwo2xf8CoeUss3uZ457fgP1Hi8HgxfcXgdp7WjdDLGUm5/yNlGyB7ehCWT21sX7jgJSoXHRH X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(180628864354917); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(102415395)(6040522)(2401047)(8121501046)(5005006)(3231232)(944501327)(52105095)(3002001)(10201501046)(93006095)(93001095)(6055026)(6041310)(20161123564045)(20161123560045)(20161123558120)(201703131423095)(201703011903075)(201702281528075)(20161123555045)(201703061421075)(20161123562045)(6072148)(201708071742011); SRVR:VI1PR08MB3295; BCL:0; PCL:0; RULEID:; SRVR:VI1PR08MB3295; X-Forefront-PRVS: 0647963F84 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6049001)(7966004)(346002)(39380400002)(366004)(39860400002)(376002)(396003)(377424004)(52116002)(2476003)(36756003)(31686004)(65826007)(5660300001)(8936002)(8676002)(81166006)(6666003)(26005)(6916009)(305945005)(64126003)(31696002)(86362001)(568964002)(7736002)(65806001)(65956001)(270700001)(6116002)(3846002)(66066001)(16526019)(77096007)(476003)(58126008)(316002)(956004)(16576012)(16586007)(6486002)(21490400003)(25786009)(2906002)(5890100001)(2616005)(37036004)(4326008)(4610100001)(5000100001)(508600001)(53936002)(386003)(84326002)(59450400001)(33964004)(44832011)(72206003); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR08MB3295; H:[10.2.206.57]; FPR:; SPF:None; LANG:en; MLV:nov; PTR:InfoNoRecords; Received-SPF: None (protection.outlook.com: arm.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: 1; VI1PR08MB3295; 23:AAmSTatOTgc45+nh/ZJXCdxPH4eLrlM6h/OplIDlFroHLA9TWgN40W2uEaoOxSjc9JmNF29yoC3lnuTmptqyaNIXsmZVnTWBfZ1eCPcTlopg7SqVcxjgA7HJKVLCdHXlzp/WLLS60y0bWs0jybueLujFShdeTr8dqG7rjVtrLdvMc2rXKZZp5pNeQiAwcEStMVyTsQ8OEXFxunpz7VENz4m1ZOlqRNsM/iRRF3ZG7uJKx+cbykRcKt8lDUZB6YASaGSFyWw/kRrpFqQTQLV2Ha3ktlSC8XxoMM6uUF+NJ4OgZ4wBBd6p36cSyMqr9B2aU2k18kSEELLohfuG4AvdYkABjGrRtEoelalLASJgXnT5bKmP1TO+23Hs2VpGI1cOQXvFWtiSP8hqj2tVjfdjwzu5N98OWoC0MImHui0CpDR9X//+9IQXb4je1RV3edbp13oVgebdS9MlOvfCPWF+XFZLlKjg8fwlvPxN9tykVO887+rzo2AEkZcPxYScpduIv+qU1YAU9ownqzAuDVe03DO7JmhuCDhr6ri4KgTlaY2x/6PgOIv6pC96mvqp3iFXWW4roStkKjbDYEHSYlVWdCxzWcLn99bNq3OsywKPLt4VTn52/VkxzeBr6npbRbkFgwJt8JEM8dDe1Y3WWivikk6XGWZhm89v4FXY+/fNOjZ0xedrtfUzJz2IDUykMab0ejHSO1DXYN5QRNx6xZtG3KA7xpKpLfq64tTkEXVqfRNtmYl9GUuX9tLGwuPQgh4RGqdAYtImTzg81qoacZuTt9Wbf/YlOGI3RaVZeHCn3CdanG/nZHAgPnhM5f7s/mWc+y3FdsggqyQf00uWM3I8ZTgeJ/flxV0Ny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GChepz7Exonbtcnf3HGYP7vwqDNtDgVh4rE3tI+7mmgcdwm2PtaRF2JhsW/bYThfcFsiiY2ymdJtMhA9dP/FZ5hYKgDevFWzz2IiXcH98GHQ/VZoJVXr59KltGSmjzN6aJZf/UxpJRZDXqMAF+yVU1wGJpxB5jzYseji07I7MXhkKqHtZjX0qA==; 5:eP+OfI8l34IveVOT4mVmABc9inTZIHRv2UQmMu3zCM/pFRwqjuaYuCvNucaJvR0e+duJeZEhY0OQNcu/64DgcumDWsUNKK41xFmdbGbG9i1sI/wlTysajvTQOhe2/WpGBCnLKFt4jEYJLsloJJ0PJekQGcK9TRpOBho63DUmiLc=; 24:frLrcIW/anmhhXIqHgiq7N84+GFsQoFS4GuYVp2/NecexdXkBoK9ZvCUmrIa9u1VcVseqVHosVqQHum28Qrl9rZi1Yy9e8SbD3tHDfxXDsc= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; VI1PR08MB3295; 7:qwo/RTP7cUtQxZ4YzjxFmfb+nVALwG2a3bJumxYKGMF/S7/I3rfD8pA93JUc/vvhOwr6wFgYpwoLyHleRjD9WqgkVp5rBcuKrgKqHup1ruE6smupVGrcVkrv7Uh1qPvFiErdaTYUVqXdBCF0eZEXa5Z/KLxz6EIRmAMyK5bKaa31Jj/hfBdsiBYx4W+DXWHJqDWZHkA0Xvheg+BwzFGiBz34UGvagihDkgUzvNp2HjQudcFiyJQAlj6AcTVI2Vne X-MS-Office365-Filtering-Correlation-Id: 12f73ea2-f8ec-45c0-42eb-08d5a5ebef56 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Apr 2018 11:51:49.2223 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 12f73ea2-f8ec-45c0-42eb-08d5a5ebef56 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR08MB3295 This enables searching shared libraries in atomics/ when the hardware supports LSE atomics of armv8.1 so one can provide optimized variants of libraries in a portable way. LSE atomics does not affect library abi, the new instructions can interoperate with old ones. I'm not familiar with how this feature of the dynamic linker is used in practice by distros or others so comments are welcome. 2018-04-19 Szabolcs Nagy * sysdeps/unix/sysv/linux/aarch64/dl-procinfo.h (HWCAP_IMPORTANT): Add HWCAP_ATOMICS. diff --git a/sysdeps/unix/sysv/linux/aarch64/dl-procinfo.h b/sysdeps/unix/sysv/linux/aarch64/dl-procinfo.h index 6887713149..4530cc2159 100644 --- a/sysdeps/unix/sysv/linux/aarch64/dl-procinfo.h +++ b/sysdeps/unix/sysv/linux/aarch64/dl-procinfo.h @@ -27,9 +27,9 @@ /* We cannot provide a general printing function. */ #define _dl_procinfo(type, word) -1 -/* HWCAP_CPUID should be available by default to influence IFUNC as well as - library search. */ -#define HWCAP_IMPORTANT HWCAP_CPUID +/* Default hwcap_mask setting, affects the library search path and cpu_features + used by glibc internal IFUNCs when the selected hwcaps are available. */ +#define HWCAP_IMPORTANT (HWCAP_CPUID | HWCAP_ATOMICS) static inline const char * __attribute__ ((unused))