`ifdef XST?

Dec 13, 2007 1 Replies

Does anybody know if XST defines any testable variables when compiling verilog code?



Some of the compilers or simulators that I'm using have differing $readmemh() semantics, and I'd like to be able to write something like:



`ifdef INCA initial $readmemh("memory",configurations,0,15); `else `ifdef XST initial $readmemh("memory",configurations,0,15); `else initial $readmemh("memory",configurations); `endif `endif


If you are using the GUI flow, the synthesis Properties page allows you to add defines. You may need to use the advanced properties page.

Hope this helps.

John Providenza

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required