From 78050b1e5f48a34e000f40c89ad254ad6756b33c Mon Sep 17 00:00:00 2001
From: Matthias Koefferlein
See Netter#schematic for a description of that function.
Usage:
+See Netter#tolerance for a description of that function.
+"tolerance" - Specifies compare tolerances for certain device parameters
+
+
+
Usage:
++Specifies a compare tolerance for a specific parameter on a given device class. +The device class is the name of a device class in the extracted netlist. +Tolerances can be given in absolute units or relative or both. +The relative tolerance is given as a factor, so 0.1 is a 10% tolerance. +Absolute and relative tolerances add, so specifying both allows for a larger +deviation. +
diff --git a/src/lay/lay/doc/manual/lvs_compare.xml b/src/lay/lay/doc/manual/lvs_compare.xml index 01dd882fc..211e5aa8a 100644 --- a/src/lay/lay/doc/manual/lvs_compare.xml +++ b/src/lay/lay/doc/manual/lvs_compare.xml @@ -81,6 +81,77 @@same_device_classes("PMOS_IN_LAYOUT", "PMOS_IN_SCHEMATIC")
same_device_classes("NMOS_IN_LAYOUT", "NMOS_IN_SCHEMATIC")
+ + When comparing device parameters, by default strict equivalence is required. + However, when drawing a device like a resistor, it's usually difficult to match + the exact value unless the resistor calibration is consistent with drawing grids and + the resistor geometry is not confined by design rule constraints. + So sometimes the target value or a device parameter can only be approximated in + the layout. This will by default lead to a mismatch. +
+ ++ The solution is to specify parameter tolerances. Tolerances can be specified + in an absolute or relative fashion. If an absolute tolerance is given, the layout + parameter may deviate from the target value by this tolerance either to + lower or higher values. So the unit of the tolerance is the same than the + unit of the parameter. +
+ ++ If a relative tolerance is given, the deviation is + computed from the target value times the tolerance. So the relative tolerance + is a factor and a value of 0.05 for example specifies an allowed deviation of + plus or minus 5%. Relative tolerances are unit-less. +
+ ++ It's also possible to specify both an absolute and a relative tolerance. In this + case, both tolerances add and the allowed deviation becomes larger. +
+ ++ To specify an absolute tolerance, use the tolerance function: +
+ +tolerance("NMOS", "L", 0.05)
+
+ + The two arguments are the name of the device class and the name of the parameter + for which the tolerance will be applied. In the case above, a tolerance of 50nm (the + unit of L is micrometer) is applied to the length parameter of "NMOS" devices. +
+ ++ A relative tolerance is specified as an additonal forth parameter. You can set + the absolute tolerance to zero to specify only relative tolerances. This will + specify 1% tolerance for the "L" parameter of "NMOS" devices: +
+ +tolerance("NMOS", "L", 0.0, 0.01)
+
+ + There is also a more explicit notation for the tolerance: +
+ +tolerance("NMOS", "L", :absolute => 0.05)
+tolerance("NMOS", "L", :relative => 0.01)
+
+ + This notation is equivalent to the two forms above. +
+ ++ An absolute plus relative tolerance can be specified by giving both. + The following calls will give you 50nm absolute and 1% relative tolerance for the "L" + parameter of "NMOS" devices: +
+ +tolerance("NMOS", "L", 0.05, 0.01)
+tolerance("NMOS", "L", :absolute => 0.05, :relative => 0.01)
+
diff --git a/src/lvs/lvs/built-in-macros/_lvs_engine.rb b/src/lvs/lvs/built-in-macros/_lvs_engine.rb index f7b79467e..e1179f3a7 100644 --- a/src/lvs/lvs/built-in-macros/_lvs_engine.rb +++ b/src/lvs/lvs/built-in-macros/_lvs_engine.rb @@ -159,7 +159,7 @@ module LVS # @name tolerance # @brief Specifies compare tolerances for certain device parameters # @synopsis tolerance(device_class_name, parameter_name, absolute_tolerance [, relative_tolerance]) - # @synopsis tolerance(device_class_name, parameter_name [:absolute => absolute_tolerance,] [:relative => relative_tolerance,]) + # @synopsis tolerance(device_class_name, parameter_name [, :absolute => absolute_tolerance] [, :relative => relative_tolerance]) # See \Netter#tolerance for a description of that function. %w(schematic compare join_symmetric_nets tolerance align same_nets same_circuits same_device_classes equivalent_pins min_caps max_res max_depth max_branch_complexity).each do |f| diff --git a/src/lvs/lvs/built-in-macros/_lvs_netter.rb b/src/lvs/lvs/built-in-macros/_lvs_netter.rb index 309d22ae5..ae27f99ea 100644 --- a/src/lvs/lvs/built-in-macros/_lvs_netter.rb +++ b/src/lvs/lvs/built-in-macros/_lvs_netter.rb @@ -102,7 +102,7 @@ module LVS # @name tolerance # @brief Specifies compare tolerances for certain device parameters # @synopsis tolerance(device_class_name, parameter_name, absolute_tolerance [, relative_tolerance]) - # @synopsis tolerance(device_class_name, parameter_name [:absolute => absolute_tolerance,] [:relative => relative_tolerance,]) + # @synopsis tolerance(device_class_name, parameter_name [, :absolute => absolute_tolerance] [, :relative => relative_tolerance]) # Specifies a compare tolerance for a specific parameter on a given device class. # The device class is the name of a device class in the extracted netlist. # Tolerances can be given in absolute units or relative or both.