ucb-bar / hammer

Hammer: Highly Agile Masks Made Effortlessly from RTL
BSD 3-Clause "New" or "Revised" License
252 stars 56 forks source link

Innovus: autodetect ccopt_design licence #759

Open edwardcwang opened 5 years ago

edwardcwang commented 5 years ago

Innvous clock_tree could autodetect if the "clock concurrent optimization" licence exists and do the right thing automatically. This is low priority as long as the flag exists.

It's a bit tricky since the full invs doesn't actually have enccco on the server:

@innovus 2> set_license_check -check_out enccco
**WARN: (IMPLIC-50):    option "enccco" is not allowed.
Current checked out base license : invs (Innovus_Impl_System 17.1).
The base license allows the following optional licenses available now on the server(s) : invs_hier invs_ms invs_20nm invs_hfr tpsxl tpsl qrcaa vtsxl vtsaa
Use "" to specify empty options.

Here's what it looks like when it fails:

innovus 12> set_license_check -check_out enccco 
**ERROR: (IMPLIC-83):   Option license 'enccco' (Encounter_ccopt_GXL 17.1) did not exist in license server. Check license server settings to ensure required licenses are installed properly and accessible.
jwright6323 commented 5 years ago

I would think you could do something like:

set hammer_got_enccco_license 0
catch {
  set_license_check -check_out_enccco
  set hammer_got_enccco_license 1
} # Not sure if set_license_check actually returns something or not

edit catch not try

edwardcwang commented 5 years ago

For the record: apparently one cannot capture the output from the command, and it does not return anything meaningful...

@innovus 23> set hammer_got_enccco_license 0
0                                      
@innovus 24> catch {          
+   set_license_check -check_out enccco
+   set hammer_got_enccco_license 1
+ }
**ERROR: (IMPLIC-83):    Option license 'enccco' (Encounter_ccopt_GXL 17.1) did not exist in license server. Check license server settings to ensure required licenses are installed properly and accessible.
0
@innovus 25> puts $hammer_got_enccco_license
1
@innovus 15> set temp [set_license_check -exists_on_server]
Name      Prod #  Product Name                                     License string            Version
invs_hier INVS40  Innovus Hierarchical Design Option               Innovus_Hier_Opt          17.1    
invs_ms   INVS30  Innovus Mixed Signal Option                      Innovus_MS_Opt            17.1    
invs_20nm INVS20  Innovus 20nm Option                              Innovus_20nm_Opt          17.1    
invs_hfr  INVS35  Innovus High Frequency Route Option              Innovus_hfr_Opt           17.1    
tpsxl     TPS200  Tempus Timing Signoff Solution XL                Tempus_Timing_Signoff_XL  17.1    
tpsl      TPS100  Tempus Timing Signoff Solution L                 Tempus_Timing_Signoff_L   17.1    
qrcaa     QRCX310 Cadence Quantus QRC Advanced Analysis GXL Option QRC_Advanced_Analysis     16.1    
vtsxl     VTS200  Voltus Power Integrity Solution XL               Voltus_Power_Integrity_XL 17.1    
vtsaa     VTS201  Voltus Advanced Analysis GXL Option              Voltus_Power_Integrity_AA 17.1    
@innovus 16> puts $temp

@innovus 17> 
edwardcwang commented 5 years ago

This is probably dead for now :(

jwright6323 commented 5 years ago

Eh, I'm interested in leaving this open. You may be able to do this in innvous another way (not convinced yet), but I could also see a future where the "site-level" environment config has license info and informs hammer about what options to use.