public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "gejoed at rediffmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug gcov-profile/100751] __gcov_dump and __gcov_reset usage Date: Thu, 27 May 2021 13:53:29 +0000 [thread overview] Message-ID: <bug-100751-4-cOe83AiEeK@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-100751-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100751 --- Comment #13 from Gejoe <gejoed at rediffmail dot com> --- I modified my sample-prog.c file just by adding a line of __gcov_reset before the while loop. However after a.out run , the sample-prog.c.gcov file was still showing the counters though I didn't give 'g' for __gcov_dump invocation. Quoting a portion from sample-prog.c.gcov file : #####: 9:int main() -: 10:{ -: 11: unsigned char c; -: 12: int result; #####: 13: unsigned char data[]={127,49,255,255}; #####: 14: c = '5'; -: 15: #####: 16: __gcov_reset(); <<<<<<<<Added here jin the original sample-prog.c file just to check the reset behaviour -: 17: do { -: 18: 4: 19: c = getchar(); 4: 20: result = isalnum(c); 4: 21: printf("When %c is passed, return value is %d\n", c, result); -: 22: 4: 23: if(c == 'g') 1: 24: __gcov_dump(); 3: 25: else if(c == 'r') #####: 26: __gcov_reset(); -: 27: 3: 28: }while(c != 'c'); I'm trying to now when would __gcov_reset help us in seeing the counter values reset to ##### instead of old data(numbers like 4,1,3, etc in .c.gcov file). Let me know if I miss any info.
next prev parent reply other threads:[~2021-05-27 13:53 UTC|newest] Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-05-25 6:54 [Bug gcov-profile/100751] New: " gejoed at rediffmail dot com 2021-05-25 6:58 ` [Bug gcov-profile/100751] " gejoed at rediffmail dot com 2021-05-25 7:01 ` gejoed at rediffmail dot com 2021-05-25 7:56 ` marxin at gcc dot gnu.org 2021-05-25 10:57 ` gejoed at rediffmail dot com 2021-05-25 12:14 ` gejoed at rediffmail dot com 2021-05-25 12:52 ` marxin at gcc dot gnu.org 2021-05-25 12:53 ` marxin at gcc dot gnu.org 2021-05-25 18:40 ` gejoed at rediffmail dot com 2021-05-26 7:31 ` marxin at gcc dot gnu.org 2021-05-26 7:34 ` cvs-commit at gcc dot gnu.org 2021-05-26 7:34 ` marxin at gcc dot gnu.org 2021-05-26 15:13 ` gejoed at rediffmail dot com 2021-05-27 13:53 ` gejoed at rediffmail dot com [this message] 2021-05-27 13:57 ` marxin at gcc dot gnu.org 2021-05-27 13:58 ` marxin at gcc dot gnu.org 2021-05-28 5:49 ` gejoed at rediffmail dot com 2021-05-28 6:15 ` gejoed at rediffmail dot com 2021-05-28 6:18 ` gejoed at rediffmail dot com 2021-05-28 6:22 ` gejoed at rediffmail dot com 2021-05-28 7:30 ` marxin at gcc dot gnu.org 2021-05-28 9:57 ` gejoed at rediffmail dot com 2021-05-28 11:38 ` cvs-commit at gcc dot gnu.org 2021-05-28 11:41 ` marxin at gcc dot gnu.org 2021-06-01 5:25 ` gejoed at rediffmail dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-100751-4-cOe83AiEeK@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).