• 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. Logic Design
  3. How to calculate speed for each path_group in RTL Compi...

Stats

  • Locked Locked
  • Replies 2
  • Subscribers 62
  • Views 13338
  • 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

How to calculate speed for each path_group in RTL Compiler

Maso
Maso over 13 years ago

Hi,

 I want to write script to calculate speed for each path_group defined in advance.

Does any body can give me some ideas to do this?

 Thanks a lot.

  • Cancel
Parents
  • grasshopper
    grasshopper over 13 years ago

    Hi Maso,

     you probably want something along lines of

      

    proc GetCgCritPeriod { args } {

    # Parse command line switches

    # return an error if incorrect arguments are given

    switch -- [parse_options [calling_proc] {} $args \

          "-mode dos(mode) specify which mode to report for when mutli-mode design (default is worst slack mode)" modeName \

          "srm cost group to provide critical period information for" obj ] {

      -2 { return }

      0 { return -code error }

    }

    if {[regexp {no_value} [get_attr slack $obj]]} { return "N/A" }

    array set endInfo [lindex [get_attr timing_info [get_attr critical_endpoint $obj]] 0]

    if {[string match "unclocked" [lindex $endInfo(capture) 0]]} { return "Unclocked" }

    return [format "%.2f" [expr {[get_attr period [lindex $endInfo(capture) 0]] / [get_attr divide_period [lindex $endInfo(capture) 0]]}]]

        }

     

        #------------------------------------------------------

        # 

        # 

        # 

        # 

        # 

        # 

        #------------------------------------------------------

        proc GetCgCritFreq { args } {

    # Parse command line switches

    # return an error if incorrect arguments are given

    switch -- [parse_options [calling_proc] {} $args \

          "-mode dos(mode) specify which mode to report for when mutli-mode design (default is worst slack mode)" modeName \

          "srm cost group to provide critical period information for" obj ] {

      -2 { return }

      0 { return -code error }

    }

    if {[regexp {no_value} [get_attr slack $obj]]} { return "N/A" }

    if {[regexp {Unclocked} [eval GetCgCritPeriod ${obj}]]} { return "Unclocked" }

    set cgSlack [get_attr slack $obj]

    return [format "%.1f" [expr {1000000 / ([eval GetCgCritPeriod ${obj}] - ${cgSlack})}]]

        }

     

    Furthermore, you there is a nice applet for it that you can use

     

    applet load generate_repport

    generate_report.... 

     

    which will generate a nice HTML report for you including this information. Don't confuse generate_report with generate_reports which is text based

     

    gh- 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • grasshopper
    grasshopper over 13 years ago

    Hi Maso,

     you probably want something along lines of

      

    proc GetCgCritPeriod { args } {

    # Parse command line switches

    # return an error if incorrect arguments are given

    switch -- [parse_options [calling_proc] {} $args \

          "-mode dos(mode) specify which mode to report for when mutli-mode design (default is worst slack mode)" modeName \

          "srm cost group to provide critical period information for" obj ] {

      -2 { return }

      0 { return -code error }

    }

    if {[regexp {no_value} [get_attr slack $obj]]} { return "N/A" }

    array set endInfo [lindex [get_attr timing_info [get_attr critical_endpoint $obj]] 0]

    if {[string match "unclocked" [lindex $endInfo(capture) 0]]} { return "Unclocked" }

    return [format "%.2f" [expr {[get_attr period [lindex $endInfo(capture) 0]] / [get_attr divide_period [lindex $endInfo(capture) 0]]}]]

        }

     

        #------------------------------------------------------

        # 

        # 

        # 

        # 

        # 

        # 

        #------------------------------------------------------

        proc GetCgCritFreq { args } {

    # Parse command line switches

    # return an error if incorrect arguments are given

    switch -- [parse_options [calling_proc] {} $args \

          "-mode dos(mode) specify which mode to report for when mutli-mode design (default is worst slack mode)" modeName \

          "srm cost group to provide critical period information for" obj ] {

      -2 { return }

      0 { return -code error }

    }

    if {[regexp {no_value} [get_attr slack $obj]]} { return "N/A" }

    if {[regexp {Unclocked} [eval GetCgCritPeriod ${obj}]]} { return "Unclocked" }

    set cgSlack [get_attr slack $obj]

    return [format "%.1f" [expr {1000000 / ([eval GetCgCritPeriod ${obj}] - ${cgSlack})}]]

        }

     

    Furthermore, you there is a nice applet for it that you can use

     

    applet load generate_repport

    generate_report.... 

     

    which will generate a nice HTML report for you including this information. Don't confuse generate_report with generate_reports which is text based

     

    gh- 

    • 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