• 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. Blogs
  2. Analog/Custom Design
  3. Spectre Tech Tips: Spectre APS Save Overview - Part 2
Stefan Wuensche
Stefan Wuensche

Community Member

Blog Activity
Options
  • Subscribe by email
  • More
  • Cancel
CDNS - RequestDemo

Have a question? Need more information?

Contact Us
save statement
spectre aps
device terminal naming
subcktiprobes
device terminal calculation
ports
filter
time_window
exclude
depth
useprobes
subcktprobelvl
useterms
subckt
subcircuit terminal current calculation

Spectre Tech Tips: Spectre APS Save Overview - Part 2

28 Jun 2019 • 6 minute read

 As an analog/mixed-signal designer, verification engineer, or CAD expert, you use Spectre® APS for analyzing your designs. Saving node voltages, element, and subcircuit port currents and power is an essential part when simulating your designs. Over the years, incremental additions to the Spectre waveform writing functionality have made it more complex.

In the previous blog, Spectre Tech Tips: Spectre APS Save Overview - Part 1, we learned that in SPECTRE17.1 ISR15 and SPECTRE18.1 ISR7 releases, the save options have been consolidated, obsolete options have been eliminated, and the related documentation has been cleaned up in spectre -h. In addition, we reviewed the following important options related to waveform writing: save, nestlvl, currents, subcktprobelvl, and pwr.

In this blog, we'll discuss advanced save features, subcircuit and device terminal current calculation, and index versus name saving in global waveform writing statements.

Advanced Save Features

Spectre supports the following advanced features for saving a waveform:

  • You can use the time_window option with the save statement to save a waveform within a user-defined time window. This enables you to reduce the waveform file size if only a portion of the full simulation time is of interest to you. For example:
    save I1.net5 time_window=[5u 10u]
  • You can use the depth option with the save statement to limit waveform writing to user-specified hierarchy levels. For example, the following save statement will save the voltage waveforms for the top level and one level below.
    save * depth=2  
  • You can use the exclude option to exclude nets from being saved, based on pattern matching. For example:
    save * exclude=[*bl* *bbl*]
  • Use the filter=rc option with the save statement to exclude nets that only connect to R and C elements. For example, the following save statement will save all node voltages except the nodes that connect only to R and C elements.
    save * filter=rc

This can also be enabled for all save statements with the savefilter=rc option.

  • Use the subckt option with the save statement to save the node voltages inside a subcircuit instance, except subcircuit ports. For example, the following save statement will save all node voltages inside the subcircuit instance pll, except subcircuit ports.
    save * subckt=pll
  • Use the ports option along with the subckt option to additionally save the subcircuit port voltage waveforms, as shown in the example below.
    save * subckt=pll ports=yes

This can also be defined globally for all subcircuit-based save statements with the saveports=yes option.

The advanced features discussed above can also be combined with one another. For example:

save * subckt=inverter22 ports=yes depth=2 exclude=[*ut]

The above statement will save all nodes inside subcircuit inverter22 and all child subcircuits one level below. It will include the subcircuit ports for these subcircuits and exclude any net which matches the pattern *ut.

Subcircuit Terminal Current Calculation

Spectre provides two methods for calculating subcircuit terminal currents. Both have their values.

  • Method 1 includes inserting a special iprobe element at the subcircuit terminal and collecting the current from the iprobe element.
  • Method 2 includes calculating the subcircuit current by summing up the currents from all elements connecting to the subcircuit port.

While inserting iprobes is the most accurate method, it may significantly increase the size of the matrix, and therefore, decrease the performance for a large number of subcircuit port currents being saved. Summing up the element currents does not increase the matrix; however, it may introduce rounding errors during calculation. In addition, summing may degrade performance when one port, for example, a VDD, is connected to thousands or millions of elements.

The Spectre subcktiprobes option defines which of the above methods is used when calculating subcircuit port currents. For example:

opt8 option subcktiprobes=all

The subcktiprobes option accepts the following possible values:

  • subcktiprobes=save, which is the default behavior in Spectre APS, inserts iprobes for individual save statements (that is save I1:1). However it sums up the currents for subcircuit port currents saved with the subcktprobelvl option (for example subcktproblvl=1).
  • subcktiprobes=all inserts iprobes for individual save statements and subcktprobelvl.
  • subcktiprobes=no does not insert any iprobe for subcircuit current saving.

We recommend that you use the Spectre APS default setting. However, if you experience extreme slowness because of the subckprobelvl option, you may improve the performance by saving the port currents for the power supply nodes individually. For example:

save I0:VDD I0:GND

The above save statement will insert iprobes for the current measurement of I0:VDD and I0:GND instead of summing up the large numbers of currents which is used then I0:VDD and I0:GND are saved with the subcktprobelvl option.

Element/Device Terminal Current Calculation

When saving element or device terminal currents, the current is typically taken from element calculation, and therefore, an iprobe insertion isn’t required. However, there may be devices which don’t calculate the current, or there may be a need for inserting an iprobe for getting better current accuracy. The useprobes option allows you to add iprobes for element and device terminal current measurements. For example:

opt9 options useprobes=yes

useprobes=no, which is the default behavior in Spectre APS, gets the terminal currents from the individual element.

useprobes=yes is required in special cases when devices don’t provide the current, or, if the default method doesn’t provide the required accuracy.

Subcircuit and Device Terminal Naming

Subcircuit and device terminal names can either be referenced by their name, that is, I1:vdd, or by their index, that is, I1:1. However, when global statements are used for element terminal current saving (currents=all), or for subcircuit terminal currents (subcktprobelvl=5), Spectre needs to decide whether to print the terminal name or the terminal index. You can use the useterms option to specify whether terminal name or index needs to be used when using the global save statements.

opt9 options useterms=name

useterms=default,  which is the default behavior in Spectre APS, uses the terminal name for element currents, and the terminal index for subcircuit terminals.

useterms=name uses the terminal name for both

useterms=index uses index for both

Summary

In the two save overview blogs, we reviewed the following important options related to waveform writing: save, nestlvl, currents, subcktprobelvl, pwr, subckiprobes, useprobes, useterms, savefilter, and saveports, and the following advanced save features: time_window, depth, exclude, filter, subckt, ports. Their spectre -h documentation is updated in Spectre 17.1 ISR15 and Spectre 18.1 ISR7. If you see any other save-related options apart from the ones listed above, these options are obsolete and replaced by the discussed options.

This blog doesn’t discuss the inline subcircuit-related saving options, waveform compression, and element/node preservation. These topics may be discussed in the upcoming blogs.

We recommend that you always save the waveforms that are needed for your analysis, and refrain from saving everything. Especially, the currents=all and the subcktproblvl=n options introduce significant simulation overhead and may degrade your simulation performance significantly.

Related Resources

  • Spectre Classic Simulator, Spectre Accelerated Parallel Simulator (APS), and Spectre Extensive Partitioning Simulator (XPS) User Guide
  • Getting the most out of Spectre APS

You may also contact your Cadence support AE for guidance.

For more information on Cadence products and services, visit www.cadence.com.

About Spectre Tech Tips

Spectre Tech Tips is a blog series aimed at exploring the capabilities and potential of Spectre®. In addition to providing insight into the useful features and enhancements in Spectre, this series broadcasts the voice of different bloggers and experts, who share their knowledge and experience on all things related to Spectre. Enter your email address in the Subscriptions box and click SUBSCRIBE NOW to receive notifications about our latest Spectre Tech Tips posts.


CDNS - RequestDemo

Try Cadence Software for your next design!

Free Trials

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information