sc_report_handler.cc revision 12921:51212996643f
1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright 9 * notice, this list of conditions and the following disclaimer in the 10 * documentation and/or other materials provided with the distribution; 11 * neither the name of the copyright holders nor the names of its 12 * contributors may be used to endorse or promote products derived from 13 * this software without specific prior written permission. 14 * 15 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 16 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 17 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 18 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 19 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 21 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 * 27 * Authors: Gabe Black 28 */ 29 30#include "base/logging.hh" 31#include "systemc/ext/utils/sc_report_handler.hh" 32 33namespace sc_core 34{ 35 36void 37sc_report_handler::report(sc_severity, const char *msg_type, const char *msg, 38 const char *file, int line) 39{ 40 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 41} 42 43void 44sc_report_handler::report(sc_severity, const char *msg_type, const char *msg, 45 int verbosity, const char *file, int line) 46{ 47 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 48} 49 50void 51sc_report_handler::report(sc_severity, int id, const char *msg, 52 const char *file, int line) 53{ 54 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 55} 56 57sc_actions 58sc_report_handler::set_actions(sc_severity, sc_actions) 59{ 60 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 61 return SC_UNSPECIFIED; 62} 63 64sc_actions 65sc_report_handler::set_actions(const char *msg_type, sc_actions) 66{ 67 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 68 return SC_UNSPECIFIED; 69} 70 71sc_actions 72sc_report_handler::set_actions(const char *msg_type, sc_severity, sc_actions) 73{ 74 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 75 return SC_UNSPECIFIED; 76} 77 78int 79sc_report_handler::stop_after(sc_severity, int limit) 80{ 81 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 82 return 0; 83} 84 85int 86sc_report_handler::stop_after(const char *msg_type, int limit) 87{ 88 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 89 return 0; 90} 91 92int 93sc_report_handler::stop_after(const char *msg_type, sc_severity, sc_actions) 94{ 95 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 96 return 0; 97} 98 99int 100sc_report_handler::get_count(sc_severity) 101{ 102 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 103 return 0; 104} 105 106int 107sc_report_handler::get_count(const char *msg_type) 108{ 109 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 110 return 0; 111} 112 113int 114sc_report_handler::get_count(const char *msg_type, sc_severity) 115{ 116 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 117 return 0; 118} 119 120int 121sc_report_handler::set_verbosity_level(int) 122{ 123 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 124 return 0; 125} 126 127int 128sc_report_handler::get_verbosity_level() 129{ 130 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 131 return 0; 132} 133 134 135sc_actions 136sc_report_handler::suppress(sc_actions) 137{ 138 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 139 return SC_UNSPECIFIED; 140} 141 142sc_actions 143sc_report_handler::suppress() 144{ 145 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 146 return SC_UNSPECIFIED; 147} 148 149sc_actions 150sc_report_handler::force(sc_actions) 151{ 152 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 153 return SC_UNSPECIFIED; 154} 155 156sc_actions 157sc_report_handler::force() 158{ 159 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 160 return SC_UNSPECIFIED; 161} 162 163 164sc_actions 165sc_report_handler::set_catch_actions(sc_actions) 166{ 167 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 168 return SC_UNSPECIFIED; 169} 170 171sc_actions 172sc_report_handler::get_catch_actions() 173{ 174 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 175 return SC_UNSPECIFIED; 176} 177 178 179void 180sc_report_handler::set_handler(sc_report_handler_proc) 181{ 182 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 183} 184 185void 186sc_report_handler::default_handler(const sc_report &, const sc_actions &) 187{ 188 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 189} 190 191sc_actions 192sc_report_handler::get_new_action_id() 193{ 194 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 195 return SC_UNSPECIFIED; 196} 197 198sc_report * 199sc_report_handler::get_cached_report() 200{ 201 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 202 return nullptr; 203} 204 205void 206sc_report_handler::clear_cached_report() 207{ 208 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 209} 210 211bool 212sc_report_handler::set_log_file_name(const char *) 213{ 214 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 215 return false; 216} 217 218const char * 219sc_report_handler::get_log_file_name() 220{ 221 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 222 return nullptr; 223} 224 225void 226sc_interrupt_here(const char *msg_type, sc_severity) 227{ 228 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 229} 230 231void 232sc_stop_here(const char *msg_type, sc_severity) 233{ 234 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 235} 236 237const std::string 238sc_report_compose_message(const sc_report &) 239{ 240 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 241 return ""; 242} 243 244bool 245sc_report_close_default_log() 246{ 247 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 248 return false; 249} 250 251} // namespace sc_core 252