• 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. Functional Verification
  3. Tutorial on NCsim

Stats

  • Locked Locked
  • Replies 5
  • Subscribers 65
  • Views 34026
  • 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

Tutorial on NCsim

ReubenMijares
ReubenMijares over 9 years ago

Hi,


I'm learning how to use ncsim and I have done so many research on Google. But what I found out was that most of the blogs are complicated to understand. For most of them, there are pre-requisites before you can totally understand what's happening.


So, I would like to ask if you have a "step-by-step" tutorial on how to simulate using NCsim? I would like to know on these particular topics:

- Waveform Dumping

- Functional Coverage report and merging

For the functional coverage report, I placed a -coverage all as options, just like what the blogs I read did. But what happens to my regression is that it runs very very slow! Usually it only takes 30 minutes. But now it takes 24 hours.

So, do you have a step-by-step tutorial on running NCsim?

Thank you.


Regards,

Reuben

  • Cancel
  • StephenH
    StephenH over 9 years ago

    Hello Reuben.

    If you register on support.cadence.com using your corporate email address, you will get access to our Rapid Adoption Kits (RAKs) and tutorials. These will lead you step by step through the different aspects of the Incisive flow. To aid your searches, be aware that "ncsim" is a legacy name for the simulator, and if you're trying to use the legacy commands "ncvlog", "ncelab", "ncsim" then you would be well advised to replace these with the single "irun" command which wraps up the entire compile, elab and simulation process into one easy step. It's much simpler to use!

    To answer your specific points though: to probe waveforms you must elaborate the design with read access enabled for the signals you want to dump. We usually do that with the irun option "-access +r" (you can pass this to ncelab directly too). Then once you've loaded the simulation, and before you start simulating, either use the GUI or the Tcl commands to "probe" signals to the waveform file. From the GUI you do it by selecting a module in the hierarchy (e.g. the top level), right click on it and "Create Probe". You then have options for which types of signals (ports, internal, memories etc) and whether to probe more than one level of hierarchy. Watch out: the default in the GUI is to send all probed signals to the waveform window and that's probably not what you want for a big design!

    From Tcl, you can simply do "probe -create -shm <top_module_name> -all -depth to_cells" to probe everything in the design excluding cell libraries. Simply replace <top_module_name> with your actual top-level module name.

    Note that you must probe signals before simulating if you want the simulator to record their values! :)

    For coverage, you elaborate with either "-coverage B:E:T:U:F", where each letter turns on a different type (e.g. F is FSM, so omit the F if you don't want FSM coverage). Personally I dislike the -coverage option as it's all-or-nothing and I normally want more careful tuning. You can get better control using a coverage control file, specified via "irun -covfile foo.ccf". You need to write a foo.ccf containing commands like "select_coverage -block tb.dut.core". You'll find all the commands listed in the docs.

    Talking of docs, you can either search and browse the docs online at support.cadence.com, or at the Linux command line you can run "cdnshelp" which opens the doc browser, this contains a search tool.

    Finally, here's a direct link to the Incisive RAKs. SOC and IP level Functional Verification - Rapid Adoption Kits (RAK) Download Landing Page

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • StephenH
    StephenH over 9 years ago

    By the way, regarding your coverage simulation performance, I would not expect such a big increase in run time so it would be very interesting to know more about your design and what coverage you're enabling. It might be best to do that 1:1 via the Cadence support system rather than broadcasting your design information here in public. :) However what I would request is a bit of info on the exact tool version you're using (quote the output from "irun -version" and the headline figures for how much coverage you have, gained from the first line of the report from this IMC command:

    imc -load cov_work/scope/test -execcmd 'report -summary -cumulative on -inst -local off'

    (change cov_work/scope/test to point to one of your actual coverage results if you haven't used the default naming)

    For example:

    % imc -load cov_work/scope/test -execcmd 'report -summary -cumulative on -inst -local off'
    IMC(64): 14.21-s070: (c) Copyright 1995-2016 Cadence Design Systems Inc
    *I,RUNLD: Successfully loaded run cov_work/scope/test.
    Starting batch mode
    Legend: Metric* means cumulative e.g. Block* means Cumulative Block Coverage
    name Overall* Average Overall* Covered Code* Average Code* Covered Fsm* Average Fsm* Covered Functional* Average Functional* Covered
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
    tb 100.00% 100.00% (2/2) n/a n/a n/a n/a 100.00% 100.00% (2/2)

    The numbers in parentheses tell us how many items are being covered for each type of coverage. It would be interesting to know if one of these is sky-high. E.g. if you're doing toggle coverage of a huge gate-level design.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ReubenMijares
    ReubenMijares over 9 years ago

    Hi Stephen,


    Thanks for the reply. I have tried both the waveform dumping and functional coverage and they are working.

    Now I have another problem. My regression outputs several coverage output files. I need to merge them all.

    According to my research, I can use imc> merge test1 test2 -out merge_results

    However, these output files are so many. I don't want to type all these output files in the command line to merge them.

    Is there a command where all of these coverage output files are merged without manually typing them?

    Regards,

    Reuben

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • ReubenMijares
    ReubenMijares over 9 years ago

    Hi,

    Okay, I tried using the asterisk and it's working. :)

    This is what I did:

    imc> merge test_* -out merge_results

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • StephenH
    StephenH over 9 years ago
    :-)
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

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