• 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. cell list excluding few devices from one category

Stats

  • Locked Locked
  • Replies 7
  • Subscribers 144
  • Views 14910
  • 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

cell list excluding few devices from one category

sjeur
sjeur over 5 years ago

Hello 

I am using list~>cells ~>name to get the cell list.This cell list gives the whole list of cells coming from one library. I would like to exclude few cells coming from category in this library.How to get the cell list with specific categories or by excluding specific category cells. 

Thanks 

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

    You'll need to use the ddCat* functions - for example, ddCatOpen or ddCatFindCat, then ddCatGetCatMembers, and ddCatClose to close it.

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • sjeur
    sjeur over 5 years ago in reply to Andrew Beckett

    Hello Andrew , Thanks for the reply. I have two list 

    first , List1=lib ~>cells~>name

    second,  coming from the category which i would like to exclude   List2=mapcar('car ddCatGetCatMembers( catId) )

    I  have already tried using remd  to exclude List2 from List1. I am not sure if it is the right approach to do it. 

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 5 years ago in reply to sjeur

    The simple solution would be to do:

    List3=setof(cell List1 !member(cell List2))

    There's a potential risk of performance if the number of cells in List2 is very large. If it is, you could do:

    catMembers=makeTable('catMembers nil)
    foreach(cell List2 catMembers[cell]=t)
    List3=setof(cell List1 !catMembers[cell])

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 5 years ago in reply to sjeur

    The simple solution would be to do:

    List3=setof(cell List1 !member(cell List2))

    There's a potential risk of performance if the number of cells in List2 is very large. If it is, you could do:

    catMembers=makeTable('catMembers nil)
    foreach(cell List2 catMembers[cell]=t)
    List3=setof(cell List1 !catMembers[cell])

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • sjeur
    sjeur over 5 years ago in reply to Andrew Beckett

    Thank you.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Sheppie
    Sheppie over 5 years ago in reply to Andrew Beckett

    Hi Andrew,

    Normally when I want to know the differences between two lists, I use something similar to the first setof() line. I do this for long lists (thousands of cells, and also disembodied property lists)  as well. What kind of performance risk are you talking about? It might just take a fraction of a second longer, or is it about memory usage?

    I have implemented your second solution at one location and, of course, it works as advertised.

    Thanks in advance.

    Kind regards,

    Sjoerd

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 5 years ago in reply to Sheppie

    Hi Sjoerd,

    The main issue is that this potentially takes M*N list cell hops (M is the length of the list in the setoff, N is the length of the list that you are checking membership of). If N is long, that's potentially a lot of sequential list cell accesses. If you use an association table instead, the key is hashed which reduces the searching significantly and the cost is closer to kM (where k is a constant).

    Essentially this is trying to avoid O(N^2) problems - but this won't be apparent unless N is very big. I did a test with both N and M around 45,000 where I carefully picked that all entries in the setof list are not in the other list, and it took 24 seconds. With the table approach is was less than 1 second (a lot less than 1 second).

    Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Sheppie
    Sheppie over 5 years ago in reply to Andrew Beckett

    Hi Andrew,

    Thanks for your detailed explanation.

    In the case where either M or N is the largest, it is not even close to the 45000 you've tested, so that's probably the reason I haven't run into long waiting times. As a test I modified the code for that particular instance to have your suggested implementation (with a table) and I saw a modest improvement. I'll definitely use this in the future, even if it wouldn't yield any significant improvement, just as a matter of writing efficient code.

    Kind regards,

    Sjoerd

    • 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