SystemC  2.3.2
Accellera SystemC proof-of-concept library
sc_kernel_ids.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3  Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
4  more contributor license agreements. See the NOTICE file distributed
5  with this work for additional information regarding copyright ownership.
6  Accellera licenses this file to you under the Apache License, Version 2.0
7  (the "License"); you may not use this file except in compliance with the
8  License. You may obtain a copy of the License at
9 
10  http://www.apache.org/licenses/LICENSE-2.0
11 
12  Unless required by applicable law or agreed to in writing, software
13  distributed under the License is distributed on an "AS IS" BASIS,
14  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
15  implied. See the License for the specific language governing
16  permissions and limitations under the License.
17 
18  *****************************************************************************/
19 
20 /*****************************************************************************
21 
22  sc_kernel_ids.h -- Report ids for the kernel code.
23 */
33 #ifndef SC_KERNEL_IDS_H
34 #define SC_KERNEL_IDS_H
35 
36 
37 #include "sysc/utils/sc_report.h"
38 
39 
46 #ifndef SC_DEFINE_MESSAGE
47 
48 #define SC_DEFINE_MESSAGE(id,unused1,unused2) \
49  namespace sc_core { extern SC_API const char id[]; }
50 namespace sc_core {
51  extern SC_API const char SC_ID_REGISTER_ID_FAILED_[]; // in sc_report_handler.cpp
52 }
53 #endif
54 
55 SC_DEFINE_MESSAGE(SC_ID_NO_BOOL_RETURNED_ , 500,
56  "operator does not return boolean")
57 SC_DEFINE_MESSAGE(SC_ID_NO_INT_RETURNED_ , 501,
58  "operator does not return int")
59 SC_DEFINE_MESSAGE(SC_ID_NO_SC_LOGIC_RETURNED_ , 502,
60  "operator does not return sc_logic")
61 SC_DEFINE_MESSAGE(SC_ID_OPERAND_NOT_SC_LOGIC_ , 503,
62  "operand is not sc_logic")
63 SC_DEFINE_MESSAGE(SC_ID_OPERAND_NOT_BOOL_ , 504,
64  "operand is not bool")
65 SC_DEFINE_MESSAGE(SC_ID_INSTANCE_EXISTS_ , 505,
66  "object already exists")
67 SC_DEFINE_MESSAGE(SC_ID_ILLEGAL_CHARACTERS_ , 506,
68  "illegal characters" )
69 SC_DEFINE_MESSAGE(SC_ID_VC6_PROCESS_HELPER_ , 507,
70  "internal error: sc_vc6_process_helper" )
71 SC_DEFINE_MESSAGE(SC_ID_VC6_MAX_PROCESSES_EXCEEDED_ , 508,
72  "maximum number of processes per module exceeded (VC6)" )
73 SC_DEFINE_MESSAGE(SC_ID_END_MODULE_NOT_CALLED_ , 509,
74  "module construction not properly completed: did "
75  "you forget to add a sc_module_name parameter to "
76  "your module constructor?" )
77 SC_DEFINE_MESSAGE(SC_ID_HIER_NAME_INCORRECT_ , 510,
78  "hierarchical name as shown may be incorrect due to previous errors" )
79 SC_DEFINE_MESSAGE(SC_ID_SET_STACK_SIZE_ , 511,
80  "set_stack_size() is only allowed for SC_THREADs and SC_CTHREADs" )
81 SC_DEFINE_MESSAGE(SC_ID_SC_MODULE_NAME_USE_ , 512,
82  "incorrect use of sc_module_name" )
83 SC_DEFINE_MESSAGE(SC_ID_SC_MODULE_NAME_REQUIRED_ , 513,
84  "an sc_module_name parameter for your constructor is required" )
85 SC_DEFINE_MESSAGE(SC_ID_SET_TIME_RESOLUTION_ , 514,
86  "set time resolution failed" )
87 SC_DEFINE_MESSAGE(SC_ID_SET_DEFAULT_TIME_UNIT_ , 515,
88  "set default time unit failed" )
89 SC_DEFINE_MESSAGE(SC_ID_DEFAULT_TIME_UNIT_CHANGED_ , 516,
90  "default time unit changed to time resolution" )
91 SC_DEFINE_MESSAGE(SC_ID_INCONSISTENT_API_CONFIG_ , 517,
92  "inconsistent library configuration detected" )
93 // available message number 518
94 SC_DEFINE_MESSAGE(SC_ID_WAIT_NOT_ALLOWED_ , 519,
95  "wait() is only allowed in SC_THREADs and SC_CTHREADs" )
96 SC_DEFINE_MESSAGE(SC_ID_NEXT_TRIGGER_NOT_ALLOWED_ , 520,
97  "next_trigger() is only allowed in SC_METHODs" )
98 SC_DEFINE_MESSAGE(SC_ID_IMMEDIATE_NOTIFICATION_ , 521,
99  "immediate notification is not allowed during update phase or elaboration" )
100 SC_DEFINE_MESSAGE(SC_ID_HALT_NOT_ALLOWED_ , 522,
101  "halt() is only allowed in SC_CTHREADs" )
102 SC_DEFINE_MESSAGE(SC_ID_WATCHING_NOT_ALLOWED_ , 523,
103  "watching() has been deprecated, use reset_signal_is()" )
104 SC_DEFINE_MESSAGE(SC_ID_DONT_INITIALIZE_ , 524,
105  "dont_initialize() has no effect for SC_CTHREADs" )
106 SC_DEFINE_MESSAGE(SC_ID_WAIT_N_INVALID_ , 525,
107  "wait(n) is only valid for n > 0" )
108 SC_DEFINE_MESSAGE(SC_ID_MAKE_SENSITIVE_ , 526,
109  "make sensitive failed" )
110 SC_DEFINE_MESSAGE(SC_ID_MAKE_SENSITIVE_POS_ , 527,
111  "make sensitive pos failed" )
112 SC_DEFINE_MESSAGE(SC_ID_MAKE_SENSITIVE_NEG_ , 528,
113  "make sensitive neg failed" )
114 SC_DEFINE_MESSAGE(SC_ID_INSERT_MODULE_ , 529,
115  "insert module failed" )
116 SC_DEFINE_MESSAGE(SC_ID_REMOVE_MODULE_ , 530,
117  "remove module failed" )
118 SC_DEFINE_MESSAGE(SC_ID_NOTIFY_DELAYED_ , 531,
119  "notify_delayed() cannot be called on events "
120  "that have pending notifications" )
121 SC_DEFINE_MESSAGE(SC_ID_GEN_UNIQUE_NAME_ , 532,
122  "cannot generate unique name from null string" )
123 SC_DEFINE_MESSAGE(SC_ID_MODULE_NAME_STACK_EMPTY_ , 533,
124  "module name stack is empty: did you forget to "
125  "add a sc_module_name parameter to your module "
126  "constructor?" )
127 SC_DEFINE_MESSAGE(SC_ID_NAME_EXISTS_ , 534,
128  "name already exists")
129 // available message number 535
130 SC_DEFINE_MESSAGE( SC_ID_IMMEDIATE_SELF_NOTIFICATION_, 536,
131  "immediate self-notification ignored as of IEEE 1666-2011" )
132 SC_DEFINE_MESSAGE( SC_ID_WAIT_DURING_UNWINDING_ , 537,
133  "wait() not allowed during unwinding" )
134 SC_DEFINE_MESSAGE(SC_ID_CYCLE_MISSES_EVENTS_ , 538,
135  "the simulation contains timed-events but they are "
136  "ignored by sc_cycle() ==> the simulation will be "
137  "incorrect" )
138 SC_DEFINE_MESSAGE( SC_ID_RETHROW_UNWINDING_ , 539,
139  "sc_unwind_exception not re-thrown during kill/reset" )
140 SC_DEFINE_MESSAGE( SC_ID_PROCESS_ALREADY_UNWINDING_ , 540,
141  "kill/reset ignored during unwinding" )
142 SC_DEFINE_MESSAGE(SC_ID_MODULE_METHOD_AFTER_START_ , 541,
143  "call to SC_METHOD in sc_module while simulation running" )
144 SC_DEFINE_MESSAGE(SC_ID_MODULE_THREAD_AFTER_START_ , 542,
145  "call to SC_THREAD in sc_module while simulation running" )
146 SC_DEFINE_MESSAGE(SC_ID_MODULE_CTHREAD_AFTER_START_ , 543,
147  "call to SC_CTHREAD in sc_module while simulation running" )
148 SC_DEFINE_MESSAGE(SC_ID_SIMULATION_TIME_OVERFLOW_ , 544,
149  "simulation time value overflow, simulation aborted" )
150 SC_DEFINE_MESSAGE(SC_ID_SIMULATION_STOP_CALLED_TWICE_ , 545,
151  "sc_stop has already been called" )
152 SC_DEFINE_MESSAGE(SC_ID_SIMULATION_START_AFTER_STOP_ , 546,
153  "sc_start called after sc_stop has been called" )
154 SC_DEFINE_MESSAGE(SC_ID_STOP_MODE_AFTER_START_ , 547,
155  "attempt to set sc_stop mode after start will be ignored" )
156 SC_DEFINE_MESSAGE( SC_ID_SIMULATION_START_AFTER_ERROR_, 548,
157  "attempt to restart simulation after error" )
158 SC_DEFINE_MESSAGE( SC_ID_SIMULATION_UNCAUGHT_EXCEPTION_, 549,
159  "uncaught exception" )
160 SC_DEFINE_MESSAGE(SC_ID_PHASE_CALLBACKS_UNSUPPORTED_ , 550,
161  "simulation phase callbacks not enabled")
162 SC_DEFINE_MESSAGE(SC_ID_PHASE_CALLBACK_NOT_IMPLEMENTED_, 551,
163  "empty simulation phase callback called" )
164 SC_DEFINE_MESSAGE(SC_ID_PHASE_CALLBACK_REGISTER_, 552,
165  "register simulation phase callback" )
166 SC_DEFINE_MESSAGE(SC_ID_PHASE_CALLBACK_FORBIDDEN_, 553,
167  "forbidden action in simulation phase callback" )
168 SC_DEFINE_MESSAGE( SC_ID_SIMULATION_START_UNEXPECTED_, 554,
169  "sc_start called unexpectedly" )
170 // available message number 555
171 SC_DEFINE_MESSAGE(SC_ID_THROW_IT_IGNORED_ , 556,
172  "throw_it on method/non-running process is being ignored " )
173 SC_DEFINE_MESSAGE(SC_ID_NOT_EXPECTING_DYNAMIC_EVENT_NOTIFY_ , 557,
174  "dynamic event notification encountered when sensitivity is static" )
175 SC_DEFINE_MESSAGE(SC_ID_DISABLE_WILL_ORPHAN_PROCESS_ , 558,
176  "disable() or dont_initialize() called on process with no static sensitivity, it will be orphaned" )
177 SC_DEFINE_MESSAGE(SC_ID_PROCESS_CONTROL_CORNER_CASE_ , 559,
178  "Undefined process control interaction" )
179 SC_DEFINE_MESSAGE(SC_ID_METHOD_TERMINATION_EVENT_ , 560,
180  "Attempt to get terminated event for a method process" )
181 SC_DEFINE_MESSAGE(SC_ID_JOIN_ON_METHOD_HANDLE_ , 561,
182  "Attempt to register method process with sc_join object" )
183 SC_DEFINE_MESSAGE(SC_ID_NO_PROCESS_SEMANTICS_ , 563,
184  "Attempt to invoke process with no semantics() method" )
185 SC_DEFINE_MESSAGE(SC_ID_EVENT_ON_NULL_PROCESS_ , 564,
186  "Attempt to get an event for non-existent process" )
187 SC_DEFINE_MESSAGE(SC_ID_EVENT_LIST_FAILED_, 565,
188  "invalid use of sc_(and|or)_event_list" )
189 SC_DEFINE_MESSAGE(SC_ID_UNKNOWN_PROCESS_TYPE_, 566,
190  "Unknown process type" )
191 SC_DEFINE_MESSAGE(SC_ID_TIME_CONVERSION_FAILED_, 567,
192  "sc_time conversion failed")
193 // available number 568
194 SC_DEFINE_MESSAGE(SC_ID_BAD_SC_MODULE_CONSTRUCTOR_ , 569,
195  "sc_module(const char*), sc_module(const std::string&) "
196  "have been deprecated, use sc_module(const sc_module_name&)" )
197 SC_DEFINE_MESSAGE(SC_ID_EMPTY_PROCESS_HANDLE_ , 570,
198  "attempt to use an empty process handle ignored" )
199 SC_DEFINE_MESSAGE(SC_ID_NO_SC_START_ACTIVITY_ , 571,
200  "no activity or clock movement for sc_start() invocation" )
201 SC_DEFINE_MESSAGE(SC_ID_KILL_PROCESS_WHILE_UNITIALIZED_ , 572,
202  "a process may not be killed before it is initialized" )
203 SC_DEFINE_MESSAGE(SC_ID_RESET_PROCESS_WHILE_NOT_RUNNING_ , 573,
204  "a process may not be asynchronously reset while the simulation is not running" )
205 SC_DEFINE_MESSAGE(SC_ID_THROW_IT_WHILE_NOT_RUNNING_ , 574,
206  "throw_it not allowed unless simulation is running " )
207 
208 
209 /*****************************************************************************
210 
211  MODIFICATION LOG - modifiers, enter your name, affiliation, date and
212  changes you are making here.
213 
214  Name, Affiliation, Date:
215  Description of Modification:
216 
217  *****************************************************************************/
218 
219 // $Log: sc_kernel_ids.h,v $
220 // Revision 1.25 2011/08/26 22:06:34 acg
221 // Torsten Maehne: formating fix.
222 //
223 // Revision 1.24 2011/08/07 19:08:04 acg
224 // Andy Goodrich: moved logs to end of file so line number synching works
225 // better between versions.
226 //
227 // Revision 1.23 2011/07/24 11:15:47 acg
228 // Philipp A. Hartmann: Improvements to error/warning messages related to
229 // process control.
230 //
231 // Revision 1.22 2011/05/09 04:07:48 acg
232 // Philipp A. Hartmann:
233 // (1) Restore hierarchy in all phase callbacks.
234 // (2) Ensure calls to before_end_of_elaboration.
235 //
236 // Revision 1.21 2011/04/19 19:15:41 acg
237 // Andy Goodrich: fix so warning message is always issued for a throw_it()
238 // on a method process.
239 //
240 // Revision 1.20 2011/04/19 15:04:27 acg
241 // Philipp A. Hartmann: clean up SC_ID messages.
242 //
243 // Revision 1.19 2011/04/19 02:39:09 acg
244 // Philipp A. Hartmann: added checks for additional throws during stack unwinds.
245 //
246 // Revision 1.18 2011/04/05 06:23:45 acg
247 // Andy Goodrich: comments for throws while the simulator is not running.
248 //
249 // Revision 1.17 2011/04/01 22:30:39 acg
250 // Andy Goodrich: change hard assertion to warning for trigger_dynamic()
251 // getting called when there is only STATIC sensitivity. This can result
252 // because of sc_process_handle::throw_it().
253 //
254 // Revision 1.16 2011/03/28 13:02:51 acg
255 // Andy Goodrich: Changes for disable() interactions.
256 //
257 // Revision 1.15 2011/03/07 17:34:21 acg
258 // Andy Goodrich: changed process control corner case message. Added more
259 // place holders for unused message numbers.
260 //
261 // Revision 1.14 2011/03/06 19:57:11 acg
262 // Andy Goodrich: refinements for the illegal suspend - synchronous reset
263 // interaction.
264 //
265 // Revision 1.13 2011/03/06 15:56:29 acg
266 // Andy Goodrich: added process control corner case error message, remove
267 // unused messages.
268 //
269 // Revision 1.12 2011/03/05 19:44:20 acg
270 // Andy Goodrich: changes for object and event naming and structures.
271 //
272 // Revision 1.11 2011/02/18 20:27:14 acg
273 // Andy Goodrich: Updated Copyrights.
274 //
275 // Revision 1.10 2011/02/13 21:47:37 acg
276 // Andy Goodrich: update copyright notice.
277 //
278 // Revision 1.9 2011/02/13 21:29:16 acg
279 // Andy Goodrich: added error messages for throws that occur before
280 // simulator intialization.
281 //
282 // Revision 1.8 2011/02/11 13:25:24 acg
283 // Andy Goodrich: Philipp A. Hartmann's changes:
284 // (1) Removal of SC_CTHREAD method overloads.
285 // (2) New exception processing code.
286 //
287 // Revision 1.7 2011/02/07 19:17:20 acg
288 // Andy Goodrich: changes for IEEE 1666 compatibility.
289 //
290 // Revision 1.6 2011/01/19 23:21:50 acg
291 // Andy Goodrich: changes for IEEE 1666 2011
292 //
293 // Revision 1.5 2010/07/30 05:21:22 acg
294 // Andy Goodrich: release 2.3 fixes.
295 //
296 // Revision 1.4 2009/02/28 00:26:58 acg
297 // Andy Goodrich: changed boost name space to sc_boost to allow use with
298 // full boost library applications.
299 //
300 // Revision 1.3 2008/11/17 15:57:15 acg
301 // Andy Goodrich: added deprecation message for sc_module(const char*)
302 //
303 // Revision 1.2 2008/05/22 17:06:25 acg
304 // Andy Goodrich: updated copyright notice to include 2008.
305 //
306 // Revision 1.1.1.1 2006/12/15 20:20:05 acg
307 // SystemC 2.3
308 //
309 // Revision 1.7 2006/08/29 23:37:13 acg
310 // Andy Goodrich: Added check for negative time.
311 //
312 // Revision 1.6 2006/04/20 17:08:16 acg
313 // Andy Goodrich: 3.0 style process changes.
314 //
315 // Revision 1.5 2006/01/25 00:31:19 acg
316 // Andy Goodrich: Changed over to use a standard message id of
317 // SC_ID_IEEE_1666_DEPRECATION for all deprecation messages.
318 //
319 // Revision 1.4 2006/01/24 20:49:04 acg
320 // Andy Goodrich: changes to remove the use of deprecated features within the
321 // simulator, and to issue warning messages when deprecated features are used.
322 //
323 // Revision 1.3 2006/01/13 18:44:29 acg
324 // Added $Log to record CVS changes into the source.
325 //
326 
327 #endif
328 
329 // Taf!
operand is not sc_logic object already exists internal maximum number of processes per module exceeded(VC6)" ) SC_DEFINE_MESSAGE(SC_ID_END_MODULE_NOT_CALLED_
operand is not sc_logic object already exists internal maximum number of processes per module module construction not properly completed
Definition: sc_kernel_ids.h:73
operand is not sc_logic object already exists internal maximum number of processes per module module construction not properly hierarchical name as shown may be incorrect due to previous errors incorrect use of sc_module_name set time resolution failed default time unit changed to time resolution immediate notification is not allowed during update phase or elaboration use reset_signal_is()" ) SC_DEFINE_MESSAGE(SC_ID_DONT_INITIALIZE_
SC_API void next_trigger(sc_simcontext *)
void SC_API halt(sc_simcontext *)
void neg(sc_fxval &c, const sc_fxnum &a)
Definition: sc_fxnum.h:2690
SC_API void sc_start()
sc_clock period is zero sc_clock low time is zero sc_fifo< T > cannot have more than one writer bind interface to port failed complete binding failed remove port failed insert primitive channel failed sc_signal< T > cannot have more than one driver resolved port not bound to resolved signal sc_semaphore requires an initial value
operand is not sc_logic object already exists internal error
Definition: sc_kernel_ids.h:69
#define SC_DEFINE_MESSAGE(id, unused1, unused2)
Definition: sc_kernel_ids.h:48
class SC_API sc_module
Definition: sc_object.h:48
SC_API const char SC_ID_REGISTER_ID_FAILED_[]
Definition: sc_bit_ids.h:77
#define SC_THREAD(func)
Definition: sc_module.h:471
SC_API void sc_stop()
STL namespace.
operand is not sc_logic object already exists internal maximum number of processes per module module construction not properly hierarchical name as shown may be incorrect due to previous errors incorrect use of sc_module_name set time resolution failed default time unit changed to time resolution immediate notification is not allowed during update phase or elaboration watching() has been deprecated
Run-time logging and reporting facilities.
operand is not sc_logic object already exists internal maximum number of processes per module module construction not properly hierarchical name as shown may be incorrect due to previous errors incorrect use of sc_module_name set time resolution failed default time unit changed to time resolution immediate notification is not allowed during update phase or elaboration use dont_initialize() has no effect for SC_CTHREADs" ) SC_DEFINE_MESSAGE(SC_ID_WAIT_N_INVALID_
#define SC_METHOD(func)
Definition: sc_module.h:464
#define SC_CTHREAD(func, edge)
Definition: sc_module.h:456
#define SC_API
Definition: sc_cmnhdr.h:168
void SC_API wait(int, sc_simcontext *)