Skip to content

Commit ee700ba

Browse files
authored
Merge pull request parallaxsw#260 from eder-matheus/master
get latest sta fixes
2 parents f71b38b + d940ab6 commit ee700ba

407 files changed

Lines changed: 5914 additions & 2519 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CMakeLists.txt

Lines changed: 50 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# OpenSTA, Static Timing Analyzer
2-
# Copyright (c) 2024, Parallax Software, Inc.
2+
# Copyright (c) 2025, Parallax Software, Inc.
33
#
44
# This program is free software: you can redistribute it and/or modify
55
# it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
#
1414
# You should have received a copy of the GNU General Public License
1515
# along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
#
17+
# The origin of this software must not be misrepresented; you must not
18+
# claim that you wrote the original software.
19+
#
20+
# Altered source versions must be plainly marked as such, and must not be
21+
# misrepresented as being the original software.
22+
#
23+
# This notice may not be removed or altered from any source distribution.
1624

1725
cmake_minimum_required (VERSION 3.10)
1826
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.13)
@@ -265,59 +273,60 @@ set(STA_TCL_FILES
265273
find_package(FLEX)
266274
find_package(BISON)
267275

276+
# Liberty scan/parse.
277+
flex_target(LibertyLex ${STA_HOME}/liberty/LibertyLex.ll
278+
${CMAKE_CURRENT_BINARY_DIR}/LibertyLex.cc)
279+
bison_target(LibertyParse ${STA_HOME}/liberty/LibertyParse.yy
280+
${CMAKE_CURRENT_BINARY_DIR}/LibertyParse.cc
281+
# centos7 bison 3.0.4 < 3.3.0 uses parser_class_name instead of api.parsr.class
282+
COMPILE_FLAGS "-Wno-deprecated")
283+
add_flex_bison_dependency(LibertyLex LibertyParse)
284+
268285
# LibertyExpr scan/parse.
269-
flex_target(LibertyExprLex ${STA_HOME}/liberty/LibertyExprLex.ll ${CMAKE_CURRENT_BINARY_DIR}/LibertyExprLex.cc
286+
flex_target(LibertyExprLex ${STA_HOME}/liberty/LibertyExprLex.ll
287+
${CMAKE_CURRENT_BINARY_DIR}/LibertyExprLex.cc
270288
COMPILE_FLAGS --prefix=LibertyExprLex_)
271-
bison_target(LibertyExprParser ${STA_HOME}/liberty/LibertyExprParse.yy ${CMAKE_CURRENT_BINARY_DIR}/LibertyExprParse.cc
289+
bison_target(LibertyExprParse ${STA_HOME}/liberty/LibertyExprParse.yy
290+
${CMAKE_CURRENT_BINARY_DIR}/LibertyExprParse.cc
272291
COMPILE_FLAGS --name-prefix=LibertyExprParse_
273292
)
274-
add_flex_bison_dependency(LibertyExprLex LibertyExprParser)
275-
276-
# Liberty scan/parse.
277-
flex_target(LibertyLex ${STA_HOME}/liberty/LibertyLex.ll ${CMAKE_CURRENT_BINARY_DIR}/LibertyLex.cc
278-
COMPILE_FLAGS --prefix=LibertyLex_
279-
)
280-
bison_target(LibertyParser ${STA_HOME}/liberty/LibertyParse.yy ${CMAKE_CURRENT_BINARY_DIR}/LibertyParse.cc
281-
COMPILE_FLAGS "--name-prefix=LibertyParse_ -v"
282-
)
283-
add_flex_bison_dependency(LibertyLex LibertyParser)
293+
add_flex_bison_dependency(LibertyExprLex LibertyExprParse)
284294

285295
# Spef scan/parse.
286296
flex_target(SpefLex ${STA_HOME}/parasitics/SpefLex.ll ${CMAKE_CURRENT_BINARY_DIR}/SpefLex.cc
287297
COMPILE_FLAGS --prefix=SpefLex_
288298
)
289-
bison_target(SpefParser ${STA_HOME}/parasitics/SpefParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SpefParse.cc
299+
bison_target(SpefParse ${STA_HOME}/parasitics/SpefParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SpefParse.cc
290300
COMPILE_FLAGS --name-prefix=SpefParse_
291301
)
292-
add_flex_bison_dependency(SpefLex SpefParser)
302+
add_flex_bison_dependency(SpefLex SpefParse)
293303

294304
# Verilog scan/parse.
295-
flex_target(VerilogLex ${STA_HOME}/verilog/VerilogLex.ll ${CMAKE_CURRENT_BINARY_DIR}/VerilogLex.cc
296-
COMPILE_FLAGS --prefix=VerilogLex_
297-
)
298-
bison_target(VerilogParser ${STA_HOME}/verilog/VerilogParse.yy ${CMAKE_CURRENT_BINARY_DIR}/VerilogParse.cc
299-
COMPILE_FLAGS --name-prefix=VerilogParse_
300-
)
301-
add_flex_bison_dependency(VerilogLex VerilogParser)
305+
flex_target(VerilogLex ${STA_HOME}/verilog/VerilogLex.ll
306+
${CMAKE_CURRENT_BINARY_DIR}/VerilogLex.cc)
307+
bison_target(VerilogParse ${STA_HOME}/verilog/VerilogParse.yy
308+
${CMAKE_CURRENT_BINARY_DIR}/VerilogParse.cc
309+
# centos7 bison 3.0.4 < 3.3.0 uses parser_class_name instead of api.parsr.class
310+
COMPILE_FLAGS "-Wno-deprecated")
311+
add_flex_bison_dependency(VerilogLex VerilogParse)
302312

303313
# Sdf scan/parse.
304-
flex_target(SdfLex ${STA_HOME}/sdf/SdfLex.ll ${CMAKE_CURRENT_BINARY_DIR}/SdfLex.cc
305-
COMPILE_FLAGS --prefix=SdfLex_
306-
)
307-
bison_target(SdfParser ${STA_HOME}/sdf/SdfParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SdfParse.cc
308-
COMPILE_FLAGS --name-prefix=SdfParse_
309-
)
310-
add_flex_bison_dependency(SdfLex SdfParser)
311-
314+
flex_target(SdfLex ${STA_HOME}/sdf/SdfLex.ll
315+
${CMAKE_CURRENT_BINARY_DIR}/SdfLex.cc)
316+
bison_target(SdfParse ${STA_HOME}/sdf/SdfParse.yy
317+
${CMAKE_CURRENT_BINARY_DIR}/SdfParse.cc
318+
# centos7 bison 3.0.4 < 3.3.0 uses parser_class_name instead of api.parsr.class
319+
COMPILE_FLAGS "-Wno-deprecated")
320+
add_flex_bison_dependency(SdfLex SdfParse)
312321

313322
# Saif scan/parse.
314323
flex_target(SaifLex ${STA_HOME}/power/SaifLex.ll ${CMAKE_CURRENT_BINARY_DIR}/SaifLex.cc
315324
COMPILE_FLAGS --prefix=SaifLex_
316325
)
317-
bison_target(SaifParser ${STA_HOME}/power/SaifParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SaifParse.cc
326+
bison_target(SaifParse ${STA_HOME}/power/SaifParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SaifParse.cc
318327
COMPILE_FLAGS --name-prefix=SaifParse_
319328
)
320-
add_flex_bison_dependency(SaifLex SaifParser)
329+
add_flex_bison_dependency(SaifLex SaifParse)
321330

322331
################################################################
323332

@@ -489,21 +498,21 @@ target_sources(OpenSTA
489498
${STA_TCL_INIT}
490499

491500
${FLEX_LibertyExprLex_OUTPUTS}
492-
${BISON_LibertyExprParser_OUTPUTS}
501+
${BISON_LibertyExprParse_OUTPUTS}
493502
${FLEX_LibertyLex_OUTPUTS}
494-
${BISON_LibertyParser_OUTPUTS}
503+
${BISON_LibertyParse_OUTPUTS}
495504

496505
${FLEX_SpefLex_OUTPUTS}
497-
${BISON_SpefParser_OUTPUTS}
506+
${BISON_SpefParse_OUTPUTS}
498507

499508
${FLEX_SdfLex_OUTPUTS}
500-
${BISON_SdfParser_OUTPUTS}
509+
${BISON_SdfParse_OUTPUTS}
501510

502511
${FLEX_VerilogLex_OUTPUTS}
503-
${BISON_VerilogParser_OUTPUTS}
512+
${BISON_VerilogParse_OUTPUTS}
504513

505514
${FLEX_SaifLex_OUTPUTS}
506-
${BISON_SaifParser_OUTPUTS}
515+
${BISON_SaifParse_OUTPUTS}
507516
)
508517

509518
target_link_libraries(OpenSTA
@@ -521,11 +530,14 @@ target_include_directories(OpenSTA
521530
PUBLIC
522531
include
523532
${TCL_INCLUDE_PATH}
533+
${FLEX_INCLUDE_DIRS}
524534

525535
PRIVATE
526536
include/sta
527537
${STA_HOME}
528538
${CUDD_INCLUDE}
539+
# For flex to find location.hh
540+
${CMAKE_CURRENT_BINARY_DIR}
529541
)
530542

531543
if (TCL_READLINE)

README.md

Lines changed: 35 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,6 @@ bison 3.8.2 3.8.2
100100
flex 2.6.4 2.6.4
101101
```
102102

103-
Note that flex versions before 2.6.4 contain 'register' declarations that
104-
are illegal in c++17.
105-
106103
External library dependencies:
107104
```
108105
Ubuntu Darwin License
@@ -113,12 +110,11 @@ zLib 1.2.5 1.2.8 zlib optional
113110
```
114111

115112
The [TCL readline library](https://tclreadline.sourceforge.net/tclreadline.html)
116-
links the GNU readline library to the TCL interpreter for command line editing
117-
On OSX, Homebrew does not support tclreadline, but the macports system does
118-
(see https://www.macports.org). To enable TCL readline support use the following
119-
Cmake option: See (https://tclreadline.sourceforge.net/) for TCL readline
120-
documentation. To change the overly verbose default prompt, add something this
121-
to your ~/.sta init file:
113+
links the GNU readline library to the TCL interpreter for command line
114+
editing To enable TCL readline support use the following Cmake option:
115+
See (https://tclreadline.sourceforge.net/) for TCL readline
116+
documentation. To change the overly verbose default prompt, add
117+
something this to your ~/.sta init file:
122118

123119
```
124120
if { ![catch {package require tclreadline}] } {
@@ -150,7 +146,7 @@ make
150146
You can use the "configure --prefix" option and "make install" to install CUDD
151147
in a different directory.
152148

153-
### Installing with CMake
149+
### Building with CMake
154150

155151
Use the following commands to checkout the git repository and build the
156152
OpenSTA library and excutable.
@@ -208,6 +204,24 @@ interactively.
208204
docker run -i -v $HOME:/data OpenSTA
209205
```
210206

207+
## Build on Macos/Darwin
208+
209+
THe XCode versions of Tcl, Flex and Bison cannot be used to build OpenSTA.
210+
Use Homebrew to install them.
211+
212+
brew install cmake swig flex bison tcl-tk zlib
213+
214+
Set these variables before using cmake to cirumvent the Xcode versions.
215+
216+
# flex/bison override apple version
217+
export PATH="$(brew --prefix bison)/bin:${PATH}"
218+
export PATH="$(brew --prefix flex)/bin:${PATH}"
219+
export CMAKE_INCLUDE_PATH="$(brew --prefix flex)/include"
220+
export CMAKE_LIBRARY_PATH="$(brew --prefix flex)/lib;$(brew --prefix bison)/lib"
221+
222+
Homebrew does not support tclreadline, but the macports system does
223+
(see https://www.macports.org).
224+
211225
## Bug Reports
212226

213227
Use the Issues tab on the github repository to report bugs.
@@ -233,15 +247,6 @@ Command files should not have absolute filenames like
233247
These obviously are not portable. Use filenames relative to the test
234248
case directory.
235249

236-
## Authors
237-
238-
* James Cherry
239-
240-
* William Scott authored the arnoldi delay calculator at Blaze, Inc
241-
which was subsequently licensed to Nefelus, Inc that has graciously
242-
contributed it to OpenSTA.
243-
244-
245250
## Contributions
246251

247252
Contributors must sign the Contributor License Agreement (doc/CLA.txt)
@@ -254,6 +259,17 @@ Contributions that claim 4% performance improvements in OpenROAD flow
254259
scripts will largely be ignored. Small performance improvements
255260
simply do not justify the time requied to audit and verify the changes.
256261

262+
Contributions that add dependencies on external libraries like boost
263+
will not be accepted.
264+
265+
## Authors
266+
267+
* James Cherry
268+
269+
* William Scott authored the arnoldi delay calculator at Blaze, Inc
270+
which was subsequently licensed to Nefelus, Inc that has graciously
271+
contributed it to OpenSTA.
272+
257273
## License
258274

259275
OpenSTA, Static Timing Analyzer

app/Main.cc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// OpenSTA, Static Timing Analyzer
2-
// Copyright (c) 2024, Parallax Software, Inc.
2+
// Copyright (c) 2025, Parallax Software, Inc.
33
//
44
// This program is free software: you can redistribute it and/or modify
55
// it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
//
1414
// You should have received a copy of the GNU General Public License
1515
// along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
//
17+
// The origin of this software must not be misrepresented; you must not
18+
// claim that you wrote the original software.
19+
//
20+
// Altered source versions must be plainly marked as such, and must not be
21+
// misrepresented as being the original software.
22+
//
23+
// This notice may not be removed or altered from any source distribution.
1624

1725
#include "StaMain.hh"
1826
#include "StaConfig.hh" // STA_VERSION

app/StaApp.i

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
%module sta
22

33
// OpenSTA, Static Timing Analyzer
4-
// Copyright (c) 2024, Parallax Software, Inc.
4+
// Copyright (c) 2025, Parallax Software, Inc.
55
//
66
// This program is free software: you can redistribute it and/or modify
77
// it under the terms of the GNU General Public License as published by
@@ -15,6 +15,14 @@
1515
//
1616
// You should have received a copy of the GNU General Public License
1717
// along with this program. If not, see <https://www.gnu.org/licenses/>.
18+
//
19+
// The origin of this software must not be misrepresented; you must not
20+
// claim that you wrote the original software.
21+
//
22+
// Altered source versions must be plainly marked as such, and must not be
23+
// misrepresented as being the original software.
24+
//
25+
// This notice may not be removed or altered from any source distribution.
1826

1927
%include "tcl/Exception.i"
2028
%include "tcl/StaTclTypes.i"

app/StaMain.cc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// OpenSTA, Static Timing Analyzer
2-
// Copyright (c) 2024, Parallax Software, Inc.
2+
// Copyright (c) 2025, Parallax Software, Inc.
33
//
44
// This program is free software: you can redistribute it and/or modify
55
// it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
//
1414
// You should have received a copy of the GNU General Public License
1515
// along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
//
17+
// The origin of this software must not be misrepresented; you must not
18+
// claim that you wrote the original software.
19+
//
20+
// Altered source versions must be plainly marked as such, and must not be
21+
// misrepresented as being the original software.
22+
//
23+
// This notice may not be removed or altered from any source distribution.
1624

1725
#include "StaMain.hh"
1826

dcalc/ArcDcalcWaveforms.cc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// OpenSTA, Static Timing Analyzer
2-
// Copyright (c) 2024, Parallax Software, Inc.
2+
// Copyright (c) 2025, Parallax Software, Inc.
33
//
44
// This program is free software: you can redistribute it and/or modify
55
// it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
//
1414
// You should have received a copy of the GNU General Public License
1515
// along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
//
17+
// The origin of this software must not be misrepresented; you must not
18+
// claim that you wrote the original software.
19+
//
20+
// Altered source versions must be plainly marked as such, and must not be
21+
// misrepresented as being the original software.
22+
//
23+
// This notice may not be removed or altered from any source distribution.
1624

1725
#include <memory>
1826

dcalc/ArcDcalcWaveforms.hh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// OpenSTA, Static Timing Analyzer
2-
// Copyright (c) 2024, Parallax Software, Inc.
2+
// Copyright (c) 2025, Parallax Software, Inc.
33
//
44
// This program is free software: you can redistribute it and/or modify
55
// it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
//
1414
// You should have received a copy of the GNU General Public License
1515
// along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
//
17+
// The origin of this software must not be misrepresented; you must not
18+
// claim that you wrote the original software.
19+
//
20+
// Altered source versions must be plainly marked as such, and must not be
21+
// misrepresented as being the original software.
22+
//
23+
// This notice may not be removed or altered from any source distribution.
1624

1725
#pragma once
1826

dcalc/ArcDelayCalc.cc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// OpenSTA, Static Timing Analyzer
2-
// Copyright (c) 2024, Parallax Software, Inc.
2+
// Copyright (c) 2025, Parallax Software, Inc.
33
//
44
// This program is free software: you can redistribute it and/or modify
55
// it under the terms of the GNU General Public License as published by
@@ -13,6 +13,14 @@
1313
//
1414
// You should have received a copy of the GNU General Public License
1515
// along with this program. If not, see <https://www.gnu.org/licenses/>.
16+
//
17+
// The origin of this software must not be misrepresented; you must not
18+
// claim that you wrote the original software.
19+
//
20+
// Altered source versions must be plainly marked as such, and must not be
21+
// misrepresented as being the original software.
22+
//
23+
// This notice may not be removed or altered from any source distribution.
1624

1725
#include "ArcDelayCalc.hh"
1826

0 commit comments

Comments
 (0)