From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8FD743858C2C; Tue, 4 Jan 2022 09:46:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8FD743858C2C From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug gcov-profile/103666] [11/12 Regression] compiling single-file programs with -fprofile-generate no longer leads to intended results since r11-627-g1dedc12d186a1108 Date: Tue, 04 Jan 2022 09:46:25 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: gcov-profile X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: diagnostic, missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: WONTFIX X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.3 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status resolution short_desc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2022 09:46:25 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D103666 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |WONTFIX Summary|[11/12 Regression] |[11/12 Regression] |compiling single-file |compiling single-file |preprocessed programs with |programs with |-fprofile-generate no |-fprofile-generate no |longer leads to intended |longer leads to intended |results since |results since |r11-627-g1dedc12d186a1108 |r11-627-g1dedc12d186a1108 --- Comment #2 from Richard Biener --- that's because the explicitely named linker output in the -fprofile-use cas= e.=20 A fix might be to separate compile and link step. I don't think there's anything special about using preprocessed source: > cat t.c int main(){} > ./xgcc -B. t.c -fprofile-generate > ./a.out=20 > ./xgcc -B. t.c -fprofile-use -o a.out-use t.c: In function 'main': t.c:1:1: warning: '/tmp/obj/gcc/a.out-use-t.gcda' profile count data file n= ot found [-Wmissing-profile] 1 | int main(){} | ^~~ > ls *.gcda a-t.gcda I'd declare this as WONTFIX. I've adjusted the C++ tester for tramp3d to u= se an explicit -dumpbase=