• 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. Search Path and Packages, Interface, etc.

Stats

  • Locked Locked
  • Replies 4
  • Subscribers 64
  • Views 14651
  • 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

Search Path and Packages, Interface, etc.

archive
archive over 18 years ago

For this discussion assume a design team is used to using a search path approach to finding verilog modules and this forms the basis for the desires to follow. When an module imports a package or instances an interface, is there a similar search path convention/feature in tools like NCSIM, RC, etc?


Originally posted in cdnusers.org by bryan
  • Cancel
Parents
  • archive
    archive over 18 years ago

    For instancing the interface, the search path works the same as for any module instantiated in a design.

    For packages, you import only the package you want to use. If you need items from multiple packages and can't wildcard import the packages, then you will have to import only the items you need.

    Example:

    package test1_pkg;
    typedef logic var_t;
    endpackage

    package test2_pkg;
    typedef bit var_t;
    endpackage

    module test;
    import test1_pkg::*;
    import test2_pkg::var_t; // wildcard import would cause error
    var_t v;
    initial $display("v=%b",v);
    endmodule


    Tim


    Originally posted in cdnusers.org by tpylant
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • archive
    archive over 18 years ago

    For instancing the interface, the search path works the same as for any module instantiated in a design.

    For packages, you import only the package you want to use. If you need items from multiple packages and can't wildcard import the packages, then you will have to import only the items you need.

    Example:

    package test1_pkg;
    typedef logic var_t;
    endpackage

    package test2_pkg;
    typedef bit var_t;
    endpackage

    module test;
    import test1_pkg::*;
    import test2_pkg::var_t; // wildcard import would cause error
    var_t v;
    initial $display("v=%b",v);
    endmodule


    Tim


    Originally posted in cdnusers.org by tpylant
    • 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