From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by sourceware.org (Postfix) with ESMTPS id CA0733858D37 for ; Fri, 22 Apr 2022 17:31:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org CA0733858D37 Received: by mail-wm1-x334.google.com with SMTP id v64-20020a1cac43000000b0038cfd1b3a6dso8401837wme.5 for ; Fri, 22 Apr 2022 10:31:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=y8faE5M1Wh/3tJ39YHIoANN9WQBgmZkJrtE86d3MOKA=; b=aL2fUxUKso8cBDCfCxcQ1QywNUqBEOs3QZAQ4T/JoADxQaZ2yAsaylwaPODhkj8gsc /HWA+czKn9jiiVmQ51yYdMb7PVgzLTkyfsZzlGp3Bp9km+kDVEKoG3PBG28uvwxLtXHN 4oX6OE2AE6Tp1rS0P3wXynPYD3DyeQdmKgbBrN7BR/lga7Y3yA43rdk3VStYgqq+dvSg jCoisA/7oxEV8uuEKioedgiaSQwPGoE1/cxhGZNkMoiVA3d2Dq7XOWakg0T/c2SX990P wy5sJ4vshwsLQs+vYw6rMVOSv2vSEJXMdKeGnk6FNgwt15jNIOsvfODa/n0aIs9tyVXg gRZA== X-Gm-Message-State: AOAM531kM4LNvLKzfgutl6yyt+/lWbZFoFSC3Pma1Hq9YrxcEnhPpcbe wiX9pMFGIGS0BBLMhrwZVR1pfM3tcET15G53iCg= X-Google-Smtp-Source: ABdhPJyF348Ryiz2o3hu56+q/9q1PJtvp4n0KkIYED7MXcYYgN8b2+D+Oq9Ih1AG97ZwyUtFpEcQ4BKkwsEOUUdN4oQ= X-Received: by 2002:a05:600c:4f53:b0:392:e99:3002 with SMTP id m19-20020a05600c4f5300b003920e993002mr5169577wmq.35.1650648683600; Fri, 22 Apr 2022 10:31:23 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Jonathan Wakely Date: Fri, 22 Apr 2022 18:31:12 +0100 Message-ID: Subject: Re: Do not perform tests that are not supported by the CPU. To: sajcho Cc: gcc-help Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-help@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-help mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Apr 2022 17:31:28 -0000 On Fri, 22 Apr 2022 at 16:34, sajcho via Gcc-help wr= ote: > > On 22-04-22 15:32:07, Jonathan Wakely wrote: > > On Fri, 22 Apr 2022 at 14:18, sajcho via Gcc-help wrote: > > > > > > Hi. > > > > > > lscpu output: > > > > > > Architecture: aarch64 > > > CPU op-mode(s): 32-bit, 64-bit > > > Byte Order: Little Endian > > > CPU(s): 6 > > > On-line CPU(s) list: 0,3-5 > > > Off-line CPU(s) list: 1,2 > > > Vendor ID: ARM > > > Model name: Cortex-A57 > > > Model: 3 > > > Thread(s) per core: 1 > > > Core(s) per cluster: 4 > > > Socket(s): - > > > Cluster(s): 1 > > > Stepping: r1p3 > > > CPU max MHz: 2035,2000 > > > CPU min MHz: 960,0000 > > > BogoMIPS: 62.50 > > > Flags: fp asimd evtstrm aes pmull sha1 sha2 crc32 c= puid > > > Caches (sum of all): > > > L1d: 128 KiB (4 instances) > > > L1i: 192 KiB (4 instances) > > > L2: 2 MiB (1 instance) > > > NUMA: > > > NUMA node(s): 1 > > > NUMA node0 CPU(s): 0,3-5 > > > Vulnerabilities: > > > Itlb multihit: Not affected > > > L1tf: Not affected > > > Mds: Not affected > > > Meltdown: Mitigation; PTI > > > Spec store bypass: Not affected > > > Spectre v1: Mitigation; __user pointer sanitization > > > Spectre v2: Mitigation; Branch predictor hardening, BHB > > > Srbds: Not affected > > > Tsx async abort: Not affected > > > > > > ../configure --prefix=3D/usr --libexecdir=3D/usr/lib --enable-languag= es=3Dc,c++,fortran,lto --enable-threads=3Dposix --enable-__cxa_atexit --ena= ble-default-pie --enable-default-ssp --enable-linker-build-id --enable-init= fini-array --enable-link-serialization=3D1 --enable-gnu-indirect-function -= -enable-plugin --disable-nls --disable-multilib --disable-sjlj-exceptions -= -disable-libunwind-exceptions --disable-libquadmath-support --disable-libqu= admath --with-system-zlib --with-linker-hash-style=3Dgnu --with-build-confi= g=3Dbootstrap-lto --with-pkgversion=3DSAUX-Aarch64 --build=3Daarch64-unknow= n-linux-gnu --host=3Daarch64-unknown-linux-gnu > > > > > > make profiledbootstrap > > > > > > This is where my question begins. > > > Is there any easy way to avoid tests (sve, sve2, aapcs ....) that are= not supported by this cpu? > > > > In theory you shouldn't need to do anything. Tests that use those > > features should be restricted to only run when the CPU supports them, > > via https://gcc.gnu.org/onlinedocs/gccint/Effective-Target-Keywords.htm= l#AArch64-specific-attributes > > > > In practice, some tests might not use the correct keywords to ensure > > that happens. > > > > Have you tried it? > > > > He didn't try. I'm confused. > > These attributes are specified in lib/target-supports.exp. > I don't know how to use them. > > I don't think my knowledge is sufficient. You don't use them, the GCC tests use them to say things like "this test requires sve hardware", which causes the testsuite framework to skip those tests if the hardware support is absent.