Skip to content

Commit 4e1fd7f

Browse files
committed
Log more warnings for VCD functionality.
1 parent 6054ef1 commit 4e1fd7f

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

simavr/sim/sim_vcd_file.c

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,8 +450,12 @@ _avr_vcd_notify(
450450
{
451451
avr_vcd_t * vcd = (avr_vcd_t *)param;
452452

453-
if (!vcd->output)
453+
if (!vcd->output) {
454+
AVR_LOG(vcd->avr, LOG_WARNING,
455+
"%s: no output\n",
456+
__FUNCTION__);
454457
return;
458+
}
455459

456460
avr_vcd_signal_t * s = (avr_vcd_signal_t*)irq;
457461
avr_vcd_log_t l = {
@@ -478,8 +482,12 @@ avr_vcd_add_signal(
478482
int signal_bit_size,
479483
const char * name )
480484
{
481-
if (vcd->signal_count == AVR_VCD_MAX_SIGNALS)
485+
if (vcd->signal_count == AVR_VCD_MAX_SIGNALS) {
486+
AVR_LOG(vcd->avr, LOG_ERROR,
487+
" %s: unable add signal '%s'\n",
488+
__FUNCTION__, name);
482489
return -1;
490+
}
483491
int index = vcd->signal_count++;
484492
avr_vcd_signal_t * s = &vcd->signal[index];
485493
strncpy(s->name, name, sizeof(s->name));

0 commit comments

Comments
 (0)