Jump to content

warning at simulation time


Recommended Posts

my code has a waring when running :

Warning: (W5) out of bounds: sc_uint[_base]: value does not fit into a length of 4

In file: ../../../../../src/sysc/datatypes/int/sc_uint_base.cpp:374

In process: tg0.traffic_generator_thread @ 0 s

what is the reason? Is it a bug? Reading a post in the old forum KMLM List i have seen that a user has solved this problem using gdb debugger writing "sc_report_handler::force(SC_INTERRUPT);" in the sc_main of his code and putting a breakpoint for sc_interrupt_here. i've tried to do this, but i don't know how to fix the breakpoint, in fact i write the command " b sc_interrupt_here" but i receive the message "Function "sc_interrupt_here()" not defined." what is the correct method to do this? or how can i solve the warning with another method?

Thanks.

:)

Link to comment
Share on other sites

You seem to assign a value bigger than 31 to a 4-bit sc_uint, and you have built your SystemC library with DEBUG_SYSTEMC defined. With this symbol defined, the library adds some additional bound (and value) checks.

To add a breakpoint in your debugger, you may need to add the namespace to the symbol as well:

b sc_core::sc_interrupt_here

Alternatively, you can break on the reported file:line position directly (since you know precisely, which error you want to look at).

Greetings from Oldenburg,

Philipp

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...