Very strange behavior with $warning
I have attached a minimal example that reproduces this issue. The issue occurs with both C++ and SystemC, however I have only provided a C++ example. It also occurs on both my windows and linux machines. I am using the very latest Git repo version: 3.863
My design is as follows:
module our; initial begin assert (1==0) else begin $warning ("3 reals: (%f), (%f), (%f)\n", 1.0, 2.5, 5.3); // this outputs gibberish end $finish; end endmodule
When executed the result is this:
 %Warning: our.sv:7: Assertion failed in TOP.v: 3 reals: (5.300000), (1.000000), (0.000000)
Ummm...what is that? Haha.
Also, my sc_time_stamp() function is set to always return 0.0. So not sure where that huge number is coming from.
Additionally, if I replace $warning with $error it causes a core dump. If I use either $display or $write it executes just fine.
Any ideas? Let me know if you need any other info.
#2 Updated by Jonathon Donaldson about 5 years ago
Holy cow that was fast. $warning works great now. Thanks!!
However, if you replace $warning with $error it still core dumps as mentioned. Guess the $error core dump is unrelated to the $warning issue. If you want I can create a separate bug ticket...?
Also available in: Atom