Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DRC: Extent marks layout as dirty/modified #1924

Open
akrinke opened this issue Nov 15, 2024 · 2 comments
Open

DRC: Extent marks layout as dirty/modified #1924

akrinke opened this issue Nov 15, 2024 · 2 comments

Comments

@akrinke
Copy link

akrinke commented Nov 15, 2024

Calling extent marks the layout as modified, although nothing should have changed.

Steps to reproduce: Load layout and run the following DRC script.

Checked with version 0.29.7.

active_layout = RBA::CellView::active.layout
active_cellname = RBA::CellView::active.cell_name
source(active_layout, active_cellname)
a = extent()
@klayoutmatthias
Copy link
Collaborator

Ah, well ...

Actually, "extent" creates a temporary layer. That layer is deleted at the end of the script, but it will render the layout modified.

The reasoning is that with a cell filter, the generated layer will be made from the bounding boxes of the cells, where these are stored directly inside the cell. This enables interoperability with all the other features, like clipping, cell filtering etc.

For a plain top-level box (simple "extent") that would not be required. Still it is implemented in the same way - for example to properly support clipping.

If you need a plain bounding box and don't use clipping for example, you can use that substitute which does not set the modified flag:

def readonly_extent
  DRC::DRCLayer::new(self, RBA::Region::new(source.cell_obj.bbox))
end

Matthias

@akrinke
Copy link
Author

akrinke commented Nov 18, 2024

Thanks for the explanation and the alternative! Since I'm only interested in the bounding box, it should work for me.

It was just unexpected that a DRC command apparently changes the layout.

Andreas

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants