Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
AMS.pdf
Скачиваний:
70
Добавлен:
05.06.2015
Размер:
2.68 Mб
Скачать

Virtuoso AMS Environment User Guide

Producing Customized Netlists

Data Objects Supported for Netlisting

The data used for netlisting is organized into objects. The AMS netlister objects include netlister, formatter, cellview, parameter, and instance. Each of these is described in detail in the following sections.

Netlister Object

The netlister object contains the global options applicable to the AMS netlister. You obtain the

ID of the netlister object by calling the amsGetNetlister function, with a command like

A_netlisterId = amsGetNetlister()

The netlister object is available throughout the life of the UNIX process that is running the AMS netlister and is a unique object for that process. The netlister object ID does not change as long as the process remains the same. However, the values of the fields of the netlister object can change with every netlist run as the netlister rereads the ams.env file.

Running a command like

A_netlisterId->?

you find that the netlister object contains the following fields. With the exception of thevlog and vhdl fields, each field corresponds to anams.env variable described in Appendix A, “Variables for ams.env Files.”

Field

Values

Corresponding ams.env

Variable

 

 

 

 

 

lsbMsb

boolean t/nil

amsLSB_MSB

scalarizeInstances

boolean t/nil

amsScalarInstances

includeInstCDFParams

boolean t/nil

includeInstCdfParams

excludeParams

l_params

amsExcludeParams

expScalingFactor

‘no | ‘sci | ‘dec

amsExpScalingFactor

modifyParamScope

‘no | ‘warn | ‘yes

modifyParamScope

vlog

The ID of the

 

 

Verilog-AMS formatter

 

 

object.

 

vhdl

Always nil. No VHDL

 

 

formatter is supported.

 

 

 

 

April 2004

327

Product Version 5.3

Virtuoso AMS Environment User Guide

Producing Customized Netlists

All of these fields are read-only. Attempting to change their values results in an error.

When you add new data to the database, be sure that the data adhere to the format and content requirements set by the values of these fields.

Formatter Object

The formatter object contains information about the netlist procedures for the formatter it represents. You use a command like the following to obtain the ID of the formatter:

A_formatterId = A_netlisterId->vlog

In this release, the only available formatter is the Verilog-AMS (vlog) formatter.

The formatter object is created when the vlog field of the netlister object is accessed for the first time. After that, the formatter object is available throughout the life of the UNIX process that is running the AMS netlister and is a unique object for that process. The formatter object ID does not change as long as the process remains the same. However, the values of the

fields of the formatter object can change with every netlist run as the netlister rereads the ams.env file.

Running the command

A_formatterId->?

you find that the formatter object contains the fields listed in the next two tables. Some of the fields correspond toams.env variables described in Appendix A, “Variables for ams.env Files.”

Table 13-2 Fields of the Formatter Object

Field

Values

Corresponding ams.env

Variable

 

 

 

 

 

comments

string

None

headers

string

None

ifdefLanguageExtensions

boolean t/nil

ifdefLanguageExtensions

useDefparam

boolean t/nil

useDefparam

includeFiles

l_strings

includeFiles

paramDefVals

l_paramValPairs

paramDefVals

paramGlobalDefVal

paramGlobalDefVal

paramGlobalDefVal

netlister

A_netlisterId

None.

 

 

 

April 2004

328

Product Version 5.3

Virtuoso AMS Environment User Guide

Producing Customized Netlists

All of these fields are read-only. Attempting to change their values results in an error.

The formatter object also lists the netlisting procedures that are in effect. The sections of the netlist that each procedure is responsible for generating are listed in the right column. The entries in that column are the same as the labels shown in Figure 13-1 on page 301.

Table 13-3 Netlisting Procedures Listed in the Formatter Object

Field

Value

Netlist Section

 

 

 

commentsProc

amsPrintComments or current

Comment

 

override procedure

 

headersProc

amsPrintHeaders or current

Header

 

override procedure

 

moduleProc

amsPrintModule

All sections except:

 

 

Comment, Header,

 

 

Includes list, Footer

footersProc

amsPrintFooters

Footer (not shown)

moduleNameProc

amsPrintModuleName

Mapped name

portsProc

amsPrintPorts

Port declarations

iosProc

amsPrintIOs

Port declarations

parametersProc

amsPrintParameters or current

Parameter declarations

 

override procedure

 

wiresProc

amsPrintWires

Signal declarations

aliasesProc

amsPrintAliases

Alias list (not shown)

instanceProc

amsPrintInstance or current

Instances

 

override procedure

 

instanceMasterNameProc

amsPrintInstanceMasterName

Instance master

 

or current override procedure

 

instanceParametersProc

amsPrintInstanceParameters

Instance parameters

 

or current override procedure

 

instancePortsProc

amsPrintInstancePorts or

Instance connections

 

current override procedure

 

attributesProc

amsPrintAttributes or current

Attributes

 

override procedure

 

 

 

 

April 2004

329

Product Version 5.3

Virtuoso AMS Environment User Guide

Producing Customized Netlists

Cellview Object

The cellview object contains fields that characterize a cellview.

The cellview object is created when netlisting begins for the cellview and is destroyed when netlisting ends. As a consequence, to view the fields you need to ask for the information during the netlisting run. You might, for example, use statements like the following in your netlisting procedures override file to obtain a list of the fields.

;; Define a print comments functions (defun MyProc (formatter cellview )

(printf "Var = %L\n" cellview->??)

)

Running these statements, you find that the cellview object contains the following fields. Notice that some of these fields return information that is collected indirectly, and is therefore more costly in terms of processing time and memory. For efficient netlisting, try to use such indirectly collected information sparingly.

Field

Values

Meaning of the Value

 

 

 

libName

string

Name of the library.

cellName

string

Name of the cell.

viewName

string

Name of the cellview.

ID

DB???

ID of the cellView

primitive

boolean t/nil

Whether the master is a Spectre primitive.

 

 

(Ports must be printed by order for

 

 

instances of primitives.)

compName

string

componentName field from the simInfo.

termOrder

l_strings

List of terminals for the component. (The

 

 

list can change for each instance.)

ports

l_ports

Not yet supported. Always returns nil.

parameters

l_parameters

Collected indirectly. The parameters of the

 

 

cellview.

 

 

 

All of these fields are read-only, so attempting to change their values results in an error.

April 2004

330

Product Version 5.3

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]