Project

General

Profile

USDB support » History » Revision 2

Revision 1 (jun chen, 03/27/2025 12:23 AM) → Revision 2/3 (jun chen, 03/27/2025 12:25 AM)

# USDB support 

 300  
 Developer: ShuMiao PE: JiaXiao 
 PV: SiQi 
 Date: 2023/12 

 ## in-house utility {SiQi) 

 vcddiff D叩DD (SiQi todo) 
 叩田叩叩DD叩叩DDDusdb-> vcd, DDvcd-> usdb叩D执叩O叩D  
 D叩DD叩 
 ``` 
 source /scratch02/rnd/sqchen/work—to—do/GB—VCD/.VD/setup.csh 
 1.usdb-> vcd: 	 usdb2vcd -i �input—usdb—file -o �output—vcd—file 
 2.vcd->usdb: 	 vcd2usdb -i �input—vcd—file 	 -o �output—usdb—file 
 ``` 

 ![](clipboard-202503270022-82q9e.png) 

 ## Spec and function {Shumiao) 
 参伲D料叩  
 USDB API specification file: attachment:"EDA2数字波形接口.pdf" EDA200D叩接叩.pdf  
 Discussion with USDB: attachment:"国标USDB问题解答.pptx" DDUSDBD叩DO.pptx 

 D叩叩叩parse    usdbDDO叩D叩叩是叩见叩供叩parserDD叩叩译叩见叩供叩libOD这叩O叩支叩cent7DDDD叩叩cent7O叩译binaryDDDOD叩O叩图叩示叩 
 ![](clipboard-202503270022-qbuor.png) 

 如叩使叩extract_usdb叩 
 option叩D释叩 
 -input_file叩叩DusdbDD叩O叩D  
 -output_file:    叩DOODO叩vcdO叩DDODDDDO叩DusdbOOvcd 
 -start_time: DDDDusdbOOD叩 
 -end_time: DDDDusdb叩叩D叩 
 -refine_path: DDDDusdbDD叩strip掉叩层叩 eg1. 叩DusdbOOvcdO叩叩 

 extract—usdb -input—file example.usdb -output—file demo.vcd -start—time �STARTTIMF -end—time �FNDT IMF 

 eg2. DDusdbDOswitching activity: 

 extract—usdb -input—file example.usdb -start—time �STARTTIMF -end—time �FNDTIMF -refine—path �PAT: 

 如叩DD vcdD叩叩 tool: vcddiff 位DDD叩DD叩 

 /reg/util/vp/util—scripts/work—util/vcddiff test1.vcd test2.vcd > diff.log 


 Case, regression {ShuMiao) 
 PS叩 Cases必须叩cent7叩binary□D叩叩DDO0支叩cent6 
 Case 1. 通叩cht□D hvp门D usdbD叩咖叩将叩转叩叩叩价叩vcdD叩叩  
 a)D叩vcd2usdb叩DDDOdemo_golden.vcdOOOdemo.usdbO叩 


 vcd2usdb -i demo—golden.vcd -o demo.usdb 

 b)DDextract_usdbOOOdemo.vcdO叩 


 extract—usdb -input—file demo.usdb -output—file demo.vcd 

 D田D叩叩DDvcddiffD衄demo_golden.vcdDdemo.vcdO叩,    ODdiff.logOD叩pass 


 vcddiff test—golden.vcd demo.vcd > diff.log 

 example case: 


 /scratch02/rnd/smli/usdb—case/usdb/usdb—to—vcd/test.tcl 

 Case 2. 搭叩cht power所叩要叩design, 门D usdbD叩咖叩D usdb叩标工switching activity信息咖生叩功叩分D结叩: 
 a)D叩vcd2usdb叩D拿叩叩Dcase叩xxx.usdbO叩 
 b)D田cht design, DOtiming analysis后D叩叩DOxxx.vcdD叩叩叩power analysis 


 extract—switching—activity -format vcd -file xxx.vcd -refine—path �PAT: report—power—anaysis > golden/power—golden.rpt 

 c)DDswitching activityD叩Dxxx.usdbO叩D叩叩叩power analysis 


 set—switching—activity -clear 
 extract—usdb -intput—file xxx.usdb -refine—path �PAT: report—power—anaysis > power.rpt 

 D田D叩叩 
 1.Switching    activity叩DDDDDDcheckpointD衄DD叩DD  
 2.D耗叩DOD叩 


 qa—report—power—analysis design golden/power—golden.rpt power.rpt 

 example case: 


 /scratch02/rnd/smli/usdb—case/usdb/usdb—to—pow/test.tcl 

 Schedule and result {JiaXiao) 


 ![](clipboard-202503270023-1ota6.png)