Unbuffered output with vpi_printf?

E

EdA

Guest
Hi,

What's the right way to get unbuffered I/O using vpi_printf?
I'm using Solaris and Linux and NC-Verilog.

I tried: setbuf(stdout, (char *) 0);
but got a seg fault after a while.

Is setvbuf the way to go?

Thanks,
/Ed
 
Hi,
Not a VPI solution, but NCSIM has an option -unbuffered to prevent
text IO buffer, will that help you?

Ajeetha,
http://www.noveldv.com
Co-Author: Using PSL/SUGAR for Formal and Dynamic Verification 2nd
Edition.



ed.arthur@comcast.net (EdA) wrote in message news:<86e89120.0404051145.559de194@posting.google.com>...
Hi,

What's the right way to get unbuffered I/O using vpi_printf?
I'm using Solaris and Linux and NC-Verilog.

I tried: setbuf(stdout, (char *) 0);
but got a seg fault after a while.

Is setvbuf the way to go?

Thanks,
/Ed
 
aji@noveldv.com (Ajeetha Kumari) wrote in message news:<8df95881.0404052355.28bd264c@posting.google.com>...
Hi,
Not a VPI solution, but NCSIM has an option -unbuffered to prevent
text IO buffer, will that help you?
Hi Ajeetha,

You're right.

% strings `which ncverilog` | grep unbuffer
+ncunbuffered
+ncunbuffered Do not buffer output

Oddly, it doesn't show up with the help (ncverilog -h).

VPI solution wasn't required.

Thanks,
/Ed

PS: Thanks to the others who replied via email.
 

Welcome to EDABoard.com

Sponsor

Back
Top