• 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. How to calculate area for a given schematic

Stats

  • Locked Locked
  • Replies 13
  • Subscribers 143
  • Views 22001
  • 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 area for a given schematic

IC Layout
IC Layout over 16 years ago

 Hello! Every body, I am using cadence IC514 version and a 90nm PDK kit called "gpdk090".
My intention is to calculate area for a given schematic.
I wrote a procedure called "area()" which will calculate area in the current level (means for transistors, capacitors and resistors only).
Now I need to call this procedure for every instance which is not a transistor,cap or a resistor.
I wrote something like this........................
foreach( inst geGetEditCellView()~>instances
    when( inst~>purpose == "cell"
        if( inst~>libName == "gpdk090" then
            area()
        else
            label:
            cv1=dbOpenCellViewByType(inst~>libName inst~>cellName "schematic")
            foreach( inst1 cv1~>instances
                when( inst1~>purpose == "cell"
                    if( inst1~>libName == "gpdk090" then
                        area()
                    else
                        goto label
        ]
Can some body guide me in this way...
                Thanks in Advance...    
                                                                Prabhakar. K

  • Cancel
Parents
  • IC Layout
    IC Layout over 16 years ago

     Thanks for your concern towards my problem.......sir,

    My intention is to have total area for a given schematic & also drawing rectangles for the instances/blocks which are in top level schematic only.

    With the suggestions you had given now I am able to obtain area for the entire schematic......I tried to draw rectangles for the instances which are in toplevel but in vain.......

    Please have a look at my new code " area_mod.il" and suggest me........

    ************************************ area_mod.il**************************************

     div_fac = 1f

     procedure( area_mod(inst)

     if(inst~>cellName == "pmos2v" then
                w1 = cdfParseFloatString(dbGetq(inst "w") )
                l1 = cdfParseFloatString(dbGetq(inst "l") )
                m1 = evalstring(dbGetq(inst "m"))    
                f1 = evalstring(dbGetq(inst "fingers"))  

               wp = w1 + 1.4u

               lp = f1*l1 + (f1-1)*0.36u + 2u

               AREA = wp*lp

    else

           if(inst~>cellName == "nmos2v" then
                w1 = cdfParseFloatString(dbGetq(inst "w") )
                l1 = cdfParseFloatString(dbGetq(inst "l") )
                m1 = evalstring(dbGetq(inst "m"))    
                f1 = evalstring(dbGetq(inst "fingers"))  

               wn = w1 + 0.6u

               ln = f1*l1 + (f1-1)*0.36u +1.12u

               AREA = wn*ln

    else

               if(inst~>cellName == "resnsppoly" then

               w1 = cdfParseFloatString(dbGetq(inst "segW") )
                l1 = cdfParseFloatString(dbGetq(inst "segL") )
                m1 = evalstring(dbGetq(inst "segments"))
                
                wr = m1*w1 + (m1-1)*0.6u + 0.56u

                lr = l1 + 1.12u

               AREA = wr*lr

    else

                if( inst~>cellName == "mimcap" then
                c1 = cdfParseFloatString(dbGetq(inst "c"))
                m1 = evalstring(dbGetq(inst "m"))
                
                areac = m1*c1
                AREA = areac/div_fac

    ) ) ) )

    AREA

    );procedure

     procedure(PKsumArea(@optional (cv geGetEditCellView()))
          foreach(inst cv~>instances
          if(inst~>libName=="gpdk090" then
            totalArea=totalArea+area_mod(inst)

    ;;;;shall I write 'dbCreateRect(.....) statement here.....for the toplevel transistors/res/caps

          else

            when(inst~>purpose=="cell"
             master=dbOpenCellViewByType(inst~>libName inst~>cellName "schematic")
             when(maste          

            println(master~>cellName)

            PKsumArea(master)

            ;;;;shall I write 'dbCreateRect(.....) statement here.....for the toplevel blocks (after calculating whole block area)
     

    ) ) ) )

    totalArea

    )

    PKsumArea()

    println(totalArea)

    ******************************************** end of area_mo.il************************************

    I have used ' cdfFofmatFloatString ' for the purpose of drawing rectangles (by formating every value to suffix "p" in other case it's giving errors).

     I hope you are understanding my problem...........

    I am very very sorry....if you feel inconvinence..

    Thanks & regards........

                        Prabhakar. K
     

     

        
     

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • IC Layout
    IC Layout over 16 years ago

     Thanks for your concern towards my problem.......sir,

    My intention is to have total area for a given schematic & also drawing rectangles for the instances/blocks which are in top level schematic only.

    With the suggestions you had given now I am able to obtain area for the entire schematic......I tried to draw rectangles for the instances which are in toplevel but in vain.......

    Please have a look at my new code " area_mod.il" and suggest me........

    ************************************ area_mod.il**************************************

     div_fac = 1f

     procedure( area_mod(inst)

     if(inst~>cellName == "pmos2v" then
                w1 = cdfParseFloatString(dbGetq(inst "w") )
                l1 = cdfParseFloatString(dbGetq(inst "l") )
                m1 = evalstring(dbGetq(inst "m"))    
                f1 = evalstring(dbGetq(inst "fingers"))  

               wp = w1 + 1.4u

               lp = f1*l1 + (f1-1)*0.36u + 2u

               AREA = wp*lp

    else

           if(inst~>cellName == "nmos2v" then
                w1 = cdfParseFloatString(dbGetq(inst "w") )
                l1 = cdfParseFloatString(dbGetq(inst "l") )
                m1 = evalstring(dbGetq(inst "m"))    
                f1 = evalstring(dbGetq(inst "fingers"))  

               wn = w1 + 0.6u

               ln = f1*l1 + (f1-1)*0.36u +1.12u

               AREA = wn*ln

    else

               if(inst~>cellName == "resnsppoly" then

               w1 = cdfParseFloatString(dbGetq(inst "segW") )
                l1 = cdfParseFloatString(dbGetq(inst "segL") )
                m1 = evalstring(dbGetq(inst "segments"))
                
                wr = m1*w1 + (m1-1)*0.6u + 0.56u

                lr = l1 + 1.12u

               AREA = wr*lr

    else

                if( inst~>cellName == "mimcap" then
                c1 = cdfParseFloatString(dbGetq(inst "c"))
                m1 = evalstring(dbGetq(inst "m"))
                
                areac = m1*c1
                AREA = areac/div_fac

    ) ) ) )

    AREA

    );procedure

     procedure(PKsumArea(@optional (cv geGetEditCellView()))
          foreach(inst cv~>instances
          if(inst~>libName=="gpdk090" then
            totalArea=totalArea+area_mod(inst)

    ;;;;shall I write 'dbCreateRect(.....) statement here.....for the toplevel transistors/res/caps

          else

            when(inst~>purpose=="cell"
             master=dbOpenCellViewByType(inst~>libName inst~>cellName "schematic")
             when(maste          

            println(master~>cellName)

            PKsumArea(master)

            ;;;;shall I write 'dbCreateRect(.....) statement here.....for the toplevel blocks (after calculating whole block area)
     

    ) ) ) )

    totalArea

    )

    PKsumArea()

    println(totalArea)

    ******************************************** end of area_mo.il************************************

    I have used ' cdfFofmatFloatString ' for the purpose of drawing rectangles (by formating every value to suffix "p" in other case it's giving errors).

     I hope you are understanding my problem...........

    I am very very sorry....if you feel inconvinence..

    Thanks & regards........

                        Prabhakar. K
     

     

        
     

    • 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