• 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. Digital Implementation
  3. dbGet and playing with the database

Stats

  • Locked Locked
  • Replies 6
  • Subscribers 92
  • Views 18386
  • 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

dbGet and playing with the database

jkang
jkang over 16 years ago

dbGet and other database operations seem like they would be very powerful tools. I'm surprised there isn't more reference material on sourcelink for how to use them. I'm slowly traversing through it using trial and error and the appendix in the Encounter Text Command Reference but I'm wondering if there are any articles out there that might be a better tutorial for working with the database inside of Encounter.

  • Cancel
Parents
  • BobD
    BobD over 16 years ago

    I like your solution, Kari!  Very clever- I wouldn't have thought to leverage windowSelect like that- especially for rows.

    Here's how I would have gone about it, given the interest in getting the pointers for the rows with a certain filter criteria, and then querying coordinates about each row:

    set rowList {}
    foreach row [dbGet top.fplan.rows] {
      set box [dbGet $row.box]
      set lly [lindex [lindex $box 0] 1]
      if {$lly > 500 && $lly < 600} {
        lappend rowList $row
      }
    }

    foreach row $rowList {
      set box [dbGet $row.box]
      Puts "Top Y: [lindex [lindex $box 0] 3] Bottom Y: [lindex [lindex $box 0] 1]"
    }

    A couple of points of information I'd like to add:

    1. As you can see, it's a tad clunky to decompose a box in dbGet currently (with two lindex statements). In older style FE-TCL terms, we used commands like "dbBoxLLX" to get the lower left x coordinate of a box.  However, these functions don't work within dbGet since they support only database units and not microns. We've talked about having a similar processing command for dbGet usage but I don't recall whether that has come to fruition. I'll check and see.
    2. dbGet's filtering mechanism doesn't work with fixed point numbers in 8.1.RTM. By that I mean, you can filter on an instance name "dbGet top.inst.name *i_9371" but you can't filter on numbers like this: "dbGet top.nets.numInputTerms 15".  This is something we're working on enhancing as part of a push for more sophisticated filtering in dbGet (for example, collecting all high fanout nets with "dbGet top.nets.numInputTerms > 15" could be useful).

    Hope this helps,
    Bob

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • BobD
    BobD over 16 years ago

    I like your solution, Kari!  Very clever- I wouldn't have thought to leverage windowSelect like that- especially for rows.

    Here's how I would have gone about it, given the interest in getting the pointers for the rows with a certain filter criteria, and then querying coordinates about each row:

    set rowList {}
    foreach row [dbGet top.fplan.rows] {
      set box [dbGet $row.box]
      set lly [lindex [lindex $box 0] 1]
      if {$lly > 500 && $lly < 600} {
        lappend rowList $row
      }
    }

    foreach row $rowList {
      set box [dbGet $row.box]
      Puts "Top Y: [lindex [lindex $box 0] 3] Bottom Y: [lindex [lindex $box 0] 1]"
    }

    A couple of points of information I'd like to add:

    1. As you can see, it's a tad clunky to decompose a box in dbGet currently (with two lindex statements). In older style FE-TCL terms, we used commands like "dbBoxLLX" to get the lower left x coordinate of a box.  However, these functions don't work within dbGet since they support only database units and not microns. We've talked about having a similar processing command for dbGet usage but I don't recall whether that has come to fruition. I'll check and see.
    2. dbGet's filtering mechanism doesn't work with fixed point numbers in 8.1.RTM. By that I mean, you can filter on an instance name "dbGet top.inst.name *i_9371" but you can't filter on numbers like this: "dbGet top.nets.numInputTerms 15".  This is something we're working on enhancing as part of a push for more sophisticated filtering in dbGet (for example, collecting all high fanout nets with "dbGet top.nets.numInputTerms > 15" could be useful).

    Hope this helps,
    Bob

    • 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