From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id 03A10385842D for ; Fri, 27 Aug 2021 08:35:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 03A10385842D Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz Received: from imap1.suse-dmz.suse.de (imap1.suse-dmz.suse.de [192.168.254.73]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id E06BE1FECA; Fri, 27 Aug 2021 08:35:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1630053345; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=U1dLUQ5KsCVrv6Rsb7ByHTUTUcxCojYxTzbyLBl5nhU=; b=vcNTXaRgxNER+fFMlReViduvOc8gee9rTvaJxqz84Uiuvs4tnjDxfJtqzm2iZChpkhh0if 8zCS3JEfKWBQeAI4A7gdegXE0l91N0Xvdc4zLeaCQif7+7PB7kWw93gPvx+2uq1faoWpHQ TGH3RwzCTIU5ty9YDI6MowOlbIOGmnA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1630053345; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=U1dLUQ5KsCVrv6Rsb7ByHTUTUcxCojYxTzbyLBl5nhU=; b=ZU7LvzGhyZ8MV4x0zJaQVVemUTBctDlI8g7bVhROIMbP2qfBsYB9alUgjwkheTDi8agsGJ +cueE2q4SPo8NbAQ== Received: from imap1.suse-dmz.suse.de (imap1.suse-dmz.suse.de [192.168.254.73]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap1.suse-dmz.suse.de (Postfix) with ESMTPS id BF69213689; Fri, 27 Aug 2021 08:35:45 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap1.suse-dmz.suse.de with ESMTPSA id cjCwLeGjKGGwHQAAGKfGzw (envelope-from ); Fri, 27 Aug 2021 08:35:45 +0000 Message-ID: Date: Fri, 27 Aug 2021 10:35:45 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.0.1 Subject: Re: [PATCH] Optimize macro: make it more predictable Content-Language: en-US From: =?UTF-8?Q?Martin_Li=c5=a1ka?= To: Richard Biener Cc: Jakub Jelinek , Michael Matz , GCC Patches References: <82e71ebf-7b2e-67e7-1f08-ea525deee4cb@suse.cz> <1dfa7226-3056-d215-4626-01126d428891@suse.cz> <88fde73d-d36a-2010-5837-30f2943d9dad@suse.cz> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, NICE_REPLY_A, 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-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Aug 2021 08:35:57 -0000 On 8/26/21 14:39, Martin Liška wrote: > I can investigate that. So there are statistics about #pragma GCC optimize and optimize attribute in openSUSE:Factory. The numbers at the line beginning represent number of functions affected by the pragma or attribute. Are we smarter in what we want? Processed 14026 packages, attr/pragma used in 111 --- Mesa-drivers.log --- 1x: "O1" --- Mesa.log --- 1x: "O1" --- PrusaSlicer.log --- 44x: "-fno-unsafe-math-optimizations" --- SVT-AV1.log --- 2x: "unroll-loops" --- abseil-cpp.log --- 4x: "no-optimize-sibling-calls" --- analitza.log --- 1x: "-fno-unsafe-math-optimizations" --- argon2.log --- 2x: "O0" --- arpack-ng:serial.log --- 2x: "-fno-unsafe-math-optimizations" --- avogadrolibs.log --- 106x: "-fno-unsafe-math-optimizations" --- caddy.log --- 32x: "no-tree-vectorize" --- calligra.log --- 1x: "-fno-unsafe-math-optimizations" --- ceph-test.log --- 2x: "no-tree-vectorize" --- ceph.log --- 2x: "no-tree-vectorize" --- ceres-solver.log --- 130x: "-fno-unsafe-math-optimizations" --- cmake:mini.log --- 1x: "no-tree-vectorize" --- cpustat.log --- 15x: "-O3" --- cross-aarch64-gcc11-bootstrap.log --- 32x: "no-omit-frame-pointer" --- cross-amdgcn-gcc11.log --- 12x: "O2" 10x: "-fno-tree-loop-distribute-patterns" 1x: "-fno-tree-loop-distribute-patterns""-fno-tree-loop-distribute-patterns" --- cross-nvptx-gcc11.log --- 6x: "-fno-tree-loop-distribute-patterns" 2x: "O2" --- csound.log --- 6x: "no-finite-math-only" 1x: "-fno-unsafe-math-optimizations" --- darktable.log --- 65213x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "tree-loop-vectorize", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "no-math-errno" 4981x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math" 1021x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "fp-contract=fast", "tree-vectorize" 1018x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unsw itch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "tree-vectorize" 1011x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "tree-vectorize", "no-math-errno" 315x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math" 71x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "no-math-errno" 54x: "finite-math-only" 13x: "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswitch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math", "unroll-loops", "tree-loop-if-convert", "tree-loop-distribution", "no-strict-aliasing", "loop-interchange", "loop-nest-optimize", "tree-loop-im", "unswit ch-loops", "tree-loop-ivcanon", "ira-loop-pressure", "split-ivs-in-unroller", "variable-expansion-in-unroller", "split-loops", "ivopts", "predictive-commoning", "tree-loop-linear", "loop-block", "loop-strip-mine", "finite-math-only", "fp-contract=fast", "fast-math" 5x: "fast-math", "fp-contract=fast" --- eigen3:docs.log --- 378x: "-fno-unsafe-math-optimizations" --- eventstat.log --- 2x: "-O3" --- frr.log --- 3x: "3" --- fwts.log --- 4x: "-O0" --- fwupd.log --- 1x: "0" --- gcc11-testresults.log --- 4151x: "no-isolate-erroneous-paths-dereference" 12x: "O2" 8x: "-fno-optimize-sibling-calls" 3x: ATTR="no-isolate-erroneous-paths-dereference""no-isolate-erroneous-paths-dereference" 2x: ATTR="no-isolate-erroneous-paths-dereference" 1x: "no-isolate-erroneous-paths-dereference"ATTR= --- gcc11.log --- 5572x: "no-isolate-erroneous-paths-dereference" 16x: "O2" 8x: "-fno-optimize-sibling-calls" --- ghc-cryptonite.log --- 3x: "O0" --- glibc.log --- 308x: "-fno-stack-protector" 1x: "-fno-stack-protector"../sysdeps/x86_64/multiarch/memcpy.c:29:1: note: XXX:optimize attribute: 1x: ATTR="-fno-stack-protector" 1x: ATTR="-fno-stack-protector""-fno-stack-protector" --- glibc:testsuite.log --- 318x: "-fno-stack-protector" --- glibc:utils.log --- 216x: "-fno-stack-protector" 1x: "-fno-stack-protector"ATTR= --- icinga2.log --- 5x: "O0" --- java-16-openjdk.log --- 24167x: "O0" --- keepalived.log --- 1x: "O0" --- kstars.log --- 187x: "-fno-unsafe-math-optimizations" --- lammps.log --- 6x: "no-var-tracking-assignments" --- lastpass-cli.log --- 1x: "unroll-loops" --- libgcrypt.log --- 28x: "O0" --- libkeccak.log --- 378x: "-O0" --- libopenshot-audio.log --- 7x: "no-associative-math" --- libqt5-qtbase.log --- 1x: "omit-frame-pointer" 1x: "no-tree-vectorize" --- libraw.log --- 12x: "no-aggressive-loop-optimizations" --- libretro-beetle-psx-hw.log --- 10217x: "unroll-loops" 56x: "unroll-loops", "unroll-loops" --- libretro-beetle-psx.log --- 11428x: "unroll-loops" 56x: "unroll-loops", "unroll-loops" --- libretro-beetle-saturn.log --- 132x: "no-crossjumping,no-gcse" 39x: "Os" 1x: "no-unroll-loops,no-peel-loops,no-crossjumping" 1x: "O2,no-unroll-loops,no-peel-loops,no-crossjumping" --- libsemigroups.log --- 3x: "-fno-unsafe-math-optimizations" --- libunwind.log --- 4x: "-O1" --- libxtrx.log --- 5x: "O3" --- libxtrxdsp.log --- 2x: "unroll-loops" --- links.log --- 464942x: "-ftree-vectorize", "-ffast-math" --- mariadb.log --- 2x: "-O0" --- memtest86+.log --- 1x: "O0" --- mercurial.log --- 19x: "no-tree-vectorize" --- monitoring-plugins.log --- 11x: "wrapv" --- mono-core.log --- 3x: "O0" --- movit.log --- 41x: "-fno-unsafe-math-optimizations" --- mvapich2:gnu-hpc-testsuite.log --- 1x: "O0" --- mvapich2:gnu-hpc.log --- 1x: "O0" --- mvapich2:standard.log --- 1x: "O0" --- mvapich2:testsuite.log --- 1x: "O0" --- mysql-connector-cpp.log --- 36x: "no-tree-vectorize" --- newlib:epiphany.log --- 3x: "-fno-tree-loop-distribute-patterns" --- newlib:riscv64.log --- 5x: "-fno-tree-loop-distribute-patterns" --- o2scl.log --- 92x: "-fno-unsafe-math-optimizations" --- ocaml.log --- 8x: "tree-vectorize" --- openbabel.log --- 14x: "-fno-unsafe-math-optimizations" --- openucx.log --- 220x: "O0" --- pdns.log --- 6x: "no-associative-math" --- perl-Cpanel-JSON-XS.log --- 1x: "O0" --- perl-Sereal-Decoder.log --- 2x: "no-tree-vectorize" --- perl-Sereal-Encoder.log --- 2x: "no-tree-vectorize" --- php7.log --- 67x: "Os" --- php7:apache2.log --- 67x: "Os" --- php7:embed.log --- 67x: "Os" --- php7:fastcgi.log --- 67x: "Os" --- php7:fpm.log --- 67x: "Os" --- php8.log --- 75x: "Os" --- php8:apache2.log --- 75x: "Os" --- php8:embed.log --- 75x: "Os" --- php8:fastcgi.log --- 75x: "Os" --- php8:fpm.log --- 74x: "Os" --- picom.log --- 27x: "-fno-fast-math" --- python-Bottleneck.log --- 25x: "O3" --- python-grpcio.log --- 12x: "no-optimize-sibling-calls" --- python-numpy.log --- 9715x: "O3" 48x: "unroll-loops" --- python-numpy:gnu-hpc.log --- 9709x: "O3" 48x: "unroll-loops" --- python-pyroomacoustics.log --- 2x: "-fno-unsafe-math-optimizations" --- python-scipy:gnu-hpc.log --- 6179x: "tree-vectorize", "unsafe-math-optimizations", "unroll-loops" 1006x: "unroll-loops" 1x: "unroll-loops"gcc: scipy/special/cephes/rgamma.c --- python-scipy:standard.log --- 6179x: "tree-vectorize", "unsafe-math-optimizations", "unroll-loops" 1005x: "unroll-loops" 1x: "unroll-loops"gcc: scipy/special/cephes/tandg.c 1x: ATTR="unroll-loops" --- python-thewalrus.log --- 2x: "-fno-unsafe-math-optimizations" --- python-torch:standard.log --- 230x: "-fno-unsafe-math-optimizations" --- python-zstandard.log --- 12x: "no-tree-vectorize" --- python3-espressomd.log --- 2x: "no-associative-math" --- qt6-base.log --- 1x: "omit-frame-pointer" 1x: "no-tree-vectorize" --- rspamd.log --- 22x: "unroll-loops" 2x: "no-tree-vectorize" --- sha3sum.log --- 120x: "-O0" --- shim.log --- 4x: "0" --- snd.log --- 223x: "tree-vectorize" --- step.log --- 49x: "-fno-unsafe-math-optimizations" --- stress-ng.log --- 1070x: "-O3" 7x: "-O0" 2x: "-O1" --- subversion.log --- 184x: "-O0" --- sympol.log --- 2x: "-fno-unsafe-math-optimizations" --- tensorflow2:lite.log --- 80x: "-fno-unsafe-math-optimizations" --- texlive.log --- 1x: "fast-math" --- votca-csg.log --- 93x: "-fno-unsafe-math-optimizations" --- votca-tools.log --- 60x: "-fno-unsafe-math-optimizations" --- votca-xtp.log --- 215x: "-fno-unsafe-math-optimizations" --- xf86-video-intel.log --- 625x: "Ofast" 15x: "Ofast", "Ofast" --- xmrig.log --- 1x: "O0" --- zstd.log --- 6x: "no-tree-vectorize"