public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* line coverage problem with gcov
@ 2014-08-07 21:11 Ciro Ceissler
  0 siblings, 0 replies; only message in thread
From: Ciro Ceissler @ 2014-08-07 21:11 UTC (permalink / raw)
  To: gcc-help

Hello,

I trying to do coverage using gcov and can't reach 100% for line
coverage, for example:

#####:  32: SC_MODULE(test) {
        -:   33:        sc_in<bool> clk;
        -:   34:        sc_in<bool> arst_n;
        -:   35:
        -:   36:        void func1 ();
        -:   37:        void func2 ();
        -:   38:
      18:  39:        SC_CTOR(test)  {
      18:  40:                SC_CTHREAD(func1, clk.pos())
      18:  41:                async_reset_signal_is(arst_n, false);
        -:   42:
      18:  43:                SC_CTHREAD(func2, clk.pos());
      18:  44:                async_reset_signal_is(arst_n, false);
        -:   45:
        -:   46:        } // end of SC_CTOR
        -:   47: }; // end of SC_MODULE

From other project, I have another behavior (just put a stub from
module), here above:

      18:  32: SC_MODULE(test2) {
        -:   33:        sc_in<bool> clk;
        -:   34:        sc_in<bool> arst_n;
        -:   35:
      18:   36:        void func1 ();
      18:   37:        void func2 ();
        -:   38:
      18:  39:        SC_CTOR(test2)  {
      18:  40:                SC_CTHREAD(func1, clk.pos())
      18:  41:                async_reset_signal_is(arst_n, false);
        -:   42:
      18:  43:                SC_CTHREAD(func2, clk.pos());
      18:  44:                async_reset_signal_is(arst_n, false);
        -:   45:
        -:   46:        } // end of SC_CTOR
        -:   47: }; // end of SC_MODULE

I don't understand why SC_MODULE wasn't covered from the first
example, but SC_CTOR was.

Can anyone tell me why this happen or could suggest another tool for coverage?

Thanks,

-- 
Ciro Ceissler

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-08-07 21:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-07 21:11 line coverage problem with gcov Ciro Ceissler

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).