| # frozen_string_literal: true |
| |
| ################################################################################################ |
| # 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. |
| ################################################################################################ |
| |
| #================================== |
| # ------ GENERAL DERIVATIONS ------ |
| #================================== |
| |
| ncomp = comp.and(nplus) |
| pcomp = comp.and(pplus) |
| tgate = poly2.and(comp).not(res_mk) |
| |
| ncomp_lv = ncomp.not(dualgate2_d) |
| ncomp_mv = ncomp.and(dualgate2_d) |
| |
| pcomp_lv = pcomp.not(dualgate2_d) |
| pcomp_mv = pcomp.and(dualgate2_d) |
| |
| ngate = nplus.and(tgate) |
| nsd = ncomp.outside(nwell).interacting(ngate).not(ngate).not(res_mk) |
| ptap = pcomp.outside(nwell).outside(dnwell).not(res_mk) |
| |
| ptap_lv = ptap.not(dualgate2_d) |
| ptap_mv = ptap.and(dualgate2_d) |
| |
| pgate = pplus.and(tgate) |
| psd = pcomp.inside(nwell).interacting(pgate).not(pgate).not(res_mk) |
| ntap = ncomp.inside(nwell).not(res_mk) |
| |
| ngate_dw = ngate.and(lvpwell).and(dnwell) |
| ptap_dw = pcomp.inside(lvpwell).inside(dnwell).outside(well_diode_mk).not(res_mk) |
| |
| pgate_dw = pgate.inside(dnwell).outside(lvpwell) |
| ntap_dw = ncomp.outside(lvpwell).inside(dnwell).not(res_mk) |
| |
| psd_dw = pcomp.not(lvpwell).and(dnwell).interacting(pgate).not(pgate).not(res_mk) |
| nwell_con = nwell.not(res_mk) |
| lvpwell_con = lvpwell.not(res_mk) |
| poly2_con = poly2.not(res_mk).not(plfuse) |
| |
| metal2_ncap = metal2.not(cap_mk).not(mom_m2_mk) |
| metal3_ncap = metal3.not(cap_mk).not(mom_m3_mk) |
| metal4_ncap = metal4.not(cap_mk).not(mom_m4_mk) |
| metal5_ncap = metal5.not(cap_mk).not(mom_m5_mk) |