• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC Design
  3. Accessing C code generated from veriloga compile

Stats

  • Locked Locked
  • Replies 1
  • Subscribers 125
  • Views 12955
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Accessing C code generated from veriloga compile

RobinCommander
RobinCommander over 11 years ago

Is it possible to access the C code generated by the veriloga compiler?

With the ahdlcom option on I get "ERROR (VACOMP-1008): Cannot compile ahdlcmi module library. ..." problems. The log files tell me the problem C code files & lines but then deletes these files so I don't have any clue as to where it is going wrong.

Running with ahdlcom 0 gets round the problem

 

While I am here I found a couple of possible minor bugs with the veriloga {} string concenation operator.

$display("test 0x %s",{0{"ab"}});  // <- should be null string?
$display("test 1x %s",{1{"ab"}});
$display("test 2x %s",{2{"ab"}});
teststr = "abcdef";  //teststr is string type
$display("test append %s",{teststr.substr(0,2),"xyz"});

Produces:

test 0x ab
test 1x ab
test 2x abab
test append abc

I tried {0{"ab"}} in Hspice to get a second opinion but it refused to run.

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 11 years ago

    Robin,

    For the first issue, you shouldn't really need to look at the C code - if the C code is causing a complication failure, that's a bug, and so you should report it to customer support with a testcase that we can reproduce it and get it fixed.

    For the other two minor bugs, I created cases and CCRs on your behalf. For the second one, you can workaround it by doing:

    otherstr=teststr.substr(0,2);
    $display("other append %s",{otherstr,"xyz"}); // correctly outputs "abcxyz"

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 11 years ago

    Robin,

    For the first issue, you shouldn't really need to look at the C code - if the C code is causing a complication failure, that's a bug, and so you should report it to customer support with a testcase that we can reproduce it and get it fixed.

    For the other two minor bugs, I created cases and CCRs on your behalf. For the second one, you can workaround it by doing:

    otherstr=teststr.substr(0,2);
    $display("other append %s",{otherstr,"xyz"}); // correctly outputs "abcxyz"

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information