summaryrefslogtreecommitdiff
path: root/ext/systemc/src/sysc/utils/sc_report_handler.cpp
blob: 0de71a18b6f14aa40d891e0a7ce4b78070f00b88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
/*****************************************************************************

  Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
  more contributor license agreements.  See the NOTICE file distributed
  with this work for additional information regarding copyright ownership.
  Accellera licenses this file to you under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with the
  License.  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
  implied.  See the License for the specific language governing
  permissions and limitations under the License.

 *****************************************************************************/

/*****************************************************************************

  sc_report_handler.cpp - 

  Original Author: Alex Riesen, Synopsys, Inc.
  see also sc_report.cpp

  CHANGE LOG AT END OF FILE
 *****************************************************************************/

#include <cstdio>
#include <stdlib.h>
#include <string.h>

#include "sysc/utils/sc_iostream.h"
#include "sysc/kernel/sc_process.h"
#include "sysc/kernel/sc_simcontext_int.h"
#include "sysc/utils/sc_stop_here.h"
#include "sysc/utils/sc_report_handler.h"
#include "sysc/utils/sc_report.h"

namespace std {}

namespace sc_core {

int sc_report_handler::verbosity_level = SC_MEDIUM;

// not documented, but available
const std::string sc_report_compose_message(const sc_report& rep)
{
    static const char * severity_names[] = {
	"Info", "Warning", "Error", "Fatal"
    };
    std::string str;

    str += severity_names[rep.get_severity()];
    str += ": ";

    if ( rep.get_id() >= 0 ) // backward compatibility with 2.0+
    {
	char idstr[64];
	std::sprintf(idstr, "(%c%d) ",
		"IWEF"[rep.get_severity()], rep.get_id());
	str += idstr;
    }
    str += rep.get_msg_type();

    if( *rep.get_msg() )
    {
	str += ": ";
	str += rep.get_msg();
    }
    if( rep.get_severity() > SC_INFO )
    {
        char line_number_str[16];
	str += "\nIn file: ";
	str += rep.get_file_name();
	str += ":";
	std::sprintf(line_number_str, "%d", rep.get_line_number());
	str += line_number_str;
	sc_simcontext* simc = sc_get_curr_simcontext();

	if( simc && sc_is_running() )
	{
	    const char* proc_name = rep.get_process_name();

	    if( proc_name )
	    {
		str += "\nIn process: ";
		str += proc_name;
		str += " @ ";
		str += rep.get_time().to_string();
	    }
	}
    }

    return str;
}
bool sc_report_close_default_log();

static ::std::ofstream* log_stream = 0;
static
struct auto_close_log
{
    ~auto_close_log()
    {
	sc_report_close_default_log();
    }
} auto_close;

const char* sc_report::get_process_name() const
{
	return process ? process->name() : 0;
}


//
// The official handler of the exception reporting
//

void sc_report_handler::default_handler(const sc_report& rep,
					const sc_actions& actions)
{
    if ( actions & SC_DISPLAY )
	::std::cout << ::std::endl << sc_report_compose_message(rep) << 
		::std::endl;

    if ( (actions & SC_LOG) && get_log_file_name() )
    {
	if ( !log_stream )
	    log_stream = new ::std::ofstream(get_log_file_name()); // ios::trunc

	*log_stream << rep.get_time() << ": "
	    << sc_report_compose_message(rep) << ::std::endl;
    }
    if ( actions & SC_STOP )
    {
	sc_stop_here(rep.get_msg_type(), rep.get_severity());
	sc_stop();
    }
    if ( actions & SC_INTERRUPT )
	sc_interrupt_here(rep.get_msg_type(), rep.get_severity());

    if ( actions & SC_ABORT )
	abort();

    if ( actions & SC_THROW ) {
        sc_process_b* proc_p = sc_get_current_process_b();
        if( proc_p && proc_p->is_unwinding() )
            proc_p->clear_unwinding();
        throw rep; 
    }
}

// not documented, but available
bool sc_report_close_default_log()
{
    delete log_stream;
    sc_report_handler::set_log_file_name(NULL);

    if ( !log_stream )
	return false;

    log_stream = 0;
    return true;
}

int sc_report_handler::get_count(sc_severity severity_) 
{ 
   return sev_call_count[severity_]; 
} 

int sc_report_handler::get_count(const char* msg_type_) 
{ 
    sc_msg_def * md = mdlookup(msg_type_); 

    if ( !md ) 
        md = add_msg_type(msg_type_); 

    return md->call_count; 
} 

int sc_report_handler::get_count(const char* msg_type_, sc_severity severity_) 
{ 
    sc_msg_def * md = mdlookup(msg_type_); 

    if ( !md ) 
        md = add_msg_type(msg_type_); 

    return md->sev_call_count[severity_]; 
} 


//
// CLASS: sc_report_handler
// implementation
//

sc_msg_def * sc_report_handler::mdlookup(const char * msg_type_)
{
    if( !msg_type_ ) // if msg_type is NULL, report unknown error
        msg_type_ = SC_ID_UNKNOWN_ERROR_;

    for ( msg_def_items * item = messages; item; item = item->next )
    {
	for ( int i = 0; i < item->count; ++i )
	    if ( !strcmp(msg_type_, item->md[i].msg_type) )
		return item->md + i;
    }
    return 0;
}

// The calculation of actions to be executed
sc_actions sc_report_handler::execute(sc_msg_def* md, sc_severity severity_)
{
    sc_actions actions = md->sev_actions[severity_]; // high prio

    if ( SC_UNSPECIFIED == actions ) // middle prio
	actions = md->actions;

    if ( SC_UNSPECIFIED == actions ) // the lowest prio
	actions = sev_actions[severity_];

    actions &= ~suppress_mask; // higher than the high prio
    actions |= force_mask; // higher than above, and the limit is the highest

    unsigned * limit = 0;
    unsigned * call_count = 0;

    // just increment counters and check for overflow
    if ( md->sev_call_count[severity_] < UINT_MAX )
	md->sev_call_count[severity_]++;
    if ( md->call_count < UINT_MAX )
	md->call_count++;
    if ( sev_call_count[severity_] < UINT_MAX )
	sev_call_count[severity_]++;

    if ( md->limit_mask & (1 << (severity_ + 1)) )
    {
	limit = md->sev_limit + severity_;
	call_count = md->sev_call_count + severity_;
    }
    if ( !limit && (md->limit_mask & 1) )
    {
	limit = &md->limit;
	call_count = &md->call_count;
    }
    if ( !limit )
    {
	limit = sev_limit + severity_;
	call_count = sev_call_count + severity_;
    }
    if ( *limit == 0 )
    {
	// stop limit disabled
    }
    else if ( *limit != UINT_MAX )
    {
	if ( *call_count >= *limit )
	    actions |= SC_STOP; // force sc_stop()
    }
    return actions;
}

void sc_report_handler::report( sc_severity severity_, 
                                const char* msg_type_, 
				const char* msg_, 
				int verbosity_, 
				const char* file_, 
				int line_ )
{
    sc_msg_def * md = mdlookup(msg_type_);

    // If the severity of the report is SC_INFO and the specified verbosity 
    // level is greater than the maximum verbosity level of the simulator then 
    // return without any action.

    if ( (severity_ == SC_INFO) && (verbosity_ > verbosity_level) ) return;

    // Process the report:

    if ( !md )
	md = add_msg_type(msg_type_);

    sc_actions actions = execute(md, severity_);
    sc_report rep(severity_, md, msg_, file_, line_, verbosity_);

    if ( actions & SC_CACHE_REPORT )
	cache_report(rep);

    handler(rep, actions);
}

void sc_report_handler::report(sc_severity severity_,
			       const char * msg_type_,
			       const char * msg_,
			       const char * file_,
			       int line_)
{
    sc_msg_def * md = mdlookup(msg_type_);

    // If the severity of the report is SC_INFO and the maximum verbosity
    // level is less than SC_MEDIUM return without any action.

    if ( (severity_ == SC_INFO) && (SC_MEDIUM > verbosity_level) ) return;

    // Process the report:


    if ( !md )
	md = add_msg_type(msg_type_);

    sc_actions actions = execute(md, severity_);
    sc_report rep(severity_, md, msg_, file_, line_);

    if ( actions & SC_CACHE_REPORT )
	cache_report(rep);

    handler(rep, actions);
}

// The following method is never called by the simulator.

void sc_report_handler::initialize()
{
#if 0 // actually, i do not know whether we have to reset these.
    suppress();
    force();
    set_actions(SC_INFO,    SC_DEFAULT_INFO_ACTIONS);
    set_actions(SC_WARNING, SC_DEFAULT_WARNING_ACTIONS);
    set_actions(SC_ERROR,   SC_DEFAULT_ERROR_ACTIONS);
    set_actions(SC_FATAL,   SC_DEFAULT_FATAL_ACTIONS);
#endif

    sev_call_count[SC_INFO]    = 0;
    sev_call_count[SC_WARNING] = 0;
    sev_call_count[SC_ERROR]   = 0;
    sev_call_count[SC_FATAL]   = 0;

    msg_def_items * items = messages;

    while ( items != &msg_terminator )
    {
	for ( int i = 0; i < items->count; ++i )
	{
	    items->md[i].call_count = 0;
	    items->md[i].sev_call_count[SC_INFO]    = 0;
	    items->md[i].sev_call_count[SC_WARNING] = 0;
	    items->md[i].sev_call_count[SC_ERROR]   = 0;
	    items->md[i].sev_call_count[SC_FATAL]   = 0;
	}
	items = items->next;
    }

    // PROCESS ANY ENVIRONMENTAL OVERRIDES:

    const char* deprecation_warn = std::getenv("SC_DEPRECATION_WARNINGS");
    if ( (deprecation_warn!=0) && !strcmp(deprecation_warn,"DISABLE") )
    {
        set_actions("/IEEE_Std_1666/deprecated", SC_DO_NOTHING);
    }
}

// free the sc_msg_def's allocated by add_msg_type
// (or implicit msg_type registration: set_actions, abort_after)
// clear last_global_report.
void sc_report_handler::release()
{
    delete last_global_report;
    last_global_report = 0;
    sc_report_close_default_log();

    msg_def_items * items = messages, * newitems = &msg_terminator;
    messages = &msg_terminator;

    while ( items != &msg_terminator )
    {
	for ( int i = 0; i < items->count; ++i )
	    if ( items->md[i].msg_type == items->md[i].msg_type_data )
		free(items->md[i].msg_type_data);

	msg_def_items * prev = items;
	items = items->next;

	if ( prev->allocated )
	{
	    delete [] prev->md;
	    delete prev;
	}
	else
	{
	    prev->next = newitems;
	    newitems = prev;
	}
    }
    messages = newitems;
}

sc_msg_def * sc_report_handler::add_msg_type(const char * msg_type_)
{
    sc_msg_def * md = mdlookup(msg_type_);
    int          msg_type_len;

    if ( md )
	return md;

    msg_def_items * items = new msg_def_items;

    if ( !items )
	return 0;

    items->count = 1;
    items->md = new sc_msg_def[items->count];

    if ( !items->md )
    {
	delete items;
	return 0;
    }
    memset(items->md, 0, sizeof(sc_msg_def) * items->count);
    msg_type_len = strlen(msg_type_);
    if ( msg_type_len > 0 )
    {
	items->md->msg_type_data = (char*) malloc(msg_type_len+1);
	strcpy( items->md->msg_type_data, msg_type_ );
	items->md->id = -1; // backward compatibility with 2.0+
    }
    else
    {
	delete items->md;
	delete items;
	return 0;
    }
    items->md->msg_type = items->md->msg_type_data;
    add_static_msg_types(items);
    items->allocated = true;

    return items->md;
}

void sc_report_handler::add_static_msg_types(msg_def_items * items)
{
    items->allocated = false;
    items->next = messages;
    messages = items;
}

sc_actions sc_report_handler::set_actions(sc_severity severity_,
					  sc_actions actions_)
{
    sc_actions old = sev_actions[severity_];
    sev_actions[severity_] = actions_;
    return old;
}

sc_actions sc_report_handler::set_actions(const char * msg_type_,
					  sc_actions actions_)
{
    sc_msg_def * md = mdlookup(msg_type_);

    if ( !md )
	md = add_msg_type(msg_type_);

    sc_actions old = md->actions;
    md->actions = actions_;

    return old;
}

sc_actions sc_report_handler::set_actions(const char * msg_type_,
					  sc_severity severity_,
					  sc_actions actions_)
{
    sc_msg_def * md = mdlookup(msg_type_);

    if ( !md )
	md = add_msg_type(msg_type_);

    sc_actions old = md->sev_actions[severity_];
    md->sev_actions[severity_] = actions_;

    return old;
}

int sc_report_handler::stop_after(sc_severity severity_, int limit)
{
    int old = sev_limit[severity_];

    sev_limit[severity_] = limit < 0 ? UINT_MAX: (unsigned) limit;

    return old;
}

int sc_report_handler::stop_after(const char * msg_type_, int limit)
{
    sc_msg_def * md = mdlookup(msg_type_);

    if ( !md )
	md = add_msg_type(msg_type_);

    int old = md->limit_mask & 1 ? md->limit: UINT_MAX;

    if ( limit < 0 )
	md->limit_mask &= ~1;
    else
    {
	md->limit_mask |= 1;
	md->limit = limit;
    }
    return old;
}

int sc_report_handler::stop_after(const char * msg_type_,
				  sc_severity severity_,
				  int limit)
{
    sc_msg_def * md = mdlookup(msg_type_);

    if ( !md )
	md = add_msg_type(msg_type_);

    int mask = 1 << (severity_ + 1);
    int old = md->limit_mask & mask ?  md->sev_limit[severity_]: UINT_MAX;

    if ( limit < 0 )
	md->limit_mask &= ~mask;
    else
    {
	md->limit_mask |= mask;
	md->sev_limit[severity_] = limit;
    }
    return old;
}

sc_actions sc_report_handler::suppress(sc_actions mask)
{
    sc_actions old = suppress_mask;
    suppress_mask = mask;
    return old;
}

sc_actions sc_report_handler::suppress()
{
    return suppress(0);
}

sc_actions sc_report_handler::force(sc_actions mask)
{
    sc_actions old = force_mask;
    force_mask = mask;
    return old;
}

sc_actions sc_report_handler::force()
{
    return force(0);
}

sc_report_handler_proc
sc_report_handler::set_handler(sc_report_handler_proc handler_)
{
    sc_report_handler_proc old = handler;
    handler = handler_ ? handler_: &sc_report_handler::default_handler;
    return old;
}

sc_report_handler_proc
sc_report_handler::get_handler()
{
    return handler;
}

sc_report* sc_report_handler::get_cached_report()
{
    sc_process_b * proc = sc_get_current_process_b();

    if ( proc )
	return proc->get_last_report();

    return last_global_report;
}

void sc_report_handler::clear_cached_report()
{
    sc_process_b * proc = sc_get_current_process_b();

    if ( proc )
	proc->set_last_report(0);
    else
    {
	delete last_global_report;
	last_global_report = 0;
    }
}

sc_actions sc_report_handler::get_new_action_id()
{
    for ( sc_actions p = 1; p; p <<= 1 )
    {
	if ( !(p & available_actions) ) // free
	{
	    available_actions |= p;
	    return p;
	}
    }
    return SC_UNSPECIFIED;
}

bool sc_report_handler::set_log_file_name(const char* name_)
{
    if ( !name_ )
    {
	free(log_file_name);
	log_file_name = 0;
	return false;
    }
    if ( log_file_name )
	return false;

    log_file_name = (char*)malloc(strlen(name_)+1);
    strcpy(log_file_name, name_);
    return true;
}

const char * sc_report_handler::get_log_file_name()
{
    return log_file_name;
}

void sc_report_handler::cache_report(const sc_report& rep)
{
    sc_process_b * proc = sc_get_current_process_b();
    if ( proc )
	proc->set_last_report(new sc_report(rep));
    else
    {
	delete last_global_report;
	last_global_report = new sc_report(rep);
    }
}

//
// backward compatibility with 2.0+
//

sc_msg_def * sc_report_handler::mdlookup(int id)
{
    for ( msg_def_items * item = messages; item; item = item->next )
    {
	for ( int i = 0; i < item->count; ++i )
	    if ( id == item->md[i].id )
		return item->md + i;
    }
    return 0;
}

int sc_report_handler::get_verbosity_level() { return verbosity_level; }

int sc_report_handler::set_verbosity_level( int level )
{
    int result = verbosity_level;
    verbosity_level = level;
    return result;
}

//
// CLASS: sc_report_handler
// static variables
//

sc_actions sc_report_handler::suppress_mask = 0;
sc_actions sc_report_handler::force_mask = 0;

sc_actions sc_report_handler::sev_actions[SC_MAX_SEVERITY] =
{
    /* info  */ SC_DEFAULT_INFO_ACTIONS,
    /* warn  */ SC_DEFAULT_WARNING_ACTIONS,
    /* error */ SC_DEFAULT_ERROR_ACTIONS,
    /* fatal */ SC_DEFAULT_FATAL_ACTIONS
};

// Note that SC_FATAL has a limit of 1 by default

sc_actions sc_report_handler::sev_limit[SC_MAX_SEVERITY] =
{
    UINT_MAX, UINT_MAX, UINT_MAX, UINT_MAX
};
sc_actions sc_report_handler::sev_call_count[SC_MAX_SEVERITY] = { 0, 0, 0, 0 };

sc_report* sc_report_handler::last_global_report = NULL;
sc_actions sc_report_handler::available_actions =
    SC_DO_NOTHING |
    SC_THROW |
    SC_LOG |
    SC_DISPLAY |
    SC_CACHE_REPORT |
    SC_INTERRUPT |
    SC_STOP |
    SC_ABORT;

sc_report_handler_proc sc_report_handler::handler =
    &sc_report_handler::default_handler;

char * sc_report_handler::log_file_name = 0;

sc_report_handler::msg_def_items * sc_report_handler::messages =
    &sc_report_handler::msg_terminator;


//
// predefined messages
//

const char SC_ID_REGISTER_ID_FAILED_[] = "register_id failed";
const char SC_ID_UNKNOWN_ERROR_[]      = "unknown error";
const char SC_ID_WITHOUT_MESSAGE_[]    = "";
const char SC_ID_NOT_IMPLEMENTED_[]    = "not implemented";
const char SC_ID_INTERNAL_ERROR_[]     = "internal error";
const char SC_ID_ASSERTION_FAILED_[]   = "assertion failed";
const char SC_ID_OUT_OF_BOUNDS_[]      = "out of bounds";

#define DEFINE_MSG(id,n)                                                     \
    {                                                                        \
	(id),                                                                \
	0u, {0u}, /* actions */                                              \
	0u, {0u}, 0u, /* limits */                                           \
	0u, {0u}, NULL, /* call counters */                                  \
	n                                                                    \
    }

static sc_msg_def default_msgs[] = {
    DEFINE_MSG(SC_ID_REGISTER_ID_FAILED_, 800),
    DEFINE_MSG(SC_ID_UNKNOWN_ERROR_, 0),
    DEFINE_MSG(SC_ID_WITHOUT_MESSAGE_, 1),
    DEFINE_MSG(SC_ID_NOT_IMPLEMENTED_, 2),
    DEFINE_MSG(SC_ID_INTERNAL_ERROR_, 3),
    DEFINE_MSG(SC_ID_ASSERTION_FAILED_, 4),
    DEFINE_MSG(SC_ID_OUT_OF_BOUNDS_, 5)
};

sc_report_handler::msg_def_items sc_report_handler::msg_terminator =
{
    default_msgs,
    sizeof(default_msgs)/sizeof(*default_msgs),
    false,
    NULL
};

} // namespace sc_core

// $Log: sc_report_handler.cpp,v $
// Revision 1.9  2011/08/29 18:04:32  acg
//  Philipp A. Hartmann: miscellaneous clean ups.
//
// Revision 1.8  2011/08/26 20:46:19  acg
//  Andy Goodrich: moved the modification log to the end of the file to
//  eliminate source line number skew when check-ins are done.
//
// Revision 1.7  2011/08/07 19:08:08  acg
//  Andy Goodrich: moved logs to end of file so line number synching works
//  better between versions.
//
// Revision 1.6  2011/08/07 18:56:03  acg
//  Philipp A. Hartmann: added cast to ? : to eliminate clang warning message.
//
// Revision 1.5  2011/03/23 16:16:49  acg
//  Andy Goodrich: finish message verbosity support.
//
// Revision 1.4  2011/02/18 20:38:44  acg
//  Andy Goodrich: Updated Copyright notice.
//
// Revision 1.3  2011/02/11 13:25:55  acg
//  Andy Goodrich: Philipp's changes for sc_unwind_exception.
//
// Revision 1.2  2011/02/01 23:02:05  acg
//  Andy Goodrich: IEEE 1666 2011 changes.
//
// Revision 1.1.1.1  2006/12/15 20:20:06  acg
// SystemC 2.3
//
// Revision 1.7  2006/05/26 20:35:52  acg
//  Andy Goodrich: removed debug message that should not have been left in.
//
// Revision 1.6  2006/03/21 00:00:37  acg
//   Andy Goodrich: changed name of sc_get_current_process_base() to be
//   sc_get_current_process_b() since its returning an sc_process_b instance.
//
// Revision 1.5  2006/01/31 21:42:07  acg
//  Andy Goodrich: Added checks for SC_DEPRECATED_WARNINGS being defined as
//  DISABLED. If so, we turn off the /IEEE_Std_1666/deprecated message group.
//
// Revision 1.4  2006/01/26 21:08:17  acg
//  Andy Goodrich: conversion to use sc_is_running instead of deprecated
//  sc_simcontext::is_running()
//
// Revision 1.3  2006/01/13 18:53:11  acg
// Andy Goodrich: Added $Log command so that CVS comments are reproduced in
// the source.

// Taf!