| ################################################################################################ |
| # Copyright 2022 GlobalFoundries PDK Authors |
| # |
| # Licensed under the Apache License, Version 2.0 (the 'License'); |
| # you may not use this file except in compliance with the License. |
| # You may obtain a copy of the License at |
| # |
| # https://www.apache.org/licenses/LICENSE-2.0 |
| # |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an 'AS IS' BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| ################################################################################################ |
| |
| if BEOL |
| |
| if METAL_LEVEL == '4LM' || METAL_LEVEL == '5LM' || METAL_LEVEL == '6LM' |
| #==================================================== |
| #----------------- Metal4 Slotting ------------------ |
| #==================================================== |
| |
| # Rule MSLOT.1_M4 : Maximum metal4 width without slotting ((Exclude Top Metal layer overlapping with TANRES_MK)) |
| logger.info('Executing rule MSLOT.1_M4') |
| mslot1_m4 = metal4.not(metal4.width(30.001.um).polygons(0.001)).not_interacting(metal4_slot).not(top_metal.interacting(tanres_mk)) |
| mslot1_m4.output('MSLOT.1_M4','MSLOT.1_M4 : Maximum metal4 width without slotting ((Exclude Top Metal layer overlapping with TANRES_MK))') |
| mslot1_m4.forget |
| |
| # Rule MSLOT.2_M4 : Minimum metal4 slot width (slot layers) |
| logger.info('Executing rule MSLOT.2_M4') |
| mslot2_m4 = metal4_slot.width(2.0.um).polygons(0.001) |
| mslot2_m4.output('MSLOT.2_M4','MSLOT.2_M4 : Minimum metal4 slot width (slot layers)') |
| mslot2_m4.forget |
| |
| # Rule MSLOT.3a_M4 : Minimum metal4 Slot length (slot mark layers) |
| logger.info('Executing rule MSLOT.3a_M4') |
| mslot3a_m4 = metal4_slot.with_bbox_max(nil,10.um) |
| mslot3a_m4.output('MSLOT.3a_M4','MSLOT.3a_M4 : Minimum metal4 Slot length (slot mark layers) ') |
| mslot3a_m4.forget |
| |
| # Rule MSLOT.3b_M4 : Maximum metal4 Slot length (slot mark layers) is 250 um |
| logger.info('Executing rule MSLOT.3b_M4') |
| mslot3b_m4 = metal4_slot.with_bbox_max(250.001,nil) |
| mslot3b_m4.output('MSLOT.3b_M4','MSLOT.3b_M4 : Maximum Slot length (slot mark layers) is 250 um') |
| mslot3b_m4.forget |
| |
| # Rule MSLOT.4a_M4 : Minimum metal4 Slot space (slot mark layers) is 10 um |
| logger.info('Executing rule MSLOT.4a_M4') |
| mslot4a_m4 = metal4_slot.space(10.um).polygons(0.001) |
| mslot4a_m4.output('MSLOT.4a_M4','MSLOT.4a_M4 : Minimum metal4 Slot space (slot mark layers) is 10 um') |
| mslot4a_m4.forget |
| |
| if metal4_slot.count() > 1 |
| # Rule MSLOT.4b_M4 : Maximum metal4 Slot space (slot mark layers) is 30 um |
| logger.info('Executing rule MSLOT.4b_M4') |
| mslot4b_m4 = metal4_slot.not_interacting(metal4_slot.space(30.001.um).polygons(0.001)) |
| mslot4b_m4.output('MSLOT.4b_M4','MSLOT.4b_M4 : Maximum metal4 Slot space (slot mark layers) is 30µm') |
| mslot4b_m4.forget |
| end |
| |
| # Rule MSLOT.5_M4 : Minimum metal4 slot (slot mark layers) to metal4 edge spacing is 10 um |
| logger.info('Executing rule MSLOT.5_M4') |
| mslot5_m4_l1 = metal4.enclosing(metal4_slot,10.0.um).polygons(0.001) |
| mslot5_m4_l2 = metal4_slot.not_inside(metal4) |
| mslot5_m4 = mslot5_m4_l1.or(mslot5_m4_l2) |
| mslot5_m4.output('MSLOT.5_M4','MSLOT.5_M4 : Minimum metal4 slot (slot mark layers) to metal4 edge spacing is 10 um') |
| mslot5_m4_l1.forget |
| mslot5_m4_l2.forget |
| mslot5_m4.forget |
| |
| if METAL_LEVEL == '5LM' || METAL_LEVEL == '6LM' |
| # Rule MSLOT.7_M4 : Minimum space from via4 to metal4 slot is 0.2 um |
| logger.info('Executing rule MSLOT.7_M4') |
| mslot7_m4 = via4.separation(metal4_slot,0.2.um).polygons(0.001).or(via4.not_outside(metal4_slot)) |
| mslot7_m4.output('MSLOT.7_M4','MSLOT.7_M4 : Minimum space from via4 to metal4 slot is 0.2 um') |
| mslot7_m4.forget |
| end #METAL_LEVEL |
| |
| # Rule MSLOT.8_M4 : Minimum space from via3 to metal4 slot is 0.2 um |
| logger.info('Executing rule MSLOT.8_M4') |
| mslot8_m4 = via3.separation(metal4_slot,0.2.um).polygons(0.001).or(via3.not_outside(metal4_slot)) |
| mslot8_m4.output('MSLOT.8_M4','MSLOT.8_M4 : Minimum space from via3 to metal4 slot is 0.2 um') |
| mslot8_m4.forget |
| |
| # Rule MSLOT.10_M4 : Slot mark layer (metal4 slot) on the metal4 hole are not allowed |
| logger.info('Executing rule MSLOT.10_M4') |
| mslot10_m4 = metal4_slot.interacting(metal4.holes) |
| mslot10_m4.output('MSLOT.10_M4','MSLOT.10_M4 : Slot mark layer (metal4 slot) on the metal4 hole are not allowed') |
| mslot10_m4.forget |
| end #METAL_LEVEL |
| |
| end #BEOL |