• 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 Design
  3. Finding Bus Range conflicts through schematic rules che...

Stats

  • Locked Locked
  • Replies 2
  • Subscribers 125
  • Views 14201
  • 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

Finding Bus Range conflicts through schematic rules check

markbeck
markbeck over 13 years ago

Greetings all,

I'm running IC6.15.500.6

I'm running into the situation where a designer might inadvertantly invert a bus without intending to.

If you have an instance with a port named "foo<1:0>" and you connect a wire to the port on an instantiated instance, Virtuoso will (by default) assign that wire a ascending port name "netxxx<0:1>". This causes the netxxx<0> to connect to port foo<1> and netxxx<1> connect to port foo<0>.

I know that you can set an environmental variable to define the order in which it is defined:  schematic netNameRangeDescend boolean t

However, I would like to add this sort of error to the standard checker that gets run when the designer does a "check and save".

I looked through the "Schematic Rules Checks Setup" dialog, but I couldn't find a pre-defined check.

Is there one?

Mark

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 13 years ago

    Mark,

    I'm not aware of such a check. This would be a good candidate for a custom check.

    Here's an example of using the new mechanism in IC615 to register schematic checks so that they are controllable via the Check->Setup Rules form (this is for doing some name case checks, but you can get the idea):

     

    /* abExampleSchematicCheckNew.ils
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Oct 28, 2011 
    Modified   
    By         
    
    This is a reimplementation of some of the checks in abExampleSchematicCheck.ils
    but taking advantage of the new interface in IC615 to register checks with
    the system. As a result it is much simpler, and does not have to take care
    of creating marker objects itself; also gives the user the ability to override
    the check, or change the severity if needed.
    
    To register, call:
    
    abRegExampleSchematicCheckNew("Your Customer Name")
    
    (with no arguments, it just calls the rule group "Customer")
    
    ***************************************************
    
    SCCS Info: @(#) abExampleSchematicCheckNew.ils 10/28/11.10:55:00 1.1
    
    */
    
    ;------------------------------------------------------------------------
    ; The let is to create a lexical scope, so that there can be
    ; private functions which are used for some of the implementation
    ;------------------------------------------------------------------------
    let(()
    
        /***************************************************************
        *                                                              *
        *  abRegExampleSchematicCheckNew([?customerName "Customer"])   *
        *                                                              *
        * PUBLIC GLOBAL function used to register the new check group  *
        * and any specific check - in this case an example of a naming *
        *                         convention.                          *
        *                                                              *
        ***************************************************************/
        defglobalfun(abRegExampleSchematicCheckNew (@optional (customerName "Customer"))
            ;----------------------------------------------------------------
            ; This registers a new tab on Check->Rules Setup
            ;----------------------------------------------------------------
            schRegisterCheckGroup(
                ?name concat(customerName)
                ?description strcat(customerName " checks")
            )
            ;----------------------------------------------------------------
            ; This registers the specific rule and default severity
            ;----------------------------------------------------------------
            schRegisterCheckRule(
                ?title "Naming conventions"
                ?name 'namingConventions
                ?groupName concat(customerName)
                ?severity 'error
                ?checkCB checkNamingConventions
            )
        )
    
        /*********************************************************************
        *                                                                    *
        *               checkNamingConventions(cv ruleObject)                *
        *                                                                    *
        * INTERNAL function used to actually implement the naming convention *
        *                               check.                               *
        *                                                                    *
        *********************************************************************/
        defun(checkNamingConventions (cv ruleObject)
            let((obj label netTable signals sigTable)
                ;------------------------------------------------------------
                ; Check that terminal names are in upper case
                ;------------------------------------------------------------
                foreach(term cv~>terminals
                    unless(term~>name==upperCase(term~>name)
                        ;----------------------------------------------------
                        ; Place the marker on the first pin - no need to
                        ; put it on every pin if there are multiple pins
                        ;----------------------------------------------------
                        obj=car(term~>pins~>fig) || cv
                        schReportCheckFailure(
                            ?object obj
                            ?checkRule ruleObject
                            ?short "Terminals not upper case"
                            ?message
                                sprintf(nil "Terminals must be in upper case: %s" 
                                    term~>name
                                ) 
                        ) 
                    ) ; unless
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for internal nets which have a lower case name
                ;------------------------------------------------------------
                foreach(net cv~>nets
                    ;--------------------------------------------------------
                    ; Only worry about nets which have a label
                    ;--------------------------------------------------------
                    label=car(exists(fig net~>figs fig~>objType=="label"))
                    when(label
                        when(exists(sig net~>signals 
                            ;------------------------------------------------
                            ; Check that the signal is not part of a 
                            ; terminal, and is not in lowercase
                            ;------------------------------------------------
                            !sig~>memTerms && sig~>name!=lowerCase(sig~>name))
                            schReportCheckFailure(
                                ?object label
                                ?checkRule ruleObject
                                ?short "Internal nets not lower case"
                                ?message
                                    sprintf(nil "Internal net names must be in lower case: %s"
                                        net~>name
                                    ) 
                            ) 
                        ) ; when there is a lower internal net name on net
                    ) ; when there's a label
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for any nets which only differ in case
                ;------------------------------------------------------------
                ;------------------------------------------------------------
                ; record all the signals together in a table indexed by
                ; the flattened case. Then use a table to record all
                ; member nets which have a mixed-case problem
                ;------------------------------------------------------------
                sigTable=makeTable('sigTable nil)
                netTable=makeTable('netTable nil)
                foreach(sig cv~>signals
                    sigTable[lowerCase(sig~>name)]=
                        cons(sig sigTable[lowerCase(sig~>name)])
                ) ; foreach
                foreach(tableEntry sigTable
                    signals=sigTable[tableEntry]
                    ;--------------------------------------------------------
                    ; If there was more than one signal with the
                    ; same flattened case, then there's
                    ; a mixed name problem. Record the member nets
                    ; in a table (to avoid duplication)
                    ;--------------------------------------------------------
                    when(cdr(signals)
                        foreach(sig signals
                            foreach(memNet sig~>memNets
                                netTable[car(memNet)]=signals
                            ) ; foreach memNet
                        ) ; foreach sig
                    ) ; when
                ) ; foreach 
                foreach(net netTable
                    ;--------------------------------------------------------
                    ; Find something suitable to put the marker on
                    ;--------------------------------------------------------
                    cond(
                        ;----------------------------------------------------
                        ; Use the pin if there is one
                        ;----------------------------------------------------
                        (net~>term~>pins
                            obj=car(net~>term~>pins~>fig)
                        )
                        ;----------------------------------------------------
                        ; Otherwise use the label
                        ;----------------------------------------------------
                        (obj=car(
                            exists(shape net~>figs 
                                shape~>objType=="label"))
                            t
                        )
                        ;----------------------------------------------------
                        ; Next try a wire
                        ;----------------------------------------------------
                        (obj=car(
                                exists(shape net~>figs
                                    shape~>objType=="line" ||
                                    shape~>objType=="path")
                            )
                            t
                        )
                        ;----------------------------------------------------
                        ; Finally, if nothing else, use the cellView
                        ;----------------------------------------------------
                        (t
                            obj=cv
                        )
                    ) ; cond
                    schReportCheckFailure(
                        ?object obj 
                        ?checkRule ruleObject
                        ?short "Net differing only in case"
                        ?message
                            sprintf(nil 
                                "Net %L cannot differ only in case from others: %L" 
                                net~>name
                                netTable[net]~>name
                            )
                    )
                ) ; foreach
            ) ; let
        ) ; defun checkNamingConventions
    
    )
    

     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 13 years ago

    Mark,

    I'm not aware of such a check. This would be a good candidate for a custom check.

    Here's an example of using the new mechanism in IC615 to register schematic checks so that they are controllable via the Check->Setup Rules form (this is for doing some name case checks, but you can get the idea):

     

    /* abExampleSchematicCheckNew.ils
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Oct 28, 2011 
    Modified   
    By         
    
    This is a reimplementation of some of the checks in abExampleSchematicCheck.ils
    but taking advantage of the new interface in IC615 to register checks with
    the system. As a result it is much simpler, and does not have to take care
    of creating marker objects itself; also gives the user the ability to override
    the check, or change the severity if needed.
    
    To register, call:
    
    abRegExampleSchematicCheckNew("Your Customer Name")
    
    (with no arguments, it just calls the rule group "Customer")
    
    ***************************************************
    
    SCCS Info: @(#) abExampleSchematicCheckNew.ils 10/28/11.10:55:00 1.1
    
    */
    
    ;------------------------------------------------------------------------
    ; The let is to create a lexical scope, so that there can be
    ; private functions which are used for some of the implementation
    ;------------------------------------------------------------------------
    let(()
    
        /***************************************************************
        *                                                              *
        *  abRegExampleSchematicCheckNew([?customerName "Customer"])   *
        *                                                              *
        * PUBLIC GLOBAL function used to register the new check group  *
        * and any specific check - in this case an example of a naming *
        *                         convention.                          *
        *                                                              *
        ***************************************************************/
        defglobalfun(abRegExampleSchematicCheckNew (@optional (customerName "Customer"))
            ;----------------------------------------------------------------
            ; This registers a new tab on Check->Rules Setup
            ;----------------------------------------------------------------
            schRegisterCheckGroup(
                ?name concat(customerName)
                ?description strcat(customerName " checks")
            )
            ;----------------------------------------------------------------
            ; This registers the specific rule and default severity
            ;----------------------------------------------------------------
            schRegisterCheckRule(
                ?title "Naming conventions"
                ?name 'namingConventions
                ?groupName concat(customerName)
                ?severity 'error
                ?checkCB checkNamingConventions
            )
        )
    
        /*********************************************************************
        *                                                                    *
        *               checkNamingConventions(cv ruleObject)                *
        *                                                                    *
        * INTERNAL function used to actually implement the naming convention *
        *                               check.                               *
        *                                                                    *
        *********************************************************************/
        defun(checkNamingConventions (cv ruleObject)
            let((obj label netTable signals sigTable)
                ;------------------------------------------------------------
                ; Check that terminal names are in upper case
                ;------------------------------------------------------------
                foreach(term cv~>terminals
                    unless(term~>name==upperCase(term~>name)
                        ;----------------------------------------------------
                        ; Place the marker on the first pin - no need to
                        ; put it on every pin if there are multiple pins
                        ;----------------------------------------------------
                        obj=car(term~>pins~>fig) || cv
                        schReportCheckFailure(
                            ?object obj
                            ?checkRule ruleObject
                            ?short "Terminals not upper case"
                            ?message
                                sprintf(nil "Terminals must be in upper case: %s" 
                                    term~>name
                                ) 
                        ) 
                    ) ; unless
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for internal nets which have a lower case name
                ;------------------------------------------------------------
                foreach(net cv~>nets
                    ;--------------------------------------------------------
                    ; Only worry about nets which have a label
                    ;--------------------------------------------------------
                    label=car(exists(fig net~>figs fig~>objType=="label"))
                    when(label
                        when(exists(sig net~>signals 
                            ;------------------------------------------------
                            ; Check that the signal is not part of a 
                            ; terminal, and is not in lowercase
                            ;------------------------------------------------
                            !sig~>memTerms && sig~>name!=lowerCase(sig~>name))
                            schReportCheckFailure(
                                ?object label
                                ?checkRule ruleObject
                                ?short "Internal nets not lower case"
                                ?message
                                    sprintf(nil "Internal net names must be in lower case: %s"
                                        net~>name
                                    ) 
                            ) 
                        ) ; when there is a lower internal net name on net
                    ) ; when there's a label
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for any nets which only differ in case
                ;------------------------------------------------------------
                ;------------------------------------------------------------
                ; record all the signals together in a table indexed by
                ; the flattened case. Then use a table to record all
                ; member nets which have a mixed-case problem
                ;------------------------------------------------------------
                sigTable=makeTable('sigTable nil)
                netTable=makeTable('netTable nil)
                foreach(sig cv~>signals
                    sigTable[lowerCase(sig~>name)]=
                        cons(sig sigTable[lowerCase(sig~>name)])
                ) ; foreach
                foreach(tableEntry sigTable
                    signals=sigTable[tableEntry]
                    ;--------------------------------------------------------
                    ; If there was more than one signal with the
                    ; same flattened case, then there's
                    ; a mixed name problem. Record the member nets
                    ; in a table (to avoid duplication)
                    ;--------------------------------------------------------
                    when(cdr(signals)
                        foreach(sig signals
                            foreach(memNet sig~>memNets
                                netTable[car(memNet)]=signals
                            ) ; foreach memNet
                        ) ; foreach sig
                    ) ; when
                ) ; foreach 
                foreach(net netTable
                    ;--------------------------------------------------------
                    ; Find something suitable to put the marker on
                    ;--------------------------------------------------------
                    cond(
                        ;----------------------------------------------------
                        ; Use the pin if there is one
                        ;----------------------------------------------------
                        (net~>term~>pins
                            obj=car(net~>term~>pins~>fig)
                        )
                        ;----------------------------------------------------
                        ; Otherwise use the label
                        ;----------------------------------------------------
                        (obj=car(
                            exists(shape net~>figs 
                                shape~>objType=="label"))
                            t
                        )
                        ;----------------------------------------------------
                        ; Next try a wire
                        ;----------------------------------------------------
                        (obj=car(
                                exists(shape net~>figs
                                    shape~>objType=="line" ||
                                    shape~>objType=="path")
                            )
                            t
                        )
                        ;----------------------------------------------------
                        ; Finally, if nothing else, use the cellView
                        ;----------------------------------------------------
                        (t
                            obj=cv
                        )
                    ) ; cond
                    schReportCheckFailure(
                        ?object obj 
                        ?checkRule ruleObject
                        ?short "Net differing only in case"
                        ?message
                            sprintf(nil 
                                "Net %L cannot differ only in case from others: %L" 
                                net~>name
                                netTable[net]~>name
                            )
                    )
                ) ; foreach
            ) ; let
        ) ; defun checkNamingConventions
    
    )
    

     

    • 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