OpenSTA/CMakeLists.txt

572 lines
15 KiB
CMake
Raw Normal View History

2019-03-29 22:18:08 +01:00
# OpenSTA, Static Timing Analyzer
# Copyright (c) 2022, Parallax Software, Inc.
2019-01-06 01:44:56 +01:00
#
2019-03-29 22:18:08 +01:00
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2019-03-29 22:18:08 +01:00
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
2019-01-06 01:44:56 +01:00
2020-01-27 19:50:00 +01:00
cmake_minimum_required (VERSION 3.9)
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.13)
2020-01-27 19:50:00 +01:00
# Use standard target names
cmake_policy(SET CMP0078 NEW)
endif()
if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.14)
2020-01-27 19:50:00 +01:00
# Allows SWIG_MODULE_NAME to be set
cmake_policy(SET CMP0086 NEW)
2020-01-28 04:45:29 +01:00
endif()
2019-01-01 21:27:23 +01:00
Network::id for maps/sets commit be70d30ae05665021254b0d7e69fb8d2f0a82890 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 17:04:49 2023 -0700 cmp Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4d4ef96948afe3d6a00c4521aeb5bc74274f5737 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 16:08:50 2023 -0700 rvo, const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit bb584e4264af2bea867b17d07e8d38c0e9eb0025 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 15:05:00 2023 -0700 const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a08fe558bca6b769b2728882258bd85aed990a27 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 14:57:33 2023 -0700 LibertyPortPair no ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4d3bd60c109d1ce9d0589d746f4968fa7bebd90d Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 14:13:07 2023 -0700 cleanup Signed-off-by: James Cherry <cherry@parallaxsw.com> commit dc25ff77771cfbe26f9318bad2b3c45879614783 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 14:06:13 2023 -0700 const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 06e81586ce11a0cc06948ed78fef99353077d69e Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 14:01:10 2023 -0700 sortByName Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 9d8592aff5b246f83e47e1b94490e3cef8d8e119 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 11:57:17 2023 -0700 sort pred Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 462a8e14df8b561ddfc842addc62c4b8435b6347 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 11:09:57 2023 -0700 const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 69f71505b684e88b22d395510429497e87bf1015 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 10:45:14 2023 -0700 flush ConstPortSeq Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 6429d578b78eac3fe7e99fcd67a120789932b2eb Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 09:19:15 2023 -0700 rm ConstNetSet Signed-off-by: James Cherry <cherry@parallaxsw.com> commit f247930b16e40560b957a36af68947249ed1ef04 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 17 08:50:50 2023 -0700 sortPathNames Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4ca2b0e0af7252c7bcbc65cf141d0ce40634d329 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 10:14:05 2023 -0700 const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 3d18640d2ebc4aae3098c7e7242a554fcb64fd42 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 09:41:27 2023 -0700 set_input/ouput_delay -reference_pin Signed-off-by: James Cherry <cherry@parallaxsw.com> commit d4a0854dd2102f46f96a94fb9eb8749f1593a85f Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 09:13:46 2023 -0700 PinPairSet no malloc Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a6f1583fc6a856c5ecc0dcb15a1d8b1f61e30718 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 08:53:33 2023 -0700 no malloc for EdgePins Signed-off-by: James Cherry <cherry@parallaxsw.com> commit c8e4b92e8b619109d6aa3c141c720646067ccb4b Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 06:31:08 2023 +0000 leak commit abab99e0fc3e466d914f6c1705aa08cdc204df51 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 16 06:07:36 2023 +0000 leaks commit d1913b554bb6e98b89673d80d2295f552eb4ffca Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 19:48:39 2023 -0700 LibertyCell::checkCornerCell Signed-off-by: James Cherry <cherry@parallaxsw.com> commit bcc172237d48deed647374f9592bac70bd2d5425 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 18:19:47 2023 -0700 rvo Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 8ef9800b87f5e5548055a13afc21397f28a6bcf7 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 18:07:46 2023 -0700 sdc net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit d7235abed04ced4e2d84e91bf9968e621268567d Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 16:00:27 2023 -0700 range iter Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a22f91a3c54c644574339d1126821d9bc8045bd6 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 15:52:50 2023 -0700 range iter Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 762615ce3de91d950eeaaa4680549a45b13e0e0a Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 15:42:19 2023 -0700 range iter Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 7e0c531613d343d23f064c24873bf5a498f6f4ce Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 12:26:49 2023 -0700 rm removeLoadCaps, removeNetLoadCaps Signed-off-by: James Cherry <cherry@parallaxsw.com> commit f2e88c6082e2d4605e9849348008bf4065401fc8 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 12:21:03 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit b5939666188c0b94dfe957e22bbd8a92f4786125 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 11:36:16 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a435081bafe10260743319f53a59cbe2ed0388b7 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 08:43:37 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit acfb247559db7b726d47f203613488df0f7add53 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 08:38:07 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 7541b71da92ea15085615988a1e6ea1d4d53d8d6 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 08:00:55 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit d033210132656ea68fa834228575b9def1d02d90 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 07:52:03 2023 -0700 sdc rm map ptrs Signed-off-by: James Cherry <cherry@parallaxsw.com> commit ca6e9ecb7821b83ab024c4fee6df8f7fc8fc2ce2 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 07:38:12 2023 -0700 instance_pvt_maps_ Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 631e4209b596386f5818045d521784db5239f58d Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 07:26:42 2023 -0700 rm GroupPathIterator Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 059c32afa87617fff530c9afa1ef8005a136739d Author: James Cherry <cherry@parallaxsw.com> Date: Sat Jan 14 20:07:44 2023 -0700 rm ClockIterator Signed-off-by: James Cherry <cherry@parallaxsw.com> commit c65fe873a6a6696220bbb44c4ecac87d5ca978ac Author: James Cherry <cherry@parallaxsw.com> Date: Sat Jan 14 19:45:58 2023 -0700 rvo Signed-off-by: James Cherry <cherry@parallaxsw.com> commit ce15c9a0cc78915acddc2f03749573d989ae96d6 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 15 01:04:03 2023 +0000 leaks commit f97955a0c7e70b65ceb3f697ff47c0524a9b3cd4 Author: James Cherry <cherry@parallaxsw.com> Date: Sat Jan 14 01:17:58 2023 +0000 leaks commit 7cdd65684adeb14e02827f5d93e7fab3b19af5dd Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 16:07:47 2023 -0700 leaks Signed-off-by: James Cherry <cherry@parallaxsw.com> commit ee97c7e50394a3927458e7ef09c5dbeb27719d15 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 11:52:48 2023 -0700 swig rm Tmp collections Signed-off-by: James Cherry <cherry@parallaxsw.com> commit c49935da8704e41459280971b7645fccd97e3d13 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 11:18:36 2023 -0700 swig rm Tmp types Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4320b00ce700914843006f592126cd8cc1c4657a Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 10:55:10 2023 -0700 swig rm TmpPinSet, TmpPinSeq Signed-off-by: James Cherry <cherry@parallaxsw.com> commit ff6004910980c9b09b41f63a553a4481404cc539 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 10:45:06 2023 -0700 swig rm Tmp collections Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 9a5bf5c1a3e5a6d2996b3ab327fa2f3015f2ff20 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 10:15:29 2023 -0700 swig rm one TmpPinSet Signed-off-by: James Cherry <cherry@parallaxsw.com> commit f441116b56e23849485b2393b30e7086c33165a8 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 09:16:56 2023 -0700 leak Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 050b08df8618340b568d9cd41fd3d5f052e2c680 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 09:10:53 2023 -0700 leak Signed-off-by: James Cherry <cherry@parallaxsw.com> commit be8c17f3a715ab53140748dc1d94698209965cf9 Author: James Cherry <cherry@parallaxsw.com> Date: Fri Jan 13 08:59:06 2023 -0700 leak Signed-off-by: James Cherry <cherry@parallaxsw.com> commit e43b82f8fb52eaeda90e3c7e76cf350ae6735ebd Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 18:57:49 2023 -0700 range iter Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 8db56209de7805ac2574fd2f76170bf68afd156d Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 18:08:54 2023 -0700 GroupPathSet net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit cb7917f9827c2ea3afebd735cd4508405a0d77d4 Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 12:00:15 2023 -0700 DataCheckLess net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit d9da3c62d7a76699c6ad62cebb1f5c39f89722fa Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 11:42:27 2023 -0700 rm hashPtr uses Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 5bbea162bb1e023aba813598c7992c740ddf9d0b Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 11:30:12 2023 -0700 EdgePins has use net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit df38405e2ebaabdd7bbf99f3b19d78b25bd95720 Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 09:51:38 2023 -0700 ExceptionPath hash use net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 9a6dcfa54c54c9f50b14248a2449c70c20a0d977 Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 08:56:49 2023 -0700 ClockInsertion, ClockLatency net id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit dbb6dc0b8c93812458df31e93f08e0dbd74e8105 Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 08:34:03 2023 -0700 ExceptionStateSet obj id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 70b8721c48ec0816289ee09b664c332ee095875f Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 08:14:37 2023 -0700 ClockGroups cmp Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4c6c4ca191a99cd8541e106fec3202ee14968f39 Author: James Cherry <cherry@parallaxsw.com> Date: Thu Jan 12 07:38:17 2023 -0700 ClockGroup typedef to ClockSet Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 66f425315e16deee5f00b05c0a505766e7afbf01 Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 20:32:38 2023 -0700 set cmps Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a94866c7828af5b6714e3e4fffc13bdaf5155c0e Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 19:08:09 2023 -0700 net use id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 6348320908f42ebb5262117182e13d0024f65537 Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 11:52:13 2023 -0700 exception id cmp Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 0edfca41b6d6408ac17f8dfe10e697c55146c1ef Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 10:47:02 2023 -0700 range iter Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 44ad77985da9f0b9e7f4780e3f233c8d94fa7db7 Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 08:27:58 2023 -0700 non-ptr set cmp Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 36de7d88c3fa683465604a9e16b2fc1f6bc5fdd0 Author: James Cherry <cherry@parallaxsw.com> Date: Wed Jan 11 08:00:54 2023 -0700 range iteration Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 4a31a2c8d9bdae58b09af8c05a64702ea3ac6c15 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 10 16:43:54 2023 -0700 tcl types Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 056a7447b494a4c8ecc9764650d78a5bed3d87e8 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 10 16:10:36 2023 -0700 tcl types Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 97239554c7625ba50ee729260f08eda7dec02365 Author: James Cherry <cherry@parallaxsw.com> Date: Tue Jan 10 13:10:42 2023 -0700 use RVO Signed-off-by: James Cherry <cherry@parallaxsw.com> commit c3247d8937d483102e3e1f2b69d7ac1d331ba9d4 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 22:41:20 2023 -0700 swig template seq's Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 5431c06feb256adb46858819fcf5d513cfa6b5ec Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 20:50:24 2023 -0700 swig set in template Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 592ad641bf01d3beb862314a0d8986f66e258642 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 17:27:25 2023 -0700 network return containers Signed-off-by: James Cherry <cherry@parallaxsw.com> commit c95f8b77e0d6bd5ffa5ba8102413c70883c756e1 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 12:15:37 2023 -0700 PinSeq const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 702e7f9ba2f901066a38f32e67b35602b6c7bbdf Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 12:02:29 2023 -0700 InstanceSeq const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 44fc25ba4a15e4ae570d74af27c9435872a126e0 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 12:01:45 2023 -0700 NetSeq const Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 03b2725c81f5d52c33c875b55056c11d482144f1 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 11:33:18 2023 -0700 rm PortPair Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 3fb82a7344dc053171c9883a113764ba691ab827 Author: James Cherry <cherry@parallaxsw.com> Date: Mon Jan 9 11:20:53 2023 -0700 PinSet id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 3dd31f027e15d40d62a11d0a88ef2a115f01fb73 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 8 15:03:33 2023 -0700 InstanceSet id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit a91dea5cc0af3bede36b3faed13adb05239ff907 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 8 11:40:15 2023 -0700 NetSet id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit b91e4b6410134eccae7969ddcfb0b27933b2e746 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 8 10:44:47 2023 -0700 CellSet, PortSet id Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 6f891f77fae5a6b19c1454a1a4b4e3dfae0b5c50 Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 8 10:29:25 2023 -0700 network object sets Signed-off-by: James Cherry <cherry@parallaxsw.com> commit eb8c627a57ecc6e7c5846a01d62b090ff91c08bf Author: James Cherry <cherry@parallaxsw.com> Date: Sun Jan 8 10:09:00 2023 -0700 PinSet1 Signed-off-by: James Cherry <cherry@parallaxsw.com> commit 8e864ecbdf87000fbb3c3097c39f06173c941e35 Author: James Cherry <cherry@parallaxsw.com> Date: Sat Jan 7 17:13:03 2023 -0700 concrete network object id Signed-off-by: James Cherry <cherry@parallaxsw.com> Signed-off-by: James Cherry <cherry@parallaxsw.com>
2023-01-19 19:23:45 +01:00
project(STA VERSION 2.4.0
2020-04-12 06:31:48 +02:00
LANGUAGES CXX
)
2019-01-01 21:27:23 +01:00
option(USE_CUDD "Use CUDD BDD package")
2020-04-05 00:53:51 +02:00
option(CUDD_DIR "CUDD BDD package directory")
2019-01-01 21:27:23 +01:00
set(CMAKE_VERBOSE_MAKEFILE ON)
set(STA_HOME ${PROJECT_SOURCE_DIR})
message(STATUS "STA version: ${PROJECT_VERSION}")
2019-07-07 18:58:47 +02:00
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
include(GetGitRevisionDescription)
get_git_head_revision(GIT_REFSPEC STA_GIT_SHA1)
message(STATUS "STA git sha: ${STA_GIT_SHA1}")
2019-01-01 21:27:23 +01:00
# Default to bulding optimnized/release executable.
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE RELEASE)
endif()
message(STATUS "System name: ${CMAKE_SYSTEM_NAME}")
message(STATUS "Compiler: ${CMAKE_CXX_COMPILER_ID} ${CMAKE_CXX_COMPILER_VERSION}")
message(STATUS "Build type: ${CMAKE_BUILD_TYPE}")
message(STATUS "Build CXX_FLAGS: ${CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}}")
2019-01-01 21:27:23 +01:00
message(STATUS "Install prefix: ${CMAKE_INSTALL_PREFIX}")
################################################################
#
# Source files.
#
################################################################
set(STA_SOURCE
app/StaMain.cc
2019-01-01 21:27:23 +01:00
dcalc/ArcDelayCalc.cc
dcalc/ArnoldiDelayCalc.cc
dcalc/ArnoldiReduce.cc
dcalc/DcalcAnalysisPt.cc
dcalc/DelayCalc.cc
dcalc/DmpCeff.cc
dcalc/DmpDelayCalc.cc
dcalc/GraphDelayCalc.cc
dcalc/GraphDelayCalc1.cc
dcalc/LumpedCapDelayCalc.cc
dcalc/NetCaps.cc
dcalc/RCDelayCalc.cc
dcalc/SimpleRCDelayCalc.cc
dcalc/UnitDelayCalc.cc
2019-01-01 21:27:23 +01:00
graph/DelayFloat.cc
2019-03-22 00:19:16 +01:00
graph/DelayNormal1.cc
2019-01-01 21:27:23 +01:00
graph/DelayNormal2.cc
graph/Graph.cc
graph/GraphCmp.cc
liberty/EquivCells.cc
liberty/FuncExpr.cc
liberty/InternalPower.cc
liberty/LeakagePower.cc
liberty/Liberty.cc
liberty/LibertyBuilder.cc
liberty/LibertyExpr.cc
liberty/LibertyExprPvt.hh
liberty/LibertyParser.cc
liberty/LibertyReader.cc
liberty/LibertyWriter.cc
2019-01-01 21:27:23 +01:00
liberty/LinearModel.cc
liberty/Sequential.cc
liberty/TableModel.cc
liberty/TimingArc.cc
liberty/TimingRole.cc
liberty/Units.cc
liberty/Wireload.cc
2019-01-01 21:27:23 +01:00
network/ConcreteLibrary.cc
network/ConcreteNetwork.cc
network/HpinDrvrLoad.cc
network/Network.cc
network/NetworkCmp.cc
network/ParseBus.cc
network/PortDirection.cc
network/SdcNetwork.cc
network/VerilogNamespace.cc
parasitics/ConcreteParasitics.cc
parasitics/EstimateParasitics.cc
parasitics/NullParasitics.cc
parasitics/Parasitics.cc
parasitics/ReduceParasitics.cc
parasitics/ReportParasiticAnnotation.cc
2019-01-01 21:27:23 +01:00
parasitics/SpefNamespace.cc
parasitics/SpefReader.cc
parasitics/SpefReaderPvt.hh
2019-01-01 21:27:23 +01:00
sdc/Clock.cc
sdc/ClockGatingCheck.cc
sdc/ClockGroups.cc
sdc/ClockInsertion.cc
sdc/ClockLatency.cc
sdc/CycleAccting.cc
sdc/DataCheck.cc
sdc/DeratingFactors.cc
sdc/DisabledPorts.cc
sdc/ExceptionPath.cc
sdc/InputDrive.cc
sdc/PinPair.cc
sdc/PortDelay.cc
sdc/PortExtCap.cc
sdc/Sdc.cc
2020-07-12 08:56:39 +02:00
sdc/SdcGraph.cc
2019-01-01 21:27:23 +01:00
sdc/SdcCmdComment.cc
sdc/WriteSdc.cc
sdf/ReportAnnotation.cc
sdf/SdfReader.cc
sdf/SdfWriter.cc
2019-01-01 21:27:23 +01:00
search/Bfs.cc
search/CheckMaxSkews.cc
search/CheckMinPeriods.cc
search/CheckMinPulseWidths.cc
2020-06-02 20:08:48 +02:00
search/CheckCapacitanceLimits.cc
search/CheckFanoutLimits.cc
2019-01-01 21:27:23 +01:00
search/CheckSlewLimits.cc
search/CheckTiming.cc
search/ClkInfo.cc
2020-08-09 03:44:19 +02:00
search/ClkNetwork.cc
2019-01-01 21:27:23 +01:00
search/ClkSkew.cc
search/Corner.cc
search/Crpr.cc
search/FindRegister.cc
search/GatedClk.cc
search/Genclks.cc
search/Latches.cc
search/Levelize.cc
search/MakeTimingModel.cc
2019-01-01 21:27:23 +01:00
search/Path.cc
search/PathAnalysisPt.cc
search/PathEnd.cc
search/PathEnum.cc
search/PathEnumed.cc
search/PathExpanded.cc
search/PathGroup.cc
search/PathRef.cc
search/PathVertex.cc
search/PathVertexRep.cc
search/Property.cc
search/ReportPath.cc
search/Search.cc
search/SearchPred.cc
search/Sim.cc
search/Sta.cc
search/StaState.cc
search/Tag.cc
search/TagGroup.cc
search/VertexVisitor.cc
search/VisitPathEnds.cc
search/VisitPathGroupVertices.cc
search/WorstSlack.cc
2019-01-04 01:14:15 +01:00
search/WritePathSpice.cc
power/Power.cc
power/ReadVcdActivities.cc
power/Vcd.cc
power/VcdReader.cc
2019-01-01 21:27:23 +01:00
util/Debug.cc
2019-11-11 16:48:27 +01:00
util/DispatchQueue.cc
2019-01-01 21:27:23 +01:00
util/Error.cc
util/Fuzzy.cc
2019-07-08 20:50:41 +02:00
util/Hash.cc
2019-01-01 21:27:23 +01:00
util/Machine.cc
util/MinMax.cc
util/PatternMatch.cc
util/Report.cc
util/ReportStd.cc
util/ReportTcl.cc
util/RiseFallMinMax.cc
util/RiseFallValues.cc
2019-01-01 21:27:23 +01:00
util/Stats.cc
util/StringSeq.cc
util/StringSet.cc
util/StringUtil.cc
util/TokenParser.cc
util/Transition.cc
2019-01-01 21:27:23 +01:00
verilog/VerilogReader.cc
2019-06-17 06:08:00 +02:00
verilog/VerilogWriter.cc
)
2019-01-01 21:27:23 +01:00
# Source files.
set(STA_TCL_FILES
tcl/Init.tcl
tcl/Util.tcl
tcl/Graph.tcl
tcl/Liberty.tcl
tcl/Link.tcl
tcl/Network.tcl
tcl/NetworkEdit.tcl
tcl/Sdc.tcl
tcl/Search.tcl
tcl/Cmds.tcl
tcl/Variables.tcl
tcl/Sta.tcl
tcl/Splash.tcl
dcalc/DelayCalc.tcl
parasitics/Parasitics.tcl
power/Power.tcl
sdf/Sdf.tcl
verilog/Verilog.tcl
)
2019-01-01 21:27:23 +01:00
################################################################
#
# Flex/bison scanner/parsers
#
################################################################
2021-02-08 01:33:53 +01:00
# Earlier versions of flex use 'register' declarations that are deprecated
# in c++11 and illegal in c++17.
2020-11-11 16:32:25 +01:00
#find_package(FLEX 2.6.4)
find_package(FLEX)
find_package(BISON)
# LibertyExpr scan/parse.
2020-01-27 21:14:45 +01:00
flex_target(LibertyExprLex ${STA_HOME}/liberty/LibertyExprLex.ll ${CMAKE_CURRENT_BINARY_DIR}/LibertyExprLex.cc
2020-01-25 18:38:03 +01:00
COMPILE_FLAGS --prefix=LibertyExprLex_)
2020-01-27 21:14:45 +01:00
bison_target(LibertyExprParser ${STA_HOME}/liberty/LibertyExprParse.yy ${CMAKE_CURRENT_BINARY_DIR}/LibertyExprParse.cc
COMPILE_FLAGS --name-prefix=LibertyExprParse_
)
add_flex_bison_dependency(LibertyExprLex LibertyExprParser)
# Liberty scan/parse.
2020-01-27 21:14:45 +01:00
flex_target(LibertyLex ${STA_HOME}/liberty/LibertyLex.ll ${CMAKE_CURRENT_BINARY_DIR}/LibertyLex.cc
COMPILE_FLAGS --prefix=LibertyLex_
)
2020-01-27 21:14:45 +01:00
bison_target(LibertyParser ${STA_HOME}/liberty/LibertyParse.yy ${CMAKE_CURRENT_BINARY_DIR}/LibertyParse.cc
2021-03-16 18:27:17 +01:00
COMPILE_FLAGS "--name-prefix=LibertyParse_ -v"
)
add_flex_bison_dependency(LibertyLex LibertyParser)
# Spef scan/parse.
2020-01-27 21:14:45 +01:00
flex_target(SpefLex ${STA_HOME}/parasitics/SpefLex.ll ${CMAKE_CURRENT_BINARY_DIR}/SpefLex.cc
COMPILE_FLAGS --prefix=SpefLex_
)
2020-01-27 21:14:45 +01:00
bison_target(SpefParser ${STA_HOME}/parasitics/SpefParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SpefParse.cc
COMPILE_FLAGS --name-prefix=SpefParse_
)
add_flex_bison_dependency(SpefLex SpefParser)
# Verilog scan/parse.
2020-01-27 21:14:45 +01:00
flex_target(VerilogLex ${STA_HOME}/verilog/VerilogLex.ll ${CMAKE_CURRENT_BINARY_DIR}/VerilogLex.cc
COMPILE_FLAGS --prefix=VerilogLex_
)
2020-01-27 21:14:45 +01:00
bison_target(VerilogParser ${STA_HOME}/verilog/VerilogParse.yy ${CMAKE_CURRENT_BINARY_DIR}/VerilogParse.cc
COMPILE_FLAGS --name-prefix=VerilogParse_
)
add_flex_bison_dependency(VerilogLex VerilogParser)
# Sdf scan/parse.
2020-01-27 21:14:45 +01:00
flex_target(SdfLex ${STA_HOME}/sdf/SdfLex.ll ${CMAKE_CURRENT_BINARY_DIR}/SdfLex.cc
COMPILE_FLAGS --prefix=SdfLex_
)
2020-01-27 21:14:45 +01:00
bison_target(SdfParser ${STA_HOME}/sdf/SdfParse.yy ${CMAKE_CURRENT_BINARY_DIR}/SdfParse.cc
COMPILE_FLAGS --name-prefix=SdfParse_
)
add_flex_bison_dependency(SdfLex SdfParser)
################################################################
2020-09-16 01:50:33 +02:00
find_package(SWIG 3.0 REQUIRED)
2020-01-25 18:38:03 +01:00
include(UseSWIG)
2020-01-25 20:12:00 +01:00
set(STA_SWIG_FILE app/StaApp.i)
2020-01-25 20:12:00 +01:00
set_property(SOURCE ${STA_SWIG_FILE}
PROPERTY CPLUSPLUS ON
)
2020-01-26 00:06:54 +01:00
# Ubuntu 18.04 cmake version 3.10.2 does not support the
# COMPILE_OPTIONS and INCLUDE_DIRECTORIES properties, so cram
2020-01-25 22:20:23 +01:00
# them into SWIG_FLAGS for the time being.
set_property(SOURCE ${STA_SWIG_FILE}
PROPERTY SWIG_FLAGS
-module sta
-namespace -prefix sta
-I${STA_HOME}/tcl
-I${STA_HOME}/sdf
-I${STA_HOME}/dcalc
-I${STA_HOME}/parasitics
-I${STA_HOME}/power
2020-01-25 22:20:23 +01:00
-I${STA_HOME}/verilog
2020-01-25 18:38:03 +01:00
)
set_property(SOURCE ${STA_SWIG_FILE}
PROPERTY DEPENDS
${STA_HOME}/dcalc/DelayCalc.i
${STA_HOME}/parasitics/Parasitics.i
${STA_HOME}/power/Power.i
${STA_HOME}/sdf/Sdf.i
${STA_HOME}/tcl/Exception.i
2020-03-09 22:29:48 +01:00
${STA_HOME}/tcl/StaTcl.i
2020-03-09 22:31:55 +01:00
${STA_HOME}/tcl/NetworkEdit.i
${STA_HOME}/verilog/Verilog.i
)
2020-01-25 18:38:03 +01:00
swig_add_library(sta_swig
LANGUAGE tcl
TYPE STATIC
SOURCES ${STA_SWIG_FILE}
)
get_target_property(SWIG_FILES sta_swig SOURCES)
foreach(SWIG_FILE ${SWIG_FILES})
set_source_files_properties(${SWIG_FILE}
PROPERTIES
# No simple way to modify the swig template that emits code full of warnings
# so suppress them.
COMPILE_OPTIONS "-Wno-cast-qual;-Wno-missing-braces;-Wno-deprecated-declarations"
)
endforeach()
2020-07-26 02:02:56 +02:00
target_link_libraries(sta_swig
2020-01-25 18:38:03 +01:00
PUBLIC
OpenSTA
)
2020-05-15 03:05:42 +02:00
# result build/CMakeFiles/sta_swig.dir/StaAppTCL_wrap.cxx
2020-04-05 20:35:51 +02:00
target_include_directories(sta_swig
PUBLIC
include/sta
PRIVATE
${STA_HOME}
2020-04-07 23:37:52 +02:00
${TCL_INCLUDE_PATH}
2020-04-05 20:35:51 +02:00
)
################################################################
set(STA_TCL_INIT ${CMAKE_CURRENT_BINARY_DIR}/StaTclInitVar.cc)
# TCL files included as part of the executable are shoved into StaTclInitVar.cc.
# These files are encoded and shipped as part of the executable
# so that they do not have to be installed on the client host.
add_custom_command(OUTPUT ${STA_TCL_INIT}
COMMAND etc/TclEncode.tcl ${STA_TCL_INIT} tcl_inits ${STA_TCL_FILES}
WORKING_DIRECTORY ${STA_HOME}
DEPENDS ${STA_TCL_FILES} etc/TclEncode.tcl
)
2019-01-01 21:27:23 +01:00
################################################################
2019-01-06 01:09:27 +01:00
#
2019-01-01 21:27:23 +01:00
# Library dependencies
2019-01-06 01:09:27 +01:00
#
2019-01-01 21:27:23 +01:00
################################################################
2020-01-08 02:08:53 +01:00
# OSX tcl is deprecated and prints a warning, so look for a user installed
# version before using the system version.
# I tried to override the library search order instead but failed.
# CMAKE_FIND_FRAMEWORK LAST bypasses the version in the framework directory
# but not the one in /usr/lib.
# This calls cmake/FindTCL.cmake
# Do not use REQUIRED because it also requires TK, which is not used by OpenSTA.
2020-01-08 02:08:53 +01:00
find_package(TCL)
2019-12-13 06:31:22 +01:00
option(USE_TCL_READLINE "Use TCL readliine package")
set(TCL_READLINE 0)
# check for tclReadline
if (USE_TCL_READLINE)
find_library(TCL_READLINE_LIBRARY tclreadline)
if (TCL_READLINE_LIBRARY)
message(STATUS "TCL readline: ${TCL_READLINE_LIBRARY}")
# Referenced by StaConfig.hh.cmake
set(TCL_READLINE 1)
get_filename_component(TCL_READLINE_LIB_DIR "${TCL_READLINE_LIBRARY}" PATH)
get_filename_component(TCL_READLINE_LIB_PARENT "${TCL_READLINE_LIB_DIR}" PATH)
find_file(TCL_READLINE_HEADER tclreadline.h
PATHS ${TCL_READLINE_LIB_PARENT}
PATH_SUFFIXES include
NO_DEFAULT_PATH
)
message(STATUS "TCL readline header: ${TCL_READLINE_HEADER}")
get_filename_component(TCL_READLINE_INCLUDE "${TCL_READLINE_HEADER}" PATH)
else()
message(STATUS "TCL readline: not found")
endif()
endif()
2019-01-06 01:09:27 +01:00
# Zlib
2019-01-01 21:27:23 +01:00
include(FindZLIB)
2020-09-09 18:43:37 +02:00
find_package(Threads)
2019-01-06 01:09:27 +01:00
################################################################
#
2020-04-03 18:23:27 +02:00
# Locate CUDD bdd package.
#
2020-04-05 00:53:51 +02:00
set(CUDD 0)
if (USE_CUDD)
find_library(CUDD_LIB
NAME cudd
PATHS ${CUDD_DIR}
PATH_SUFFIXES lib lib/cudd
)
if (CUDD_LIB)
message(STATUS "CUDD library: ${CUDD_LIB}")
get_filename_component(CUDD_LIB_DIR "${CUDD_LIB}" PATH)
get_filename_component(CUDD_LIB_PARENT1 "${CUDD_LIB_DIR}" PATH)
find_file(CUDD_HEADER cudd.h
PATHS ${CUDD_LIB_PARENT1}/include ${CUDD_LIB_PARENT1}/include/cudd)
if (CUDD_HEADER)
get_filename_component(CUDD_INCLUDE "${CUDD_HEADER}" PATH)
message(STATUS "CUDD header: ${CUDD_HEADER}")
# Referenced by StaConfig.hh.cmake
set(CUDD 1)
else()
message(STATUS "CUDD header: not found")
endif()
2020-04-03 18:23:27 +02:00
else()
message(STATUS "CUDD library: not found")
2020-04-03 18:23:27 +02:00
endif()
2019-01-01 21:27:23 +01:00
endif()
2019-01-06 01:09:27 +01:00
if("${SSTA}" STREQUAL "")
set(SSTA 0)
endif()
2019-03-13 01:25:53 +01:00
message(STATUS "SSTA: ${SSTA}")
2019-01-06 01:09:27 +01:00
2020-04-05 23:53:44 +02:00
# configure a header file to pass some of the CMake settings
2019-02-16 21:07:59 +01:00
configure_file(${STA_HOME}/util/StaConfig.hh.cmake
2020-04-05 23:53:44 +02:00
${STA_HOME}/include/sta/StaConfig.hh
)
2019-01-01 21:27:23 +01:00
###########################################################
2019-06-05 20:29:28 +02:00
# Library
2019-01-01 21:27:23 +01:00
###########################################################
# compatibility with configure
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${STA_HOME}/app)
add_library(OpenSTA
${STA_SOURCE}
${STA_TCL_INIT}
${FLEX_LibertyExprLex_OUTPUTS}
${BISON_LibertyExprParser_OUTPUTS}
${FLEX_LibertyLex_OUTPUTS}
${BISON_LibertyParser_OUTPUTS}
${FLEX_SpefLex_OUTPUTS}
${BISON_SpefParser_OUTPUTS}
${FLEX_SdfLex_OUTPUTS}
${BISON_SdfParser_OUTPUTS}
${FLEX_VerilogLex_OUTPUTS}
${BISON_VerilogParser_OUTPUTS}
)
2019-01-01 21:27:23 +01:00
2019-12-13 06:31:22 +01:00
target_include_directories(OpenSTA
2020-04-05 00:53:51 +02:00
PUBLIC
2020-04-06 00:56:27 +02:00
include
2020-04-07 05:37:20 +02:00
${TCL_INCLUDE_PATH}
${TCL_READLINE_INCLUDE}
2020-04-05 02:07:43 +02:00
PRIVATE
2020-04-06 00:56:27 +02:00
include/sta
${STA_HOME}
2020-04-07 23:37:52 +02:00
${CUDD_INCLUDE}
2019-12-13 06:31:22 +01:00
)
2019-01-01 21:27:23 +01:00
2020-11-10 04:44:50 +01:00
target_compile_options(OpenSTA
PRIVATE
$<$<CXX_COMPILER_ID:GNU>:-Wall -Wextra -pedantic -Wcast-qual -Wredundant-decls -Wformat-security>
2021-01-01 20:46:51 +01:00
$<$<CXX_COMPILER_ID:AppleClang>:-Wall -Wextra -pedantic -Wcast-qual -Wredundant-decls -Wformat-security -Wno-gnu-zero-variadic-macro-arguments>
$<$<CXX_COMPILER_ID:Clang>:-Wall -Wextra -pedantic -Wcast-qual -Wredundant-decls -Wformat-security -Wno-gnu-zero-variadic-macro-arguments>
2020-11-10 04:44:50 +01:00
)
2020-09-17 03:29:15 +02:00
# Disable compiler specific extensions like gnu++11.
set_target_properties(OpenSTA PROPERTIES CXX_EXTENSIONS OFF)
2020-09-17 18:22:00 +02:00
target_compile_features(OpenSTA PUBLIC cxx_std_11)
2019-05-28 07:46:24 +02:00
2019-01-01 21:27:23 +01:00
###########################################################
# Executable
###########################################################
# compatibility with configure
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${STA_HOME}/app)
# Note executable and lib name cannot be the same because
# on osx something is case insensitive. Using STA for the
# lib name results in "No rule to make target ../depend.
2020-04-07 05:37:20 +02:00
add_executable(sta app/Main.cc)
2020-01-25 18:38:03 +01:00
2019-01-01 21:27:23 +01:00
target_link_libraries(sta
2020-01-25 18:38:03 +01:00
sta_swig
2020-07-26 02:02:56 +02:00
OpenSTA
2020-01-08 01:17:19 +01:00
${TCL_LIBRARY}
2020-09-09 18:43:37 +02:00
${CMAKE_THREAD_LIBS_INIT}
)
if (TCL_READLINE_LIBRARY)
target_link_libraries(sta ${TCL_READLINE_LIBRARY})
endif()
2020-04-12 06:31:48 +02:00
if (ZLIB_LIBRARIES)
target_link_libraries(sta ${ZLIB_LIBRARIES})
endif()
2020-04-05 01:12:41 +02:00
if (CUDD_LIB)
2020-04-12 06:31:48 +02:00
target_link_libraries(sta ${CUDD_LIB})
2020-04-05 01:12:41 +02:00
endif()
2019-01-01 21:27:23 +01:00
message(STATUS "STA executable: ${STA_HOME}/app/sta")
################################################################
# Install
# cmake .. -DCMAKE_INSTALL_PREFIX=<prefix_path>
# executable
install(TARGETS sta DESTINATION bin)
# library
2019-06-05 20:29:28 +02:00
install(TARGETS OpenSTA DESTINATION lib)
2019-01-01 21:27:23 +01:00
# include
2020-04-06 00:56:27 +02:00
install(DIRECTORY include/sta DESTINATION include)
2019-01-23 05:41:32 +01:00
################################################################
2020-08-31 06:35:15 +02:00
add_custom_target(sta_tags etags -o TAGS
2020-06-02 20:08:48 +02:00
${STA_SOURCE}
2020-08-31 06:35:15 +02:00
*/*.hh
include/sta/*.hh
${STA_TCL_FILES}
${SWIG_TCL_FILES}
WORKING_DIRECTORY ${STA_HOME}
)