John,
About verbosity of info messages, no I'm not proposing to have SC_REPORT_INFO call the report() method that takes verbosity argument. That would only serve half the purpose. Info messages reported w/o using the SC_REPORT_INFO macro would not have a verbosity, i.e. sc_report_handler::report(SC_INFO, "myid", "msg", __FILE__, __LINE__) would not get the info messages checked against verbosity.
What I'm proposing is that the existing sc_report_handler::report() method assign a default verbosity value of 200 to SC_INFO messages and check them against max verbosity, and SC_REPORT_INFO macro be left unchanged.
This will ensure the clean property:
- all SC_INFO messages have a verbosity value, either explicitly user assigned or an implicit default value
- all SC_INFO messages are checked against max verbosity
- is fully backward compatible
About, adding sc_core::sc_gen_report(), I agree with you that there isn't a big justification to add it at this time. This will become part of the extended module-sepcific verbosity discussion in the LWG.
About SC_IGNORE_VERBOSITY = 9999, I'm not sure I understand. What can users do with this? Define SC_MY_VERBOSITY = 700? How will he define it? By changing the header file?
-Bishnupriya
________________________________
From: john.aynsley@doulos.com [mailto:john.aynsley@doulos.com]
Sent: Wednesday, December 08, 2010 8:45 AM
To: Bishnupriya Bhattacharya; systemc-p1666-technical@eda.org
Subject: RE: Verbosity Control
Bishupriya,
See below:
Also, what do you think of adding sc_gen_report as proposed by Philipp? I see no reason to do so right now.
John A
-----Bishnupriya Bhattacharya <bpriya@cadence.com> wrote: -----
To: "john.aynsley@doulos.com" <john.aynsley@doulos.com>
From: Bishnupriya Bhattacharya <bpriya@cadence.com>
Date: 12/07/2010 05:41PM
Cc: Bishnupriya Bhattacharya <bpriya@cadence.com>
Subject: RE: Verbosity Control
John,
1) The enum SC_IGNORE_VERBOSITY = 9999 was proposed by Alan for the case where we have only one report() signature with an optional verbosity argument at the end. We are not going with that signature. Philip had also not liked this enum. So I don't think we need this enum.
[JA] SEE SEPARATE EMAIL TO ALAN
2) I agree on your point to not change the existing macros to supply verbosity argument - that can be misleading. However, I don't like that some SC_INFO messages are subject to verbosity check and some are not. This is not consistent. Its better - as per the original proposal - that the existing report() signature assigns a default verbosity value of 200 to the INFO messages and check these against max verbosity. Then all INFO messages have a verbosity property - either explicitly user assigned or an implicit default value, and all INFO messages are subject to verbosity check. This is nice and clean and fully backward compatible.
[JA] I'm not sure I understand. Are you saying change the definitions of the current SC_REPORT_INFO macro to call the overloaded sc_report_handler::report method with a verbosity, but leave SC_REPORT_WARNING/ERROR/FATAL unchanged? I would be fine with that.
3) About the new macro, I like adding SC_REPORT_INFO_VERB(msg_type, msg, verbosity).
Users will either do
sc_report_handler::report(SC_INFO, "myid", "mymsg", 500, __FILE__, __LINE__);
sc_report_handler::report(SC_WARNING, "myid", "msg", __FILE__, __LINE__);
or
SC_REPORT_INFO_VERB("myid", "mymsg", 500);
SC_REPORT_WARNING("myid", "msg");
[JA] Yes, this is how I understood it.
We should have this discussion on the reflector also.
Thanks,
-Bishnupriya
-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.Received on Tue Dec 7 21:04:51 2010
This archive was generated by hypermail 2.1.8 : Tue Dec 07 2010 - 21:04:53 PST