JP2692813B2 - Scan circuit conversion method - Google Patents

Scan circuit conversion method

Info

Publication number
JP2692813B2
JP2692813B2 JP62237329A JP23732987A JP2692813B2 JP 2692813 B2 JP2692813 B2 JP 2692813B2 JP 62237329 A JP62237329 A JP 62237329A JP 23732987 A JP23732987 A JP 23732987A JP 2692813 B2 JP2692813 B2 JP 2692813B2
Authority
JP
Japan
Prior art keywords
scan
module
circuit
conversion
name
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP62237329A
Other languages
Japanese (ja)
Other versions
JPS6480883A (en
Inventor
宏晃 西
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP62237329A priority Critical patent/JP2692813B2/en
Publication of JPS6480883A publication Critical patent/JPS6480883A/en
Application granted granted Critical
Publication of JP2692813B2 publication Critical patent/JP2692813B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Tests Of Electronic Circuits (AREA)
  • Test And Diagnosis Of Digital Computers (AREA)

Description

【発明の詳細な説明】 〔発明の目的〕 (産業上の利用分野) この発明は複数のゲートや記憶素子からなるデジタル
論理回路を、テスト容易なデジタル論理回路に自動変換
する方式に関する。 (従来の技術) 大規模な論理回路の検査性向上のために、通常のフリ
ップ・フロップ(以下F/Fと記す)やラッチの代わり
に、予めスキャン可能なF/Fやラッチを用い、各F/F間や
ラッチ間をスキャンパスで接続し、順序回路を該F/Fや
ラッチからなるシフトレジスタ列と、組合わせ回路に分
割できるスキャン設計法が使用されている。(上記スキ
ャンイン・アウト可能な回路構成としては、例えば特公
昭57−3107である。) 但し、論理回路設計者は、上記スキャン設計を行なう
に当って守らなければならない規則があり、論理設計自
体に厳しい制約が課されている。 例えば、スキャン用F/Fにマスター・スレーブ型のも
のを使用したときに、以下のスキャン設計ルールが存在
する。 論理回路内の記憶素子(F/Fやラッチ)以外に、ゲ
ートのみからなるループ回路は存在してはならない。 スキャン用F/Fに印加されるシステムクロックは、
全体回路の外からon,off可能でなければならない。 システムロック同士のANDゲートを取ってはならな
い。(クロックは、全体回路内部で発生してはならな
い。) 非同期なクロック、クリア、プリセット信号は許さ
ない。 よって、上記規則を守るとすると、論理設計に要する
時間が増大する。また、この様な規則が守られていない
大規模な論理回路を、スキャン可能な論理回路に人手で
変換するには多大な労力を必要とすると共に、人為的な
ミスが発生する恐れがある。 一方最近では、例えば情報処理学会、第31回全国大会
予稿集P.1661の「検査容易化設計の自動化の一方式」に
みられる様に、通常の論理回路を自動的に検査容易な論
理回路に変換する方法も存在する。 この方法ではスキャン情報の作成と、スキャン機能の
付加からなり、スキャン機能の付加としては、(1)F/
Fのスキャン機能付F/Fへの置換、(2)スキャン用外部
ピンの周辺回路の生成、(3)スキャン・アドレス・デ
コーダ等のスキャン用回路の付加を機械的に行なってい
る。但し、階層化設計されている論理回路に関して、該
階層を活かしてスキャン化回路変換はされていない。 他方、テスト容易化回路の付加された論理回路の設計
作業を支援するシステムに関しては、特開昭60−27985
が知られているが、回路の付加は回路図のパターン情報
を介して行なわれ論理回路接続言語をコンパイルして作
成したオブジェクト形式を介しては行なわれていない。 (発明が解決しようとする問題点) 上記従来技術では、予め論理設計者が、スキャン設計
ルールを守って論理設計する必要があり、該スキャン設
計ルールによって論理設計の自由度が低下し、所望の論
理回路を設計するのに、余計な時間を要するという弊害
があった。 また、論理回路内のF/F数の増加に伴なって、アドレ
ススキャン方式で用いられる、大きなアドレス・デコー
ダ回路等、付加回路が大規模になるという不都合も存在
する。 本発明の目的は、上記不具合を除去するために、非ス
キャン化回路を、最小限の回路の付加を持って自動的に
スキャン可能な回路に変換する方法を提供することであ
る。 〔発明の構成〕 (問題点を解決するための手段) 既に、階層的にモジュール単位に論理設計された、論
理接続記述をコンパイルしたオブジェクト形式のデータ
を、階層的に管理記憶するデータベースと、スキャン化
回路変換情報格納部と、スキャン設計ルール違反情報格
納部と、スキャン化回路自動変換部からなり、該スキャ
ン化回路自動変換部は、該スキャン化回路自動変換情報
と、該スキャン設計ルールに違反している論理回路のモ
ジュールの情報を読み出し、また、上記データベースか
ら階層モジュール名と該階層モジュール内の下位モジュ
ールタイプ名とモジュール識別名を読み出し、該階層モ
ジュール名が被スキャン化回路変換モジュールか否かを
判定し、そうである場合は該当モジュールのデータのみ
を該データベースより読み出し、スキャン化を行ない、
再びスキャン化回路変換後のモジュールのデータを該デ
ータベースに書き込むことが可能であるのが本発明の特
徴である。 (作 用) 階層的に論理設計された論理接続記述をコンパイルし
た結果は、階層的にデータベースに格納されているため
容易に、階層毎にオブジェクト形式として取り出せ、ま
た、スキャン回路の自動変換に適した情報テーブルを作
成し、該情報テーブル上で、データの挿入、置換を行な
い自動変換を行なうため高速に処理ができる。 さらに、スキャン回路自動変換を施した後、該スキャ
ン回路自動変換を行なったモジュールのデータのみをデ
ータベースに書き込むことによって、該データベースを
介して他のシステム(例えば、レイアウト論理シミュレ
ータ、テスト発生システム)とのインターフェースが可
能となる。 (実施例) 第1図に、本発明の構成を説明する図を示す。101
は、論理回路の接続関係を記述した言語で、論理回路を
トップ・ダウンもしくはボトム・アップに設計可能な様
に、階層的にモジュール単位に記述されている。102は
該言語記述のコンパイラで、103は論理接続関係の情報
等が格納されているデータベースである。104は、101の
論理接続記述の構成要素であるセルの情報を格納してい
るセルライブラリデータベースである。105は論理接続
情報データベース(103)とセルライブラリデータベー
ス(104)をリンク、及び階層設定されたデータの展開
処理を行なうリンカーで、106は階層展開後のデータが
格納されているデータベースである。107はスキャン設
計ルールチェックシステムで、108は論理シミュレー
タ、109はテスト発生システムで、110はレイアウトシス
テムを示し、階層展開情報データを入力としている。 120は、本発明の構成を示す部分で、121はスキャン化
回路変換情報で、122はスキャン化回路自動変換システ
ムで、123はユーザーが指定可能なスキャン化回路変換
コマンドで、124はスキャン設計ルール違反情報であ
る。該スキャン設計ルール違反情報は、107のスキャン
設計ルールチェックシステムの出力になっている。矢印
はデータの流れを示し、論理接続情報データベース(10
3)とスキャン回路自動変換システム(122)の間に印さ
れた双方向の矢印は、スキャン化回路自動変換システム
が、論理接続情報データベースより、必要な情報を読み
出し、スキャン化回路自動変換を行ない、再び論理接続
情報データベースに書込みが可能なことを示している。 上記データベースに書込み可能なことによって、スキ
ャン化回路自動変換後の回路情報を使用して論理シミュ
レーション、テスト発生、レイアウトができるという特
長がある。またスキャン設計ルールチェックシステム
(107)を介して閉じたシステムになっているため、ス
キャン化回路自動変換の結果を再度チェックすることも
可能である。 第2図に、第1図の120で示したスキャン化回路自動
変換の処理フローを示す。201と211は端子で、202〜20
5,と208〜210は処理を、206と207は判定を示している。
まず処理を開始する(201)。ユーザー指定のスキャン
化回路変換コマンドを読み込む(202)。該情報はユー
ザが指定し、既にルール化されているスキャン化回路変
換情報に優先され、通常のF/Fを如何なるスキャンF/Fに
置換するかとか、モジュール間のスキャンパスを如何な
る順番で接続するかとか、どのモジュールに如何なるタ
イプのモジュール名(スキャンクロックの外部、内部の
バッファ等のタイプ名)を挿入するかを指定する。 次にスキャン化回路変換情報を読み込む(203)。こ
こでは、上記ユーザ指定のスキャン化回路変換情報と同
様に、置換するF/Fのタイプ名、スキャンパスの接続の
順番、スキャン関係のデータ、クロック、モード信号等
の外部入出力バッファ等のタイプ名と、スキャン設計ル
ール違反の種類に対応する、スキャン可能な回路に変換
するための情報を読み込んでいる。 そして、スキャン設計ルール違反情報を読み込む(20
4)。詳細は後述する。次に論理接続情報データベース
より、モジュール名、下位モジュールタイプ名、モジュ
ール識別名を読み出す(205)。全てのモジュール名を
論理接続情報データベースより読み出したか否かを判定
し(206)、読み出した場合には209へ行く。さもなけれ
ば、上記の読み出したデータが、ユーザー指定のスキャ
ン化回路変換コマンド情報や、スキャン化回路変換情報
や、スキャン設計ルール違反情報内に格納されているモ
ジュール名、モジュールタイプ名、モジュール識別名に
等しいかを判別する(207)。否の場合は205へ戻り、等
しい場合は、該当するモジュールがスキャン化回路変換
が必要か否かを識別するタグを付ける。終了後205へ戻
る。209では上記タグにより、スキャン化回路変換が必
要なモジュールの接続情報を上記データベースより読み
出し、変換テーブルを作成し変換を行なう。(209)。
変換後はワークファイルにデータを出力し、変換が全て
終了した後に、該論理接続情報データベースを書き直す
(210)。以上で全処理を終了する(211)。 第3図を使用して、スキャン設計ルール違反情報及
び、スキャン化回路変換情報内の、スキャン設計ルール
違反の種類に対応する回路変換情報を説明する。第3図
(a)はスキャン設計ルール違反の第1の例で、FFは通
常のF/Fのモジュールタイプ名で、ID1,ID2はモジュール
識別名である。302のシステムクロック入力端子Cに、
全体回路の外部から‘0',‘1'に制御不可能な信号ISが
入力しているとき、モジュール識別名ID2の入力信号IS
は、スキャン設計ルールに違反している。また、別のス
キャン設計ルール違反の例としては第3図(c)に示し
た様に、305の入力端子PSに非同期なプリセット信号IS1
と、入力端子CRの非同期なクリア信号IS2が入力してい
るとすると、モジュール識別名ID1の入力信号IS1とIS2
は該ルールに違反している。この様なスキャン設計ルー
ル違反情報には、モジュール識別名と信号名と違反の種
類が格納してある。 一方、スキャン化回路変換情報としては、第3図
(a)の違反例に対しては、第3図(b)に示した様
に、スキャン用F/F(304)のシステムクロック入力を
‘0'でoff可能にするANDの機能を有するモジュールタイ
プ名AD2を挿入して、テストモード信号TMとゲートをと
れる様になっている。また、第3図(c)の違反に対し
ては、NANDの機能を有するND2というタイプ名のモジュ
ール(307,308)を挿入し、各々スキャンモード信号SM
とゲートをとる様に指定する。 第4図に、スキャン化回路自動変換を施すために作成
された変換テーブルの全体図を示す。401は論理接続情
報データベースより読み出した後、ユーザー指定のスキ
ャン化回路変換コマンド内のモジュール名、またはスキ
ャン化回路変換情報内のモジュール名、またはスキャン
設計ルール違反情報内のモジュールを識別するためのモ
ジュール識別名(階層設計された論理回路中のモジュー
ル識別名を示すにはモジュールタイプ名も必要)らと比
較判定後、一致した被変換モジュール名とタグである。
402は、モジュール401内で使用している下位モジュール
タイプ名とスキャン化回路変換のタグのテーブルで、40
3は下位モジュールの各々に付加された識別名とタイプ
名を示すテーブルである。404は下位モジュールの入力
端子及び出力端子が如何なる信号名と接続しているかを
示すポイント情報を格納したテーブルで、テーブル403
からポインティングされている。また、テーブル404の
ポインティング先の405は、信号名、該信号名のモジュ
ール401に於ける入力、出力、内部信号の何れかを識別
する入出力区分と、リンクポインタ情報を有するテーブ
ルである。406は各信号が如何なるモジュールの如何な
る端子に接続しているかを示すリンク情報テーブルで、
テーブル403と404をポインティングしている。また該テ
ーブル406はテーブル405のリンクポインタによってポイ
ンティングされている。 次にスキャン化回路自動変換を具体的な回路を例に上
げて説明する。第5図は4ビット直列形加算器の機能を
有する論理回路の階層接続図である。第5図(a)はス
キャン化回路変換前の図で、第5図(b)はスキャン化
回路変換後の図である。 501の箱は全体階層を示し、モジュール名はAであ
る。501の中には下位モジュール502〜506が存在し、モ
ジュール識別名はID1〜ID5で、モジュールタイプ名は順
番にB,B,C,FF,Eである。502と503(モジュール名B)は
4ビットシフトレジスタで、504(モジュール名C)は
全加算器で505(モジュール名FF)はD型F/Fで、506
(モジュール名E)は5ビットシフトレジスタである。 モジュールAの入力信号はIN1,IN2とICKで、502にIN1
とICKが、503にIN2とICKが入力している。また信号ICK
は505,506にも入力している。一方、504には502の出力
信号IS1と503の出力信号IS2と、505の出力信号IS3が入
力している。また504の出力信号IS4は506へ入力し、IS5
は505に入力している。そして全体モジュール501の出力
信号は506の出力信号からなっておりOT1〜OT5である。 第5図(b)は第5図(a)と同一機能を有し、スキ
ャン化自動変換後の階層接続図である。第5図(a)と
同等の信号には、同一の信号名が付けてある。同様にモ
ジュール名についても、511はモジュール名がAで、残
りの下位モジュール名とモジュール識別名も、スキャン
化変換前の名前と同一である。(但し505のFFは置換さ
れてSFFになっている)。512,513(モジュール名B)は
スキャン用F/Fで構成された4ビットシフトレジスタ
で、516(モジュール名E)も同様にスキャン用F/Fで構
成されている。また515は被スキャン化回路変換モジュ
ールなので、モジュール名はFFからSFFに置換される。
点線ISCK1とISCK2はスキャンクロック信号で、スキャン
用F/Fが存在するモジュール(512,513,515,516)にクロ
ックを供給している。一点鎖線はスキャンパスで、SI
N1,SIS1,SIS2,SIS3,SOT1の順に接続されている。 第6図は4ビットシフトレジスタで、第6図(a)は
第5図(a)の502と、第6図(b)は第5図(b)の5
12に等しい。第6図(a)はスキャン化回路自動変換前
の図で、第6図(b)はスキャン化回路変換後の図であ
る。602〜605はD型F/Fでモジュール名はFFで、モジュ
ール識別名は順にID1〜ID4である。601(モジュール名
B)の入力信号はIN1とICKで、出力信号はOT1で内部信
号はIS1〜IS3である。612〜615はスキャン用D型F/Fモ
ジュール名はSFFで、モジュール識別名は第6図(a)
のものと等しい。また第6図(a)と同等の信号名は第
6図(b)にそのまま付けてある。但し、各SFFにはス
キャンクロックISCK3とISCK4が供給され、スキャンクロ
ックのドライブ能力を高めるバッファ616と617が挿入さ
れている。616と617のバッファのモジュールタイプ名は
B1で、モジュール識別名は各々ID5とID6である。また61
6と617の入力信号はISCK1とISCK2である。一方、スキャ
ンパスはSIN1がモジュールBの入力信号で、SOT1が出力
信号で、順にSIN1,SIS1,SIS2,SIS3,SOT1とつながってい
る。 最後にスキャン回路自動変換の手段を、第5図と第6
図の論理回路を用いて説明する。まず、ユーザーはモジ
ュールタイプ名B内にスキャンクロックの内部バッファ
B1と(入力信号名ISCK1)同じくバッファ名B1(入力信
号名ISCK2)を挿入すべく、スキャン化回路変換コマン
ドに記述する。また、これがスキャンクロックの第1相
クロック、第2相クロックのバッファの挿入であること
を示す、挿入の種類を示す情報も記述する。一方、スキ
ャン化回路変換情報としては、まずF/Fの置換情報とし
ては、モジュールタイプ名FFをSFFに置換する様になっ
ており、スキャンパスの接続順は、被スキャン化回路変
換モジュールの論理接続記述内の並びとなっている。ま
た、例に取り上げた回路はチップレベルの階層ではない
ので、スキャン関係のデータ、クロックモード信号の入
出力バッファについての説明は省略する。更にスキャン
設計ルール違反情報についても省略する。 既に第2図を用いて説明した様に、上記ユーザ指定の
スキャン化回路変換コマンドとスキャン化回路変換情報
を読み込んだ後、論理接続情報データベースより、モジ
ュール名、下位モジュールタイプ名、モジュール識別名
を読み込む。今、該論理接続情報データベースにはモジ
ュール単位にB,C,E,Aの順にモジュール内の接続情報が
格納されているとする。すると、まずモジュール名Bを
読み出し、また下位モジュールタイプ名FFを読み出し、
モジュール識別名ID1〜ID4をも読み出す。まだ全てのモ
ジュール名を読み出していないので、これらが、ユーザ
ー指定のスキャン化回路変換情報内のモジュール名か、
スキャン化回路変換情報内のモジュール名かを判定す
る。前述した様に、ユーザ指定のスキャン化回路変換モ
ジュール名として“B"を指定していたので、被スキャン
化回路変換モジュール名とみなされる。同様に、スキャ
ン化回路変換情報として被置換F/F名として“FF"が指定
してあるので、この場合からも被スキャン化回路変換モ
ジュール名とみなされ、タグには被スキャン化回路変換
の識別子が付く。次にモジュール名Cを読み出しC内の
下位モジュールタイプ名にはFFは存在しない(C内の下
位モジュール接続関係の説明は省略してある)ので、ま
た、他のスキャン化回路変換情報等のモジュール名とも
一致しないので、タグには変換を行なわないことを示す
識別子が付く。モジュールEについては詳細に説明しな
いが、下位モジュールタイプ名にFFが存在するので、被
スキャン化回路変換モジュールとみなされる。これらの
モジュール名と被スキャン化回路変換のタグは主記憶装
置内に記憶され、上位モジュールを論理接続情報データ
ベースから読み出したとき、被スキャン化回路変換モジ
ュールか否かの判定時に使用する。最後にモジュール名
Aを読み出し、下位モジュールタイプ名が被スキャン化
回路変換モジュール名かを、スキャン化回路変換情報及
び上記モジュール名とタグの情報より判定する。この場
合、下位モジュールタイプ名は、B,C,FF,Eなので、FFは
被置換F/F名として該当し、B,Eは上記タグの情報より、
モジュールAは被スキャン化回路変換モジュールである
ことが判定される。論理接続情報データベースには必ず
しもB,C,E,Aの順にモジュールの情報が格納されている
とは限らないため、第2図の処理(209)では、逐次モ
ジュール名と下位モジュールタイプ名を再び読み出し、
下位モジュールタイプ名が、前述した被スキャン化回路
変換モジュール名か否かタグを用いて判定し、被スキャ
ン化回路変換モジュール名であるときは、該モジュール
内の接続関係のデータを全て上記データベースより読み
出す。もちろん、モジュール名を読み出したとき、該モ
ジュール名が被スキャン化回路変換モジュール名である
とタグによって判定されれば、更に下位モジュールタイ
プ名を読み出して、被スキャン化回路変換モジュール名
か否かを判定するまでもない。 次に、第4図のワークテーブルを使用して、第6図の
回路のスキャン化回路変換の手順を示す。401のモジュ
ール名はBで、スキャン化回路変換のタグは、被スキャ
ン化回路変換モジュールであることを示す。また、402
の下位モジュールタイプ名はFFで、スキャン化回路変換
のタグも被スキャン化回路変換モジュールであることを
示す。403の下位モジュール識別名はID1〜ID4で、該モ
ジュール識別名に対応したモジュールタイプ名はFFにな
っている。テーブル405にはOT1,IN1,ICK,IS1,IS2,IS3
順に信号名が入っており、入出力区分は、出力、入力、
入力、内部、内部、内部、を意味するコード番号が入っ
ている。また、テーブ404には403のモジュール識別名ID
1にポインティングされているものとして、順に4,2,3と
入っており、405の信号名のアドレスをポインティング
している。また405の信号名IN1のリンクポインタがポイ
ンティングしている406のリンク情報は、下位モジュー
ル識別名ID1をポインティングし、下位モジュール端子
番号2(404のテーブルのアドレスは2番目)をもポイ
ンティングしている。 テーブル内での変換は次のステップで行なう。第1に
テーブル402の下位モジュールタイプ名をFFからSFFに置
換する。第2に、テーブル403の下位モジュールタイプ
名FFに置換する。同時F/F数を計数し、今の場合4つで
あるから、スキャンパスの5信号名を発生する。第3
に、スキャンクロック信号名を発生するが、今の場合、
ユーザー指定のスキャン回路変換コマンド内にスキャン
用の2相クロックのバッファの入力信号名が指定してあ
るので、該バッファの出力信号名を発生する。第4とし
て、405の信号名テーブルに、SIN1,SIS1,SIS2,SIS3,SOT
1のスキャンパスの信号名と、ISCK1,ISCK2,ISCK3,ISCK4
の4つのスキャンクロックに関する信号名を挿入する。
このとき、入出力区分、リンクポインタ情報も作成す
る。また、406のリンク情報も作成する。そして、第5
に下位モジュール端子番号及びテーブル403から404のポ
インティング情報を更新する。最後にスキャン回路変換
のタグをクリアし、モジュールBについてのスキャン化
回路自動変換は終了する。 同様にしてモジュールE,Aについてスキャン化回路自
動変換を行える。 上述した様な処理を行えば、チップレベルの回路につ
いてもスキャン化回路自動変換は可能であり、スキャン
設計ルール違反の場合の論理回路挿入も同様にスキャン
化回路に変換できる。 また、スキャンパスを複数にする場合は、スキャン化
回路変換情報にスキャンパスの識別子情報を格納すると
伴に、スキャン化回路変換の処理で、被スキャン化回路
変換されるモジュールに、スキャンパスの識別子を付
け、更に下位モジュール間のスキャンパス信号名にも識
別子を付加すれば前述した方法で複数のスキャンパスを
発生できる。 以上述べたように、本実施例によれば、第1図、第2
図を用いて説明したように、論理接続情報データベース
から、スキャン化回路変換が必要なモジュールの接続デ
ータのみを読み出して来て、高速に処理を行なうことが
でき、非スキャン化回路を容易にスキャン化回路に変換
できる。 〔発明の効果〕 以上説明したように本発明によれば、階層的に設計さ
れたスキャン動作不可能な論理回路を、階層モジュール
単位に最少限の付加回路を持ってスキャン化回路変換で
き、また、論理接続情報を格納しているデータベースに
変換後の回路情報を書き込み、他の論理シミュレータテ
スト発生システム、レイアウトシステムとのインターフ
ェースを容易にとれる。更に、スキャン設計ルールチェ
ックシステムが、上記データベースとインターフェース
されているとき、スキャン設計ルール違反情報を介し
て、スキャン化回路自動変換後の回路の再チェックも可
能になる。
DETAILED DESCRIPTION OF THE INVENTION Object of the Invention (Field of Industrial Application) The present invention relates to a method for automatically converting a digital logic circuit including a plurality of gates and storage elements into a digital logic circuit which can be easily tested. (Prior Art) In order to improve the testability of a large-scale logic circuit, a pre-scannable F / F or latch is used instead of a normal flip-flop (hereinafter referred to as F / F) or latch. A scan design method is used in which F / Fs and latches are connected by a scan path, and a sequential circuit can be divided into a shift register array including the F / Fs and latches and a combination circuit. (The scan-in / out circuit configuration is, for example, Japanese Patent Publication No. 57-3107.) However, there are rules that the logic circuit designer must keep in performing the scan design, and the logic design itself. Are severely restricted. For example, the following scan design rules exist when a master / slave type is used for the scanning F / F. There should be no loop circuit consisting only of gates other than storage elements (F / F and latches) in the logic circuit. The system clock applied to the scan F / F is
It must be possible to turn it on and off from outside the entire circuit. Do not take AND gates between system locks. (The clock must not be generated inside the entire circuit.) Asynchronous clocks, clears, and preset signals are not allowed. Therefore, if the above rules are observed, the time required for logic design increases. In addition, it takes a lot of labor to manually convert a large-scale logic circuit that does not follow such rules into a scannable logic circuit, and human error may occur. On the other hand, recently, for example, as can be seen in "One Method of Automation of Design for Easy Inspection" of Information Processing Society of Japan, Proceedings of the 31st National Convention P.1661, a normal logic circuit can be automatically tested easily. There is also a way to convert to. This method consists of creating scan information and adding the scan function. The addition of the scan function is (1) F /
Mechanical replacement of F with F / F with scan function, (2) generation of peripheral circuits for external scan pins, and (3) addition of scan circuits such as scan address decoder. However, with respect to a logic circuit that is hierarchically designed, scan circuit conversion is not performed by making use of the hierarchy. On the other hand, a system for supporting the design work of a logic circuit to which a test facilitation circuit is added is disclosed in JP-A-60-27985.
However, the addition of the circuit is performed through the pattern information of the circuit diagram and not through the object format created by compiling the logic circuit connection language. (Problems to be Solved by the Invention) In the above-described conventional technology, it is necessary for a logic designer to perform a logic design in advance in compliance with a scan design rule, and the scan design rule lowers the degree of freedom of the logic design. There is an adverse effect that it takes extra time to design a logic circuit. Further, as the number of F / Fs in the logic circuit increases, there is also a disadvantage that an additional circuit such as a large address decoder circuit used in the address scan method becomes large in scale. An object of the present invention is to provide a method for converting a non-scanning circuit into a circuit that can be automatically scanned with a minimum addition of circuits in order to eliminate the above-mentioned problems. [Structure of the Invention] (Means for Solving Problems) A database for hierarchically managing and storing object format data in which logical connection descriptions are compiled and logically designed hierarchically in module units, and a scan The conversion circuit conversion information storage unit, the scan design rule violation information storage unit, and the scan conversion circuit automatic conversion unit, and the scan conversion circuit automatic conversion unit violates the scan conversion circuit automatic conversion information and the scan design rule. The module information of the logic circuit being read is read, and the hierarchical module name, the lower module type name and the module identification name in the hierarchical module are read from the database, and whether the hierarchical module name is the scan target circuit conversion module or not. If it is, read only the data of the corresponding module from the database. However, it performs a scan of,
It is a feature of the present invention that the data of the module after the scan circuit conversion can be written in the database again. (Operation) Since the result of compiling the logical connection description that is hierarchically designed logically is stored in the database hierarchically, it can be easily extracted as an object format for each hierarchy and is suitable for automatic conversion of scan circuits. An information table is created, and data is inserted and replaced on the information table to perform automatic conversion, which enables high-speed processing. Furthermore, after the scan circuit automatic conversion is performed, only the data of the module that has undergone the scan circuit automatic conversion is written in the database, so that another system (for example, a layout logic simulator, a test generation system) can be connected via the database. Interface is possible. (Embodiment) FIG. 1 shows a diagram for explaining the configuration of the present invention. 101
Is a language that describes the connection relationship of logic circuits and is described hierarchically in module units so that logic circuits can be designed top-down or bottom-up. Reference numeral 102 is a compiler of the language description, and 103 is a database in which information on logical connection is stored. Reference numeral 104 is a cell library database that stores information on cells that are constituent elements of the logical connection description 101. Reference numeral 105 denotes a linker that links the logical connection information database (103) and the cell library database (104) and expands the hierarchically set data, and 106 is a database that stores the data after the hierarchical expansion. 107 is a scan design rule check system, 108 is a logic simulator, 109 is a test generation system, 110 is a layout system, and hierarchical development information data is input. Reference numeral 120 is a portion showing the configuration of the present invention, 121 is scan circuit conversion information, 122 is a scan circuit automatic conversion system, 123 is a scan circuit conversion command that can be specified by the user, and 124 is a scan design rule. Violation information. The scan design rule violation information is output from the scan design rule check system 107. The arrows indicate the flow of data, and the logical connection information database (10
The bidirectional arrow marked between 3) and the scan circuit automatic conversion system (122) indicates that the scan circuit automatic conversion system reads necessary information from the logical connection information database and performs the scan circuit automatic conversion. , Indicates that writing to the logical connection information database is possible again. By being writable in the above-mentioned database, there is a feature that logic simulation, test generation, and layout can be performed by using circuit information after automatic conversion of the scanning circuit. Further, since the system is closed via the scan design rule check system (107), it is possible to check the result of the scan circuit automatic conversion again. FIG. 2 shows a processing flow of the automatic conversion of the scanning circuit shown by 120 in FIG. 201 and 211 are terminals, 202 to 20
5, and 208 to 210 indicate processing, and 206 and 207 indicate judgment.
First, the process is started (201). The scan circuit conversion command specified by the user is read (202). This information is specified by the user and has priority over the scan circuit conversion information that has already been ruled. What kind of scan F / F is used to replace the normal F / F, and in what order the scan paths between modules are connected. And what type of module name (type name of external or internal buffer etc. of scan clock) to be inserted into which module. Next, scan conversion circuit conversion information is read (203). Here, like the user-specified scan circuit conversion information, the type name of the F / F to be replaced, the scan path connection order, the scan-related data, the clock, the type of the external input / output buffer such as the mode signal, etc. The name and the information for converting into a scannable circuit corresponding to the type of scan design rule violation are read. Then, the scan design rule violation information is read (20
Four). Details will be described later. Next, the module name, lower module type name, and module identification name are read from the logical connection information database (205). It is determined whether all module names have been read from the logical connection information database (206), and if they have been read, the process proceeds to 209. Otherwise, the read data above is the user-specified scan circuit conversion command information, scan circuit conversion information, or the module name, module type name, or module identification name stored in the scan design rule violation information. It is determined whether it is equal to (207). If no, the process returns to 205. If they are the same, the corresponding module attaches a tag for identifying whether or not scan conversion circuit conversion is necessary. After completion, return to 205. At 209, the tag reads the connection information of the module requiring the scan circuit conversion from the database, creates the conversion table, and performs the conversion. (209).
After the conversion, the data is output to the work file, and after the conversion is completed, the logical connection information database is rewritten (210). With that, all the processes are completed (211). The scan design rule violation information and the circuit conversion information corresponding to the type of scan design rule violation in the scan circuit conversion information will be described with reference to FIG. FIG. 3A is a first example of scan design rule violation, where FF is a normal F / F module type name, and ID1 and ID2 are module identification names. To the system clock input terminal C of 302,
When the uncontrollable signal IS is input to the '0' and '1' from the outside of the whole circuit, the input signal IS of the module identification name ID2
Violates the scan design rules. As another example of the scan design rule violation, as shown in FIG. 3C, a preset signal IS1 asynchronous with the input terminal PS of 305 is used.
And the asynchronous clear signal IS2 of the input terminal CR is input, the input signals IS1 and IS2 of the module identification name ID1
Violates the rule. Such scan design rule violation information stores a module identification name, a signal name, and a violation type. On the other hand, as the scan circuit conversion information, for the violation example of FIG. 3A, the system clock input of the scan F / F (304) is set as shown in FIG. 3B. A module type name AD2 having an AND function that enables OFF at 0'is inserted so that the gate can be taken with the test mode signal TM. For the violation of FIG. 3 (c), a module (307, 308) of the type name ND2 having the function of NAND is inserted, and each scan mode signal SM
And specify to take the gate. FIG. 4 shows an overall view of the conversion table created to perform the scan circuit automatic conversion. 401 is a module for reading the logical connection information database and then identifying the module name in the scan circuit conversion command specified by the user, the module name in the scan circuit conversion information, or the module in the scan design rule violation information. It is the converted module name and tag that match after identification and comparison with the identification name (the module type name is also required to indicate the module identification name in the hierarchically designed logic circuit).
402 is a table of the lower module type name used in the module 401 and the tag of scan circuit conversion,
Reference numeral 3 is a table showing the identification name and the type name added to each of the lower modules. A table 403 stores point information indicating what kind of signal name the input terminal and output terminal of the lower module are connected to.
Has been pointed to by. A pointing destination 405 of the table 404 is a table having a signal name, an input / output section for identifying any of an input, an output, and an internal signal in the module 401 of the signal name, and link pointer information. Reference numeral 406 is a link information table showing which terminal of which module each signal is connected to,
Pointing to tables 403 and 404. The table 406 is pointed by the link pointer of the table 405. Next, the scan conversion circuit automatic conversion will be described taking a specific circuit as an example. FIG. 5 is a hierarchical connection diagram of a logic circuit having the function of a 4-bit serial adder. FIG. 5 (a) is a diagram before the conversion into the scanning circuit, and FIG. 5 (b) is a diagram after the conversion into the scanning circuit. The box 501 indicates the entire hierarchy, and the module name is A. Lower modules 502 to 506 exist in 501, module identification names are ID1 to ID5, and module type names are B, B, C, FF, and E in order. 502 and 503 (module name B) are 4-bit shift registers, 504 (module name C) is a full adder and 505 (module name FF) is a D type F / F, 506
(Module name E) is a 5-bit shift register. Input signals of the module A is IN 1, IN 2 and ICK, IN 1 502
And ICK are input, and IN 2 and ICK are input to 503. Also signal ICK
Has also entered 505,506. On the other hand, the output signal IS 1 of 502, the output signal IS 2 of 503, and the output signal IS 3 of 505 are input to 504. The output signal IS 4 of 504 is input to 506 and IS 5
Is typing in 505. The output signals of the whole module 501 are composed of the output signals of 506 and are OT 1 to OT 5 . FIG. 5 (b) is a hierarchical connection diagram having the same function as FIG. 5 (a) and after the automatic scan conversion. Signals equivalent to those in FIG. 5A are given the same signal names. Similarly, regarding the module name, the module name of 511 is A, and the remaining lower module names and module identification names are also the same as the names before the scan conversion. (However, FF of 505 is replaced with SFF). 512 and 513 (module name B) are 4-bit shift registers composed of scanning F / Fs, and 516 (module name E) is also composed of scanning F / Fs. Further, since 515 is the circuit-to-be-scanned conversion module, the module name is replaced with FF from SFF.
Dotted lines ISCK 1 and ISCK 2 are scan clock signals and supply clocks to the modules (512, 513, 515, 516) in which the scanning F / F exists. The alternate long and short dash line is the scan path, SI
N 1, SIS 1, SIS 2 , SIS 3, are connected in the order of SOT 1. FIG. 6 shows a 4-bit shift register. FIG. 6 (a) shows 502 in FIG. 5 (a) and FIG. 6 (b) shows 5 in FIG. 5 (b).
Equal to 12. FIG. 6 (a) is a diagram before the scan conversion circuit automatic conversion, and FIG. 6 (b) is a diagram after the scan conversion circuit conversion. Reference numerals 602 to 605 are D-type F / Fs, module names are FF, and module identification names are ID 1 to ID 4 in order. The input signals of 601 (module name B) are IN 1 and ICK, the output signals are OT 1 , and the internal signals are IS 1 to IS 3 . 612 to 615 have a scanning D-type F / F module name of SFF and a module identification name of FIG. 6 (a).
Equal to that of Signal names equivalent to those in FIG. 6 (a) are directly attached to FIG. 6 (b). However, scan clocks ISCK 3 and ISCK 4 are supplied to each SFF, and buffers 616 and 617 for enhancing the drive capability of the scan clocks are inserted. The module type names for the 616 and 617 buffers are
In B1, the module identifiers are ID 5 and ID 6 , respectively. Again 61
The input signals for 6 and 617 are ISCK 1 and ISCK 2 . On the other hand, in the scan path, SIN 1 is an input signal of the module B, SOT 1 is an output signal, and they are sequentially connected to SIN 1 , SIS 1 , SIS 2 , SIS 3 , and SOT 1 . Finally, the means for automatic conversion of the scan circuit is shown in FIGS.
A description will be given using the logic circuit in the figure. First, the user selects the scan clock internal buffer in the module type name B.
B1 and (input signal name ISCK 1 ) are also described in the scan circuit conversion command to insert the buffer name B1 (input signal name ISCK 2 ). Also, information indicating the type of insertion indicating that this is the insertion of the buffer of the first phase clock of the scan clock and the buffer of the second phase clock is also described. On the other hand, as scan conversion circuit conversion information, first, as replacement information of F / F, the module type name FF is replaced with SFF, and the scan path connection order is the logic of the scan target circuit conversion module. It is a sequence in the connection description. Further, since the circuits taken as examples are not in a chip level hierarchy, description of scan-related data and clock mode signal input / output buffers will be omitted. Further, the scan design rule violation information is also omitted. As already described with reference to FIG. 2, after reading the user-specified scan circuit conversion command and scan circuit conversion information, the module name, lower module type name, and module identification name are read from the logical connection information database. Read. Now, it is assumed that the logical connection information database stores the connection information in the module in the order of B, C, E, A for each module. Then, first read the module name B, then read the lower module type name FF,
Module ID names ID 1 to ID 4 are also read. Since we have not read all the module names yet, these are the module names in the scan circuit conversion information specified by the user,
It is determined whether the module name is in the scan circuit conversion information. As described above, since "B" is designated as the user-specified scan circuit conversion module name, it is regarded as the scan target circuit conversion module name. Similarly, since "FF" is specified as the replacement target F / F name as the scan conversion circuit conversion information, it is considered to be the scan conversion circuit conversion module name even in this case, and the tag of the scan conversion circuit conversion is included in the tag. It has an identifier. Next, the module name C is read, and there is no FF in the lower module type name in C (the explanation of the lower module connection relationship in C is omitted). Since the name does not match, the tag has an identifier indicating that no conversion is performed. Although the module E will not be described in detail, it is regarded as a scan target circuit conversion module because FF exists in the lower module type name. These module names and tags to be scanned circuit conversion are stored in the main storage device, and are used when determining whether or not a scanned circuit conversion module is selected when the upper module is read from the logical connection information database. Finally, the module name A is read, and it is determined whether the lower module type name is the scanned circuit conversion module name or not based on the scan circuit conversion information and the module name and tag information. In this case, the lower module type name is B, C, FF, E, so FF corresponds as the F / F name to be replaced, and B, E from the above tag information,
It is determined that the module A is the scan target circuit conversion module. Since the module information is not necessarily stored in the logical connection information database in the order of B, C, E, A, the sequential module name and the lower module type name are re-created in the process (209) of FIG. reading,
If the lower module type name is the above-mentioned scanned circuit conversion module name, it is determined using a tag. If the scanned circuit conversion module name is the scanned circuit conversion module name, all the connection relation data in the module are obtained from the above database. read out. Of course, when the module name is read out, if the tag determines that the module name is the scanned circuit conversion module name, the lower module type name is further read to determine whether or not the scanned circuit conversion module name. Needless to say. Next, using the work table of FIG. 4, the procedure of scan circuit conversion of the circuit of FIG. 6 will be described. The module name of 401 is B, and the tag for scan conversion circuit conversion indicates that it is a scan conversion circuit conversion module. Also, 402
The lower module type name of FF is FF, indicating that the tag for scan circuit conversion is also the scan target circuit conversion module. The lower module identification names of 403 are ID 1 to ID 4 , and the module type name corresponding to the module identification name is FF. The table 405 contains signal names in the order of OT 1 , IN 1 , ICK, IS 1 , IS 2 , IS 3 , and the input / output classification is output, input,
Contains code numbers that mean input, internal, internal, internal. In addition, the module identification name ID 403 of the table 404
As it is pointed to 1 , the numbers 4, 2 and 3 are entered in order, and the address of the signal name of 405 is pointed. The link information of 406, which the link pointer of the signal name IN 1 of 405 points to, points to the lower module identification name ID 1 and also the lower module terminal number 2 (the address of the table of 404 is the second). ing. Conversion in the table is done in the next step. First, the lower module type name in the table 402 is replaced with FF from SFF. Second, the lower module type name FF in the table 403 is replaced. The number of simultaneous F / Fs is counted, and since there are four in this case, five signal names of the scan path are generated. Third
, The scan clock signal name is generated, but in the present case,
Since the input signal name of the scan two-phase clock buffer is specified in the scan circuit conversion command specified by the user, the output signal name of the buffer is generated. Fourth, in the signal name table 405, SIN 1 , SIS 1 , SIS 2 , SIS 3 , SOT
1 scan path signal name and ISCK 1 ,, ISCK 2 ,, ISCK 3 ,, ISCK 4
Insert the signal names for the four scan clocks.
At this time, input / output classification and link pointer information are also created. Also, the link information of 406 is created. And the fifth
The lower module terminal number and the pointing information of the tables 403 to 404 are updated. Finally, the tag for scan circuit conversion is cleared, and the scan circuit automatic conversion for module B ends. Similarly, automatic conversion of the scan circuit can be performed for modules E and A. By performing the processing as described above, the scan circuit automatic conversion can be performed even for the chip level circuit, and the logic circuit insertion when the scan design rule is violated can also be converted into the scan circuit. Further, when there are a plurality of scan paths, the scan path identifier information is stored in the scan conversion circuit conversion information, and the scan path identifier is assigned to the module to be scanned circuit conversion in the scan conversion circuit conversion processing. A plurality of scan paths can be generated by the above-mentioned method by adding an identifier to the scan path signal name between lower modules. As described above, according to the present embodiment, FIG.
As explained using the figure, only the connection data of the modules that need scan conversion circuit conversion is read from the logical connection information database, high-speed processing is possible, and non-scan circuits can be easily scanned. Can be converted into a digital circuit. [Effects of the Invention] As described above, according to the present invention, a hierarchically designed logic circuit incapable of scan operation can be converted into a scan circuit with a minimum number of additional circuits in each hierarchical module. , The converted circuit information is written in the database storing the logical connection information, and the interface with other logic simulator test generation system and layout system can be easily taken. Further, when the scan design rule check system is interfaced with the above database, it is possible to recheck the circuit after the automatic conversion of the scanning circuit via the scan design rule violation information.

【図面の簡単な説明】 第1図は本発明の実施例に於けるスキャン化回路自動変
換システムと他のシステムとの関連図、第2図は本発明
の実施例に於けるスキャン化回路変換処理フロー図、第
3図はスキャン設計ルール違反情報の説明図、第4図は
スキャン化回路変換処理を行なうときに作成する変換テ
ーブルを示す図、第5図は本発明の実施例に於ける論理
回路接続図、第6図は第5図の下位階層の論理回路接続
図である。 101……論理接続記述、102……コンパイラ、 103……論理接続情報データベース、 122……スキャン化回路自動変換システム。
BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a diagram showing a relation between an automatic scanning circuit conversion system according to an embodiment of the present invention and another system, and FIG. 2 is a scanning circuit conversion according to an embodiment of the present invention. FIG. 3 is a process flow diagram, FIG. 3 is an explanatory diagram of scan design rule violation information, FIG. 4 is a diagram showing a conversion table created when performing scan circuit conversion processing, and FIG. 5 is an embodiment of the present invention. A logic circuit connection diagram and FIG. 6 are logic circuit connection diagrams of the lower hierarchy of FIG. 101 ... Logical connection description, 102 ... Compiler, 103 ... Logical connection information database, 122 ... Scanned circuit automatic conversion system.

Claims (1)

(57)【特許請求の範囲】 1.トップダウンまたはボトムアップに階層設計され
た、非スキャン化論理回路を、スキャンテスト可能な論
理回路に自動変換する方法であり、前記非スキャン化論
理回路の接続記述のコンパイル結果が格納されている論
理接続情報データベースから、階層を展開する前に階層
毎に付けられているモジュールタイプ、及び下位階層モ
ジュール名、該下位階層モジュール識別名を読み出し
て、スキャン化回路変換を施すか否かを判定するステッ
プと、 スキャン化回路変換を施すべきモジュール名が、他の階
層内で使用されているか否かを判定するステップと、ス
キャン化回路変換を施すべきモジュール内の接続情報の
みを読み出すステップと、階層を展開する前に階層モジ
ュール毎にスキャン化回路変換を行うステップと、 スキャン化回路変換後のモジュール情報を該論理接続情
報データベースに書き込むステップを有することを特徴
とする、スキャン化回路変換方法。
(57) [Claims] A method for automatically converting a non-scanned logic circuit, which is hierarchically designed top-down or bottom-up, into a scan testable logic circuit, and a logic in which a compilation result of a connection description of the non-scanned logic circuit is stored. A step of reading the module type, the lower layer module name, and the lower layer module identification name assigned to each layer before expanding the layer from the connection information database and determining whether or not to perform the scan circuit conversion And a step of determining whether or not the module name to be scanned circuit conversion is used in another layer, a step of reading only the connection information in the module to be scanned circuit conversion, and a layer Steps to perform scan circuit conversion for each hierarchical module before expansion, and after scan circuit conversion It characterized by having a step of writing the module information in the logical connection information database, scanning circuit conversion method.
JP62237329A 1987-09-24 1987-09-24 Scan circuit conversion method Expired - Fee Related JP2692813B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP62237329A JP2692813B2 (en) 1987-09-24 1987-09-24 Scan circuit conversion method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62237329A JP2692813B2 (en) 1987-09-24 1987-09-24 Scan circuit conversion method

Publications (2)

Publication Number Publication Date
JPS6480883A JPS6480883A (en) 1989-03-27
JP2692813B2 true JP2692813B2 (en) 1997-12-17

Family

ID=17013759

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62237329A Expired - Fee Related JP2692813B2 (en) 1987-09-24 1987-09-24 Scan circuit conversion method

Country Status (1)

Country Link
JP (1) JP2692813B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5067091A (en) * 1988-01-21 1991-11-19 Kabushiki Kaisha Toshiba Circuit design conversion apparatus

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6027985A (en) * 1983-07-26 1985-02-13 Mitsubishi Electric Corp Designing device of logical circuit
JPS61151782A (en) * 1984-12-26 1986-07-10 Hitachi Ltd Formation of logic operation circuit

Also Published As

Publication number Publication date
JPS6480883A (en) 1989-03-27

Similar Documents

Publication Publication Date Title
CN101883991B (en) Method and apparatus for describing components adapted for dynamically modifying scan path for system-on-chip testing
US8863053B2 (en) Intelligent timing analysis and constraint generation GUI
US6292931B1 (en) RTL analysis tool
US5864487A (en) Method and apparatus for identifying gated clocks within a circuit design using a standard optimization tool
CN101884032B (en) Method and apparatus for describing parallel access to a system-on-chip
US6405355B1 (en) Method for placement-based scan-in and scan-out ports selection
US7587690B1 (en) Method and system for global coverage analysis
US20060048083A1 (en) Chip development system enabled for the handling of multi-level circuit design data
CA2410073A1 (en) Modular design method and system for programmable logic devices
US6289491B1 (en) Netlist analysis tool by degree of conformity
JPH0793395A (en) Method for managing electronic circuit design data
US6845489B1 (en) Database for design of integrated circuit device and method for designing integrated circuit device
US6256770B1 (en) Register transfer level (RTL) based scan insertion for integrated circuit design processes
US6205567B1 (en) Fault simulation method and apparatus, and storage medium storing fault simulation program
US20080295045A1 (en) Method for Creating Hdl Description Files of Digital Systems, and Systems Obtained
JP4077578B2 (en) Integrated circuit device design method
JP4405599B2 (en) Generation and use of design shells for integrated circuit design
JP2692813B2 (en) Scan circuit conversion method
US7315997B2 (en) Method and apparatus for supporting designing of LSI, and computer product
JP5440094B2 (en) Circuit design apparatus and method
EP0440553B1 (en) Gate addressing system for logic simulation machine
Sehgal et al. Hierarchy-aware and area-efficient test infrastructure design for core-based system chips
US6377909B1 (en) Method and apparatus for preparing a logic simulation model and recording medium for storing the same
US6237121B1 (en) Method and apparatus for performing register transfer level scan selection
US20090100387A1 (en) HDL processing method and computer-readable storage medium

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees