• 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 SKILL
  3. Can the pcell information be stored when GDS stream out...

Stats

  • Locked Locked
  • Replies 1
  • Subscribers 143
  • Views 13428
  • 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

Can the pcell information be stored when GDS stream out?

richardyuan
richardyuan over 10 years ago

I want to do data processing on the GDS file after stream out. It's better to retrieve the pcell level information. i.e., the GDS data changes with the pcell parameters.

I noticed that when stream out there is an option called "Keep Pcells".  Can all those pcell information( especially pcell parameters and the program to generate the pcell) be stored after stream out?

  • Cancel
  • Andrew Beckett
    Andrew Beckett over 10 years ago

    The "Keep Pcells" functionality was an attempt to allow a round-trip flow with stream out - it dumped both the stream file plus some side files to allow the layout to be produced with pcells again if streamed back in along with the side files. It was rather complex and only partially reliable (for example, if you then take the stream file through some other tool that modified it, it may not beable to recover; or if different versions were used, it may not be reliable).

    There was also a second option, Dump PCell Info which wrote out information about which variants of each pcell were used for the design being streamed out.

    Neither of these exist in IC61X and there is certainly no plan to implement the first of these, and I don't think the second either.

    I wrote some SKILL to implement the Dump PCell Info (in effect):

    /* abReportPcellVariantsUsed.il
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Jun 14, 2012 
    Modified   
    By         
    
    Code to report all the variants of pcells used in the design.
    Similar data came out of the "dump pcell info" option in pipo
    in IC5141, but that functionality is not there in xstream in IC61.
    
    To use:
    
    ; report on the hierarchy from the cellView in the current window
    abReportPcellVariantsUsed(?file "./report.txt")
    ; as above, but only showing non-default pcell parameters
    abReportPcellVariantsUsed(?file "./report.txt" ?nonDefault t)
    ; give a specific cellView id rather than current edit cellView
    abReportPcellVariantsUsed(?file "./report.txt" ?cv cvId)
    
    ***************************************************
    
    SCCS Info: @(#) abReportPcellVariantsUsed.il 06/14/12.11:59:31 1.1
    
    */
    
    
    /****************************************************************************
    *                                                                           *
    *           (abCollectPcellVariantsUsed cv [mastersDone pcells])            *
    *                                                                           *
    * Traverse hierarchy recursively, returning a table containing the variants *
    *      for each pcell superMaster that are used in the design. The 2nd      *
    *      and 3rd arguments are only passed from within the function when      *
    *                         it is called recursively                          *
    *                                                                           *
    ****************************************************************************/
    
    (defun abCollectPcellVariantsUsed (cv @optional 
                                          (mastersDone (makeTable 'done nil)) 
                                          (pcells (makeTable 'pcells nil)))
      (let (variants variantTable)
        ;--------------------------------------------------------------------
        ; Record that this master has been visited, to speed things up so
        ; that masters are not traversed more than once
        ;--------------------------------------------------------------------
        (setarray mastersDone cv t)
        (foreach instHeader (dbGetq cv instHeaders)
                 (if (setq variants (dbGetq instHeader variants))
                   ;---------------------------------------------------------
                   ; If there are variants of this instHeader, record them
                   ;---------------------------------------------------------
                   (progn
                     ;-------------------------------------------------------
                     ; Either get the existing variant table for this
                     ; pcell superMaster, or create a new one
                     ;-------------------------------------------------------
                     (setq variantTable 
                           (or 
                             (arrayref pcells (dbGetq instHeader master))
                             (setarray pcells (dbGetq instHeader master)
                                       (makeTable 'variants nil))))
                     ;-------------------------------------------------------
                     ; Record any variants found in the table
                     ;-------------------------------------------------------
                     (foreach variant variants
                              (setarray variantTable (dbGetq variant master) t)
                              )
                     )
                   ;---------------------------------------------------------
                   ; Otherwise traverse the hierarchy if not already visited.
                   ; Note: This includes any pcell variants, which may contain
                   ; hierarchy
                   ;---------------------------------------------------------
                   (unless (arrayref mastersDone (dbGetq instHeader master))
                     (abCollectPcellVariantsUsed (dbGetq instHeader master)
                                                 mastersDone pcells)
                     )
                   )
                 )
        pcells
        )
      )
    
    /************************************************************************
    *                                                                       *
    *  (abReportPcellVariantsUsed [?file poport] [?cv (geGetEditCellView)]  *
    *                          [?nonDefault nil])                           *
    *                                                                       *
    * Writes out a report of all the variants used in the design hierarchy. *
    * The ?file can be either a fileName, or an open port. The ?nonDefault  *
    * argument allows you to restrict the report to only output non-default *
    *                 pcell parameters in the variants list                 *
    *                                                                       *
    ************************************************************************/
    
    (defun abReportPcellVariantsUsed (@key (file poport) (cv (geGetEditCellView)) nonDefault)
      (let (pcells port defaults)
        (setq port
              (cond
                ((stringp file) (outfile file))
                ((and (openportp file) (outportp file)) file)
                (nil)))
        (when (null port)
          (error "abReportPcellVariantsUsed: first argument must be a valid file name to write to, or an open port: %L" file)
          )
        (setq pcells (abCollectPcellVariantsUsed cv))
        (foreach master pcells
                 ;-----------------------------------------------------------
                 ; If asked to output just the non-default parameters only,
                 ; record the superMaster defaults in a table
                 ;-----------------------------------------------------------
                 (when nonDefault
                   ;---------------------------------------------------------
                   ; since parameters can't be symbols, make default a spurious
                   ; value in case unlikely situation where variant has additional
                   ; parameter that the master does not 
                   ;---------------------------------------------------------
                   (setq defaults (makeTable 'defaults 'special))
                   (foreach param (dbGetq (dbGetq master parameters) value)
                            (setarray defaults (dbGetq param name) (dbGetq param value))
                            )
                   )
                 (fprintf port "PCell %s %s %s has variants:\n"
                          (dbGetq master libName)
                          (dbGetq master cellName)
                          (dbGetq master viewName)
                          )
                 (foreach variantMaster
                          (arrayref pcells master)
                          (fprintf port " ")
                          (foreach param (dbGetq (dbGetq variantMaster parameters) value)
                                   ;-----------------------------------------
                                   ; Output either just the non-default, or all parameters
                                   ;-----------------------------------------
                                   (when (or (null nonDefault)
                                             (nequal (arrayref defaults (dbGetq param name))
                                                     (dbGetq param value)))
                                     (fprintf port " %s=%L"
                                              (dbGetq param name) (dbGetq param value))
                                     )
                                   )
                          (fprintf port "\n")
                          )
                 (fprintf port "\n")
                 )
        (when (stringp file) 
          (close port))
        t
        )
      )
    

    Regards,

    Andrew.

    • 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