From 09e8eb6e6a6fca11bd24f9fd3e3204e515d953cf Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 17 Jul 2021 16:31:19 -0700 Subject: [PATCH 01/35] Build fixes/tweaks for (optional) shared libs, reduced footprint * fix a handful of warnings, add missing gia.c to module.make * add makefile overrides and a soname, make library symlinks * add separate shared library/test targets * add -fvisibility=hidden to cxxflags, makes build result much smaller * add visibility pragma for demo consumer * add ci workflow with simple gcc/clang matrix Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 94 ++++++++++++++++++++++++++++++++++++++++ Makefile | 66 +++++++++++++++++++--------- src/aig/gia/module.make | 3 +- src/base/main/mainReal.c | 4 +- 4 files changed, 144 insertions(+), 23 deletions(-) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000000..da55567ff1 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,94 @@ +name: ci + +on: + workflow_dispatch: + pull_request: + push: + branches: + - master + paths-ignore: + - '**.md' + - '**.rst' + - '**.sh' + +jobs: + build: + name: ${{ matrix.name }} + runs-on: ${{ matrix.os }} + defaults: + run: + shell: bash + + strategy: + fail-fast: false + matrix: + + name: [ + ubuntu-20.04-gcc, + ubuntu-20.04-clang, + macOS-10.15-gcc, + ] + + include: + - name: ubuntu-20.04-gcc + os: ubuntu-20.04 + compiler: gcc + version: "9" + + - name: ubuntu-20.04-clang + os: ubuntu-20.04 + compiler: clang + version: "6" + + - name: macOS-10.15-gcc + os: macOS-10.15 + compiler: gcc + version: "10" + + steps: + - uses: actions/checkout@v2 + + - name: Install and setup Linux packages + if: runner.os == 'Linux' + run: | + sudo apt-get -y -qq update + sudo apt-get install -y libreadline-dev ncurses-dev + if [ "${{ matrix.compiler }}" = "gcc" ]; then + sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib + echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV + else + sudo apt-get install -y clang-${{ matrix.version }} g++-multilib + echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV + fi + + - name: Build and test Linux + if: runner.os == 'Linux' + env: + CC: ${{ env.CC }} + CXX: ${{ env.CXX }} + run: | + make ABC_MAKE_VERBOSE=1 ABC_USE_NAMESPACE=xxx OPTFLAGS= ABC_USE_PIC=1 abc test + + - name: Install and setup MacOS packages + if: runner.os == 'macOS' + run: | + if [ "${{ matrix.compiler }}" = "gcc" ]; then + brew install gcc@${{ matrix.version }} + echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV + else + ls -ls /Applications/ + sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.2.app + echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV + fi + + - name: Build and test MacOS + if: runner.os == 'macOS' + env: + CC: ${{ env.CC }} + CXX: ${{ env.CXX }} + run: | + make ABC_MAKE_VERBOSE=1 ABC_USE_NAMESPACE=xxx OPTFLAGS= ABC_USE_PIC=1 abc test diff --git a/Makefile b/Makefile index 50cff2d170..51949e9275 100644 --- a/Makefile +++ b/Makefile @@ -1,21 +1,22 @@ -CC := gcc -CXX := g++ -AR := ar +CC ?= gcc +CXX ?= g++ +AR ?= ar LD := $(CXX) +LN ?= ln +MV ?= mv MSG_PREFIX ?= ABCSRC ?= . VPATH = $(ABCSRC) -$(info $(MSG_PREFIX)Using CC=$(CC)) -$(info $(MSG_PREFIX)Using CXX=$(CXX)) -$(info $(MSG_PREFIX)Using AR=$(AR)) -$(info $(MSG_PREFIX)Using LD=$(LD)) - PROG := abc OS := $(shell uname -s) +VERSION ?= 1.1.0 +SOVERSION ?= 1 +SONAME := lib$(PROG).so.$(SOVERSION) + MODULES := \ $(wildcard src/ext*) \ src/base/abc src/base/abci src/base/cmd src/base/io src/base/main src/base/exor \ @@ -64,9 +65,12 @@ endif # compile ABC using the C++ compiler and put everything in the namespace $(ABC_NAMESPACE) ifdef ABC_USE_NAMESPACE - CFLAGS += -DABC_NAMESPACE=$(ABC_USE_NAMESPACE) -fpermissive -x c++ + CFLAGS += -DABC_NAMESPACE=$(ABC_USE_NAMESPACE) -std=c++11 -fvisibility=hidden -fpermissive CC := $(CXX) + DLIBS := -lstdc++ $(info $(MSG_PREFIX)Compiling in namespace $(ABC_NAMESPACE)) +else + ABC_USE_LIBSTDCXX := 1 endif # compile CUDD with ABC @@ -120,7 +124,7 @@ GCC_VERSION=$(shell $(CC) -dumpversion) GCC_MAJOR=$(word 1,$(subst .,$(space),$(GCC_VERSION))) GCC_MINOR=$(word 2,$(subst .,$(space),$(GCC_VERSION))) -$(info $(MSG_PREFIX)Found GCC_VERSION $(GCC_VERSION)) +$(info $(MSG_PREFIX)Found CC_VERSION $(GCC_VERSION)) ifeq ($(findstring $(GCC_MAJOR),0 1 2 3),) ifeq ($(GCC_MAJOR),4) $(info $(MSG_PREFIX)Found GCC_MAJOR==4) @@ -130,9 +134,12 @@ CFLAGS += -Wno-unused-but-set-variable endif else $(info $(MSG_PREFIX)Found GCC_MAJOR>=5) +CLANG_HEADER=$(shell $(CC) --version | grep -w clang) +ifeq (,$(CLANG_HEADER)) CFLAGS += -Wno-unused-but-set-variable endif endif +endif endif @@ -151,11 +158,17 @@ ifdef ABC_USE_LIBSTDCXX $(info $(MSG_PREFIX)Using explicit -lstdc++) endif +$(info $(MSG_PREFIX)Using CC=$(CC)) +$(info $(MSG_PREFIX)Using CXX=$(CXX)) +$(info $(MSG_PREFIX)Using AR=$(AR)) +$(info $(MSG_PREFIX)Using LD=$(LD)) + $(info $(MSG_PREFIX)Using CFLAGS=$(CFLAGS)) CXXFLAGS += $(CFLAGS) -std=c++17 -fno-exceptions +$(info $(MSG_PREFIX)Using CXXFLAGS=$(CXXFLAGS)) SRC := -GARBAGE := core core.* *.stackdump ./tags $(PROG) arch_flags +GARBAGE := core core.* *.stackdump ./tags $(PROG) demo arch_flags .PHONY: all default tags clean docs cmake_info @@ -168,6 +181,8 @@ OBJ := \ $(patsubst %.y, %.o, $(filter %.y, $(SRC))) LIBOBJ := $(filter-out src/base/main/main.o,$(OBJ)) +MAINOBJ := src/base/main/main.o +DEMOOBJ := src/demo.o DEP := $(OBJ:.o=.d) @@ -213,25 +228,36 @@ depend: $(DEP) clean: @echo "$(MSG_PREFIX)\`\` Cleaning up..." - $(VERBOSE)rm -rvf $(PROG) lib$(PROG).a - $(VERBOSE)rm -rvf $(OBJ) - $(VERBOSE)rm -rvf $(GARBAGE) - $(VERBOSE)rm -rvf $(OBJ:.o=.d) + $(VERBOSE)rm -rvf $(PROG) lib$(PROG).* $(OBJ) $(GARBAGE) $(OBJ:.o=.d) tags: etags `find . -type f -regex '.*\.\(c\|h\)'` -$(PROG): $(OBJ) - @echo "$(MSG_PREFIX)\`\` Building binary:" $(notdir $@) - $(VERBOSE)$(LD) -o $@ $^ $(LDFLAGS) $(LIBS) +lib: lib$(PROG).so.$(VERSION) + +test: demo + ./demo i10.aig + +demo: $(DEMOOBJ) lib$(PROG).a + @echo "$(MSG_PREFIX)\`\` Linking binary:" $(notdir $@) + +$(VERBOSE)$(LD) -o $@ $(DEMOOBJ) lib$(PROG).a $(LDFLAGS) $(DLIBS) $(LIBS) + +$(PROG): $(MAINOBJ) lib$(PROG).so + @echo "$(MSG_PREFIX)\`\` Linking binary:" $(notdir $@) + +$(VERBOSE)$(LD) -o $@ $(MAINOBJ) -L. -l$(PROG) $(LDFLAGS) $(LIBS) lib$(PROG).a: $(LIBOBJ) @echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@) $(VERBOSE)$(AR) rsv $@ $? -lib$(PROG).so: $(LIBOBJ) +lib$(PROG).so.$(VERSION): $(LIBOBJ) @echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@) - $(VERBOSE)$(CXX) -shared -o $@ $^ $(LIBS) + +$(VERBOSE)$(LD) -shared -Wl,-soname=$(SONAME) -o $@ $^ $(LIBS) + +lib$(PROG).so: lib$(PROG).so.$(VERSION) + ldconfig -v -n . + @$(LN) -sf lib$(PROG).so.$(VERSION) lib$(PROG).so + @$(LN) -sf lib$(PROG).so.$(VERSION) $(SONAME) docs: @echo "$(MSG_PREFIX)\`\` Building documentation." $(notdir $@) diff --git a/src/aig/gia/module.make b/src/aig/gia/module.make index 2e64d1d1b2..99938cd6c0 100644 --- a/src/aig/gia/module.make +++ b/src/aig/gia/module.make @@ -1,4 +1,5 @@ -SRC += src/aig/gia/giaAig.c \ +SRC += src/aig/gia/gia.c \ + src/aig/gia/giaAig.c \ src/aig/gia/giaAgi.c \ src/aig/gia/giaAiger.c \ src/aig/gia/giaAigerExt.c \ diff --git a/src/base/main/mainReal.c b/src/base/main/mainReal.c index 420f2cf101..ec2fcb0751 100644 --- a/src/base/main/mainReal.c +++ b/src/base/main/mainReal.c @@ -59,9 +59,9 @@ SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. #include "mainInt.h" #include "base/wlc/wlc.h" +#pragma GCC visibility push(default) ABC_NAMESPACE_IMPL_START - //////////////////////////////////////////////////////////////////////// /// DECLARATIONS /// //////////////////////////////////////////////////////////////////////// @@ -422,5 +422,5 @@ static int TypeCheck( Abc_Frame_t * pAbc, const char * s ) /// END OF FILE /// //////////////////////////////////////////////////////////////////////// - ABC_NAMESPACE_IMPL_END +#pragma GCC visibility pop From 9507c0be153e60cb0c48ce420a61fd6978242e4e Mon Sep 17 00:00:00 2001 From: Anonymous Maarten Date: Tue, 13 Nov 2018 23:44:22 +0100 Subject: [PATCH 02/35] Add pure cmake build system --- CMakeLists.txt | 377 +++++++++++++++++++++++-------- src/aig/aig/CMakeLists.txt | 35 +++ src/aig/gia/CMakeLists.txt | 95 ++++++++ src/aig/hop/CMakeLists.txt | 14 ++ src/aig/ioa/CMakeLists.txt | 7 + src/aig/ivy/CMakeLists.txt | 26 +++ src/aig/miniaig/CMakeLists.txt | 0 src/aig/saig/CMakeLists.txt | 30 +++ src/base/abc/CMakeLists.txt | 27 +++ src/base/abci/CMakeLists.txt | 79 +++++++ src/base/acb/CMakeLists.txt | 12 + src/base/bac/CMakeLists.txt | 19 ++ src/base/cba/CMakeLists.txt | 12 + src/base/cmd/CMakeLists.txt | 14 ++ src/base/exor/CMakeLists.txt | 10 + src/base/io/CMakeLists.txt | 35 +++ src/base/main/CMakeLists.txt | 23 ++ src/base/pla/CMakeLists.txt | 11 + src/base/test/CMakeLists.txt | 5 + src/base/ver/CMakeLists.txt | 8 + src/base/wlc/CMakeLists.txt | 23 ++ src/base/wln/CMakeLists.txt | 10 + src/bdd/bbr/CMakeLists.txt | 8 + src/bdd/cas/CMakeLists.txt | 6 + src/bdd/cudd/CMakeLists.txt | 65 ++++++ src/bdd/dsd/CMakeLists.txt | 10 + src/bdd/epd/CMakeLists.txt | 5 + src/bdd/extrab/CMakeLists.txt | 15 ++ src/bdd/llb/CMakeLists.txt | 26 +++ src/bdd/mtr/CMakeLists.txt | 6 + src/bdd/reo/CMakeLists.txt | 12 + src/bool/bdc/CMakeLists.txt | 8 + src/bool/dec/CMakeLists.txt | 9 + src/bool/deco/CMakeLists.txt | 0 src/bool/kit/CMakeLists.txt | 16 ++ src/bool/lucky/CMakeLists.txt | 11 + src/bool/rpo/CMakeLists.txt | 5 + src/bool/rsb/CMakeLists.txt | 6 + src/map/amap/CMakeLists.txt | 17 ++ src/map/cov/CMakeLists.txt | 11 + src/map/fpga/CMakeLists.txt | 17 ++ src/map/if/CMakeLists.txt | 30 +++ src/map/mapper/CMakeLists.txt | 21 ++ src/map/mio/CMakeLists.txt | 11 + src/map/mpm/CMakeLists.txt | 15 ++ src/map/scl/CMakeLists.txt | 15 ++ src/map/super/CMakeLists.txt | 7 + src/misc/bar/CMakeLists.txt | 5 + src/misc/bbl/CMakeLists.txt | 5 + src/misc/bzlib/CMakeLists.txt | 11 + src/misc/espresso/CMakeLists.txt | 43 ++++ src/misc/extra/CMakeLists.txt | 21 ++ src/misc/hash/CMakeLists.txt | 0 src/misc/mem/CMakeLists.txt | 5 + src/misc/mvc/CMakeLists.txt | 19 ++ src/misc/nm/CMakeLists.txt | 6 + src/misc/parse/CMakeLists.txt | 6 + src/misc/st/CMakeLists.txt | 6 + src/misc/tim/CMakeLists.txt | 9 + src/misc/util/CMakeLists.txt | 12 + src/misc/vec/CMakeLists.txt | 0 src/misc/zlib/CMakeLists.txt | 19 ++ src/opt/cgt/CMakeLists.txt | 9 + src/opt/csw/CMakeLists.txt | 8 + src/opt/cut/CMakeLists.txt | 13 ++ src/opt/dar/CMakeLists.txt | 13 ++ src/opt/dau/CMakeLists.txt | 16 ++ src/opt/dau/dauCanon.c | 2 +- src/opt/dsc/CMakeLists.txt | 5 + src/opt/fret/CMakeLists.txt | 8 + src/opt/fsim/CMakeLists.txt | 10 + src/opt/fxch/CMakeLists.txt | 8 + src/opt/fxu/CMakeLists.txt | 16 ++ src/opt/lpk/CMakeLists.txt | 15 ++ src/opt/mfs/CMakeLists.txt | 12 + src/opt/nwk/CMakeLists.txt | 18 ++ src/opt/res/CMakeLists.txt | 11 + src/opt/ret/CMakeLists.txt | 11 + src/opt/rwr/CMakeLists.txt | 11 + src/opt/rwt/CMakeLists.txt | 7 + src/opt/sbd/CMakeLists.txt | 13 ++ src/opt/sfm/CMakeLists.txt | 14 ++ src/opt/sim/CMakeLists.txt | 13 ++ src/phys/place/CMakeLists.txt | 14 ++ src/proof/abs/CMakeLists.txt | 20 ++ src/proof/acec/CMakeLists.txt | 23 ++ src/proof/cec/CMakeLists.txt | 19 ++ src/proof/dch/CMakeLists.txt | 14 ++ src/proof/fra/CMakeLists.txt | 21 ++ src/proof/fraig/CMakeLists.txt | 16 ++ src/proof/int/CMakeLists.txt | 14 ++ src/proof/int2/CMakeLists.txt | 8 + src/proof/live/CMakeLists.txt | 13 ++ src/proof/pdr/CMakeLists.txt | 14 ++ src/proof/ssc/CMakeLists.txt | 9 + src/proof/ssw/CMakeLists.txt | 24 ++ src/sat/bmc/CMakeLists.txt | 36 +++ src/sat/bsat/CMakeLists.txt | 18 ++ src/sat/bsat2/CMakeLists.txt | 11 + src/sat/cnf/CMakeLists.txt | 13 ++ src/sat/csat/CMakeLists.txt | 5 + src/sat/glucose/CMakeLists.txt | 10 + src/sat/msat/CMakeLists.txt | 17 ++ src/sat/psat/CMakeLists.txt | 0 src/sat/satoko/CMakeLists.txt | 7 + src/sat/xsat/CMakeLists.txt | 7 + 106 files changed, 1860 insertions(+), 97 deletions(-) create mode 100644 src/aig/aig/CMakeLists.txt create mode 100644 src/aig/gia/CMakeLists.txt create mode 100644 src/aig/hop/CMakeLists.txt create mode 100644 src/aig/ioa/CMakeLists.txt create mode 100644 src/aig/ivy/CMakeLists.txt create mode 100644 src/aig/miniaig/CMakeLists.txt create mode 100644 src/aig/saig/CMakeLists.txt create mode 100644 src/base/abc/CMakeLists.txt create mode 100644 src/base/abci/CMakeLists.txt create mode 100644 src/base/acb/CMakeLists.txt create mode 100644 src/base/bac/CMakeLists.txt create mode 100644 src/base/cba/CMakeLists.txt create mode 100644 src/base/cmd/CMakeLists.txt create mode 100644 src/base/exor/CMakeLists.txt create mode 100644 src/base/io/CMakeLists.txt create mode 100644 src/base/main/CMakeLists.txt create mode 100644 src/base/pla/CMakeLists.txt create mode 100644 src/base/test/CMakeLists.txt create mode 100644 src/base/ver/CMakeLists.txt create mode 100644 src/base/wlc/CMakeLists.txt create mode 100644 src/base/wln/CMakeLists.txt create mode 100644 src/bdd/bbr/CMakeLists.txt create mode 100644 src/bdd/cas/CMakeLists.txt create mode 100644 src/bdd/cudd/CMakeLists.txt create mode 100644 src/bdd/dsd/CMakeLists.txt create mode 100644 src/bdd/epd/CMakeLists.txt create mode 100644 src/bdd/extrab/CMakeLists.txt create mode 100644 src/bdd/llb/CMakeLists.txt create mode 100644 src/bdd/mtr/CMakeLists.txt create mode 100644 src/bdd/reo/CMakeLists.txt create mode 100644 src/bool/bdc/CMakeLists.txt create mode 100644 src/bool/dec/CMakeLists.txt create mode 100644 src/bool/deco/CMakeLists.txt create mode 100644 src/bool/kit/CMakeLists.txt create mode 100644 src/bool/lucky/CMakeLists.txt create mode 100644 src/bool/rpo/CMakeLists.txt create mode 100644 src/bool/rsb/CMakeLists.txt create mode 100644 src/map/amap/CMakeLists.txt create mode 100644 src/map/cov/CMakeLists.txt create mode 100644 src/map/fpga/CMakeLists.txt create mode 100644 src/map/if/CMakeLists.txt create mode 100644 src/map/mapper/CMakeLists.txt create mode 100644 src/map/mio/CMakeLists.txt create mode 100644 src/map/mpm/CMakeLists.txt create mode 100644 src/map/scl/CMakeLists.txt create mode 100644 src/map/super/CMakeLists.txt create mode 100644 src/misc/bar/CMakeLists.txt create mode 100644 src/misc/bbl/CMakeLists.txt create mode 100644 src/misc/bzlib/CMakeLists.txt create mode 100644 src/misc/espresso/CMakeLists.txt create mode 100644 src/misc/extra/CMakeLists.txt create mode 100644 src/misc/hash/CMakeLists.txt create mode 100644 src/misc/mem/CMakeLists.txt create mode 100644 src/misc/mvc/CMakeLists.txt create mode 100644 src/misc/nm/CMakeLists.txt create mode 100644 src/misc/parse/CMakeLists.txt create mode 100644 src/misc/st/CMakeLists.txt create mode 100644 src/misc/tim/CMakeLists.txt create mode 100644 src/misc/util/CMakeLists.txt create mode 100644 src/misc/vec/CMakeLists.txt create mode 100644 src/misc/zlib/CMakeLists.txt create mode 100644 src/opt/cgt/CMakeLists.txt create mode 100644 src/opt/csw/CMakeLists.txt create mode 100644 src/opt/cut/CMakeLists.txt create mode 100644 src/opt/dar/CMakeLists.txt create mode 100644 src/opt/dau/CMakeLists.txt create mode 100644 src/opt/dsc/CMakeLists.txt create mode 100644 src/opt/fret/CMakeLists.txt create mode 100644 src/opt/fsim/CMakeLists.txt create mode 100644 src/opt/fxch/CMakeLists.txt create mode 100644 src/opt/fxu/CMakeLists.txt create mode 100644 src/opt/lpk/CMakeLists.txt create mode 100644 src/opt/mfs/CMakeLists.txt create mode 100644 src/opt/nwk/CMakeLists.txt create mode 100644 src/opt/res/CMakeLists.txt create mode 100644 src/opt/ret/CMakeLists.txt create mode 100644 src/opt/rwr/CMakeLists.txt create mode 100644 src/opt/rwt/CMakeLists.txt create mode 100644 src/opt/sbd/CMakeLists.txt create mode 100644 src/opt/sfm/CMakeLists.txt create mode 100644 src/opt/sim/CMakeLists.txt create mode 100644 src/phys/place/CMakeLists.txt create mode 100644 src/proof/abs/CMakeLists.txt create mode 100644 src/proof/acec/CMakeLists.txt create mode 100644 src/proof/cec/CMakeLists.txt create mode 100644 src/proof/dch/CMakeLists.txt create mode 100644 src/proof/fra/CMakeLists.txt create mode 100644 src/proof/fraig/CMakeLists.txt create mode 100644 src/proof/int/CMakeLists.txt create mode 100644 src/proof/int2/CMakeLists.txt create mode 100644 src/proof/live/CMakeLists.txt create mode 100644 src/proof/pdr/CMakeLists.txt create mode 100644 src/proof/ssc/CMakeLists.txt create mode 100644 src/proof/ssw/CMakeLists.txt create mode 100644 src/sat/bmc/CMakeLists.txt create mode 100644 src/sat/bsat/CMakeLists.txt create mode 100644 src/sat/bsat2/CMakeLists.txt create mode 100644 src/sat/cnf/CMakeLists.txt create mode 100644 src/sat/csat/CMakeLists.txt create mode 100644 src/sat/glucose/CMakeLists.txt create mode 100644 src/sat/msat/CMakeLists.txt create mode 100644 src/sat/psat/CMakeLists.txt create mode 100644 src/sat/satoko/CMakeLists.txt create mode 100644 src/sat/xsat/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index bbb153e642..7d192b22a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,8 +1,11 @@ -cmake_minimum_required(VERSION 3.5.0) +cmake_minimum_required(VERSION 3.5.0 FATAL_ERROR) +project(abc C CXX) include(CMakeParseArguments) include(CheckCCompilerFlag) include(CheckCXXCompilerFlag) +include(GNUInstallDirs) + # Generate compilation database compile_commands.json set(CMAKE_EXPORT_COMPILE_COMMANDS ON) @@ -10,121 +13,303 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_CXX_STANDARD 17 CACHE STRING "the C++ standard to use for this project") set(CMAKE_CXX_STANDARD_REQUIRED ON) -function(addprefix var prefix) - foreach( s ${ARGN} ) - list(APPEND tmp "-I${s}") - endforeach() - set(${var} ${tmp} PARENT_SCOPE) -endfunction() +set(ABC_USE_NAMESPACE "" CACHE STRING "ABC namespace") +option(ABC_USE_STDINT_H "Use C99 stdint.h header for platform-dependent types") +option(ABC_USE_NO_CUDD "Compile CUDD with ABC") +option(ABC_USE_NO_READLINE "Whether to use libreadline") +option(ABC_USE_NO_PTHREADS "Whether to compile with thread support") +option(ABC_USE_PIC "Whether to compile into position independent code") +option(ABC_USE_LIBSTDCXX "Link explicitly to stdc++") -# filter out flags that are not appropriate for the compiler being used -function(target_compile_options_filtered target visibility) - foreach( flag ${ARGN} ) - if( flag MATCHES "^-D.*" ) - target_compile_options( ${target} ${visibility} ${flag} ) - else() - check_c_compiler_flag( ${flag} C_COMPILER_SUPPORTS__${flag} ) - if( C_COMPILER_SUPPORTS__${flag} ) - target_compile_options( ${target} ${visibility} $<$:${flag}> ) - endif() +add_library(abc_interface INTERFACE) - check_cxx_compiler_flag( ${flag} CXX_COMPILER_SUPPORTS__${flag} ) - if( CXX_COMPILER_SUPPORTS__${flag} ) - target_compile_options( ${target} ${visibility} $<$:${flag}> ) - endif() - endif() - endforeach() -endfunction() +set(ABC_MODULES + src/base/abc src/base/abci src/base/cmd src/base/io src/base/main src/base/exor + src/base/ver src/base/wlc src/base/wln src/base/acb src/base/bac src/base/cba src/base/pla src/base/test + src/map/mapper src/map/mio src/map/super src/map/if + src/map/amap src/map/cov src/map/scl src/map/mpm + src/misc/extra src/misc/mvc src/misc/st src/misc/util src/misc/nm + src/misc/vec src/misc/hash src/misc/tim src/misc/bzlib src/misc/zlib + src/misc/mem src/misc/bar src/misc/bbl src/misc/parse + src/opt/cut src/opt/fxu src/opt/fxch src/opt/rwr src/opt/mfs src/opt/sim + src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt + src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd + src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat src/sat/cnf src/sat/bmc src/sat/glucose + src/bool/bdc src/bool/deco src/bool/dec src/bool/kit src/bool/lucky + src/bool/rsb src/bool/rpo + src/proof/pdr src/proof/abs src/proof/live src/proof/ssc src/proof/int + src/proof/cec src/proof/acec src/proof/dch src/proof/fraig src/proof/fra src/proof/ssw + src/aig/aig src/aig/saig src/aig/gia src/aig/ioa src/aig/ivy src/aig/hop + src/aig/miniaig +) + +file(GLOB "src/ext*" ABC_EXTERNAL_MODULES) + +if(ABC_EXTERNAL_MODULES) + message(STATUS "External abc modules: ${ABC_EXTERNAL_MODULES}") + list(APPEND ABC_MODULES ${ABC_EXTERNAL_MODULES}) +endif() + +target_compile_definitions(abc_interface INTERFACE $<$:_DEBUG> $<$>:NDEBUG>) +target_include_directories(abc_interface INTERFACE "${abc_SOURCE_DIR}/src") +target_link_libraries(abc_interface + INTERFACE ${CMAKE_DL_LIBS} +) -project(abc) +if(NOT ABC_USE_NO_CUDD) + message(STATUS "Compiling with CUDD") + list(APPEND ABC_MODULES src/bdd/cudd src/bdd/extrab src/bdd/dsd src/bdd/epd src/bdd/mtr src/bdd/reo src/bdd/cas src/bdd/bbr src/bdd/llb) + target_compile_definitions(abc_interface + INTERFACE ABC_USE_CUDD=1 + ) +endif() -if(READLINE_FOUND MATCHES TRUE) - addprefix(ABC_READLINE_INCLUDES_FLAGS "-I" ${READLINE_INCLUDE}) - string(REPLACE ";" " " ABC_READLINE_INCLUDES_FLAGS "${ABC_READLINE_INCLUDES_FLAGS}") - list(APPEND ABC_READLINE_FLAGS "ABC_READLINE_INCLUDES=${ABC_READLINE_INCLUDES_FLAGS}") +if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND NOT (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.6.0")) + target_compile_options(abc_interface + INTERFACE -Wno-unused-but-set-variable + ) +endif() - string(REPLACE ";" " " ABC_READLINE_LIBRARIES_FLAGS "${READLINE_LIBRARIES}") - list(APPEND ABC_READLINE_FLAGS "ABC_READLINE_LIBRARIES=${ABC_READLINE_LIBRARIES_FLAGS}") -elseif(READLINE_FOUND MATCHES FALSE) - list(APPEND ABC_READLINE_FLAGS "ABC_USE_NO_READLINE=1") +if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") + target_compile_options(abc_interface + INTERFACE + -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare + ) + target_link_libraries(abc_interface INTERFACE m) + if(WIN32 OR ABC_USE_NAMESPACE) + target_compile_options(abc_interface + INTERFACE + $<$:-fpermissive> + ) + endif() +elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + target_compile_definitions(abc_interface + INTERFACE + "_CONSOLE" + "_MBCS" + "_SCL_SECURE_NO_WARNINGS" + "_CRT_SECURE_NO_WARNINGS" + ) +endif() +if(WIN32) + target_compile_definitions(abc_interface + INTERFACE + $<$:ABC_DLL=ABC_DLLEXPORT> + $<$>:WIN32_NO_DLL> + ) endif() if(ABC_USE_NAMESPACE) - set(ABC_USE_NAMESPACE_FLAGS "ABC_USE_NAMESPACE=${ABC_USE_NAMESPACE}") + message(STATUS "Compiling in namespace ${ABC_USE_NAMESPACE}") + target_compile_definitions(abc_interface INTERFACE "ABC_NAMESPACE=${ABC_USE_NAMESPACE}") endif() -if( APPLE ) - set(make_env ${CMAKE_COMMAND} -E env SDKROOT=${CMAKE_OSX_SYSROOT}) +include(CheckTypeSize) +check_type_size("(void*)0" SIZEOF_VOID_P) +if(ABC_USE_STDINT_H) + target_compile_definitions(abc_interface INTERFACE "ABC_USE_STDINT_H=1") +else() + check_type_size("(long)0" SIZEOF_LONG) + check_type_size("(int)0" SIZEOF_INT) + if(UNIX OR APPLE) + set(ARCH_PREFIX "LIN") + elseif(WIN32) + set(ARCH_PREFIX "NT") + else() + message(FATAL_ERROR "Unknown arch") + endif() + if(SIZEOF_VOID_P EQUAL 4) + set(ARCH_SUFFIX "") + elseif(SIZEOF_VOID_P EQUAL 8) + set(ARCH_SUFFIX "64") + else() + message(FATAL_ERROR "Unknown pointer size") + endif() + target_compile_definitions(abc_interface INTERFACE + "SIZEOF_VOID_P=${SIZEOF_VOID_P}" + "SIZEOF_LONG=${SIZEOF_LONG}" + "SIZEOF_INT=${SIZEOF_INT}" + "${ARCH_PREFIX}${ARCH_SUFFIX}" + ) +endif() +if(CMAKE_SYSTEM_PROCESS STREQUAL "arm") + target_compile_definitions(abc_interface INTERFACE + ABC_MEMALIGN=4 + ) endif() -# run make to extract compiler options, linker options and list of source files -execute_process( - COMMAND - ${make_env} - make - ${ABC_READLINE_FLAGS} - ${ABC_USE_NAMESPACE_FLAGS} - ARCHFLAGS_EXE=${CMAKE_CURRENT_BINARY_DIR}/abc_arch_flags_program.exe - ABC_MAKE_NO_DEPS=1 - CC=${CMAKE_C_COMPILER} - CXX=${CMAKE_CXX_COMPILER} - LD=${CMAKE_CXX_COMPILER} - cmake_info - WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} - OUTPUT_VARIABLE MAKE_OUTPUT +if(NOT ABC_USE_NO_READLINE) + message(STATUS "Using libreadline") + target_compile_definitions(abc_interface + INTERFACE ABC_USE_READLINE + ) + find_path(ABC_READLINE_INCLUDES + NAMES readline.h + HINTS + $ENV{READLINE_ROOT} + PATH_SUFFIXES include include/readline + ) + find_library(ABC_READLINE_LIBRARIES + NAMES readline libreadline + HINTS + $ENV{READLINE_ROOT} + ) + if(NOT ABC_READLINE_INCLUDES OR NOT ABC_READLINE_LIBRARIES) + message(FATAL_ERROR "Could not find readline") + endif() + target_include_directories(abc_interface + INTERFACE ${ABC_READLINE_INCLUDES} + ) + target_link_libraries(abc_interface + INTERFACE ${ABC_READLINE_LIBRARIES} + ) +endif() + +if(NOT ABC_USE_NO_PTHREADS) + message(STATUS "Using pthreads") + target_compile_definitions(abc_interface + INTERFACE ABC_USE_PTHREADS + ) + if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + option(ABC_USE_EXTERNAL_PTHREAD "Use external pthread library") + if(ABC_USE_EXTERNAL_PTHREAD) + find_path(ABC_EXTERNAL_PTHREAD_INCLUDES + NAMES pthread.h + HINTS + $ENV{PTHREAD_ROOT} + PATH_SUFFIXES include include/readline + ) + find_library(ABC_EXTERNAL_PTHREAD_LIBRARIES + NAMES pthread pthread_lib pthread_dll + HINTS + $ENV{PTHREAD_ROOT} + ) + set(ABC_PTHREAD_INCLUDES "${ABC_EXTERNAL_PTHREAD_INCLUDES}") + set(ABC_PTHREAD_LIBRARIES "${ABC_EXTERNAL_PTHREAD_LIBRARIES}") + else() + if(SIZEOF_VOID_P EQUAL 8) + set(PTHREAD_ARCH "x64") + else() + set(PTHREAD_ARCH "x86") + endif() + set(ABC_PTHREAD_INCLUDES "${abc_SOURCE_DIR}/lib") + set(ABC_PTHREAD_LIBRARIES "${abc_SOURCE_DIR}/lib/${PTHREAD_ARCH}/pthreadVC2.lib") + install(FILES "${abc_SOURCE_DIR}/lib/${PTHREAD_ARCH}/pthreadVC2.dll" + DESTINATION "${CMAKE_INSTALL_BINDIR}" + ) + endif() + if(NOT ABC_PTHREAD_INCLUDES OR NOT ABC_PTHREAD_LIBRARIES) + message(FATAL_ERROR "Could not find pthread") + endif() + target_include_directories(abc_interface INTERFACE "${ABC_PTHREAD_INCLUDES}") + target_link_libraries(abc_interface INTERFACE "${ABC_PTHREAD_LIBRARIES}") + else() + set(CMAKE_THREAD_PREFER_PTHREAD ON) + set(THREADS_PREFER_PTHREAD_FLAG ON) + find_package(Threads REQUIRED) + target_link_libraries(abc_interface + INTERFACE Threads::Threads + ) + endif() +endif() + +if(ABC_USE_PIC) + message(STATUS "Compiling position independent code") + set(CMAKE_POSITION_INDEPENDENT_CODE ON) +endif() + +if(ABC_USE_LIBSTDCXX) + message(STATUS "Using explicit -lstdc++") + target_link_libraries(abc_interface + INTERFACE stdc++ + ) +endif() + +define_property(GLOBAL + PROPERTY LIBABC_SOURCES + BRIEF_DOCS "Sources of libabc" + FULL_DOCS "All source files of libabc" ) -# extract options from make output -function(extract_var SEPARATOR DEST_VARIABLE MAKE_OUTPUT) - string(REGEX MATCH "${SEPARATOR} .* ${SEPARATOR}" TMP "${MAKE_OUTPUT}") - string(REGEX REPLACE "${SEPARATOR} (.*) ${SEPARATOR}" "\\1" TMP "${TMP}") +define_property(GLOBAL + PROPERTY ABC_SOURCES + BRIEF_DOCS "Sources of executables of abc" + FULL_DOCS "All source files of libabc" +) - separate_arguments(TMP) +function(abc_libabc_add_sources) + cmake_parse_arguments(AAM "" "NAME" "SOURCES" ${ARGN}) + file(RELATIVE_PATH RELDIR "${abc_SOURCE_DIR}" "${CMAKE_CURRENT_LIST_DIR}") + set(RELSOURCES) + foreach(SOURCE ${AAM_SOURCES}) + list(APPEND RELSOURCES "${RELDIR}/${SOURCE}") + endforeach() + source_group("${RELDIR}" FILES "${AAM_SOURCES}") + set_property(GLOBAL APPEND PROPERTY LIBABC_SOURCES ${RELSOURCES}) +endfunction() - set(${DEST_VARIABLE} ${TMP} PARENT_SCOPE) +function(abc_add_executable) + cmake_parse_arguments(AAE "" "NAME" "SOURCES" ${ARGN}) + file(RELATIVE_PATH RELDIR "${abc_SOURCE_DIR}" "${CMAKE_CURRENT_LIST_DIR}") + set(RELSOURCES) + foreach(SOURCE ${AAE_SOURCES}) + list(APPEND RELSOURCES "${RELDIR}${SOURCE}") + endforeach() + if(ABC_USE_NAMESPACE) + set_source_files_properties(${AAE_SOURCES} PROPERTIES LANGUAGE CXX) + endif() + add_executable("${AAE_NAME}" ${AAE_SOURCES}) + target_link_libraries("${AAE_NAME}" PUBLIC libabc) + set_property(GLOBAL APPEND PROPERTY ABC_SOURCES ${RELSOURCES}) endfunction() -extract_var(SEPARATOR_SRC ABC_SRC ${MAKE_OUTPUT}) -extract_var(SEPARATOR_LIBS ABC_LIBS ${MAKE_OUTPUT}) -extract_var(SEPARATOR_CFLAGS ABC_CFLAGS ${MAKE_OUTPUT}) -extract_var(SEPARATOR_CXXFLAGS ABC_CXXFLAGS ${MAKE_OUTPUT}) +foreach(ABC_MODULE ${ABC_MODULES}) + add_subdirectory("${ABC_MODULE}") +endforeach() + +get_property(LIBABC_SOURCES GLOBAL PROPERTY LIBABC_SOURCES) +get_property(ABC_SOURCES GLOBAL PROPERTY ABC_SOURCES) if(ABC_USE_NAMESPACE) - set_source_files_properties(${ABC_SRC} PROPERTIES LANGUAGE CXX) + set_source_files_properties(${LIBABC_SOURCES} PROPERTIES LANGUAGE CXX) endif() -function(abc_properties target visibility) - target_include_directories(${target} ${visibility} ${CMAKE_CURRENT_SOURCE_DIR}/src ) - target_compile_options_filtered(${target} ${visibility} ${ABC_CFLAGS} ${ABC_CXXFLAGS} -Wno-unused-but-set-variable ) - target_link_libraries(${target} ${visibility} ${ABC_LIBS}) -endfunction() - -set(ABC_MAIN_SRC src/base/main/main.c) -list(REMOVE_ITEM ABC_SRC ${ABC_MAIN_SRC}) - -add_library(libabc EXCLUDE_FROM_ALL ${ABC_SRC}) -abc_properties(libabc PUBLIC) -set_property(TARGET libabc PROPERTY OUTPUT_NAME abc) - -add_executable(abc ${ABC_MAIN_SRC}) -target_link_libraries(abc PRIVATE libabc) -abc_properties(abc PRIVATE) - -add_library(libabc-pic EXCLUDE_FROM_ALL ${ABC_SRC}) -abc_properties(libabc-pic PUBLIC) -set_property(TARGET libabc-pic PROPERTY POSITION_INDEPENDENT_CODE ON) -set_property(TARGET libabc-pic PROPERTY OUTPUT_NAME abc-pic) - -if(NOT DEFINED ABC_SKIP_TESTS) - enable_testing() - include(FetchContent) - FetchContent_Declare( - googletest - DOWNLOAD_EXTRACT_TIMESTAMP TRUE - # Specify the commit you depend on and update it regularly. - URL "https://github.com/google/googletest/archive/refs/tags/v1.14.0.zip" +add_library(libabc ${LIBABC_SOURCES}) +target_link_libraries(libabc PUBLIC abc_interface) +set_target_properties(libabc + PROPERTIES OUTPUT_NAME "abc" +) +if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + set_target_properties(libabc + PROPERTIES OUTPUT_NAME "abc$<$:d>$<$>:r>" ) - FetchContent_MakeAvailable(googletest) - include(GoogleTest) - add_subdirectory(test) -endif() \ No newline at end of file +endif() + +install(TARGETS libabc + ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" + LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" +) +if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + if(BUILD_SHARED_LIBS) + install(FILES $ DESTINATION bin OPTIONAL) + endif() +endif() + +enable_testing() +add_test(NAME base_i10 + COMMAND abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" + WORKING_DIRECTORY "${abc_SOURCE_DIR}" +) + +add_custom_target(etags + etags ${LIBABC_SOURCES} ${ABC_SOURCES} + COMMENT "Generating etags" + WORKING_DIRECTORY "${abc_SOURCE_DIR}" +) + +add_custom_target(docs + doxygen doxygen.conf + COMMENT "Building documentation." + WORKING_DIRECTORY "${abc_SOURCE_DIR}" +) diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt new file mode 100644 index 0000000000..7ffccfb66a --- /dev/null +++ b/src/aig/aig/CMakeLists.txt @@ -0,0 +1,35 @@ +abc_libabc_add_sources( + NAME aig_aig + SOURCES + aigDup.c + aigCuts.c + aigPartSat.c + aigInter.c + aigMem.c + aigMan.c + aigRepr.c + aigPartReg.c + aigShow.c + aigCheck.c + aigTruth.c + aigScl.c + aigTable.c + aigObj.c + aigDfs.c + aigRet.c + aigJust.c + aigFrames.c + aigOper.c + aigPack.c + aigPart.c + aigUtil.c + aigTsim.c + aigTiming.c + aigFanout.c + aigCanon.c + aigOrder.c + aigRetF.c + aigWin.c + aigMffc.c + aigSplit.c +) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt new file mode 100644 index 0000000000..1d12f4fc41 --- /dev/null +++ b/src/aig/gia/CMakeLists.txt @@ -0,0 +1,95 @@ +abc_libabc_add_sources( + NAME aig_gia + SOURCES + giaIso.c + giaGig.c + giaSplit.c + giaTruth.c + giaBalAig.c + giaNf.c + giaSim2.c + giaRetime.c + giaOf.c + giaMini.c + giaResub.c + giaSpeedup.c + giaCSatOld.c + giaSatLE.c + giaCof.c + giaLf.c + giaSatMap.c + giaIso3.c + giaCSat.c + giaBalLut.c + giaAig.c + giaSort.c + giaStr.c + giaShrink.c + giaMfs.c + giaAiger.c + giaBidec.c + giaEra2.c + giaSatLut.c + giaRex.c + giaQbf.c + giaExist.c + giaSweep.c + giaIff.c + giaSatEdge.c + giaFalse.c + giaScript.c + giaSweeper.c + giaTim.c + giaFrames.c + giaAigerExt.c + giaTis.c + giaDup.c + giaFront.c + giaMf.c + giaCex.c + giaPf.c + giaSat3.c + giaCTas.c + giaStg.c + giaEnable.c + giaUnate.c + giaPat.c + giaMan.c + giaEsop.c + giaSupMin.c + giaKf.c + giaIf.c + giaIso2.c + giaForce.c + giaMem.c + giaEquiv.c + giaEmbed.c + giaCSat2.c + giaSwitch.c + giaFx.c + giaAgi.c + giaEra.c + giaCCof.c + giaTsim.c + giaBalMap.c + giaSupp.c + giaShow.c + giaShrink6.c + giaFanout.c + giaClp.c + giaJf.c + giaScl.c + giaPack.c + giaDfs.c + giaIiff.c + giaGlitch.c + giaHash.c + giaShrink7.c + giaEdge.c + giaCut.c + giaSim.c + giaUtil.c + giaMuxes.c + giaCone.c + giaSatoko.c +) diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt new file mode 100644 index 0000000000..69b29e5c2b --- /dev/null +++ b/src/aig/hop/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME aig_hop + SOURCES + hopTable.c + hopBalance.c + hopObj.c + hopMan.c + hopUtil.c + hopOper.c + hopDfs.c + hopTruth.c + hopMem.c + hopCheck.c +) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt new file mode 100644 index 0000000000..c547a36b6c --- /dev/null +++ b/src/aig/ioa/CMakeLists.txt @@ -0,0 +1,7 @@ +abc_libabc_add_sources( + NAME aig_ioa + SOURCES + ioaUtil.c + ioaReadAig.c + ioaWriteAig.c +) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt new file mode 100644 index 0000000000..5bae2323f4 --- /dev/null +++ b/src/aig/ivy/CMakeLists.txt @@ -0,0 +1,26 @@ +abc_libabc_add_sources( + NAME aig_ivy + SOURCES + ivyUtil.c + ivyTable.c + ivyObj.c + ivyCutTrav.c + ivyFraig.c + ivyBalance.c + ivyOper.c + ivyCanon.c + ivyMan.c + ivyFastMap.c + ivyRwr.c + ivyCheck.c + ivyCut.c + ivyResyn.c + ivyDsd.c + ivyMem.c + ivyFanout.c + ivyShow.c + ivyDfs.c + ivyMulti.c + ivySeq.c + ivyHaig.c +) diff --git a/src/aig/miniaig/CMakeLists.txt b/src/aig/miniaig/CMakeLists.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt new file mode 100644 index 0000000000..79e79de60a --- /dev/null +++ b/src/aig/saig/CMakeLists.txt @@ -0,0 +1,30 @@ +abc_libabc_add_sources( + NAME aig_saig + SOURCES + saigDup.c + saigOutDec.c + saigScl.c + saigIsoSlow.c + saigPhase.c + saigSynch.c + saigIsoFast.c + saigSimSeq.c + saigCone.c + saigRetStep.c + saigIso.c + saigConstr.c + saigRetFwd.c + saigTempor.c + saigStrSim.c + saigSwitch.c + saigInd.c + saigTrans.c + saigWnd.c + saigIoa.c + saigRetMin.c + saigSimMv.c + saigConstr2.c + saigMiter.c + saigSimFast.c + saigDual.c +) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt new file mode 100644 index 0000000000..6c45d0440f --- /dev/null +++ b/src/base/abc/CMakeLists.txt @@ -0,0 +1,27 @@ +abc_libabc_add_sources( + NAME base_abc + SOURCES + abcUtil.c + abcFanio.c + abcShow.c + abcDfs.c + abcSop.c + abcAig.c + abcFunc.c + abcHie.c + abcCheck.c + abcHieCec.c + abcMinBase.c + abcBlifMv.c + abcLib.c + abcNetlist.c + abcNames.c + abcHieNew.c + abcNtk.c + abcFanOrder.c + abcHieGia.c + abcBarBuf.c + abcObj.c + abcRefs.c + abcLatch.c +) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt new file mode 100644 index 0000000000..e175398075 --- /dev/null +++ b/src/base/abci/CMakeLists.txt @@ -0,0 +1,79 @@ +abc_libabc_add_sources( + NAME base_abci + SOURCES + abcExtract.c + abcQuant.c + abcDebug.c + abcIvy.c + abcReach.c + abcHaig.c + abcAuto.c + abcFxu.c + abcAttach.c + abcDetect.c + abcRpo.c + abcBm.c + abcOdc.c + abcMfs.c + abcSymm.c + abcFx.c + abcCas.c + abcDress3.c + abcDress2.c + abcStrash.c + abcReconv.c + abcMini.c + abcProve.c + abcSpeedup.c + abcExact.c + abcRefactor.c + abcRestruct.c + abcRec3.c + abcLutmin.c + abcTim.c + abcNtbdd.c + abcTiming.c + abcFraig.c + abcXsim.c + abcQbf.c + abcSense.c + abcEco.c + abcDec.c + abcCut.c + abcUnreach.c + abcIf.c + abcBmc.c + abcDar.c + abcBalance.c + abcMerge.c + abcReorder.c + abcResub.c + abcMiter.c + abcRr.c + abcDress.c + abcSweep.c + abcPart.c + abcBidec.c + abcLog.c + abcCascade.c + abcScorr.c + abcUnate.c + abcCollapse.c + abcVerify.c + abcRewrite.c + abcDsd.c + abcMulti.c + abcMap.c + abcNpnSave.c + abc.c + abcIfif.c + abcLut.c + abcGen.c + abcSaucy.c + abcPrint.c + abcNpn.c + abcOrder.c + abcSat.c + abcRenode.c + abcIfMux.c +) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt new file mode 100644 index 0000000000..a101e0b459 --- /dev/null +++ b/src/base/acb/CMakeLists.txt @@ -0,0 +1,12 @@ +abc_libabc_add_sources( + NAME base_acb + SOURCES + acbAbc.c + acbFunc.c + acbAig.c + acbSets.c + acbUtil.c + acbPush.c + acbMfs.c + acbCom.c +) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt new file mode 100644 index 0000000000..1c7131b624 --- /dev/null +++ b/src/base/bac/CMakeLists.txt @@ -0,0 +1,19 @@ +abc_libabc_add_sources( + NAME base_bac + SOURCES + bacWriteBlif.c + bacBlast.c + bacPrsTrans.c + bacWriteVer.c + bacReadBlif.c + bacLib.c + bacPrsBuild.c + bacCom.c + bacReadVer.c + bacReadSmt.c + bacNtk.c + bacPtr.c + bacWriteSmt.c + bacBac.c + bacPtrAbc.c +) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt new file mode 100644 index 0000000000..746caca920 --- /dev/null +++ b/src/base/cba/CMakeLists.txt @@ -0,0 +1,12 @@ +abc_libabc_add_sources( + NAME base_cba + SOURCES + cbaCom.c + cbaNtk.c + cbaBlast.c + cbaWriteVer.c + cbaCba.c + cbaReadBlif.c + cbaWriteBlif.c + cbaReadVer.c +) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt new file mode 100644 index 0000000000..1a45bb2c64 --- /dev/null +++ b/src/base/cmd/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME base_cmd + SOURCES + cmdFlag.c + cmdUtils.c + cmdPlugin.c + cmdLoad.c + cmdAuto.c + cmdStarter.c + cmdHist.c + cmdAlias.c + cmd.c + cmdApi.c +) diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt new file mode 100644 index 0000000000..34ba52b2c6 --- /dev/null +++ b/src/base/exor/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME base_exor + SOURCES + exorBits.c + exorUtil.c + exorList.c + exorLink.c + exorCubes.c + exor.c +) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt new file mode 100644 index 0000000000..ece63dab0c --- /dev/null +++ b/src/base/io/CMakeLists.txt @@ -0,0 +1,35 @@ +abc_libabc_add_sources( + NAME base_io + SOURCES + ioReadBlifAig.c + ioWriteSmv.c + ioWriteList.c + ioReadPlaMo.c + ioWriteBook.c + ioReadBaf.c + ioWriteCnf.c + ioJson.c + ioReadBlif.c + io.c + ioReadBlifMv.c + ioWriteBlifMv.c + ioWritePla.c + ioReadBblif.c + ioWriteBlif.c + ioReadAiger.c + ioReadPla.c + ioWriteEqn.c + ioReadDsd.c + ioWriteAiger.c + ioWriteDot.c + ioWriteBblif.c + ioWriteGml.c + ioReadEdif.c + ioWriteVerilog.c + ioWriteBaf.c + ioWriteBench.c + ioReadEqn.c + ioReadBench.c + ioUtil.c + ioReadVerilog.c +) diff --git a/src/base/main/CMakeLists.txt b/src/base/main/CMakeLists.txt new file mode 100644 index 0000000000..4c5e9ae5c1 --- /dev/null +++ b/src/base/main/CMakeLists.txt @@ -0,0 +1,23 @@ +abc_libabc_add_sources( + NAME base_main_mod + SOURCES + mainFrame.c + mainInit.c + mainLib.c + mainReal.c + libSupport.c + mainUtils.c +) + +abc_add_executable( + NAME abc + SOURCES + main.c +) + +install(TARGETS abc + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" +) +if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + install(FILES $ DESTINATION bin OPTIONAL) +endif() diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt new file mode 100644 index 0000000000..add1783363 --- /dev/null +++ b/src/base/pla/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME base_pla + SOURCES + plaSimple.c + plaRead.c + plaMan.c + plaMerge.c + plaWrite.c + plaCom.c + plaHash.c +) diff --git a/src/base/test/CMakeLists.txt b/src/base/test/CMakeLists.txt new file mode 100644 index 0000000000..70ed6f07fa --- /dev/null +++ b/src/base/test/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME base_test + SOURCES + test.c +) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt new file mode 100644 index 0000000000..00a5a9df31 --- /dev/null +++ b/src/base/ver/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME base_ver + SOURCES + verFormula.c + verStream.c + verParse.c + verCore.c +) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt new file mode 100644 index 0000000000..87ded95737 --- /dev/null +++ b/src/base/wlc/CMakeLists.txt @@ -0,0 +1,23 @@ +abc_libabc_add_sources( + NAME base_wlc + SOURCES + wlcStdin.c + wlcWin.c + wlcGraft.c + wlcMem.c + wlcAbs.c + wlcNtk.c + wlcSim.c + wlcCom.c + wlcReadSmt.c + wlcShow.c + wlcUif.c + wlcAbs2.c + wlcNdr.c + wlcBlast.c + wlcWriteVer.c + wlcPth.c + wlcReadVer.c + wlcJson.c + wlcAbc.c +) diff --git a/src/base/wln/CMakeLists.txt b/src/base/wln/CMakeLists.txt new file mode 100644 index 0000000000..26a0a61e39 --- /dev/null +++ b/src/base/wln/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME base_wln + SOURCES + wlnNtk.c + wlnObj.c + wlnWriteVer.c + wlnRetime.c + wln.c + wlnNdr.c +) diff --git a/src/bdd/bbr/CMakeLists.txt b/src/bdd/bbr/CMakeLists.txt new file mode 100644 index 0000000000..6207d7921b --- /dev/null +++ b/src/bdd/bbr/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME bdd_bbr + SOURCES + bbrCex.c + bbrImage.c + bbrReach.c + bbrNtbdd.c +) diff --git a/src/bdd/cas/CMakeLists.txt b/src/bdd/cas/CMakeLists.txt new file mode 100644 index 0000000000..1ffcad65ec --- /dev/null +++ b/src/bdd/cas/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME bdd_cas + SOURCES + casDec.c + casCore.c +) diff --git a/src/bdd/cudd/CMakeLists.txt b/src/bdd/cudd/CMakeLists.txt new file mode 100644 index 0000000000..552c0b85d9 --- /dev/null +++ b/src/bdd/cudd/CMakeLists.txt @@ -0,0 +1,65 @@ +abc_libabc_add_sources( + NAME bdd_cudd + SOURCES + cuddZddSetop.c + cuddLinear.c + cuddZddCount.c + cuddBridge.c + cuddMatMult.c + cuddAnneal.c + cuddPriority.c + cuddEssent.c + cuddZddSymm.c + cuddClip.c + cuddZddGroup.c + cuddAddFind.c + cuddSplit.c + cuddUtil.c + cuddBddCorr.c + cuddAddNeg.c + cuddLCache.c + cuddBddAbs.c + cuddSign.c + cuddLiteral.c + cuddAddApply.c + cuddCheck.c + cuddExact.c + cuddZddLin.c + cuddTable.c + cuddDecomp.c + cuddAndAbs.c + cuddExport.c + cuddReorder.c + cuddCof.c + cuddGenetic.c + cuddCache.c + cuddInteract.c + cuddZddReord.c + cuddAddInv.c + cuddZddMisc.c + cuddZddFuncs.c + cuddZddPort.c + cuddApa.c + cuddSolve.c + cuddHarwell.c + cuddAddAbs.c + cuddZddUtil.c + cuddZddIsop.c + cuddBddIte.c + cuddSubsetSP.c + cuddCompose.c + cuddRead.c + cuddAddIte.c + cuddAddWalsh.c + cuddLevelQ.c + cuddGroup.c + cuddSymmetry.c + cuddRef.c + cuddAPI.c + cuddInit.c + cuddSubsetHB.c + cuddGenCof.c + cuddSat.c + cuddWindow.c + cuddApprox.c +) diff --git a/src/bdd/dsd/CMakeLists.txt b/src/bdd/dsd/CMakeLists.txt new file mode 100644 index 0000000000..564b1c3c01 --- /dev/null +++ b/src/bdd/dsd/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME bdd_dsd + SOURCES + dsdTree.c + dsdCheck.c + dsdMan.c + dsdApi.c + dsdLocal.c + dsdProc.c +) diff --git a/src/bdd/epd/CMakeLists.txt b/src/bdd/epd/CMakeLists.txt new file mode 100644 index 0000000000..61a632ff7c --- /dev/null +++ b/src/bdd/epd/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME bdd_epd + SOURCES + epd.c +) diff --git a/src/bdd/extrab/CMakeLists.txt b/src/bdd/extrab/CMakeLists.txt new file mode 100644 index 0000000000..9509d5895b --- /dev/null +++ b/src/bdd/extrab/CMakeLists.txt @@ -0,0 +1,15 @@ +abc_libabc_add_sources( + NAME bdd_extrab + SOURCES + extraBddImage.c + extraBddKmap.c + extraBddUnate.c + extraBddAuto.c + extraBddThresh.c + extraBddCas.c + extraBddMaxMin.c + extraBddMisc.c + extraBddTime.c + extraBddSet.c + extraBddSymm.c +) diff --git a/src/bdd/llb/CMakeLists.txt b/src/bdd/llb/CMakeLists.txt new file mode 100644 index 0000000000..0d7ca32fc9 --- /dev/null +++ b/src/bdd/llb/CMakeLists.txt @@ -0,0 +1,26 @@ +abc_libabc_add_sources( + NAME bdd_llb + SOURCES + llb3Nonlin.c + llb1Man.c + llb1Pivot.c + llb1Hint.c + llb2Core.c + llb1Cluster.c + llb1Sched.c + llb4Sweep.c + llb2Image.c + llb2Driver.c + llb2Flow.c + llb4Nonlin.c + llb2Bad.c + llb4Image.c + llb1Matrix.c + llb3Image.c + llb1Core.c + llb1Constr.c + llb4Cex.c + llb2Dump.c + llb1Group.c + llb1Reach.c +) diff --git a/src/bdd/mtr/CMakeLists.txt b/src/bdd/mtr/CMakeLists.txt new file mode 100644 index 0000000000..cf84703ef8 --- /dev/null +++ b/src/bdd/mtr/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME bdd_mtr + SOURCES + mtrGroup.c + mtrBasic.c +) diff --git a/src/bdd/reo/CMakeLists.txt b/src/bdd/reo/CMakeLists.txt new file mode 100644 index 0000000000..fc060eb857 --- /dev/null +++ b/src/bdd/reo/CMakeLists.txt @@ -0,0 +1,12 @@ +abc_libabc_add_sources( + NAME bdd_reo + SOURCES + reoShuffle.c + reoSift.c + reoSwap.c + reoApi.c + reoCore.c + reoProfile.c + reoUnits.c + reoTransfer.c +) diff --git a/src/bool/bdc/CMakeLists.txt b/src/bool/bdc/CMakeLists.txt new file mode 100644 index 0000000000..a26868d86f --- /dev/null +++ b/src/bool/bdc/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME bool_bdc + SOURCES + bdcTable.c + bdcSpfd.c + bdcCore.c + bdcDec.c +) diff --git a/src/bool/dec/CMakeLists.txt b/src/bool/dec/CMakeLists.txt new file mode 100644 index 0000000000..3d5136cba6 --- /dev/null +++ b/src/bool/dec/CMakeLists.txt @@ -0,0 +1,9 @@ +abc_libabc_add_sources( + NAME bool_dec + SOURCES + decUtil.c + decAbc.c + decMan.c + decFactor.c + decPrint.c +) diff --git a/src/bool/deco/CMakeLists.txt b/src/bool/deco/CMakeLists.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/bool/kit/CMakeLists.txt b/src/bool/kit/CMakeLists.txt new file mode 100644 index 0000000000..27045b8858 --- /dev/null +++ b/src/bool/kit/CMakeLists.txt @@ -0,0 +1,16 @@ +abc_libabc_add_sources( + NAME bool_kit + SOURCES + kitHop.c + kitCloud.c + kitFactor.c + cloud.c + kitDsd.c + kitTruth.c + kitSop.c + kitIsop.c + kitBdd.c + kitGraph.c + kitPla.c + kitAig.c +) diff --git a/src/bool/lucky/CMakeLists.txt b/src/bool/lucky/CMakeLists.txt new file mode 100644 index 0000000000..e4c4227a0b --- /dev/null +++ b/src/bool/lucky/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME bool_lucky + SOURCES + luckySimple.c + luckySwapIJ.c + luckySwap.c + luckyFast16.c + lucky.c + luckyFast6.c + luckyRead.c +) diff --git a/src/bool/rpo/CMakeLists.txt b/src/bool/rpo/CMakeLists.txt new file mode 100644 index 0000000000..fc411f118d --- /dev/null +++ b/src/bool/rpo/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME bool_rpo + SOURCES + rpo.c +) diff --git a/src/bool/rsb/CMakeLists.txt b/src/bool/rsb/CMakeLists.txt new file mode 100644 index 0000000000..57bf6b8fa0 --- /dev/null +++ b/src/bool/rsb/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME bool_rsb + SOURCES + rsbMan.c + rsbDec6.c +) diff --git a/src/map/amap/CMakeLists.txt b/src/map/amap/CMakeLists.txt new file mode 100644 index 0000000000..586c47c22c --- /dev/null +++ b/src/map/amap/CMakeLists.txt @@ -0,0 +1,17 @@ +abc_libabc_add_sources( + NAME map_amap + SOURCES + amapLib.c + amapGraph.c + amapRead.c + amapMerge.c + amapRule.c + amapLiberty.c + amapMan.c + amapUniq.c + amapPerm.c + amapMatch.c + amapParse.c + amapOutput.c + amapCore.c +) diff --git a/src/map/cov/CMakeLists.txt b/src/map/cov/CMakeLists.txt new file mode 100644 index 0000000000..b58717e943 --- /dev/null +++ b/src/map/cov/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME map_cov + SOURCES + covCore.c + covMinEsop.c + covMinMan.c + covMan.c + covBuild.c + covMinSop.c + covMinUtil.c +) diff --git a/src/map/fpga/CMakeLists.txt b/src/map/fpga/CMakeLists.txt new file mode 100644 index 0000000000..7611f768b3 --- /dev/null +++ b/src/map/fpga/CMakeLists.txt @@ -0,0 +1,17 @@ +abc_libabc_add_sources( + NAME map_fpga + SOURCES + fpgaFanout.c + fpgaCreate.c + fpgaVec.c + fpgaCore.c + fpgaSwitch.c + fpgaCutUtils.c + fpgaCut.c + fpgaTruth.c + fpga.c + fpgaTime.c + fpgaMatch.c + fpgaUtils.c + fpgaLib.c +) diff --git a/src/map/if/CMakeLists.txt b/src/map/if/CMakeLists.txt new file mode 100644 index 0000000000..a951911cde --- /dev/null +++ b/src/map/if/CMakeLists.txt @@ -0,0 +1,30 @@ +abc_libabc_add_sources( + NAME map_if + SOURCES + ifMan.c + ifSat.c + ifTime.c + ifDec08.c + ifMap.c + ifTest.c + ifTruth.c + ifReduce.c + ifSelect.c + ifUtil.c + ifDec07.c + ifTune.c + ifCut.c + ifDsd.c + ifCore.c + ifDec16.c + ifDec75.c + ifLibLut.c + ifLibBox.c + ifCache.c + ifDec10.c + ifMatch2.c + ifData2.c + ifCom.c + ifDelay.c + ifSeq.c +) diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt new file mode 100644 index 0000000000..a496fbb827 --- /dev/null +++ b/src/map/mapper/CMakeLists.txt @@ -0,0 +1,21 @@ +abc_libabc_add_sources( + NAME map_mapper + SOURCES + mapperTable.c + mapperTree.c + mapperCore.c + mapperCreate.c + mapperSwitch.c + mapperCanon.c + mapperCut.c + mapperTruth.c + mapperSuper.c + mapperTime.c + mapperVec.c + mapperCutUtils.c + mapperRefs.c + mapper.c + mapperMatch.c + mapperUtils.c + mapperLib.c +) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt new file mode 100644 index 0000000000..f5a4136f4c --- /dev/null +++ b/src/map/mio/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME map_mio + SOURCES + mioFunc.c + mioUtils.c + mioParse.c + mioRead.c + mioApi.c + mio.c + mioSop.c +) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt new file mode 100644 index 0000000000..806fa9c446 --- /dev/null +++ b/src/map/mpm/CMakeLists.txt @@ -0,0 +1,15 @@ +abc_libabc_add_sources( + NAME map_mpm + SOURCES + mpmMan.c + mpmUtil.c + mpmCore.c + mpmMap.c + mpmPre.c + mpmAbc.c + mpmDsd.c + mpmMig.c + mpmLib.c + mpmTruth.c + mpmGates.c +) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt new file mode 100644 index 0000000000..8372158290 --- /dev/null +++ b/src/map/scl/CMakeLists.txt @@ -0,0 +1,15 @@ +abc_libabc_add_sources( + NAME map_scl + SOURCES + sclDnsize.c + sclUpsize.c + sclBufSize.c + sclLibUtil.c + sclLoad.c + scl.c + sclLibScl.c + sclSize.c + sclUtil.c + sclBuffer.c + sclLiberty.c +) diff --git a/src/map/super/CMakeLists.txt b/src/map/super/CMakeLists.txt new file mode 100644 index 0000000000..97828f5a50 --- /dev/null +++ b/src/map/super/CMakeLists.txt @@ -0,0 +1,7 @@ +abc_libabc_add_sources( + NAME map_super + SOURCES + superGate.c + superAnd.c + super.c +) diff --git a/src/misc/bar/CMakeLists.txt b/src/misc/bar/CMakeLists.txt new file mode 100644 index 0000000000..98918a4bab --- /dev/null +++ b/src/misc/bar/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME misc_bar + SOURCES + bar.c +) diff --git a/src/misc/bbl/CMakeLists.txt b/src/misc/bbl/CMakeLists.txt new file mode 100644 index 0000000000..36adefa0cd --- /dev/null +++ b/src/misc/bbl/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME misc_bbl + SOURCES + bblif.c +) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt new file mode 100644 index 0000000000..991be131a4 --- /dev/null +++ b/src/misc/bzlib/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME misc_bzlib + SOURCES + crctable.c + blocksort.c + huffman.c + compress.c + decompress.c + bzlib.c + randtable.c +) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt new file mode 100644 index 0000000000..b0790b8ae4 --- /dev/null +++ b/src/misc/espresso/CMakeLists.txt @@ -0,0 +1,43 @@ +abc_libabc_add_sources( + NAME misc_espresso + SOURCES + pair.c + unate.c + gimpel.c + opo.c + map.c + cvrin.c + gasp.c + essen.c + irred.c + reduce.c + indep.c + cols.c + hack.c + setc.c + espresso.c + cvrout.c + cubehack.c + matrix.c + cofactor.c + part.c + sminterf.c + dominate.c + solution.c + contain.c + rows.c + cvrm.c + cvrmisc.c + cubestr.c + exact.c + expand.c + verify.c + equiv.c + globals.c + primes.c + compl.c + sharp.c + mincov.c + set.c + sparse.c +) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt new file mode 100644 index 0000000000..a283918674 --- /dev/null +++ b/src/misc/extra/CMakeLists.txt @@ -0,0 +1,21 @@ +abc_libabc_add_sources( + NAME misc_extra + SOURCES + extraUtilBitMatrix.c + extraUtilFile.c + extraUtilCube.c + extraUtilMult.c + extraUtilUtil.c + extraUtilPerm.c + extraUtilReader.c + extraUtilCanon.c + extraUtilMaj.c + extraUtilMemory.c + extraUtilTruth.c + extraUtilPath.c + extraUtilProgress.c + extraUtilSupp.c + extraUtilDsd.c + extraUtilMisc.c + extraUtilEnum.c +) diff --git a/src/misc/hash/CMakeLists.txt b/src/misc/hash/CMakeLists.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/misc/mem/CMakeLists.txt b/src/misc/mem/CMakeLists.txt new file mode 100644 index 0000000000..6aa0df3110 --- /dev/null +++ b/src/misc/mem/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME misc_mem + SOURCES + mem.c +) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt new file mode 100644 index 0000000000..a7e4ee3a8a --- /dev/null +++ b/src/misc/mvc/CMakeLists.txt @@ -0,0 +1,19 @@ +abc_libabc_add_sources( + NAME misc_mvc + SOURCES + mvcCompare.c + mvcContain.c + mvcMan.c + mvcCover.c + mvcOpAlg.c + mvcSort.c + mvcPrint.c + mvcDivisor.c + mvcUtils.c + mvcDivide.c + mvcApi.c + mvcList.c + mvcOpBool.c + mvcLits.c + mvcCube.c +) diff --git a/src/misc/nm/CMakeLists.txt b/src/misc/nm/CMakeLists.txt new file mode 100644 index 0000000000..bf4706f5fd --- /dev/null +++ b/src/misc/nm/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME misc_nm + SOURCES + nmTable.c + nmApi.c +) diff --git a/src/misc/parse/CMakeLists.txt b/src/misc/parse/CMakeLists.txt new file mode 100644 index 0000000000..b0436adc56 --- /dev/null +++ b/src/misc/parse/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME misc_parse + SOURCES + parseEqn.c + parseStack.c +) diff --git a/src/misc/st/CMakeLists.txt b/src/misc/st/CMakeLists.txt new file mode 100644 index 0000000000..8b0cdb9060 --- /dev/null +++ b/src/misc/st/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME misc_st + SOURCES + st.c + stmm.c +) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt new file mode 100644 index 0000000000..8be56dabc5 --- /dev/null +++ b/src/misc/tim/CMakeLists.txt @@ -0,0 +1,9 @@ +abc_libabc_add_sources( + NAME misc_tim + SOURCES + timDump.c + timTrav.c + timTime.c + timBox.c + timMan.c +) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt new file mode 100644 index 0000000000..498e04d3fd --- /dev/null +++ b/src/misc/util/CMakeLists.txt @@ -0,0 +1,12 @@ +abc_libabc_add_sources( + NAME misc_util + SOURCES + utilSort.c + utilBridge.c + utilColor.c + utilIsop.c + utilSignal.c + utilFile.c + utilNam.c + utilCex.c +) diff --git a/src/misc/vec/CMakeLists.txt b/src/misc/vec/CMakeLists.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt new file mode 100644 index 0000000000..04bd82c9cb --- /dev/null +++ b/src/misc/zlib/CMakeLists.txt @@ -0,0 +1,19 @@ +abc_libabc_add_sources( + NAME misc_zlib + SOURCES + adler32.c + gzclose.c + inftrees.c + infback.c + crc32.c + trees.c + deflate.c + gzlib.c + gzwrite.c + inffast.c + gzread.c + zutil.c + inflate.c + compress_.c + uncompr.c +) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt new file mode 100644 index 0000000000..0f2f04c759 --- /dev/null +++ b/src/opt/cgt/CMakeLists.txt @@ -0,0 +1,9 @@ +abc_libabc_add_sources( + NAME opt_cgt + SOURCES + cgtSat.c + cgtDecide.c + cgtMan.c + cgtAig.c + cgtCore.c +) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt new file mode 100644 index 0000000000..256338a893 --- /dev/null +++ b/src/opt/csw/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME opt_csw + SOURCES + cswMan.c + cswCut.c + cswTable.c + cswCore.c +) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt new file mode 100644 index 0000000000..437239d9be --- /dev/null +++ b/src/opt/cut/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME opt_cut + SOURCES + cutPre22.c + cutNode.c + cutTruth.c + cutMan.c + cutOracle.c + cutCut.c + cutMerge.c + cutApi.c + cutSeq.c +) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt new file mode 100644 index 0000000000..5ac002feb9 --- /dev/null +++ b/src/opt/dar/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME opt_dar + SOURCES + darPrec.c + darRefact.c + darScript.c + darCut.c + darData.c + darMan.c + darBalance.c + darLib.c + darCore.c +) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt new file mode 100644 index 0000000000..439cdc42b4 --- /dev/null +++ b/src/opt/dau/CMakeLists.txt @@ -0,0 +1,16 @@ +abc_libabc_add_sources( + NAME opt_dau + SOURCES + dauCore.c + dauDsd.c + dauNpn.c + dauNpn2.c + dauMerge.c + dauGia.c + dauCanon.c + dauCount.c + dauTree.c + dauEnum.c + dauDivs.c + dauNonDsd.c +) diff --git a/src/opt/dau/dauCanon.c b/src/opt/dau/dauCanon.c index bd97c280c0..26452677f8 100644 --- a/src/opt/dau/dauCanon.c +++ b/src/opt/dau/dauCanon.c @@ -1506,7 +1506,7 @@ SeeAlso [] ***********************************************************************/ -// Johnson¨CTrotter algorithm +// Johnson\A8CTrotter algorithm static int Abc_NextPermSwapC(char * pData, signed char * pDir, int size) { int i, j, k = -1; diff --git a/src/opt/dsc/CMakeLists.txt b/src/opt/dsc/CMakeLists.txt new file mode 100644 index 0000000000..11e9042073 --- /dev/null +++ b/src/opt/dsc/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME opt_dsc + SOURCES + dsc.c +) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt new file mode 100644 index 0000000000..3ed1f7ed6f --- /dev/null +++ b/src/opt/fret/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME opt_fret + SOURCES + fretFlow.c + fretMain.c + fretTime.c + fretInit.c +) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt new file mode 100644 index 0000000000..3591d11ac5 --- /dev/null +++ b/src/opt/fsim/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME opt_fsim + SOURCES + fsimTsim.c + fsimFront.c + fsimCore.c + fsimSwitch.c + fsimSim.c + fsimMan.c +) diff --git a/src/opt/fxch/CMakeLists.txt b/src/opt/fxch/CMakeLists.txt new file mode 100644 index 0000000000..bd218f1522 --- /dev/null +++ b/src/opt/fxch/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME opt_fxch + SOURCES + Fxch.c + FxchSCHashTable.c + FxchMan.c + FxchDiv.c +) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt new file mode 100644 index 0000000000..200ba3ac3c --- /dev/null +++ b/src/opt/fxu/CMakeLists.txt @@ -0,0 +1,16 @@ +abc_libabc_add_sources( + NAME opt_fxu + SOURCES + fxu.c + fxuSingle.c + fxuPrint.c + fxuCreate.c + fxuList.c + fxuHeapD.c + fxuHeapS.c + fxuReduce.c + fxuUpdate.c + fxuSelect.c + fxuPair.c + fxuMatrix.c +) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt new file mode 100644 index 0000000000..41b241b6bc --- /dev/null +++ b/src/opt/lpk/CMakeLists.txt @@ -0,0 +1,15 @@ +abc_libabc_add_sources( + NAME opt_lpk + SOURCES + lpkSets.c + lpkMap.c + lpkAbcDsd.c + lpkMux.c + lpkAbcMux.c + lpkCut.c + lpkMulti.c + lpkAbcDec.c + lpkCore.c + lpkMan.c + lpkAbcUtil.c +) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt new file mode 100644 index 0000000000..0798789994 --- /dev/null +++ b/src/opt/mfs/CMakeLists.txt @@ -0,0 +1,12 @@ +abc_libabc_add_sources( + NAME opt_mfs + SOURCES + mfsDiv.c + mfsResub.c + mfsWin.c + mfsSat.c + mfsMan.c + mfsInter.c + mfsStrash.c + mfsCore.c +) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt new file mode 100644 index 0000000000..6b733fa1e9 --- /dev/null +++ b/src/opt/nwk/CMakeLists.txt @@ -0,0 +1,18 @@ +abc_libabc_add_sources( + NAME opt_nwk + SOURCES + nwkObj.c + nwkStrash.c + nwkMap.c + nwkDfs.c + nwkMerge.c + nwkMan.c + nwkTiming.c + nwkFanio.c + nwkFlow.c + nwkSpeedup.c + nwkCheck.c + nwkBidec.c + nwkAig.c + nwkUtil.c +) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt new file mode 100644 index 0000000000..d903597642 --- /dev/null +++ b/src/opt/res/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME opt_res + SOURCES + resWin.c + resCore.c + resSim.c + resFilter.c + resStrash.c + resDivs.c + resSat.c +) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt new file mode 100644 index 0000000000..84b6d3848f --- /dev/null +++ b/src/opt/ret/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME opt_ret + SOURCES + retFlow.c + retIncrem.c + retInit.c + retLvalue.c + retArea.c + retDelay.c + retCore.c +) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt new file mode 100644 index 0000000000..8c5ea05fb7 --- /dev/null +++ b/src/opt/rwr/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME opt_rwr + SOURCES + rwrDec.c + rwrPrint.c + rwrUtil.c + rwrExp.c + rwrMan.c + rwrEva.c + rwrLib.c +) diff --git a/src/opt/rwt/CMakeLists.txt b/src/opt/rwt/CMakeLists.txt new file mode 100644 index 0000000000..eef2fd3fd4 --- /dev/null +++ b/src/opt/rwt/CMakeLists.txt @@ -0,0 +1,7 @@ +abc_libabc_add_sources( + NAME opt_rwt + SOURCES + rwtDec.c + rwtMan.c + rwtUtil.c +) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt new file mode 100644 index 0000000000..7d21ae495a --- /dev/null +++ b/src/opt/sbd/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME opt_sbd + SOURCES + sbdCut2.c + sbdCore.c + sbdLut.c + sbdSat.c + sbd.c + sbdPath.c + sbdCnf.c + sbdCut.c + sbdWin.c +) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt new file mode 100644 index 0000000000..0e5496d657 --- /dev/null +++ b/src/opt/sfm/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME opt_sfm + SOURCES + sfmMit.c + sfmDec.c + sfmLib.c + sfmTim.c + sfmSat.c + sfmArea.c + sfmCnf.c + sfmWin.c + sfmNtk.c + sfmCore.c +) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt new file mode 100644 index 0000000000..41a25f69b6 --- /dev/null +++ b/src/opt/sim/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME opt_sim + SOURCES + simSupp.c + simSymSat.c + simMan.c + simSym.c + simSymStr.c + simSwitch.c + simSeq.c + simUtils.c + simSymSim.c +) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt new file mode 100644 index 0000000000..729ee44e8f --- /dev/null +++ b/src/phys/place/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME phys_place + SOURCES + place_inc.c + place_gordian.c + place_bin.c + place_base.c + place_qpsolver.c + place_pads.c + place_partition.c + place_genqp.c + place_legalize.c + place_io.c +) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt new file mode 100644 index 0000000000..c601fa5d44 --- /dev/null +++ b/src/proof/abs/CMakeLists.txt @@ -0,0 +1,20 @@ +abc_libabc_add_sources( + NAME proof_abs + SOURCES + absRpm.c + absOldCex.c + absOldRef.c + absVta.c + absRefSelect.c + absGlaOld.c + absRef.c + absPth.c + absUtil.c + absOldSat.c + absDup.c + absOldSim.c + absRpmOld.c + absIter.c + absOut.c + absGla.c +) diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt new file mode 100644 index 0000000000..066231797d --- /dev/null +++ b/src/proof/acec/CMakeLists.txt @@ -0,0 +1,23 @@ +abc_libabc_add_sources( + NAME proof_acec + SOURCES + acecOrder.c + acecCore.c + acecPa.c + acecUtil.c + acecNorm.c + acecTree.c + acecSt.c + acecCo.c + acecPolyn.c + acecCover.c + acecPool.c + acecXor.c + acecBo.c + acec2Mult.c + acecMult.c + acecFadds.c + acecPo.c + acecRe.c + acecCl.c +) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt new file mode 100644 index 0000000000..9d871dce1d --- /dev/null +++ b/src/proof/cec/CMakeLists.txt @@ -0,0 +1,19 @@ +abc_libabc_add_sources( + NAME proof_cec + SOURCES + cecCec.c + cecSplit.c + cecPat.c + cecSeq.c + cecSweep.c + cecCore.c + cecCorr.c + cecSynth.c + cecIso.c + cecMan.c + cecSatG.c + cecSolve.c + cecSat.c + cecChoice.c + cecClass.c +) diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt new file mode 100644 index 0000000000..fda0473634 --- /dev/null +++ b/src/proof/dch/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME proof_dch + SOURCES + dchSat.c + dchAig.c + dchSweep.c + dchCore.c + dchMan.c + dchChoice.c + dchCnf.c + dchSimSat.c + dchClass.c + dchSim.c +) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt new file mode 100644 index 0000000000..e68fd57987 --- /dev/null +++ b/src/proof/fra/CMakeLists.txt @@ -0,0 +1,21 @@ +abc_libabc_add_sources( + NAME proof_fra + SOURCES + fraCnf.c + fraInd.c + fraBmc.c + fraClaus.c + fraCec.c + fraPart.c + fraClass.c + fraSec.c + fraCore.c + fraHot.c + fraClau.c + fraIndVer.c + fraSat.c + fraSim.c + fraLcr.c + fraMan.c + fraImp.c +) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt new file mode 100644 index 0000000000..7938e540f2 --- /dev/null +++ b/src/proof/fraig/CMakeLists.txt @@ -0,0 +1,16 @@ +abc_libabc_add_sources( + NAME proof_fraig + SOURCES + fraigFeed.c + fraigTable.c + fraigSat.c + fraigFanout.c + fraigMan.c + fraigVec.c + fraigApi.c + fraigUtil.c + fraigMem.c + fraigNode.c + fraigPrime.c + fraigCanon.c +) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt new file mode 100644 index 0000000000..7297de8809 --- /dev/null +++ b/src/proof/int/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME proof_int + SOURCES + intMan.c + intFrames.c + intCore.c + intContain.c + intUtil.c + intDup.c + intInter.c + intM114.c + intCheck.c + intCtrex.c +) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt new file mode 100644 index 0000000000..921f0123cf --- /dev/null +++ b/src/proof/int2/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME proof_int2 + SOURCES + int2Refine.c + int2Bmc.c + int2Util.c + int2Core.c +) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt new file mode 100644 index 0000000000..ec06f60def --- /dev/null +++ b/src/proof/live/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME proof_live + SOURCES + arenaViolation.c + kliveness.c + liveness_sim.c + liveness.c + monotone.c + combination.c + ltl_parser.c + kLiveConstraints.c + disjunctiveMonotone.c +) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt new file mode 100644 index 0000000000..63270f4bc2 --- /dev/null +++ b/src/proof/pdr/CMakeLists.txt @@ -0,0 +1,14 @@ +abc_libabc_add_sources( + NAME proof_pdr + SOURCES + pdrUtil.c + pdrTsim.c + pdrIncr.c + pdrTsim3.c + pdrCnf.c + pdrInv.c + pdrMan.c + pdrSat.c + pdrTsim2.c + pdrCore.c +) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt new file mode 100644 index 0000000000..9aa7e483fb --- /dev/null +++ b/src/proof/ssc/CMakeLists.txt @@ -0,0 +1,9 @@ +abc_libabc_add_sources( + NAME proof_ssc + SOURCES + sscCore.c + sscSat.c + sscSim.c + sscClass.c + sscUtil.c +) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt new file mode 100644 index 0000000000..76e553ada8 --- /dev/null +++ b/src/proof/ssw/CMakeLists.txt @@ -0,0 +1,24 @@ +abc_libabc_add_sources( + NAME proof_ssw + SOURCES + sswBmc.c + sswMan.c + sswSat.c + sswPart.c + sswDyn.c + sswPairs.c + sswSim.c + sswCnf.c + sswRarity.c + sswSemi.c + sswLcorr.c + sswCore.c + sswIslands.c + sswUnique.c + sswSweep.c + sswSimSat.c + sswFilter.c + sswAig.c + sswConstr.c + sswClass.c +) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt new file mode 100644 index 0000000000..9000d7d1a3 --- /dev/null +++ b/src/sat/bmc/CMakeLists.txt @@ -0,0 +1,36 @@ +abc_libabc_add_sources( + NAME sat_bmc + SOURCES + bmcBmc.c + bmcBmcS.c + bmcMaj2.c + bmcMaj.c + bmcBmci.c + bmcChain.c + bmcCexMin2.c + bmcMaj3.c + bmcCexTools.c + bmcClp.c + bmcUnroll.c + bmcMesh.c + bmcBmcAnd.c + bmcLoad.c + bmcMaxi.c + bmcFault.c + bmcBCore.c + bmcCexMin1.c + bmcCexDepth.c + bmcBmc2.c + bmcMulti.c + bmcBmc3.c + bmcEco.c + bmcICheck.c + bmcCexCare.c + bmcGen.c + bmcExpand.c + bmcMesh2.c + bmcFx.c + bmcCexCut.c + bmcInse.c + bmcBmcG.c +) diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt new file mode 100644 index 0000000000..7818e3d163 --- /dev/null +++ b/src/sat/bsat/CMakeLists.txt @@ -0,0 +1,18 @@ +abc_libabc_add_sources( + NAME sat_bsat + SOURCES + satInterB.c + satSolver2.c + satSolver.c + satUtil.c + satStore.c + satMem.c + satSolver3.c + satProof.c + satInterA.c + satTruth.c + satSolver2i.c + satTrace.c + satInter.c + satInterP.c +) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt new file mode 100644 index 0000000000..fa2befbac0 --- /dev/null +++ b/src/sat/bsat2/CMakeLists.txt @@ -0,0 +1,11 @@ +abc_libabc_add_sources( + NAME sat_bsat2 + SOURCES + System.cpp + SimpSolver.cpp + MainSimp.cpp + MainSat.cpp + AbcApi.cpp + Options.cpp + Solver.cpp +) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt new file mode 100644 index 0000000000..c9088bc2c4 --- /dev/null +++ b/src/sat/cnf/CMakeLists.txt @@ -0,0 +1,13 @@ +abc_libabc_add_sources( + NAME sat_cnf + SOURCES + cnfPost.c + cnfMan.c + cnfCut.c + cnfMap.c + cnfFast.c + cnfUtil.c + cnfData.c + cnfWrite.c + cnfCore.c +) diff --git a/src/sat/csat/CMakeLists.txt b/src/sat/csat/CMakeLists.txt new file mode 100644 index 0000000000..0b61e3e482 --- /dev/null +++ b/src/sat/csat/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME sat_csat + SOURCES + csat_apis.c +) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt new file mode 100644 index 0000000000..8b891867b8 --- /dev/null +++ b/src/sat/glucose/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME sat_glucose + SOURCES + System.cpp + AbcGlucose.cpp + SimpSolver.cpp + AbcGlucoseCmd.cpp + Glucose.cpp + Options.cpp +) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt new file mode 100644 index 0000000000..78c15a6700 --- /dev/null +++ b/src/sat/msat/CMakeLists.txt @@ -0,0 +1,17 @@ +abc_libabc_add_sources( + NAME sat_msat + SOURCES + msatQueue.c + msatOrderH.c + msatActivity.c + msatSolverCore.c + msatClauseVec.c + msatSolverApi.c + msatMem.c + msatSolverIo.c + msatSolverSearch.c + msatRead.c + msatSort.c + msatClause.c + msatVec.c +) diff --git a/src/sat/psat/CMakeLists.txt b/src/sat/psat/CMakeLists.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/sat/satoko/CMakeLists.txt b/src/sat/satoko/CMakeLists.txt new file mode 100644 index 0000000000..3341a6f9c1 --- /dev/null +++ b/src/sat/satoko/CMakeLists.txt @@ -0,0 +1,7 @@ +abc_libabc_add_sources( + NAME sat_satoko + SOURCES + solver_api.c + solver.c + cnf_reader.c +) diff --git a/src/sat/xsat/CMakeLists.txt b/src/sat/xsat/CMakeLists.txt new file mode 100644 index 0000000000..a027e76ffe --- /dev/null +++ b/src/sat/xsat/CMakeLists.txt @@ -0,0 +1,7 @@ +abc_libabc_add_sources( + NAME sat_xsat + SOURCES + xsatSolver.c + xsatSolverAPI.c + xsatCnfReader.c +) From e0c1c1eb82b99e16660bb4522130f25004912f45 Mon Sep 17 00:00:00 2001 From: Anonymous Maarten Date: Tue, 13 Nov 2018 23:37:43 +0100 Subject: [PATCH 03/35] Export Abc_RealMain if building shared libabc --- src/base/main/main.c | 2 +- src/base/main/mainReal.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/base/main/main.c b/src/base/main/main.c index 7832bada72..f440aa33be 100644 --- a/src/base/main/main.c +++ b/src/base/main/main.c @@ -2,7 +2,7 @@ ABC_NAMESPACE_IMPL_START -int Abc_RealMain(int argc, char *argv[]); +extern ABC_DLL int Abc_RealMain(int argc, char *argv[]); ABC_NAMESPACE_IMPL_END diff --git a/src/base/main/mainReal.c b/src/base/main/mainReal.c index ec2fcb0751..51c82ffe0d 100644 --- a/src/base/main/mainReal.c +++ b/src/base/main/mainReal.c @@ -85,7 +85,7 @@ unsigned enable_dbg_outs = 1; SeeAlso [] ***********************************************************************/ -int Abc_RealMain( int argc, char * argv[] ) +ABC_DLL int Abc_RealMain( int argc, char * argv[] ) { Abc_Frame_t * pAbc; Vec_Str_t* sCommandUsr = Vec_StrAlloc(1000); From 3fc17847192e089f72ed5272dc5beb1bf3f1d09f Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 1 Nov 2021 10:33:49 -0700 Subject: [PATCH 04/35] new: dev: update original cmake cfg and sources, add tox/update ci files * update cmake source modules using PR script * add basic versioning for cmake shared libs * complete target/install properties, export config * move toolchain file to tools dir, add python script from PR * add tox file, update ci workflow to use it * tox handles most build tool dependencies, cmake, ninja, cpplint * make sure ABC_USE_STDINT_H is fallback if ABC_USE_NAMESPACE is not set Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 110 +++++++++++---------- CMakeLists.txt | 98 +++++++++++++++++-- src/aig/aig/CMakeLists.txt | 46 ++++----- src/aig/gia/CMakeLists.txt | 161 +++++++++++++++++-------------- src/aig/hop/CMakeLists.txt | 10 +- src/aig/ioa/CMakeLists.txt | 4 +- src/aig/ivy/CMakeLists.txt | 30 +++--- src/aig/saig/CMakeLists.txt | 38 ++++---- src/base/abc/CMakeLists.txt | 32 +++--- src/base/abci/CMakeLists.txt | 121 +++++++++++------------ src/base/acb/CMakeLists.txt | 9 +- src/base/bac/CMakeLists.txt | 20 ++-- src/base/cba/CMakeLists.txt | 10 +- src/base/cmd/CMakeLists.txt | 14 +-- src/base/exor/CMakeLists.txt | 6 +- src/base/io/CMakeLists.txt | 38 ++++---- src/base/pla/CMakeLists.txt | 8 +- src/base/ver/CMakeLists.txt | 4 +- src/base/wlc/CMakeLists.txt | 22 ++--- src/base/wln/CMakeLists.txt | 8 +- src/bdd/bbr/CMakeLists.txt | 2 +- src/bdd/cas/CMakeLists.txt | 2 +- src/bdd/cudd/CMakeLists.txt | 98 +++++++++---------- src/bdd/dsd/CMakeLists.txt | 6 +- src/bdd/extrab/CMakeLists.txt | 12 +-- src/bdd/llb/CMakeLists.txt | 30 +++--- src/bdd/mtr/CMakeLists.txt | 2 +- src/bdd/reo/CMakeLists.txt | 10 +- src/bool/bdc/CMakeLists.txt | 2 +- src/bool/dec/CMakeLists.txt | 6 +- src/bool/kit/CMakeLists.txt | 14 +-- src/bool/lucky/CMakeLists.txt | 6 +- src/map/amap/CMakeLists.txt | 18 ++-- src/map/cov/CMakeLists.txt | 10 +- src/map/fpga/CMakeLists.txt | 16 +-- src/map/if/CMakeLists.txt | 38 ++++---- src/map/mapper/CMakeLists.txt | 18 ++-- src/map/mio/CMakeLists.txt | 6 +- src/map/mpm/CMakeLists.txt | 12 +-- src/map/scl/CMakeLists.txt | 14 +-- src/misc/bzlib/CMakeLists.txt | 4 +- src/misc/espresso/CMakeLists.txt | 58 +++++------ src/misc/extra/CMakeLists.txt | 21 ++-- src/misc/mvc/CMakeLists.txt | 20 ++-- src/misc/nm/CMakeLists.txt | 2 +- src/misc/tim/CMakeLists.txt | 2 +- src/misc/util/CMakeLists.txt | 8 +- src/misc/zlib/CMakeLists.txt | 22 ++--- src/opt/cgt/CMakeLists.txt | 6 +- src/opt/csw/CMakeLists.txt | 4 +- src/opt/cut/CMakeLists.txt | 10 +- src/opt/dar/CMakeLists.txt | 8 +- src/opt/dau/CMakeLists.txt | 18 ++-- src/opt/fret/CMakeLists.txt | 4 +- src/opt/fsim/CMakeLists.txt | 6 +- src/opt/fxu/CMakeLists.txt | 14 +-- src/opt/lpk/CMakeLists.txt | 12 +-- src/opt/mfs/CMakeLists.txt | 10 +- src/opt/nwk/CMakeLists.txt | 16 +-- src/opt/res/CMakeLists.txt | 6 +- src/opt/ret/CMakeLists.txt | 6 +- src/opt/rwr/CMakeLists.txt | 10 +- src/opt/sbd/CMakeLists.txt | 10 +- src/opt/sfm/CMakeLists.txt | 10 +- src/opt/sim/CMakeLists.txt | 8 +- src/phys/place/CMakeLists.txt | 10 +- src/proof/abs/CMakeLists.txt | 20 ++-- src/proof/acec/CMakeLists.txt | 26 ++--- src/proof/cec/CMakeLists.txt | 25 ++--- src/proof/dch/CMakeLists.txt | 12 +-- src/proof/fra/CMakeLists.txt | 22 ++--- src/proof/fraig/CMakeLists.txt | 12 +-- src/proof/int/CMakeLists.txt | 12 +-- src/proof/int2/CMakeLists.txt | 2 +- src/proof/live/CMakeLists.txt | 10 +- src/proof/pdr/CMakeLists.txt | 14 +-- src/proof/ssc/CMakeLists.txt | 2 +- src/proof/ssw/CMakeLists.txt | 28 +++--- src/sat/bmc/CMakeLists.txt | 48 ++++----- src/sat/bsat/CMakeLists.txt | 20 ++-- src/sat/bsat2/CMakeLists.txt | 4 +- src/sat/cnf/CMakeLists.txt | 12 +-- src/sat/glucose/CMakeLists.txt | 6 +- src/sat/glucose2/CMakeLists.txt | 10 ++ src/sat/msat/CMakeLists.txt | 18 ++-- src/sat/satoko/CMakeLists.txt | 2 +- src/sat/xsat/CMakeLists.txt | 2 +- tools/clang_toolchain.cmake | 13 +++ tools/mk-cmakelists.py | 26 +++++ tox.ini | 73 ++++++++++++++ 90 files changed, 1037 insertions(+), 798 deletions(-) create mode 100644 src/sat/glucose2/CMakeLists.txt create mode 100644 tools/clang_toolchain.cmake create mode 100644 tools/mk-cmakelists.py create mode 100644 tox.ini diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index da55567ff1..23428553ac 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,10 +22,11 @@ jobs: strategy: fail-fast: false matrix: + python-version: [3.8] name: [ ubuntu-20.04-gcc, - ubuntu-20.04-clang, + ubuntu-18.04-gcc, macOS-10.15-gcc, ] @@ -33,12 +34,12 @@ jobs: - name: ubuntu-20.04-gcc os: ubuntu-20.04 compiler: gcc - version: "9" + version: "10" - - name: ubuntu-20.04-clang - os: ubuntu-20.04 - compiler: clang - version: "6" + - name: ubuntu-18.04-gcc + os: ubuntu-18.04 + compiler: gcc + version: "9" - name: macOS-10.15-gcc os: macOS-10.15 @@ -46,49 +47,60 @@ jobs: version: "10" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + + - name: Install Tox + run: | + python -m pip install --upgrade pip + pip install tox + + - name: Install and setup Linux packages + if: runner.os == 'Linux' + run: | + sudo apt-get -y -qq update + sudo apt-get install -y libreadline-dev ncurses-dev + if [ "${{ matrix.compiler }}" = "gcc" ]; then + sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib + echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV + else + sudo apt-get install -y clang-${{ matrix.version }} g++-multilib + echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV + fi - - name: Install and setup Linux packages - if: runner.os == 'Linux' - run: | - sudo apt-get -y -qq update - sudo apt-get install -y libreadline-dev ncurses-dev - if [ "${{ matrix.compiler }}" = "gcc" ]; then - sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib - echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV - echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV - else - sudo apt-get install -y clang-${{ matrix.version }} g++-multilib - echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV - echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV - fi + - name: Build and test Linux + if: runner.os == 'Linux' + env: + CC: ${{ env.CC }} + CXX: ${{ env.CXX }} + run: | + tox -e build - - name: Build and test Linux - if: runner.os == 'Linux' - env: - CC: ${{ env.CC }} - CXX: ${{ env.CXX }} - run: | - make ABC_MAKE_VERBOSE=1 ABC_USE_NAMESPACE=xxx OPTFLAGS= ABC_USE_PIC=1 abc test - - - name: Install and setup MacOS packages - if: runner.os == 'macOS' - run: | - if [ "${{ matrix.compiler }}" = "gcc" ]; then - brew install gcc@${{ matrix.version }} - echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV - echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV - else - ls -ls /Applications/ - sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.2.app - echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV - echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV - fi + - name: Install and setup MacOS packages + if: runner.os == 'macOS' + run: | + if [ "${{ matrix.compiler }}" = "gcc" ]; then + brew install gcc@${{ matrix.version }} + echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV + else + ls -ls /Applications/ + sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.app + echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV + echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV + fi - - name: Build and test MacOS - if: runner.os == 'macOS' - env: - CC: ${{ env.CC }} - CXX: ${{ env.CXX }} - run: | - make ABC_MAKE_VERBOSE=1 ABC_USE_NAMESPACE=xxx OPTFLAGS= ABC_USE_PIC=1 abc test + - name: Build and test MacOS + if: runner.os == 'macOS' + env: + CC: ${{ env.CC }} + CXX: ${{ env.CXX }} + run: | + tox -e ctest diff --git a/CMakeLists.txt b/CMakeLists.txt index 7d192b22a0..84db7f3611 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,40 @@ cmake_minimum_required(VERSION 3.5.0 FATAL_ERROR) -project(abc C CXX) + +# with at least one base tag, this can have dynamic (git) versioning: +# git describe last tag = 1.1.0 +# git describe last tag + rev count = 1.1.0.45 +# +# for now, set -DSCM_VERSION_INFO in the build env to override +if(NOT SCM_VERSION_INFO) + set(LIBRARY_VERSION 1.1.0) + set(SCM_VERSION_INFO ${LIBRARY_VERSION}) +endif() +set(LIBRARY_SOVERSION 1) + +project( + abc + LANGUAGES C CXX + VERSION ${SCM_VERSION_INFO} +) + +set(CMAKE_EXPORT_COMPILE_COMMANDS ON) +set(CMAKE_VERBOSE_MAKEFILE ON) + +set(CMAKE_CXX_STANDARD 11) +set(CMAKE_CXX_STANDARD_REQUIRED ON) +set(CMAKE_CXX_EXTENSIONS OFF) + +if(CMAKE_CXX_COMPILER_ID STREQUAL Clang) + set(CLANG_DEFAULT_CXX_STDLIB libc++) + set(CLANG_DEFAULT_RTLIB compiler-rt) +endif() + +if(NOT CMAKE_BUILD_TYPE) + set(CMAKE_BUILD_TYPE + "RelWithDebInfo" + CACHE STRING "Default build type: RelWithDebInfo" FORCE + ) +endif() include(CMakeParseArguments) include(CheckCCompilerFlag) @@ -23,6 +58,21 @@ option(ABC_USE_LIBSTDCXX "Link explicitly to stdc++") add_library(abc_interface INTERFACE) +set(ABC_HEADERS + src/base/main/abcapis_old.h + src/base/main/abcapis.h +) + +string(REPLACE "src/" "${CMAKE_CURRENT_SOURCE_DIR}/src/" ABC_HEADERS + "${ABC_HEADERS}" +) + +# Cache variable so this can be used in parent projects +set(abc_INCLUDE_DIR + "${CMAKE_CURRENT_LIST_DIR}/src" + CACHE INTERNAL "Directory where common headers are located" +) + set(ABC_MODULES src/base/abc src/base/abci src/base/cmd src/base/io src/base/main src/base/exor src/base/ver src/base/wlc src/base/wln src/base/acb src/base/bac src/base/cba src/base/pla src/base/test @@ -34,7 +84,7 @@ set(ABC_MODULES src/opt/cut src/opt/fxu src/opt/fxch src/opt/rwr src/opt/mfs src/opt/sim src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd - src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat src/sat/cnf src/sat/bmc src/sat/glucose + src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/bool/bdc src/bool/deco src/bool/dec src/bool/kit src/bool/lucky src/bool/rsb src/bool/rpo src/proof/pdr src/proof/abs src/proof/live src/proof/ssc src/proof/int @@ -51,7 +101,12 @@ if(ABC_EXTERNAL_MODULES) endif() target_compile_definitions(abc_interface INTERFACE $<$:_DEBUG> $<$>:NDEBUG>) -target_include_directories(abc_interface INTERFACE "${abc_SOURCE_DIR}/src") +target_include_directories( + abc_interface + INTERFACE $ + $ +) + target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS} ) @@ -73,13 +128,14 @@ endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") target_compile_options(abc_interface INTERFACE - -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare + -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare -Wno-deprecated ) target_link_libraries(abc_interface INTERFACE m) if(WIN32 OR ABC_USE_NAMESPACE) target_compile_options(abc_interface INTERFACE $<$:-fpermissive> + $<$:-fvisibility=hidden> ) endif() elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") @@ -102,11 +158,15 @@ endif() if(ABC_USE_NAMESPACE) message(STATUS "Compiling in namespace ${ABC_USE_NAMESPACE}") target_compile_definitions(abc_interface INTERFACE "ABC_NAMESPACE=${ABC_USE_NAMESPACE}") +else() + set(ABC_USE_STDINT_H 1) endif() include(CheckTypeSize) check_type_size("(void*)0" SIZEOF_VOID_P) + if(ABC_USE_STDINT_H) + message(STATUS "Setting ABC_USE_STDINT_H ${ABC_USE_STDINT_H}") target_compile_definitions(abc_interface INTERFACE "ABC_USE_STDINT_H=1") else() check_type_size("(long)0" SIZEOF_LONG) @@ -218,7 +278,7 @@ if(ABC_USE_PIC) set(CMAKE_POSITION_INDEPENDENT_CODE ON) endif() -if(ABC_USE_LIBSTDCXX) +if(ABC_USE_LIBSTDCXX OR NOT ABC_USE_NAMESPACE) message(STATUS "Using explicit -lstdc++") target_link_libraries(abc_interface INTERFACE stdc++ @@ -279,17 +339,37 @@ target_link_libraries(libabc PUBLIC abc_interface) set_target_properties(libabc PROPERTIES OUTPUT_NAME "abc" ) + if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") set_target_properties(libabc PROPERTIES OUTPUT_NAME "abc$<$:d>$<$>:r>" ) endif() -install(TARGETS libabc - ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" - LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" +if(BUILD_SHARED_LIBS) + set_target_properties( + libabc PROPERTIES VERSION ${LIBRARY_VERSION} + SOVERSION ${LIBRARY_SOVERSION} + ) +endif() + +install(FILES ${ABC_HEADERS} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/abc ) + +install( + TARGETS abc_interface libabc + EXPORT abcConfig + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + INCLUDES + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} +) + +install(EXPORT abcConfig + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/abc NAMESPACE abc::) + if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") if(BUILD_SHARED_LIBS) install(FILES $ DESTINATION bin OPTIONAL) diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt index 7ffccfb66a..544a97338e 100644 --- a/src/aig/aig/CMakeLists.txt +++ b/src/aig/aig/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME aig_aig SOURCES + aigRet.c aigDup.c - aigCuts.c - aigPartSat.c - aigInter.c - aigMem.c - aigMan.c - aigRepr.c - aigPartReg.c - aigShow.c + aigPack.c + aigSplit.c + aigRetF.c + aigObj.c aigCheck.c - aigTruth.c + aigPartReg.c + aigTsim.c + aigJust.c + aigTiming.c aigScl.c aigTable.c - aigObj.c - aigDfs.c - aigRet.c - aigJust.c - aigFrames.c + aigWin.c + aigShow.c + aigFanout.c aigOper.c - aigPack.c + aigMffc.c + aigFrames.c + aigMem.c + aigOrder.c aigPart.c aigUtil.c - aigTsim.c - aigTiming.c - aigFanout.c aigCanon.c - aigOrder.c - aigRetF.c - aigWin.c - aigMffc.c - aigSplit.c + aigDfs.c + aigTruth.c + aigCuts.c + aigPartSat.c + aigRepr.c + aigMan.c + aigInter.c ) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index 1d12f4fc41..cb6421cb29 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -1,95 +1,110 @@ abc_libabc_add_sources( NAME aig_gia SOURCES - giaIso.c - giaGig.c giaSplit.c - giaTruth.c - giaBalAig.c - giaNf.c + giaHash.c + giaIso.c + giaSweeper.c giaSim2.c - giaRetime.c - giaOf.c + giaSupMin.c + giaSweep.c + giaCSat2.c + giaSatLut.c + giaKf.c giaMini.c - giaResub.c - giaSpeedup.c - giaCSatOld.c - giaSatLE.c - giaCof.c - giaLf.c - giaSatMap.c - giaIso3.c - giaCSat.c - giaBalLut.c + giaCSat3.c + giaPat.c + giaDeep.c giaAig.c - giaSort.c - giaStr.c - giaShrink.c + giaSatoko.c + giaGen.c giaMfs.c - giaAiger.c - giaBidec.c - giaEra2.c - giaSatLut.c - giaRex.c - giaQbf.c + giaReshape1.c + giaClp.c + giaUtil.c + giaGig.c + giaTruth.c + giaTsim.c + giaTim.c + giaShrink.c + giaSatMap.c + giaDfs.c + giaAgi.c giaExist.c - giaSweep.c - giaIff.c - giaSatEdge.c + giaMem.c + giaSwitch.c + giaSim.c + giaCut.c + giaShow.c giaFalse.c - giaScript.c - giaSweeper.c - giaTim.c - giaFrames.c + giaOf.c + giaBalLut.c + giaCof.c + giaStr.c + giaPat2.c + giaBalMap.c + giaMinLut.c + giaEmbed.c + giaSupps.c giaAigerExt.c - giaTis.c - giaDup.c - giaFront.c - giaMf.c - giaCex.c - giaPf.c - giaSat3.c - giaCTas.c + giaIiff.c + giaResub2.c + giaAiger.c + giaIff.c + giaRetime.c + giaGlitch.c + giaResub3.c giaStg.c - giaEnable.c - giaUnate.c - giaPat.c giaMan.c - giaEsop.c - giaSupMin.c - giaKf.c - giaIf.c - giaIso2.c - giaForce.c - giaMem.c - giaEquiv.c - giaEmbed.c - giaCSat2.c - giaSwitch.c - giaFx.c - giaAgi.c + giaResub.c + giaFront.c giaEra.c + giaPf.c + giaQbf.c + giaBidec.c + giaCex.c giaCCof.c - giaTsim.c - giaBalMap.c + giaDup.c + giaPack.c + giaEnable.c + giaCSat.c + giaSatEdge.c + giaSpeedup.c + giaSimBase.c + giaBalAig.c + giaFrames.c + giaScl.c giaSupp.c - giaShow.c - giaShrink6.c + giaShrink7.c giaFanout.c - giaClp.c + giaEsop.c + giaSat3.c + giaForce.c + giaEra2.c + giaSort.c + giaFx.c + giaSatLE.c + giaEquiv.c + giaIso2.c + giaMinLut2.c + gia.c giaJf.c - giaScl.c - giaPack.c - giaDfs.c - giaIiff.c - giaGlitch.c - giaHash.c - giaShrink7.c + giaNf.c + giaIf.c + giaScript.c giaEdge.c - giaCut.c - giaSim.c - giaUtil.c + giaShrink6.c + giaIso3.c giaMuxes.c + giaLf.c + giaCSatOld.c + giaRex.c + giaMf.c + giaStoch.c + giaTis.c + giaCTas.c giaCone.c - giaSatoko.c + giaReshape2.c + giaUnate.c + giaDecs.c ) diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt index 69b29e5c2b..1db86faf3c 100644 --- a/src/aig/hop/CMakeLists.txt +++ b/src/aig/hop/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME aig_hop SOURCES - hopTable.c - hopBalance.c - hopObj.c - hopMan.c hopUtil.c hopOper.c + hopMem.c hopDfs.c hopTruth.c - hopMem.c + hopBalance.c + hopTable.c hopCheck.c + hopObj.c + hopMan.c ) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt index c547a36b6c..040b8625c8 100644 --- a/src/aig/ioa/CMakeLists.txt +++ b/src/aig/ioa/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME aig_ioa SOURCES - ioaUtil.c - ioaReadAig.c ioaWriteAig.c + ioaReadAig.c + ioaUtil.c ) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt index 5bae2323f4..4a70d8697b 100644 --- a/src/aig/ivy/CMakeLists.txt +++ b/src/aig/ivy/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME aig_ivy SOURCES + ivyBalance.c + ivyDsd.c + ivyCanon.c + ivyHaig.c + ivyCheck.c ivyUtil.c - ivyTable.c + ivyDfs.c ivyObj.c ivyCutTrav.c - ivyFraig.c - ivyBalance.c + ivyFanout.c + ivyShow.c + ivySeq.c + ivyMem.c + ivyCut.c ivyOper.c - ivyCanon.c - ivyMan.c - ivyFastMap.c + ivyFraig.c ivyRwr.c - ivyCheck.c - ivyCut.c + ivyMan.c ivyResyn.c - ivyDsd.c - ivyMem.c - ivyFanout.c - ivyShow.c - ivyDfs.c ivyMulti.c - ivySeq.c - ivyHaig.c + ivyFastMap.c + ivyTable.c ) diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt index 79e79de60a..01625652db 100644 --- a/src/aig/saig/CMakeLists.txt +++ b/src/aig/saig/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME aig_saig SOURCES - saigDup.c - saigOutDec.c + saigRetStep.c + saigSwitch.c + saigStrSim.c + saigMiter.c + saigConstr2.c + saigConstr.c + saigWnd.c saigScl.c - saigIsoSlow.c - saigPhase.c - saigSynch.c - saigIsoFast.c - saigSimSeq.c saigCone.c - saigRetStep.c saigIso.c - saigConstr.c saigRetFwd.c - saigTempor.c - saigStrSim.c - saigSwitch.c + saigSimFast.c saigInd.c + saigDual.c + saigDup.c saigTrans.c - saigWnd.c - saigIoa.c - saigRetMin.c + saigSynch.c + saigIsoFast.c + saigIsoSlow.c + saigOutDec.c + saigTempor.c + saigPhase.c + saigSimSeq.c saigSimMv.c - saigConstr2.c - saigMiter.c - saigSimFast.c - saigDual.c + saigRetMin.c + saigIoa.c ) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt index 6c45d0440f..e255c3300f 100644 --- a/src/base/abc/CMakeLists.txt +++ b/src/base/abc/CMakeLists.txt @@ -1,27 +1,27 @@ abc_libabc_add_sources( NAME base_abc SOURCES - abcUtil.c - abcFanio.c - abcShow.c - abcDfs.c - abcSop.c - abcAig.c - abcFunc.c - abcHie.c abcCheck.c abcHieCec.c - abcMinBase.c - abcBlifMv.c + abcHie.c abcLib.c - abcNetlist.c - abcNames.c - abcHieNew.c + abcLatch.c abcNtk.c + abcFunc.c abcFanOrder.c - abcHieGia.c - abcBarBuf.c abcObj.c + abcBarBuf.c + abcBlifMv.c + abcAig.c abcRefs.c - abcLatch.c + abcNetlist.c + abcUtil.c + abcDfs.c + abcHieNew.c + abcFanio.c + abcNames.c + abcShow.c + abcSop.c + abcMinBase.c + abcHieGia.c ) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index e175398075..be4f3ac226 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -1,79 +1,80 @@ abc_libabc_add_sources( NAME base_abci SOURCES - abcExtract.c - abcQuant.c - abcDebug.c - abcIvy.c + abcBalance.c + abcLutmin.c + abcLut.c + abcRunGen.c + abcSense.c + abcPart.c + abcDec.c + abcMulti.c + abcQbf.c + abcRewrite.c + abcReconv.c + abcRr.c + abcCut.c abcReach.c - abcHaig.c - abcAuto.c - abcFxu.c - abcAttach.c - abcDetect.c - abcRpo.c - abcBm.c - abcOdc.c - abcMfs.c abcSymm.c - abcFx.c - abcCas.c - abcDress3.c + abcSweep.c + abcDsd.c abcDress2.c abcStrash.c - abcReconv.c - abcMini.c - abcProve.c - abcSpeedup.c - abcExact.c - abcRefactor.c + abcOdc.c + abcUnreach.c abcRestruct.c - abcRec3.c - abcLutmin.c - abcTim.c - abcNtbdd.c - abcTiming.c - abcFraig.c + abc.c + abcMfs.c + abcGen.c + abcSaucy.c + abcHaig.c + abcSpeedup.c + abcCas.c + abcDebug.c + abcRpo.c + abcExtract.c + abcDar.c abcXsim.c - abcQbf.c - abcSense.c + abcReorder.c abcEco.c - abcDec.c - abcCut.c - abcUnreach.c - abcIf.c + abcExact.c + abcIfif.c + abcCascade.c + abcBm.c abcBmc.c - abcDar.c - abcBalance.c - abcMerge.c - abcReorder.c + abcRefactor.c abcResub.c - abcMiter.c - abcRr.c + abcIvy.c + abcFx.c + abcMap.c + abcDetect.c + abcMini.c + abcMerge.c + abcRec3.c + abcProve.c + abcVerify.c + abcFxu.c + abcRenode.c + abcLog.c abcDress.c - abcSweep.c - abcPart.c + abcTiming.c + abcOrder.c abcBidec.c - abcLog.c - abcCascade.c - abcScorr.c + abcSat.c + abcIf.c + abcPrint.c abcUnate.c + abcFraig.c + abcScorr.c + abcMiter.c + abcTim.c abcCollapse.c - abcVerify.c - abcRewrite.c - abcDsd.c - abcMulti.c - abcMap.c - abcNpnSave.c - abc.c - abcIfif.c - abcLut.c - abcGen.c - abcSaucy.c - abcPrint.c + abcAttach.c abcNpn.c - abcOrder.c - abcSat.c - abcRenode.c + abcDress3.c + abcNpnSave.c abcIfMux.c + abcNtbdd.c + abcQuant.c + abcAuto.c ) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt index a101e0b459..5d63a9bf83 100644 --- a/src/base/acb/CMakeLists.txt +++ b/src/base/acb/CMakeLists.txt @@ -1,12 +1,13 @@ abc_libabc_add_sources( NAME base_acb SOURCES - acbAbc.c + acbTest.c acbFunc.c + acbAbc.c + acbCom.c + acbMfs.c acbAig.c - acbSets.c acbUtil.c + acbSets.c acbPush.c - acbMfs.c - acbCom.c ) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt index 1c7131b624..74925d1834 100644 --- a/src/base/bac/CMakeLists.txt +++ b/src/base/bac/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME base_bac SOURCES - bacWriteBlif.c - bacBlast.c - bacPrsTrans.c bacWriteVer.c - bacReadBlif.c - bacLib.c - bacPrsBuild.c - bacCom.c - bacReadVer.c bacReadSmt.c - bacNtk.c + bacPrsTrans.c bacPtr.c + bacBlast.c + bacReadVer.c + bacReadBlif.c + bacPtrAbc.c + bacCom.c bacWriteSmt.c + bacNtk.c bacBac.c - bacPtrAbc.c + bacPrsBuild.c + bacLib.c + bacWriteBlif.c ) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt index 746caca920..4a06959f45 100644 --- a/src/base/cba/CMakeLists.txt +++ b/src/base/cba/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME base_cba SOURCES - cbaCom.c - cbaNtk.c cbaBlast.c - cbaWriteVer.c - cbaCba.c - cbaReadBlif.c cbaWriteBlif.c + cbaNtk.c cbaReadVer.c + cbaWriteVer.c + cbaReadBlif.c + cbaCba.c + cbaCom.c ) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt index 1a45bb2c64..834faf0a56 100644 --- a/src/base/cmd/CMakeLists.txt +++ b/src/base/cmd/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME base_cmd SOURCES - cmdFlag.c - cmdUtils.c - cmdPlugin.c - cmdLoad.c + cmd.c cmdAuto.c cmdStarter.c - cmdHist.c - cmdAlias.c - cmd.c + cmdPlugin.c cmdApi.c + cmdUtils.c + cmdAlias.c + cmdHist.c + cmdLoad.c + cmdFlag.c ) diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt index 34ba52b2c6..0db3a82cb9 100644 --- a/src/base/exor/CMakeLists.txt +++ b/src/base/exor/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME base_exor SOURCES - exorBits.c - exorUtil.c - exorList.c exorLink.c + exorList.c exorCubes.c + exorBits.c exor.c + exorUtil.c ) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index ece63dab0c..0198a6ec06 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME base_io SOURCES - ioReadBlifAig.c - ioWriteSmv.c + ioReadAiger.c + ioWriteBlif.c + ioWriteBblif.c ioWriteList.c + ioWritePla.c + ioJson.c + ioReadBench.c + ioWriteSmv.c + ioReadBlifAig.c + ioReadVerilog.c + ioReadPla.c + ioReadBblif.c + ioWriteCnf.c ioReadPlaMo.c - ioWriteBook.c ioReadBaf.c - ioWriteCnf.c - ioJson.c + ioWriteAiger.c + ioWriteBook.c ioReadBlif.c - io.c ioReadBlifMv.c + ioWriteVerilog.c + ioWriteGml.c ioWriteBlifMv.c - ioWritePla.c - ioReadBblif.c - ioWriteBlif.c - ioReadAiger.c - ioReadPla.c ioWriteEqn.c - ioReadDsd.c - ioWriteAiger.c ioWriteDot.c - ioWriteBblif.c - ioWriteGml.c - ioReadEdif.c - ioWriteVerilog.c ioWriteBaf.c + ioReadEdif.c + ioReadDsd.c ioWriteBench.c ioReadEqn.c - ioReadBench.c + io.c ioUtil.c - ioReadVerilog.c ) diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt index add1783363..b7ed90098b 100644 --- a/src/base/pla/CMakeLists.txt +++ b/src/base/pla/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME base_pla SOURCES + plaCom.c + plaWrite.c plaSimple.c - plaRead.c - plaMan.c plaMerge.c - plaWrite.c - plaCom.c + plaMan.c plaHash.c + plaRead.c ) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt index 00a5a9df31..34272103a1 100644 --- a/src/base/ver/CMakeLists.txt +++ b/src/base/ver/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME base_ver SOURCES - verFormula.c + verCore.c verStream.c + verFormula.c verParse.c - verCore.c ) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt index 87ded95737..de2efee12f 100644 --- a/src/base/wlc/CMakeLists.txt +++ b/src/base/wlc/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME base_wlc SOURCES - wlcStdin.c - wlcWin.c - wlcGraft.c wlcMem.c + wlcStdin.c wlcAbs.c - wlcNtk.c wlcSim.c wlcCom.c - wlcReadSmt.c - wlcShow.c - wlcUif.c wlcAbs2.c - wlcNdr.c - wlcBlast.c - wlcWriteVer.c - wlcPth.c + wlcReadSmt.c wlcReadVer.c wlcJson.c + wlcWin.c wlcAbc.c + wlcPth.c + wlcBlast.c + wlcUif.c + wlcWriteVer.c + wlcGraft.c + wlcNdr.c + wlcNtk.c + wlcShow.c ) diff --git a/src/base/wln/CMakeLists.txt b/src/base/wln/CMakeLists.txt index 26a0a61e39..dbaa865940 100644 --- a/src/base/wln/CMakeLists.txt +++ b/src/base/wln/CMakeLists.txt @@ -1,10 +1,12 @@ abc_libabc_add_sources( NAME base_wln SOURCES - wlnNtk.c + wlnWlc.c + wlnMem.c wlnObj.c - wlnWriteVer.c + wlnNtk.c wlnRetime.c - wln.c + wlnWriteVer.c wlnNdr.c + wln.c ) diff --git a/src/bdd/bbr/CMakeLists.txt b/src/bdd/bbr/CMakeLists.txt index 6207d7921b..8410ebdc46 100644 --- a/src/bdd/bbr/CMakeLists.txt +++ b/src/bdd/bbr/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME bdd_bbr SOURCES - bbrCex.c bbrImage.c bbrReach.c bbrNtbdd.c + bbrCex.c ) diff --git a/src/bdd/cas/CMakeLists.txt b/src/bdd/cas/CMakeLists.txt index 1ffcad65ec..7d0d295b7e 100644 --- a/src/bdd/cas/CMakeLists.txt +++ b/src/bdd/cas/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bdd_cas SOURCES - casDec.c casCore.c + casDec.c ) diff --git a/src/bdd/cudd/CMakeLists.txt b/src/bdd/cudd/CMakeLists.txt index 552c0b85d9..a8c3d58651 100644 --- a/src/bdd/cudd/CMakeLists.txt +++ b/src/bdd/cudd/CMakeLists.txt @@ -1,65 +1,65 @@ abc_libabc_add_sources( NAME bdd_cudd SOURCES - cuddZddSetop.c - cuddLinear.c - cuddZddCount.c - cuddBridge.c - cuddMatMult.c - cuddAnneal.c - cuddPriority.c - cuddEssent.c - cuddZddSymm.c + cuddGroup.c + cuddZddReord.c cuddClip.c - cuddZddGroup.c - cuddAddFind.c - cuddSplit.c - cuddUtil.c - cuddBddCorr.c - cuddAddNeg.c - cuddLCache.c - cuddBddAbs.c - cuddSign.c - cuddLiteral.c - cuddAddApply.c - cuddCheck.c - cuddExact.c + cuddAddAbs.c cuddZddLin.c - cuddTable.c - cuddDecomp.c - cuddAndAbs.c - cuddExport.c - cuddReorder.c - cuddCof.c - cuddGenetic.c - cuddCache.c - cuddInteract.c - cuddZddReord.c - cuddAddInv.c - cuddZddMisc.c + cuddExact.c + cuddAddWalsh.c + cuddSymmetry.c + cuddAddNeg.c cuddZddFuncs.c - cuddZddPort.c + cuddTable.c cuddApa.c - cuddSolve.c cuddHarwell.c - cuddAddAbs.c - cuddZddUtil.c - cuddZddIsop.c - cuddBddIte.c - cuddSubsetSP.c - cuddCompose.c - cuddRead.c + cuddInit.c + cuddCheck.c + cuddSolve.c + cuddUtil.c + cuddAndAbs.c cuddAddIte.c - cuddAddWalsh.c + cuddInteract.c + cuddSign.c + cuddApprox.c cuddLevelQ.c - cuddGroup.c - cuddSymmetry.c + cuddZddCount.c + cuddAddFind.c + cuddZddIsop.c + cuddMatMult.c + cuddBridge.c + cuddSubsetSP.c cuddRef.c + cuddDecomp.c + cuddZddGroup.c + cuddLCache.c cuddAPI.c - cuddInit.c - cuddSubsetHB.c + cuddZddSetop.c + cuddGenetic.c + cuddCompose.c + cuddExport.c + cuddEssent.c + cuddReorder.c + cuddRead.c + cuddAddApply.c + cuddAnneal.c + cuddCof.c cuddGenCof.c + cuddSubsetHB.c + cuddAddInv.c cuddSat.c + cuddLiteral.c + cuddZddPort.c + cuddCache.c cuddWindow.c - cuddApprox.c + cuddBddIte.c + cuddLinear.c + cuddSplit.c + cuddZddMisc.c + cuddBddAbs.c + cuddPriority.c + cuddZddSymm.c + cuddZddUtil.c + cuddBddCorr.c ) diff --git a/src/bdd/dsd/CMakeLists.txt b/src/bdd/dsd/CMakeLists.txt index 564b1c3c01..b7f04e17b4 100644 --- a/src/bdd/dsd/CMakeLists.txt +++ b/src/bdd/dsd/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME bdd_dsd SOURCES - dsdTree.c dsdCheck.c - dsdMan.c + dsdProc.c dsdApi.c + dsdTree.c dsdLocal.c - dsdProc.c + dsdMan.c ) diff --git a/src/bdd/extrab/CMakeLists.txt b/src/bdd/extrab/CMakeLists.txt index 9509d5895b..b5367fd871 100644 --- a/src/bdd/extrab/CMakeLists.txt +++ b/src/bdd/extrab/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME bdd_extrab SOURCES - extraBddImage.c - extraBddKmap.c - extraBddUnate.c extraBddAuto.c - extraBddThresh.c - extraBddCas.c + extraBddKmap.c + extraBddSymm.c extraBddMaxMin.c + extraBddCas.c extraBddMisc.c extraBddTime.c extraBddSet.c - extraBddSymm.c + extraBddUnate.c + extraBddImage.c + extraBddThresh.c ) diff --git a/src/bdd/llb/CMakeLists.txt b/src/bdd/llb/CMakeLists.txt index 0d7ca32fc9..4577fb2470 100644 --- a/src/bdd/llb/CMakeLists.txt +++ b/src/bdd/llb/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME bdd_llb SOURCES - llb3Nonlin.c - llb1Man.c - llb1Pivot.c - llb1Hint.c - llb2Core.c - llb1Cluster.c + llb1Constr.c + llb2Dump.c llb1Sched.c - llb4Sweep.c - llb2Image.c - llb2Driver.c llb2Flow.c - llb4Nonlin.c - llb2Bad.c - llb4Image.c llb1Matrix.c - llb3Image.c + llb2Bad.c + llb2Image.c llb1Core.c - llb1Constr.c + llb2Driver.c + llb1Cluster.c llb4Cex.c - llb2Dump.c + llb1Pivot.c + llb1Man.c + llb4Image.c + llb4Sweep.c + llb3Nonlin.c llb1Group.c + llb4Nonlin.c + llb2Core.c + llb1Hint.c llb1Reach.c + llb3Image.c ) diff --git a/src/bdd/mtr/CMakeLists.txt b/src/bdd/mtr/CMakeLists.txt index cf84703ef8..634875995a 100644 --- a/src/bdd/mtr/CMakeLists.txt +++ b/src/bdd/mtr/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bdd_mtr SOURCES - mtrGroup.c mtrBasic.c + mtrGroup.c ) diff --git a/src/bdd/reo/CMakeLists.txt b/src/bdd/reo/CMakeLists.txt index fc060eb857..0ef766be29 100644 --- a/src/bdd/reo/CMakeLists.txt +++ b/src/bdd/reo/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME bdd_reo SOURCES - reoShuffle.c reoSift.c - reoSwap.c - reoApi.c + reoShuffle.c + reoTransfer.c reoCore.c - reoProfile.c reoUnits.c - reoTransfer.c + reoApi.c + reoSwap.c + reoProfile.c ) diff --git a/src/bool/bdc/CMakeLists.txt b/src/bool/bdc/CMakeLists.txt index a26868d86f..5b7cf10b4b 100644 --- a/src/bool/bdc/CMakeLists.txt +++ b/src/bool/bdc/CMakeLists.txt @@ -2,7 +2,7 @@ abc_libabc_add_sources( NAME bool_bdc SOURCES bdcTable.c + bdcDec.c bdcSpfd.c bdcCore.c - bdcDec.c ) diff --git a/src/bool/dec/CMakeLists.txt b/src/bool/dec/CMakeLists.txt index 3d5136cba6..696e908566 100644 --- a/src/bool/dec/CMakeLists.txt +++ b/src/bool/dec/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME bool_dec SOURCES - decUtil.c + decPrint.c decAbc.c - decMan.c + decUtil.c decFactor.c - decPrint.c + decMan.c ) diff --git a/src/bool/kit/CMakeLists.txt b/src/bool/kit/CMakeLists.txt index 27045b8858..4f01e60e89 100644 --- a/src/bool/kit/CMakeLists.txt +++ b/src/bool/kit/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME bool_kit SOURCES - kitHop.c + kitPla.c kitCloud.c - kitFactor.c - cloud.c - kitDsd.c kitTruth.c - kitSop.c kitIsop.c + kitSop.c kitBdd.c - kitGraph.c - kitPla.c + kitHop.c + kitDsd.c + kitFactor.c kitAig.c + cloud.c + kitGraph.c ) diff --git a/src/bool/lucky/CMakeLists.txt b/src/bool/lucky/CMakeLists.txt index e4c4227a0b..48cb0b4d87 100644 --- a/src/bool/lucky/CMakeLists.txt +++ b/src/bool/lucky/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME bool_lucky SOURCES - luckySimple.c - luckySwapIJ.c luckySwap.c - luckyFast16.c lucky.c + luckySwapIJ.c + luckySimple.c luckyFast6.c luckyRead.c + luckyFast16.c ) diff --git a/src/map/amap/CMakeLists.txt b/src/map/amap/CMakeLists.txt index 586c47c22c..010ddac6b5 100644 --- a/src/map/amap/CMakeLists.txt +++ b/src/map/amap/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_amap SOURCES - amapLib.c + amapMan.c + amapOutput.c amapGraph.c - amapRead.c - amapMerge.c - amapRule.c + amapLib.c + amapMatch.c + amapCore.c amapLiberty.c - amapMan.c - amapUniq.c amapPerm.c - amapMatch.c + amapRule.c amapParse.c - amapOutput.c - amapCore.c + amapRead.c + amapMerge.c + amapUniq.c ) diff --git a/src/map/cov/CMakeLists.txt b/src/map/cov/CMakeLists.txt index b58717e943..754c39a00e 100644 --- a/src/map/cov/CMakeLists.txt +++ b/src/map/cov/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_cov SOURCES - covCore.c - covMinEsop.c - covMinMan.c - covMan.c - covBuild.c covMinSop.c + covMinMan.c covMinUtil.c + covBuild.c + covCore.c + covMan.c + covMinEsop.c ) diff --git a/src/map/fpga/CMakeLists.txt b/src/map/fpga/CMakeLists.txt index 7611f768b3..a4e584bf46 100644 --- a/src/map/fpga/CMakeLists.txt +++ b/src/map/fpga/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_fpga SOURCES - fpgaFanout.c - fpgaCreate.c + fpgaTime.c + fpgaCut.c fpgaVec.c fpgaCore.c - fpgaSwitch.c fpgaCutUtils.c - fpgaCut.c - fpgaTruth.c - fpga.c - fpgaTime.c - fpgaMatch.c fpgaUtils.c + fpgaFanout.c + fpga.c fpgaLib.c + fpgaTruth.c + fpgaCreate.c + fpgaMatch.c + fpgaSwitch.c ) diff --git a/src/map/if/CMakeLists.txt b/src/map/if/CMakeLists.txt index a951911cde..745b33a86d 100644 --- a/src/map/if/CMakeLists.txt +++ b/src/map/if/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME map_if SOURCES - ifMan.c + ifLibBox.c + ifDec75.c + ifSeq.c + ifDelay.c + ifCom.c + ifDsd.c + ifData2.c + ifDec10.c ifSat.c - ifTime.c + ifUtil.c + ifMan.c + ifTune.c + ifDec16.c + ifCache.c ifDec08.c - ifMap.c + ifLibLut.c ifTest.c ifTruth.c - ifReduce.c ifSelect.c - ifUtil.c + ifMatch2.c ifDec07.c - ifTune.c - ifCut.c - ifDsd.c ifCore.c - ifDec16.c - ifDec75.c - ifLibLut.c - ifLibBox.c - ifCache.c - ifDec10.c - ifMatch2.c - ifData2.c - ifCom.c - ifDelay.c - ifSeq.c + ifReduce.c + ifMap.c + ifCut.c + ifTime.c ) diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt index a496fbb827..665145bd98 100644 --- a/src/map/mapper/CMakeLists.txt +++ b/src/map/mapper/CMakeLists.txt @@ -2,20 +2,20 @@ abc_libabc_add_sources( NAME map_mapper SOURCES mapperTable.c - mapperTree.c - mapperCore.c + mapperTime.c + mapperRefs.c + mapperSuper.c + mapper.c mapperCreate.c mapperSwitch.c + mapperCore.c mapperCanon.c - mapperCut.c mapperTruth.c - mapperSuper.c - mapperTime.c + mapperUtils.c + mapperLib.c mapperVec.c + mapperTree.c mapperCutUtils.c - mapperRefs.c - mapper.c mapperMatch.c - mapperUtils.c - mapperLib.c + mapperCut.c ) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt index f5a4136f4c..72d5e71ad9 100644 --- a/src/map/mio/CMakeLists.txt +++ b/src/map/mio/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_mio SOURCES - mioFunc.c - mioUtils.c + mioSop.c mioParse.c + mioFunc.c mioRead.c mioApi.c + mioUtils.c mio.c - mioSop.c ) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt index 806fa9c446..6ca6eab7ce 100644 --- a/src/map/mpm/CMakeLists.txt +++ b/src/map/mpm/CMakeLists.txt @@ -2,14 +2,14 @@ abc_libabc_add_sources( NAME map_mpm SOURCES mpmMan.c - mpmUtil.c - mpmCore.c - mpmMap.c - mpmPre.c - mpmAbc.c mpmDsd.c - mpmMig.c mpmLib.c + mpmMig.c + mpmUtil.c mpmTruth.c + mpmMap.c + mpmCore.c mpmGates.c + mpmPre.c + mpmAbc.c ) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt index 8372158290..5e95dbf1c4 100644 --- a/src/map/scl/CMakeLists.txt +++ b/src/map/scl/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_scl SOURCES - sclDnsize.c - sclUpsize.c - sclBufSize.c + sclLiberty.c + sclLibScl.c + sclBuffer.c sclLibUtil.c - sclLoad.c scl.c - sclLibScl.c + sclUpsize.c + sclBufSize.c sclSize.c sclUtil.c - sclBuffer.c - sclLiberty.c + sclLoad.c + sclDnsize.c ) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt index 991be131a4..0f45852e56 100644 --- a/src/misc/bzlib/CMakeLists.txt +++ b/src/misc/bzlib/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME misc_bzlib SOURCES - crctable.c - blocksort.c huffman.c compress.c decompress.c bzlib.c + blocksort.c randtable.c + crctable.c ) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt index b0790b8ae4..8aec1478ce 100644 --- a/src/misc/espresso/CMakeLists.txt +++ b/src/misc/espresso/CMakeLists.txt @@ -1,43 +1,43 @@ abc_libabc_add_sources( NAME misc_espresso SOURCES - pair.c + cols.c + matrix.c + sminterf.c + cvrmisc.c unate.c - gimpel.c - opo.c - map.c - cvrin.c - gasp.c essen.c - irred.c - reduce.c + gasp.c + sharp.c + map.c indep.c - cols.c - hack.c + reduce.c + expand.c setc.c - espresso.c - cvrout.c - cubehack.c - matrix.c + exact.c cofactor.c - part.c - sminterf.c - dominate.c + cubehack.c + gimpel.c + globals.c + equiv.c + cvrin.c + verify.c + compl.c solution.c - contain.c rows.c + mincov.c cvrm.c - cvrmisc.c - cubestr.c - exact.c - expand.c - verify.c - equiv.c - globals.c + cvrout.c + opo.c + part.c + sparse.c + contain.c + pair.c + hack.c primes.c - compl.c - sharp.c - mincov.c set.c - sparse.c + espresso.c + cubestr.c + dominate.c + irred.c ) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt index a283918674..2454afd7d4 100644 --- a/src/misc/extra/CMakeLists.txt +++ b/src/misc/extra/CMakeLists.txt @@ -1,21 +1,24 @@ abc_libabc_add_sources( NAME misc_extra SOURCES - extraUtilBitMatrix.c extraUtilFile.c + extraUtilGen.c + extraUtilMaj.c + extraUtilEnum.c extraUtilCube.c - extraUtilMult.c extraUtilUtil.c - extraUtilPerm.c extraUtilReader.c - extraUtilCanon.c - extraUtilMaj.c - extraUtilMemory.c extraUtilTruth.c + extraUtilMacc.c + extraUtilCanon.c + extraUtilDsd.c + extraUtilCfs.c extraUtilPath.c + extraUtilPerm.c extraUtilProgress.c - extraUtilSupp.c - extraUtilDsd.c extraUtilMisc.c - extraUtilEnum.c + extraUtilMult.c + extraUtilBitMatrix.c + extraUtilMemory.c + extraUtilSupp.c ) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt index a7e4ee3a8a..8900ec3707 100644 --- a/src/misc/mvc/CMakeLists.txt +++ b/src/misc/mvc/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_mvc SOURCES - mvcCompare.c - mvcContain.c mvcMan.c mvcCover.c - mvcOpAlg.c - mvcSort.c - mvcPrint.c mvcDivisor.c - mvcUtils.c - mvcDivide.c - mvcApi.c - mvcList.c - mvcOpBool.c + mvcOpAlg.c + mvcContain.c mvcLits.c + mvcUtils.c mvcCube.c + mvcCompare.c + mvcOpBool.c + mvcPrint.c + mvcSort.c + mvcList.c + mvcApi.c + mvcDivide.c ) diff --git a/src/misc/nm/CMakeLists.txt b/src/misc/nm/CMakeLists.txt index bf4706f5fd..ef2789c4fd 100644 --- a/src/misc/nm/CMakeLists.txt +++ b/src/misc/nm/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME misc_nm SOURCES - nmTable.c nmApi.c + nmTable.c ) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt index 8be56dabc5..f430ed9557 100644 --- a/src/misc/tim/CMakeLists.txt +++ b/src/misc/tim/CMakeLists.txt @@ -4,6 +4,6 @@ abc_libabc_add_sources( timDump.c timTrav.c timTime.c - timBox.c timMan.c + timBox.c ) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt index 498e04d3fd..b38e24dafd 100644 --- a/src/misc/util/CMakeLists.txt +++ b/src/misc/util/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME misc_util SOURCES - utilSort.c - utilBridge.c utilColor.c utilIsop.c + utilSort.c + utilCex.c + utilNam.c utilSignal.c + utilBridge.c utilFile.c - utilNam.c - utilCex.c ) diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt index 04bd82c9cb..a661bb86d5 100644 --- a/src/misc/zlib/CMakeLists.txt +++ b/src/misc/zlib/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_zlib SOURCES - adler32.c - gzclose.c + zutil.c + inflate.c inftrees.c - infback.c + gzclose.c crc32.c - trees.c - deflate.c - gzlib.c - gzwrite.c inffast.c - gzread.c - zutil.c - inflate.c - compress_.c + gzlib.c + infback.c uncompr.c + compress_.c + deflate.c + gzread.c + trees.c + adler32.c + gzwrite.c ) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt index 0f2f04c759..bd10d557e0 100644 --- a/src/opt/cgt/CMakeLists.txt +++ b/src/opt/cgt/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME opt_cgt SOURCES - cgtSat.c - cgtDecide.c + cgtCore.c cgtMan.c + cgtSat.c cgtAig.c - cgtCore.c + cgtDecide.c ) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt index 256338a893..e24c9df53e 100644 --- a/src/opt/csw/CMakeLists.txt +++ b/src/opt/csw/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_csw SOURCES - cswMan.c cswCut.c - cswTable.c cswCore.c + cswMan.c + cswTable.c ) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt index 437239d9be..dfc052ed2c 100644 --- a/src/opt/cut/CMakeLists.txt +++ b/src/opt/cut/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_cut SOURCES - cutPre22.c + cutSeq.c cutNode.c - cutTruth.c - cutMan.c - cutOracle.c cutCut.c cutMerge.c cutApi.c - cutSeq.c + cutOracle.c + cutTruth.c + cutPre22.c + cutMan.c ) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt index 5ac002feb9..f9f62f3607 100644 --- a/src/opt/dar/CMakeLists.txt +++ b/src/opt/dar/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_dar SOURCES + darCore.c darPrec.c - darRefact.c + darBalance.c + darLib.c darScript.c darCut.c darData.c darMan.c - darBalance.c - darLib.c - darCore.c + darRefact.c ) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt index 439cdc42b4..e60a257016 100644 --- a/src/opt/dau/CMakeLists.txt +++ b/src/opt/dau/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_dau SOURCES - dauCore.c - dauDsd.c - dauNpn.c - dauNpn2.c - dauMerge.c - dauGia.c - dauCanon.c - dauCount.c dauTree.c + dauDsd.c dauEnum.c - dauDivs.c dauNonDsd.c + dauCount.c + dauDivs.c + dauCanon.c + dauMerge.c + dauGia.c + dauCore.c + dauNpn.c + dauNpn2.c ) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt index 3ed1f7ed6f..d01604ac6d 100644 --- a/src/opt/fret/CMakeLists.txt +++ b/src/opt/fret/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fret SOURCES - fretFlow.c fretMain.c - fretTime.c fretInit.c + fretFlow.c + fretTime.c ) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt index 3591d11ac5..cdae7250d8 100644 --- a/src/opt/fsim/CMakeLists.txt +++ b/src/opt/fsim/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME opt_fsim SOURCES - fsimTsim.c - fsimFront.c - fsimCore.c fsimSwitch.c + fsimCore.c fsimSim.c + fsimFront.c fsimMan.c + fsimTsim.c ) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt index 200ba3ac3c..ec59dcfba5 100644 --- a/src/opt/fxu/CMakeLists.txt +++ b/src/opt/fxu/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_fxu SOURCES - fxu.c - fxuSingle.c + fxuHeapD.c + fxuPair.c + fxuUpdate.c + fxuList.c fxuPrint.c + fxuSelect.c fxuCreate.c - fxuList.c - fxuHeapD.c + fxu.c fxuHeapS.c fxuReduce.c - fxuUpdate.c - fxuSelect.c - fxuPair.c + fxuSingle.c fxuMatrix.c ) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt index 41b241b6bc..1688146617 100644 --- a/src/opt/lpk/CMakeLists.txt +++ b/src/opt/lpk/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME opt_lpk SOURCES + lpkMux.c lpkSets.c - lpkMap.c lpkAbcDsd.c - lpkMux.c - lpkAbcMux.c - lpkCut.c - lpkMulti.c lpkAbcDec.c lpkCore.c - lpkMan.c + lpkMulti.c lpkAbcUtil.c + lpkMan.c + lpkCut.c + lpkAbcMux.c + lpkMap.c ) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt index 0798789994..ee2d4a1ec6 100644 --- a/src/opt/mfs/CMakeLists.txt +++ b/src/opt/mfs/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME opt_mfs SOURCES - mfsDiv.c - mfsResub.c + mfsStrash.c mfsWin.c - mfsSat.c + mfsCore.c mfsMan.c + mfsDiv.c + mfsSat.c mfsInter.c - mfsStrash.c - mfsCore.c + mfsResub.c ) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt index 6b733fa1e9..75b7caa0f1 100644 --- a/src/opt/nwk/CMakeLists.txt +++ b/src/opt/nwk/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME opt_nwk SOURCES - nwkObj.c nwkStrash.c - nwkMap.c nwkDfs.c - nwkMerge.c - nwkMan.c - nwkTiming.c - nwkFanio.c nwkFlow.c + nwkFanio.c + nwkMap.c + nwkObj.c + nwkTiming.c + nwkMerge.c + nwkUtil.c + nwkAig.c nwkSpeedup.c nwkCheck.c + nwkMan.c nwkBidec.c - nwkAig.c - nwkUtil.c ) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt index d903597642..0ea35b4a1a 100644 --- a/src/opt/res/CMakeLists.txt +++ b/src/opt/res/CMakeLists.txt @@ -2,10 +2,10 @@ abc_libabc_add_sources( NAME opt_res SOURCES resWin.c - resCore.c + resStrash.c + resSat.c resSim.c + resCore.c resFilter.c - resStrash.c resDivs.c - resSat.c ) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt index 84b6d3848f..fa28ff4566 100644 --- a/src/opt/ret/CMakeLists.txt +++ b/src/opt/ret/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_ret SOURCES - retFlow.c - retIncrem.c retInit.c + retIncrem.c retLvalue.c - retArea.c retDelay.c + retArea.c + retFlow.c retCore.c ) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt index 8c5ea05fb7..f04575f099 100644 --- a/src/opt/rwr/CMakeLists.txt +++ b/src/opt/rwr/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_rwr SOURCES - rwrDec.c - rwrPrint.c - rwrUtil.c + rwrLib.c rwrExp.c - rwrMan.c rwrEva.c - rwrLib.c + rwrDec.c + rwrMan.c + rwrUtil.c + rwrPrint.c ) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt index 7d21ae495a..a2fc55d484 100644 --- a/src/opt/sbd/CMakeLists.txt +++ b/src/opt/sbd/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sbd SOURCES - sbdCut2.c - sbdCore.c sbdLut.c sbdSat.c - sbd.c - sbdPath.c + sbdCut2.c sbdCnf.c - sbdCut.c + sbdCore.c sbdWin.c + sbdPath.c + sbd.c + sbdCut.c ) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt index 0e5496d657..a4200e0143 100644 --- a/src/opt/sfm/CMakeLists.txt +++ b/src/opt/sfm/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME opt_sfm SOURCES + sfmNtk.c + sfmArea.c sfmMit.c - sfmDec.c - sfmLib.c sfmTim.c + sfmDec.c + sfmCore.c sfmSat.c - sfmArea.c sfmCnf.c + sfmLib.c sfmWin.c - sfmNtk.c - sfmCore.c ) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt index 41a25f69b6..d7ae044c12 100644 --- a/src/opt/sim/CMakeLists.txt +++ b/src/opt/sim/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sim SOURCES - simSupp.c simSymSat.c simMan.c - simSym.c - simSymStr.c simSwitch.c - simSeq.c + simSymStr.c + simSym.c + simSupp.c simUtils.c + simSeq.c simSymSim.c ) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt index 729ee44e8f..a58875f98b 100644 --- a/src/phys/place/CMakeLists.txt +++ b/src/phys/place/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME phys_place SOURCES - place_inc.c - place_gordian.c place_bin.c + place_genqp.c place_base.c + place_inc.c + place_io.c + place_legalize.c + place_gordian.c place_qpsolver.c place_pads.c place_partition.c - place_genqp.c - place_legalize.c - place_io.c ) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt index c601fa5d44..d9991ddb5d 100644 --- a/src/proof/abs/CMakeLists.txt +++ b/src/proof/abs/CMakeLists.txt @@ -2,19 +2,19 @@ abc_libabc_add_sources( NAME proof_abs SOURCES absRpm.c - absOldCex.c - absOldRef.c absVta.c - absRefSelect.c - absGlaOld.c - absRef.c absPth.c + absIter.c + absOldRef.c + absRef.c absUtil.c - absOldSat.c - absDup.c - absOldSim.c + absOldCex.c + absGla.c absRpmOld.c - absIter.c absOut.c - absGla.c + absDup.c + absOldSim.c + absGlaOld.c + absRefSelect.c + absOldSat.c ) diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt index 066231797d..adc4690ad4 100644 --- a/src/proof/acec/CMakeLists.txt +++ b/src/proof/acec/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME proof_acec SOURCES - acecOrder.c - acecCore.c - acecPa.c - acecUtil.c + acecRe.c acecNorm.c acecTree.c + acecPa.c + acecUtil.c + acecCl.c + acec2Mult.c + acecOrder.c + acecMult.c acecSt.c - acecCo.c - acecPolyn.c - acecCover.c acecPool.c - acecXor.c acecBo.c - acec2Mult.c - acecMult.c - acecFadds.c + acecCover.c acecPo.c - acecRe.c - acecCl.c + acecFadds.c + acecCore.c + acecCo.c + acecXor.c + acecPolyn.c ) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt index 9d871dce1d..3e001162f0 100644 --- a/src/proof/cec/CMakeLists.txt +++ b/src/proof/cec/CMakeLists.txt @@ -1,19 +1,22 @@ abc_libabc_add_sources( NAME proof_cec SOURCES + cecSat.c + cecSynth.c + cecSim.c cecCec.c - cecSplit.c - cecPat.c - cecSeq.c - cecSweep.c - cecCore.c + cecChoice.c + cecSatG2.c cecCorr.c - cecSynth.c - cecIso.c - cecMan.c cecSatG.c - cecSolve.c - cecSat.c - cecChoice.c cecClass.c + cecSolve.c + cecCore.c + cecSweep.c + cecPat.c + cecSplit.c + cecSeq.c + cecMan.c + cecSolveG.c + cecIso.c ) diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt index fda0473634..be96316bf1 100644 --- a/src/proof/dch/CMakeLists.txt +++ b/src/proof/dch/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_dch SOURCES - dchSat.c - dchAig.c dchSweep.c - dchCore.c - dchMan.c - dchChoice.c - dchCnf.c + dchAig.c dchSimSat.c + dchMan.c dchClass.c dchSim.c + dchCnf.c + dchCore.c + dchChoice.c + dchSat.c ) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt index e68fd57987..17750074cf 100644 --- a/src/proof/fra/CMakeLists.txt +++ b/src/proof/fra/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME proof_fra SOURCES - fraCnf.c - fraInd.c + fraImp.c + fraClass.c + fraSim.c + fraHot.c fraBmc.c - fraClaus.c fraCec.c - fraPart.c - fraClass.c - fraSec.c fraCore.c - fraHot.c + fraLcr.c + fraPart.c fraClau.c + fraMan.c + fraCnf.c + fraClaus.c fraIndVer.c fraSat.c - fraSim.c - fraLcr.c - fraMan.c - fraImp.c + fraSec.c + fraInd.c ) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt index 7938e540f2..5fadae228a 100644 --- a/src/proof/fraig/CMakeLists.txt +++ b/src/proof/fraig/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME proof_fraig SOURCES - fraigFeed.c - fraigTable.c - fraigSat.c - fraigFanout.c fraigMan.c + fraigCanon.c + fraigFeed.c fraigVec.c - fraigApi.c fraigUtil.c fraigMem.c + fraigTable.c fraigNode.c fraigPrime.c - fraigCanon.c + fraigApi.c + fraigFanout.c + fraigSat.c ) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt index 7297de8809..7a425b6495 100644 --- a/src/proof/int/CMakeLists.txt +++ b/src/proof/int/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_int SOURCES - intMan.c - intFrames.c intCore.c - intContain.c - intUtil.c intDup.c - intInter.c intM114.c - intCheck.c + intUtil.c intCtrex.c + intMan.c + intContain.c + intFrames.c + intCheck.c + intInter.c ) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt index 921f0123cf..b8e15c4de5 100644 --- a/src/proof/int2/CMakeLists.txt +++ b/src/proof/int2/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME proof_int2 SOURCES - int2Refine.c int2Bmc.c int2Util.c + int2Refine.c int2Core.c ) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt index ec06f60def..a2385f68b2 100644 --- a/src/proof/live/CMakeLists.txt +++ b/src/proof/live/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME proof_live SOURCES + combination.c + liveness.c + liveness_sim.c + disjunctiveMonotone.c arenaViolation.c kliveness.c - liveness_sim.c - liveness.c monotone.c - combination.c - ltl_parser.c kLiveConstraints.c - disjunctiveMonotone.c + ltl_parser.c ) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt index 63270f4bc2..06d7edfbf5 100644 --- a/src/proof/pdr/CMakeLists.txt +++ b/src/proof/pdr/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_pdr SOURCES - pdrUtil.c - pdrTsim.c - pdrIncr.c - pdrTsim3.c - pdrCnf.c - pdrInv.c pdrMan.c + pdrIncr.c pdrSat.c - pdrTsim2.c pdrCore.c + pdrInv.c + pdrUtil.c + pdrCnf.c + pdrTsim3.c + pdrTsim.c + pdrTsim2.c ) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt index 9aa7e483fb..a90d29d189 100644 --- a/src/proof/ssc/CMakeLists.txt +++ b/src/proof/ssc/CMakeLists.txt @@ -3,7 +3,7 @@ abc_libabc_add_sources( SOURCES sscCore.c sscSat.c + sscUtil.c sscSim.c sscClass.c - sscUtil.c ) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt index 76e553ada8..8eb301fee6 100644 --- a/src/proof/ssw/CMakeLists.txt +++ b/src/proof/ssw/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_ssw SOURCES - sswBmc.c - sswMan.c - sswSat.c - sswPart.c - sswDyn.c - sswPairs.c - sswSim.c + sswClass.c sswCnf.c + sswSimSat.c + sswConstr.c + sswPart.c sswRarity.c + sswFilter.c + sswAig.c + sswCore.c + sswMan.c + sswDyn.c sswSemi.c + sswSat.c + sswUnique.c sswLcorr.c - sswCore.c + sswBmc.c sswIslands.c - sswUnique.c + sswSim.c sswSweep.c - sswSimSat.c - sswFilter.c - sswAig.c - sswConstr.c - sswClass.c + sswPairs.c ) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt index 9000d7d1a3..dfd7e3b23b 100644 --- a/src/sat/bmc/CMakeLists.txt +++ b/src/sat/bmc/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME sat_bmc SOURCES - bmcBmc.c - bmcBmcS.c - bmcMaj2.c - bmcMaj.c - bmcBmci.c - bmcChain.c - bmcCexMin2.c - bmcMaj3.c - bmcCexTools.c bmcClp.c - bmcUnroll.c - bmcMesh.c - bmcBmcAnd.c - bmcLoad.c + bmcCexDepth.c + bmcChain.c + bmcBmcS.c bmcMaxi.c - bmcFault.c - bmcBCore.c + bmcBmc.c bmcCexMin1.c - bmcCexDepth.c - bmcBmc2.c - bmcMulti.c + bmcMesh2.c + bmcInse.c + bmcMesh.c + bmcMaj.c + bmcExpand.c bmcBmc3.c bmcEco.c - bmcICheck.c - bmcCexCare.c + bmcCexTools.c + bmcBmci.c + bmcCexMin2.c bmcGen.c - bmcExpand.c - bmcMesh2.c - bmcFx.c + bmcICheck.c bmcCexCut.c - bmcInse.c + bmcBmc2.c + bmcFault.c + bmcLoad.c + bmcMaj2.c + bmcUnroll.c + bmcMulti.c + bmcBCore.c + bmcCexCare.c bmcBmcG.c + bmcBmcAnd.c + bmcFx.c + bmcMaj3.c ) diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt index 7818e3d163..d279844ada 100644 --- a/src/sat/bsat/CMakeLists.txt +++ b/src/sat/bsat/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME sat_bsat SOURCES - satInterB.c - satSolver2.c - satSolver.c - satUtil.c - satStore.c satMem.c - satSolver3.c + satTrace.c satProof.c - satInterA.c + satSolver2.c + satSolver3.c + satStore.c + satUtil.c satTruth.c - satSolver2i.c - satTrace.c - satInter.c + satInterB.c + satInterA.c satInterP.c + satInter.c + satSolver2i.c + satSolver.c ) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt index fa2befbac0..a40ee9595c 100644 --- a/src/sat/bsat2/CMakeLists.txt +++ b/src/sat/bsat2/CMakeLists.txt @@ -2,10 +2,10 @@ abc_libabc_add_sources( NAME sat_bsat2 SOURCES System.cpp + AbcApi.cpp SimpSolver.cpp + Options.cpp MainSimp.cpp MainSat.cpp - AbcApi.cpp - Options.cpp Solver.cpp ) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt index c9088bc2c4..5ab43ddd76 100644 --- a/src/sat/cnf/CMakeLists.txt +++ b/src/sat/cnf/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME sat_cnf SOURCES - cnfPost.c - cnfMan.c - cnfCut.c - cnfMap.c - cnfFast.c cnfUtil.c - cnfData.c cnfWrite.c + cnfData.c cnfCore.c + cnfMap.c + cnfMan.c + cnfCut.c + cnfPost.c + cnfFast.c ) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt index 8b891867b8..5922ee85ba 100644 --- a/src/sat/glucose/CMakeLists.txt +++ b/src/sat/glucose/CMakeLists.txt @@ -2,9 +2,9 @@ abc_libabc_add_sources( NAME sat_glucose SOURCES System.cpp - AbcGlucose.cpp - SimpSolver.cpp - AbcGlucoseCmd.cpp Glucose.cpp + AbcGlucoseCmd.cpp + SimpSolver.cpp Options.cpp + AbcGlucose.cpp ) diff --git a/src/sat/glucose2/CMakeLists.txt b/src/sat/glucose2/CMakeLists.txt new file mode 100644 index 0000000000..8f0dd551d3 --- /dev/null +++ b/src/sat/glucose2/CMakeLists.txt @@ -0,0 +1,10 @@ +abc_libabc_add_sources( + NAME sat_glucose2 + SOURCES + SimpSolver2.cpp + Options2.cpp + AbcGlucose2.cpp + System2.cpp + Glucose2.cpp + AbcGlucoseCmd2.cpp +) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt index 78c15a6700..e5c1f5fe2c 100644 --- a/src/sat/msat/CMakeLists.txt +++ b/src/sat/msat/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME sat_msat SOURCES - msatQueue.c + msatSolverApi.c msatOrderH.c - msatActivity.c - msatSolverCore.c + msatRead.c + msatQueue.c + msatSolverSearch.c msatClauseVec.c - msatSolverApi.c + msatVec.c + msatClause.c msatMem.c - msatSolverIo.c - msatSolverSearch.c - msatRead.c msatSort.c - msatClause.c - msatVec.c + msatSolverCore.c + msatActivity.c + msatSolverIo.c ) diff --git a/src/sat/satoko/CMakeLists.txt b/src/sat/satoko/CMakeLists.txt index 3341a6f9c1..a45c747644 100644 --- a/src/sat/satoko/CMakeLists.txt +++ b/src/sat/satoko/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_satoko SOURCES + cnf_reader.c solver_api.c solver.c - cnf_reader.c ) diff --git a/src/sat/xsat/CMakeLists.txt b/src/sat/xsat/CMakeLists.txt index a027e76ffe..4a2aa655c6 100644 --- a/src/sat/xsat/CMakeLists.txt +++ b/src/sat/xsat/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_xsat SOURCES + xsatCnfReader.c xsatSolver.c xsatSolverAPI.c - xsatCnfReader.c ) diff --git a/tools/clang_toolchain.cmake b/tools/clang_toolchain.cmake new file mode 100644 index 0000000000..4b167b3de7 --- /dev/null +++ b/tools/clang_toolchain.cmake @@ -0,0 +1,13 @@ +set(CMAKE_ASM_COMPILER "clang") +set(CMAKE_ASM-ATT_COMPILER "clang") +set(CMAKE_C_COMPILER "clang") +set(CMAKE_CXX_COMPILER "clang++") +set(CMAKE_Fortran_COMPILER "gfortran") +set(CMAKE_AR + ar + CACHE FILEPATH "Archive manager" FORCE +) +set(CMAKE_RANLIB + ranlib + CACHE FILEPATH "Archive index generator" FORCE +) diff --git a/tools/mk-cmakelists.py b/tools/mk-cmakelists.py new file mode 100644 index 0000000000..ad2a7e2626 --- /dev/null +++ b/tools/mk-cmakelists.py @@ -0,0 +1,26 @@ +#!/usr/bin/env python +import os +from pathlib import Path + +s = """abc_libabc_add_sources( + NAME {NAME} + SOURCES +{SOURCES} +) +""" +for root, _, files in os.walk("src"): + if "module.make" not in files: + continue + if "main" in root: + continue + r = Path(root).relative_to("src") + makefile = open(Path(root)/"module.make").read() + target = str(r).replace("/","_") + sources = list(filter(lambda s: s in makefile, files)) + if sources: + sources_str = "\n".join(" {}".format(source) for source in sources) + txt = s.format(NAME=target, SOURCES=sources_str) + else: + txt = "" + cmake = Path(root) / "CMakeLists.txt" + cmake.open("w").write(txt) diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000000..aa4ae9ef30 --- /dev/null +++ b/tox.ini @@ -0,0 +1,73 @@ +[tox] +envlist = py3{6,7,8,9}-build +skip_missing_interpreters = true +skipsdist = true + +[base] +setenv = + {abc,tests}: CFLAGS=-O2 -g -DNDEBUG + {abc,tests}: CXXFLAGS={env:CFLAGS:-O2 -g -DNDEBUG} + {abc,tests}: LDFLAGS={env:CFLAGS:-O2 -g -DNDEBUG} + {build}: PREFIX={env:PREFIX:./install} + +passenv = + CC + CXX + PYTHON + DISPLAY + XAUTHORITY + HOME + USERNAME + USER + CI + XDG_* + GITHUB* + PIP_DOWNLOAD_CACHE + +[testenv] +envdir = {toxinidir}/.env +skip_install = true + +setenv = + {abc,tests}: {[base]setenv} + {build}: {[base]setenv} + +passenv = + {[base]passenv} + +whitelist_externals = + {abc,tests,lint,build,clang,ctest,grind,unbuild}: bash + {abc,tests,clean}: make + {build,clang}: mkdir + +changedir = + {build,clang}: build + +deps = + {abc,tests,lint,build,clang,ctest,grind}: pip>=21.3 + {abc,tests}: this-cli + {build,clang,ctest,grind}: cmake + {build,clang,ctest,grind}: ninja + lint: cpplint + grind: ValgrindCI + +commands_pre = + {build,clang}: mkdir -p {toxinidir}/build + +commands = + abc: make -j4 ABC_USE_NO_CUDD=1 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} abc + tests: make -j4 ABC_USE_NO_CUDD=1 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} test + clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DCMAKE_TOOLCHAIN_FILE=../tools/clang_toolchain.cmake ..' + build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_PREFIX=$PREFIX ..' + {build,clang}: bash -c 'cmake --build . --target abc -j $(nproc)' + {build,clang}: bash -c 'ctest -V --test-dir ./' + build: cmake --build . --target install + ctest: bash -c 'ctest -j $(nproc) --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=xxx -DCMAKE_BUILD_TYPE=Debug --test-command ctest --rerun-failed --output-on-failure -V' + lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' + grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DABC_USE_NAMESPACE=xxx -DCMAKE_BUILD_TYPE=Debug' + grind: bash -c 'cmake --build build --target abc -j $(nproc)' + grind: bash -c 'valgrind --tool=memcheck --xml=yes --xml-file=abc_check.xml --leak-check=full --show-leak-kinds=definite,possible --error-exitcode=127 ./build/src/base/main/abc "-c" "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"' + grind: valgrind-ci abc_check.xml --number-of-errors + grind: valgrind-ci abc_check.xml --summary + unbuild: bash -c 'rm -rf build/ abc_check.xml' + clean: make clean From a82225eb94dca8d310d200dfea0ba0890c96f8e8 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 6 Nov 2021 18:35:16 -0700 Subject: [PATCH 05/35] fix: make clang build work, mainly C++ type/literal errors * fix type invalid literal errors * use pSat2 from abcglucuse2 header for correct cec solver type Signed-off-by: Stephen L Arnold --- src/aig/gia/giaIso3.c | 2 +- src/proof/cec/cecSolveG.c | 12 ++++++------ src/sat/msat/msatSolverSearch.c | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/aig/gia/giaIso3.c b/src/aig/gia/giaIso3.c index b526676d36..d850e87dc5 100644 --- a/src/aig/gia/giaIso3.c +++ b/src/aig/gia/giaIso3.c @@ -177,7 +177,7 @@ Vec_Wec_t * Gia_Iso4Gia( Gia_Man_t * p ) Vec_WecForEachLevel( vLevs, vLevel, l ) { Gia_Obj_t * pObj; int i; - unsigned RandC[2] = { Abc_Random(0), Abc_Random(0) }; + unsigned int RandC[2] = { Abc_Random(0), Abc_Random(0) }; if ( l == 0 ) { Gia_ManForEachObjVec( vLevel, p, pObj, i ) diff --git a/src/proof/cec/cecSolveG.c b/src/proof/cec/cecSolveG.c index c4b01b5093..64fcac13d9 100644 --- a/src/proof/cec/cecSolveG.c +++ b/src/proof/cec/cecSolveG.c @@ -435,7 +435,7 @@ void CecG_CnfNodeAddToSolver( Cec_ManSat_t * p, Gia_Obj_t * pObj ) void CecG_ManSatSolverRecycle( Cec_ManSat_t * p ) { int Lit; - if ( p->pSat ) + if ( p->pSat2 ) { Gia_Obj_t * pObj; int i; @@ -443,20 +443,20 @@ void CecG_ManSatSolverRecycle( Cec_ManSat_t * p ) CecG_ObjSetSatNum( p, pObj, 0 ); Vec_PtrClear( p->vUsedNodes ); // memset( p->pSatVars, 0, sizeof(int) * Gia_ManObjNumMax(p->pAigTotal) ); - sat_solver_stop( p->pSat ); + sat_solver_stop( p->pSat2 ); } - p->pSat = (struct sat_solver_t*)sat_solver_start(); + p->pSat2 = sat_solver_start(); assert( 0 <= p->pPars->SolverType && p->pPars->SolverType <= 2 ); - sat_solver_set_jftr( p->pSat, p->pPars->SolverType ); + sat_solver_set_jftr( p->pSat2, p->pPars->SolverType ); //sat_solver_setnvars( p->pSat, 1000 ); // minisat only //p->pSat->factors = ABC_CALLOC( double, p->pSat->cap ); // var 0 is not used // var 1 is reserved for const0 node - add the clause // p->nSatVars = 0; - CecG_ObjSetSatNum( p, Gia_ManConst0(p->pAig), sat_solver_addvar( p->pSat ) ); + CecG_ObjSetSatNum( p, Gia_ManConst0(p->pAig), sat_solver_addvar( p->pSat2 ) ); Lit = toLitCond( CecG_ObjSatNum( p, Gia_ManConst0(p->pAig) ), 1 ); - sat_solver_addclause( p->pSat, &Lit, 1 ); + sat_solver_addclause( p->pSat2, &Lit, 1 ); // if ( p->pPars->fPolarFlip ) // no need to normalize const0 node (bug fix by SS on 9/17/2012) // Lit = lit_neg( Lit ); diff --git a/src/sat/msat/msatSolverSearch.c b/src/sat/msat/msatSolverSearch.c index 2eda5038d6..a553a25456 100644 --- a/src/sat/msat/msatSolverSearch.c +++ b/src/sat/msat/msatSolverSearch.c @@ -52,7 +52,7 @@ int Msat_SolverAssume( Msat_Solver_t * p, Msat_Lit_t Lit ) { assert( Msat_QueueReadSize(p->pQueue) == 0 ); if ( p->fVerbose ) - printf(L_IND "assume(" L_LIT ")\n", L_ind, L_lit(Lit)); + printf(L_IND"assume(" L_LIT")\n", L_ind, L_lit(Lit)); Msat_IntVecPush( p->vTrailLim, Msat_IntVecReadSize(p->vTrail) ); // assert( Msat_IntVecReadSize(p->vTrailLim) <= Msat_IntVecReadSize(p->vTrail) + 1 ); // assert( Msat_IntVecReadSize( p->vTrailLim ) < p->nVars ); @@ -83,7 +83,7 @@ void Msat_SolverUndoOne( Msat_Solver_t * p ) Msat_OrderVarUnassigned( p->pOrder, Var ); if ( p->fVerbose ) - printf(L_IND "unbind(" L_LIT")\n", L_ind, L_lit(Lit)); + printf(L_IND"unbind(" L_LIT")\n", L_ind, L_lit(Lit)); } /**Function************************************************************* @@ -107,7 +107,7 @@ void Msat_SolverCancel( Msat_Solver_t * p ) { Msat_Lit_t Lit; Lit = Msat_IntVecReadEntry( p->vTrail, Msat_IntVecReadEntryLast(p->vTrailLim) ); - printf(L_IND "cancel(" L_LIT ")\n", L_ind, L_lit(Lit)); + printf(L_IND"cancel(" L_LIT")\n", L_ind, L_lit(Lit)); } } for ( c = Msat_IntVecReadSize(p->vTrail) - Msat_IntVecPop( p->vTrailLim ); c != 0; c-- ) @@ -188,7 +188,7 @@ int Msat_SolverEnqueue( Msat_Solver_t * p, Msat_Lit_t Lit, Msat_Clause_t * pC ) if ( p->fVerbose ) { // printf(L_IND"bind("L_LIT")\n", L_ind, L_lit(Lit)); - printf(L_IND "bind(" L_LIT ") ", L_ind, L_lit(Lit)); + printf(L_IND"bind(" L_LIT") ", L_ind, L_lit(Lit)); Msat_ClausePrintSymbols( pC ); } p->pAssigns[Var] = Lit; From 5c6daa263d5ce5c1bdea8b9f54a18a4854a5f97d Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 6 Nov 2021 18:41:30 -0700 Subject: [PATCH 06/35] chg: dev: cleanup windows builds and sources, update workflows * add win32 defines ABC_NO_DYNAMIC_LINKING, WIN32 * static_cast => uint returns in acbTest.c !refactor * check for win first, win/mingw definitions inside if(msys or mingw) * fix missing leading ddunder on mingw32__ * switch msys env for clang64, re-enable readline * cleanup cmake type checks and workflow env * mingw clang-64 thinks sizeof long is 4 * use abc typedefs instead of hard-coded types Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 23 ++++++++++++-- .github/workflows/win.yml | 64 ++++++++++++++++++++++++++++++++++++++ CMakeLists.txt | 23 +++++++++----- Makefile | 2 +- src/aig/aig/aigPart.c | 6 ++-- src/base/acb/acbTest.c | 10 +++--- src/bdd/cas/casCore.c | 48 ++++++++++++++-------------- src/bdd/cudd/cuddAPI.c | 2 +- src/bdd/cudd/cuddBddCorr.c | 2 +- src/bdd/cudd/cuddDecomp.c | 6 ++-- src/bdd/cudd/cuddExport.c | 4 +-- src/bdd/cudd/cuddReorder.c | 2 +- src/bdd/cudd/cuddUtil.c | 8 ++--- src/bdd/cudd/cuddZddUtil.c | 4 +-- src/bdd/mtr/mtrBasic.c | 6 ++-- src/bool/kit/kitGraph.c | 8 ++--- src/misc/st/st.c | 8 ++--- src/misc/st/stmm.c | 8 ++--- src/misc/util/utilFile.c | 2 +- src/proof/fra/fraLcr.c | 36 ++++++++++----------- tox.ini | 10 +++--- 21 files changed, 185 insertions(+), 97 deletions(-) create mode 100644 .github/workflows/win.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 23428553ac..e365685b38 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,8 +26,10 @@ jobs: name: [ ubuntu-20.04-gcc, + ubuntu-20.04-clang, ubuntu-18.04-gcc, macOS-10.15-gcc, + macOS-10.15-clang, ] include: @@ -35,16 +37,31 @@ jobs: os: ubuntu-20.04 compiler: gcc version: "10" + toxcmd: build + + - name: ubuntu-20.04-clang + os: ubuntu-20.04 + compiler: clang + version: "10" + toxcmd: clang - name: ubuntu-18.04-gcc os: ubuntu-18.04 compiler: gcc version: "9" + toxcmd: abc,tests - name: macOS-10.15-gcc os: macOS-10.15 compiler: gcc - version: "10" + version: "11" + toxcmd: ctest + + - name: macOS-10.15-clang + os: macOS-10.15 + compiler: xcode + version: "12.3" + toxcmd: clang steps: - uses: actions/checkout@v2 @@ -81,7 +98,7 @@ jobs: CC: ${{ env.CC }} CXX: ${{ env.CXX }} run: | - tox -e build + tox -e ${{ matrix.toxcmd }} - name: Install and setup MacOS packages if: runner.os == 'macOS' @@ -103,4 +120,4 @@ jobs: CC: ${{ env.CC }} CXX: ${{ env.CXX }} run: | - tox -e ctest + tox -e ${{ matrix.toxcmd }} diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml new file mode 100644 index 0000000000..39c2972029 --- /dev/null +++ b/.github/workflows/win.yml @@ -0,0 +1,64 @@ +name: msystem + +on: + workflow_dispatch: + pull_request: + push: + branches: + - master + +jobs: + msys2-build: + runs-on: windows-latest + strategy: + fail-fast: false + matrix: + include: [ + { msystem: MINGW64, arch: x86_64 }, + { msystem: CLANG64, arch: clang-x86_64 }, + { msystem: MINGW32, arch: i686 }, + ] + defaults: + run: + shell: msys2 {0} + steps: + - uses: actions/checkout@v2 + + - name: Setup MinGW native environment + uses: msys2/setup-msys2@v2 + with: + msystem: ${{ matrix.msystem }} + update: false + install: >- + git + make + mingw-w64-${{ matrix.arch }}-toolchain + mingw-w64-${{ matrix.arch }}-cmake + mingw-w64-${{ matrix.arch }}-ninja + mingw-w64-${{ matrix.arch }}-pkgconf + mingw-w64-${{ matrix.arch }}-readline + + - run: >- + cmake + -Wdev + -B build + -DBUILD_SHARED_LIBS=ON + -DABC_USE_NAMESPACE=xxx + -DCMAKE_BUILD_TYPE=Debug + -DCMAKE_INSTALL_PREFIX=$PWD/_dist + + - name: CMake build + run: | + cmake --build build --parallel + + - name: Test + run: ctest --test-dir build --output-on-failure --parallel -V + + - uses: actions/upload-artifact@v1 + if: failure() + with: + name: WindowsCMakeTestlog + path: build/Testing/Temporary/LastTest.log + + - name: Install project + run: cmake --install build diff --git a/CMakeLists.txt b/CMakeLists.txt index 84db7f3611..2b480eaf39 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -148,10 +148,14 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") ) endif() if(WIN32) + if(MINGW OR MSYS) + add_definitions(-DWIN32 -D__MINGW32__) + endif() target_compile_definitions(abc_interface INTERFACE $<$:ABC_DLL=ABC_DLLEXPORT> $<$>:WIN32_NO_DLL> + $<$>:ABC_NO_DYNAMIC_LINKING> ) endif() @@ -163,18 +167,19 @@ else() endif() include(CheckTypeSize) -check_type_size("(void*)0" SIZEOF_VOID_P) if(ABC_USE_STDINT_H) + check_type_size("void*" SIZEOF_VOID_P LANGUAGE C) message(STATUS "Setting ABC_USE_STDINT_H ${ABC_USE_STDINT_H}") target_compile_definitions(abc_interface INTERFACE "ABC_USE_STDINT_H=1") else() - check_type_size("(long)0" SIZEOF_LONG) - check_type_size("(int)0" SIZEOF_INT) - if(UNIX OR APPLE) - set(ARCH_PREFIX "LIN") - elseif(WIN32) + check_type_size("void*" SIZEOF_VOID_P LANGUAGE CXX) + check_type_size(long SIZEOF_LONG LANGUAGE CXX) + check_type_size(int SIZEOF_INT LANGUAGE CXX) + if(WIN32 OR MINGW OR MSYS) set(ARCH_PREFIX "NT") + elseif(UNIX OR APPLE) + set(ARCH_PREFIX "LIN") else() message(FATAL_ERROR "Unknown arch") endif() @@ -192,6 +197,7 @@ else() "${ARCH_PREFIX}${ARCH_SUFFIX}" ) endif() + if(CMAKE_SYSTEM_PROCESS STREQUAL "arm") target_compile_definitions(abc_interface INTERFACE ABC_MEMALIGN=4 @@ -268,7 +274,7 @@ if(NOT ABC_USE_NO_PTHREADS) set(THREADS_PREFER_PTHREAD_FLAG ON) find_package(Threads REQUIRED) target_link_libraries(abc_interface - INTERFACE Threads::Threads + INTERFACE ${CMAKE_THREAD_LIBS_INIT} ) endif() endif() @@ -294,7 +300,7 @@ define_property(GLOBAL define_property(GLOBAL PROPERTY ABC_SOURCES BRIEF_DOCS "Sources of executables of abc" - FULL_DOCS "All source files of libabc" + FULL_DOCS "All source files of abc" ) function(abc_libabc_add_sources) @@ -350,6 +356,7 @@ if(BUILD_SHARED_LIBS) set_target_properties( libabc PROPERTIES VERSION ${LIBRARY_VERSION} SOVERSION ${LIBRARY_SOVERSION} + WINDOWS_EXPORT_ALL_SYMBOLS TRUE ) endif() diff --git a/Makefile b/Makefile index 51949e9275..6b35774028 100644 --- a/Makefile +++ b/Makefile @@ -168,7 +168,7 @@ CXXFLAGS += $(CFLAGS) -std=c++17 -fno-exceptions $(info $(MSG_PREFIX)Using CXXFLAGS=$(CXXFLAGS)) SRC := -GARBAGE := core core.* *.stackdump ./tags $(PROG) demo arch_flags +GARBAGE := core core.* *.stackdump ./tags $(PROG) demo arch_flags result.blif .PHONY: all default tags clean docs cmake_info diff --git a/src/aig/aig/aigPart.c b/src/aig/aig/aigPart.c index 9b978e3b47..a6c515696b 100644 --- a/src/aig/aig/aigPart.c +++ b/src/aig/aig/aigPart.c @@ -309,7 +309,7 @@ Vec_Ptr_t * Aig_ManSupports( Aig_Man_t * pMan ) { pPart0 = (Part_One_t *)Aig_ObjFanin0(pObj)->pData; vSupp = Part_ManTransferEntry(pPart0); - Vec_IntPush( vSupp, (int)(long)pObj->pNext ); + Vec_IntPush( vSupp, (int)(ABC_PTRINT_T)pObj->pNext ); Vec_PtrPush( vSupports, vSupp ); assert( pPart0->nRefs > 0 ); if ( --pPart0->nRefs == 0 ) @@ -321,7 +321,7 @@ Vec_Ptr_t * Aig_ManSupports( Aig_Man_t * pMan ) if ( pObj->nRefs ) { pPart0 = Part_ManFetchEntry( p, 1, pObj->nRefs ); - pPart0->pOuts[ pPart0->nOuts++ ] = (int)(long)pObj->pNext; + pPart0->pOuts[ pPart0->nOuts++ ] = (int)(ABC_PTRINT_T)pObj->pNext; pObj->pData = pPart0; } continue; @@ -972,7 +972,7 @@ Aig_Obj_t * Aig_ManDupPart_rec( Aig_Man_t * pNew, Aig_Man_t * pOld, Aig_Obj_t * if ( Aig_ObjIsCi(pObj) ) { assert( Vec_IntSize(vSuppMap) == Aig_ManCiNum(pNew) ); - Vec_IntPush( vSuppMap, (int)(long)pObj->pNext ); + Vec_IntPush( vSuppMap, (int)(ABC_PTRINT_T)pObj->pNext ); return (Aig_Obj_t *)(pObj->pData = Aig_ObjCreateCi(pNew)); } assert( Aig_ObjIsNode(pObj) ); diff --git a/src/base/acb/acbTest.c b/src/base/acb/acbTest.c index c22d4b55b3..fc450818ea 100644 --- a/src/base/acb/acbTest.c +++ b/src/base/acb/acbTest.c @@ -235,7 +235,7 @@ void Gia_ManDualMux( Gia_Man_t * p, int LitC[2], int LitT[2], int LitE[2], int L if ( fForceZero ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], Abc_LitNot(LitZ[1]) ); } -int Gia_ManDualCompare( Gia_Man_t * p, int LitF[2], int LitS[2] ) +int Gia_ManDualCompare( Gia_Man_t * p, unsigned int LitF[2], unsigned int LitS[2] ) { int iMiter = Gia_ManHashXor( p, LitF[0], LitS[0] ); iMiter = Gia_ManHashOr( p, LitF[1], iMiter ); @@ -421,8 +421,8 @@ Gia_Man_t * Acb_NtkGiaDeriveMiter( Gia_Man_t * pOne, Gia_Man_t * pTwo, int Type { for ( i = 0; i < Gia_ManCoNum(pOne); i += 2 ) { - unsigned pLitsF[2] = { Gia_ManCo(pOne, i)->Value, Gia_ManCo(pOne, i+1)->Value }; - unsigned pLitsS[2] = { Gia_ManCo(pTwo, i)->Value, Gia_ManCo(pTwo, i+1)->Value }; + unsigned int pLitsF[2] = { Gia_ManCo(pOne, i)->Value, Gia_ManCo(pOne, i+1)->Value }; + unsigned int pLitsS[2] = { Gia_ManCo(pTwo, i)->Value, Gia_ManCo(pTwo, i+1)->Value }; Gia_ManAppendCo( pNew, pLitsF[0] ); Gia_ManAppendCo( pNew, pLitsS[0] ); } @@ -431,8 +431,8 @@ Gia_Man_t * Acb_NtkGiaDeriveMiter( Gia_Man_t * pOne, Gia_Man_t * pTwo, int Type { for ( i = 0; i < Gia_ManCoNum(pOne); i += 2 ) { - unsigned pLitsF[2] = { Gia_ManCo(pOne, i)->Value, Gia_ManCo(pOne, i+1)->Value }; - unsigned pLitsS[2] = { Gia_ManCo(pTwo, i)->Value, Gia_ManCo(pTwo, i+1)->Value }; + unsigned int pLitsF[2] = { Gia_ManCo(pOne, i)->Value, Gia_ManCo(pOne, i+1)->Value }; + unsigned int pLitsS[2] = { Gia_ManCo(pTwo, i)->Value, Gia_ManCo(pTwo, i+1)->Value }; Gia_ManAppendCo( pNew, pLitsF[1] ); Gia_ManAppendCo( pNew, pLitsS[1] ); } diff --git a/src/bdd/cas/casCore.c b/src/bdd/cas/casCore.c index 23d7be521d..1c4dec62ba 100644 --- a/src/bdd/cas/casCore.c +++ b/src/bdd/cas/casCore.c @@ -832,12 +832,12 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * */ /* Find the bits that are different. */ - refAddr = ( long )Cudd_Regular(Func); + refAddr = ( ABC_PTRINT_T )Cudd_Regular(Func); diff = 0; gen = st__init_gen( visited ); while ( st__gen( gen, ( const char ** ) &Node, NULL ) ) { - diff |= refAddr ^ ( long ) Node; + diff |= refAddr ^ ( ABC_PTRINT_T ) Node; } st__free_gen( gen ); gen = NULL; @@ -852,7 +852,7 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * // write the buffer for the output - fprintf( pFile, ".names %s%lx %s\n", Prefix, ( mask & (long)Cudd_Regular(Func) ) / sizeof(DdNode), OutputName ); + fprintf( pFile, ".names %s%lx %s\n", Prefix, ( mask & (ABC_PTRINT_T)Cudd_Regular(Func) ) / sizeof(DdNode), OutputName ); fprintf( pFile, "%s 1\n", (Cudd_IsComplement(Func))? "0": "1" ); @@ -862,7 +862,7 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * if ( Node->index == CUDD_MAXINDEX ) { // write the terminal node - fprintf( pFile, ".names %s%lx\n", Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + fprintf( pFile, ".names %s%lx\n", Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, " %s\n", (cuddV(Node) == 0.0)? "0": "1" ); continue; } @@ -875,9 +875,9 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * if ( Else == ElseR ) { // no inverter fprintf( pFile, ".names %s %s%lx %s%lx %s%lx\n", InputNames[Node->index], - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)Then ) / sizeof(DdNode), - Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Then ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, "01- 1\n" ); fprintf( pFile, "1-1 1\n" ); } @@ -885,9 +885,9 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * { // inverter int * pSlot; fprintf( pFile, ".names %s %s%lx_i %s%lx %s%lx\n", InputNames[Node->index], - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)Then ) / sizeof(DdNode), - Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Then ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, "01- 1\n" ); fprintf( pFile, "1-1 1\n" ); @@ -899,8 +899,8 @@ void WriteDDintoBLIFfile( FILE * pFile, DdNode * Func, char * OutputName, char * *pSlot = 1; fprintf( pFile, ".names %s%lx %s%lx_i\n", - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode) ); fprintf( pFile, "0 1\n" ); } } @@ -977,12 +977,12 @@ void WriteDDintoBLIFfileReorder( DdManager * dd, FILE * pFile, DdNode * Func, ch */ /* Find the bits that are different. */ - refAddr = ( long )Cudd_Regular(bFmin); + refAddr = ( ABC_PTRINT_T )Cudd_Regular(bFmin); diff = 0; gen = st__init_gen( visited ); while ( st__gen( gen, ( const char ** ) &Node, NULL ) ) { - diff |= refAddr ^ ( long ) Node; + diff |= refAddr ^ ( ABC_PTRINT_T ) Node; } st__free_gen( gen ); gen = NULL; @@ -997,7 +997,7 @@ void WriteDDintoBLIFfileReorder( DdManager * dd, FILE * pFile, DdNode * Func, ch // write the buffer for the output - fprintf( pFile, ".names %s%lx %s\n", Prefix, ( mask & (long)Cudd_Regular(bFmin) ) / sizeof(DdNode), OutputName ); + fprintf( pFile, ".names %s%lx %s\n", Prefix, ( mask & (ABC_PTRINT_T)Cudd_Regular(bFmin) ) / sizeof(DdNode), OutputName ); fprintf( pFile, "%s 1\n", (Cudd_IsComplement(bFmin))? "0": "1" ); @@ -1007,7 +1007,7 @@ void WriteDDintoBLIFfileReorder( DdManager * dd, FILE * pFile, DdNode * Func, ch if ( Node->index == CUDD_MAXINDEX ) { // write the terminal node - fprintf( pFile, ".names %s%lx\n", Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + fprintf( pFile, ".names %s%lx\n", Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, " %s\n", (cuddV(Node) == 0.0)? "0": "1" ); continue; } @@ -1020,24 +1020,24 @@ void WriteDDintoBLIFfileReorder( DdManager * dd, FILE * pFile, DdNode * Func, ch if ( Else == ElseR ) { // no inverter fprintf( pFile, ".names %s %s%lx %s%lx %s%lx\n", InputNames[Node->index], - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)Then ) / sizeof(DdNode), - Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Then ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, "01- 1\n" ); fprintf( pFile, "1-1 1\n" ); } else { // inverter fprintf( pFile, ".names %s %s%lx_i %s%lx %s%lx\n", InputNames[Node->index], - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)Then ) / sizeof(DdNode), - Prefix, ( mask & (long)Node ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Then ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)Node ) / sizeof(DdNode) ); fprintf( pFile, "01- 1\n" ); fprintf( pFile, "1-1 1\n" ); fprintf( pFile, ".names %s%lx %s%lx_i\n", - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode), - Prefix, ( mask & (long)ElseR ) / sizeof(DdNode) ); + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode), + Prefix, ( mask & (ABC_PTRINT_T)ElseR ) / sizeof(DdNode) ); fprintf( pFile, "0 1\n" ); } } diff --git a/src/bdd/cudd/cuddAPI.c b/src/bdd/cudd/cuddAPI.c index 155202736c..7f28733d00 100644 --- a/src/bdd/cudd/cuddAPI.c +++ b/src/bdd/cudd/cuddAPI.c @@ -3503,7 +3503,7 @@ Cudd_StdPostReordHook( const char *str, void *data) { - long initialTime = (long) data; + long initialTime = (ABC_PTRINT_T) data; int retval; long finalTime = util_cpu_time(); double totalTimeSec = (double)(finalTime - initialTime) / 1000.0; diff --git a/src/bdd/cudd/cuddBddCorr.c b/src/bdd/cudd/cuddBddCorr.c index 72c57c9540..b4a1d5b84c 100644 --- a/src/bdd/cudd/cuddBddCorr.c +++ b/src/bdd/cudd/cuddBddCorr.c @@ -472,7 +472,7 @@ CorrelHash( entry = (HashEntry *) key; #if SIZEOF_VOID_P == 8 && SIZEOF_INT == 4 - val = ((int) ((long)entry->f))*997 + ((int) ((long)entry->g)); + val = ((int) ((ABC_PTRINT_T)entry->f))*997 + ((int) ((ABC_PTRINT_T)entry->g)); #else val = ((int) entry->f)*997 + ((int) entry->g); #endif diff --git a/src/bdd/cudd/cuddDecomp.c b/src/bdd/cudd/cuddDecomp.c index 1d534670ca..2dd5cad01d 100644 --- a/src/bdd/cudd/cuddDecomp.c +++ b/src/bdd/cudd/cuddDecomp.c @@ -117,11 +117,11 @@ long lastTimeG; /*---------------------------------------------------------------------------*/ -#define FactorsNotStored(factors) ((int)((long)(factors) & 01)) +#define FactorsNotStored(factors) ((int)((ABC_PTRINT_T)(factors) & 01)) -#define FactorsComplement(factors) ((Conjuncts *)((long)(factors) | 01)) +#define FactorsComplement(factors) ((Conjuncts *)((ABC_PTRINT_T)(factors) | 01)) -#define FactorsUncomplement(factors) ((Conjuncts *)((long)(factors) ^ 01)) +#define FactorsUncomplement(factors) ((Conjuncts *)((ABC_PTRINT_T)(factors) ^ 01)) /**AutomaticStart*************************************************************/ diff --git a/src/bdd/cudd/cuddExport.c b/src/bdd/cudd/cuddExport.c index 41735a8c8f..9fbdfaa42f 100644 --- a/src/bdd/cudd/cuddExport.c +++ b/src/bdd/cudd/cuddExport.c @@ -403,12 +403,12 @@ Cudd_DumpDot( */ /* Find the bits that are different. */ - refAddr = (long) Cudd_Regular(f[0]); + refAddr = (ABC_PTRINT_T) Cudd_Regular(f[0]); diff = 0; gen = st__init_gen(visited); if (gen == NULL) goto failure; while ( st__gen(gen, (const char **)&scan, NULL)) { - diff |= refAddr ^ (long) scan; + diff |= refAddr ^ (ABC_PTRINT_T) scan; } st__free_gen(gen); gen = NULL; diff --git a/src/bdd/cudd/cuddReorder.c b/src/bdd/cudd/cuddReorder.c index c48b0c1385..bcbb098411 100644 --- a/src/bdd/cudd/cuddReorder.c +++ b/src/bdd/cudd/cuddReorder.c @@ -457,7 +457,7 @@ cuddDynamicAllocNode( ** as well. */ // offset = (unsigned long) mem & (sizeof(DdNode) - 1); // mem += (sizeof(DdNode) - offset) / sizeof(DdNodePtr); - offset = (unsigned long) mem & (32 - 1); + offset = (ABC_PTRUINT_T) mem & (32 - 1); mem += (32 - offset) / sizeof(DdNodePtr); #ifdef DD_DEBUG // assert(((unsigned long) mem & (sizeof(DdNode) - 1)) == 0); diff --git a/src/bdd/cudd/cuddUtil.c b/src/bdd/cudd/cuddUtil.c index fe913fee32..4b2e1ebb7d 100644 --- a/src/bdd/cudd/cuddUtil.c +++ b/src/bdd/cudd/cuddUtil.c @@ -2634,13 +2634,13 @@ Cudd_AverageDistance( for (j = 0; j < slots; j++) { scan = nodelist[j]; while (scan != sentinel) { - diff = (long) scan - (long) cuddT(scan); + diff = (ABC_PTRINT_T) scan - (ABC_PTRINT_T) cuddT(scan); tesubtotal += (double) ddAbs(diff); - diff = (long) scan - (long) Cudd_Regular(cuddE(scan)); + diff = (ABC_PTRINT_T) scan - (ABC_PTRINT_T) Cudd_Regular(cuddE(scan)); tesubtotal += (double) ddAbs(diff); temeasured += 2.0; if (scan->next != sentinel) { - diff = (long) scan - (long) scan->next; + diff = (ABC_PTRINT_T) scan - (ABC_PTRINT_T) scan->next; nextsubtotal += (double) ddAbs(diff); nextmeasured += 1.0; } @@ -2659,7 +2659,7 @@ Cudd_AverageDistance( scan = nodelist[j]; while (scan != NULL) { if (scan->next != NULL) { - diff = (long) scan - (long) scan->next; + diff = (ABC_PTRINT_T) scan - (ABC_PTRINT_T) scan->next; nextsubtotal += (double) ddAbs(diff); nextmeasured += 1.0; } diff --git a/src/bdd/cudd/cuddZddUtil.c b/src/bdd/cudd/cuddZddUtil.c index 6a63227f44..0835aa8ec3 100644 --- a/src/bdd/cudd/cuddZddUtil.c +++ b/src/bdd/cudd/cuddZddUtil.c @@ -610,11 +610,11 @@ Cudd_zddDumpDot( */ /* Find the bits that are different. */ - refAddr = (long) f[0]; + refAddr = (ABC_PTRINT_T) f[0]; diff = 0; gen = st__init_gen(visited); while ( st__gen(gen, (const char **)&scan, NULL)) { - diff |= refAddr ^ (long) scan; + diff |= refAddr ^ (ABC_PTRINT_T) scan; } st__free_gen(gen); diff --git a/src/bdd/mtr/mtrBasic.c b/src/bdd/mtr/mtrBasic.c index 1855dfe76a..a0e1bafff0 100644 --- a/src/bdd/mtr/mtrBasic.c +++ b/src/bdd/mtr/mtrBasic.c @@ -427,9 +427,9 @@ Mtr_PrintTree( (void) fprintf(stdout, #if SIZEOF_VOID_P == 8 "N=0x%-8lx C=0x%-8lx Y=0x%-8lx E=0x%-8lx P=0x%-8lx F=%x L=%u S=%u\n", - (unsigned long) node, (unsigned long) node->child, - (unsigned long) node->younger, (unsigned long) node->elder, - (unsigned long) node->parent, node->flags, node->low, node->size); + (ABC_PTRUINT_T) node, (ABC_PTRUINT_T) node->child, + (ABC_PTRUINT_T) node->younger, (ABC_PTRUINT_T) node->elder, + (ABC_PTRUINT_T) node->parent, node->flags, node->low, node->size); #else "N=0x%-8x C=0x%-8x Y=0x%-8x E=0x%-8x P=0x%-8x F=%x L=%hu S=%hu\n", (unsigned) node, (unsigned) node->child, diff --git a/src/bool/kit/kitGraph.c b/src/bool/kit/kitGraph.c index a81b640459..b14f170a45 100644 --- a/src/bool/kit/kitGraph.c +++ b/src/bool/kit/kitGraph.c @@ -325,17 +325,17 @@ unsigned Kit_GraphToTruth( Kit_Graph_t * pGraph ) // assign the elementary variables Kit_GraphForEachLeaf( pGraph, pNode, i ) - pNode->pFunc = (void *)(long)uTruths[i]; + pNode->pFunc = (void *)(ABC_PTRUINT_T)uTruths[i]; // compute the function for each internal node Kit_GraphForEachNode( pGraph, pNode, i ) { - uTruth0 = (unsigned)(long)Kit_GraphNode(pGraph, pNode->eEdge0.Node)->pFunc; - uTruth1 = (unsigned)(long)Kit_GraphNode(pGraph, pNode->eEdge1.Node)->pFunc; + uTruth0 = (unsigned)(ABC_PTRUINT_T)Kit_GraphNode(pGraph, pNode->eEdge0.Node)->pFunc; + uTruth1 = (unsigned)(ABC_PTRUINT_T)Kit_GraphNode(pGraph, pNode->eEdge1.Node)->pFunc; uTruth0 = pNode->eEdge0.fCompl? ~uTruth0 : uTruth0; uTruth1 = pNode->eEdge1.fCompl? ~uTruth1 : uTruth1; uTruth = uTruth0 & uTruth1; - pNode->pFunc = (void *)(long)uTruth; + pNode->pFunc = (void *)(ABC_PTRUINT_T)uTruth; } // complement the result if necessary diff --git a/src/misc/st/st.c b/src/misc/st/st.c index b54509d6e2..cb1ee8dfec 100644 --- a/src/misc/st/st.c +++ b/src/misc/st/st.c @@ -17,7 +17,7 @@ ABC_NAMESPACE_IMPL_START #define st__NUMCMP(x,y) ((x) != (y)) -#define st__NUMHASH(x,size) (Abc_AbsInt((long)x)%(size)) +#define st__NUMHASH(x,size) (Abc_AbsInt((ABC_PTRINT_T)x)%(size)) //#define st__PTRHASH(x,size) ((int)((ABC_PTRUINT_T)(x)>>2)%size) // 64-bit bug fix 9/17/2007 #define st__PTRHASH(x,size) ((int)(((ABC_PTRUINT_T)(x)>>2)%size)) #define EQUAL(func, x, y) \ @@ -144,7 +144,7 @@ int return 0; } else { if (value != 0) { - *value = (long) ptr->record; + *value = (ABC_PTRINT_T) ptr->record; } return 1; } @@ -411,7 +411,7 @@ int *last = ptr->next; if (value != NULL) *value = ptr->record; - *keyp = (long) ptr->key; + *keyp = (ABC_PTRINT_T) ptr->key; ABC_FREE(ptr); table->num_entries--; return 1; @@ -544,7 +544,7 @@ int } *key_p = gen->entry->key; if (value_p != 0) { - *value_p = (long) gen->entry->record; + *value_p = (ABC_PTRINT_T) gen->entry->record; } gen->entry = gen->entry->next; return 1; diff --git a/src/misc/st/stmm.c b/src/misc/st/stmm.c index 99d78ae19c..8916df5d44 100644 --- a/src/misc/st/stmm.c +++ b/src/misc/st/stmm.c @@ -15,7 +15,7 @@ ABC_NAMESPACE_IMPL_START #define STMM_NUMCMP(x,y) ((x) != (y)) -#define STMM_NUMHASH(x,size) (Abc_AbsInt((long)x)%(size)) +#define STMM_NUMHASH(x,size) (Abc_AbsInt((ABC_PTRINT_T)x)%(size)) //#define STMM_PTRHASH(x,size) ((int)((ABC_PTRUINT_T)(x)>>2)%size) // 64-bit bug fix 9/17/2007 #define STMM_PTRHASH(x,size) ((int)(((ABC_PTRUINT_T)(x)>>2)%size)) #define EQUAL(func, x, y) \ @@ -168,7 +168,7 @@ stmm_lookup_int (stmm_table *table, char *key, int *value) else { if (value != 0) { - *value = (long) ptr->record; + *value = (ABC_PTRINT_T) ptr->record; } return 1; } @@ -470,7 +470,7 @@ stmm_delete_int (stmm_table *table, long *keyp, char **value) *last = ptr->next; if (value != NULL) *value = ptr->record; - *keyp = (long) ptr->key; + *keyp = (ABC_PTRINT_T) ptr->key; // ABC_FREE( ptr ); Extra_MmFixedEntryRecycle ((Extra_MmFixed_t *)table->pMemMan, (char *) ptr); @@ -611,7 +611,7 @@ stmm_gen_int (stmm_generator *gen, char **key_p, long *value_p) *key_p = gen->entry->key; if (value_p != 0) { - *value_p = (long) gen->entry->record; + *value_p = (ABC_PTRINT_T) gen->entry->record; } gen->entry = gen->entry->next; return 1; diff --git a/src/misc/util/utilFile.c b/src/misc/util/utilFile.c index f64d71c24a..696b9f75ad 100644 --- a/src/misc/util/utilFile.c +++ b/src/misc/util/utilFile.c @@ -202,7 +202,7 @@ char* vnsprintf(const char* format, va_list args) static FILE* dummy_file = NULL; if (!dummy_file) { -#if !defined(_MSC_VER) && !defined(__MINGW32) +#if !defined(_MSC_VER) && !defined(__MINGW32__) dummy_file = fopen("/dev/null", "wb"); #else dummy_file = fopen("NUL", "wb"); diff --git a/src/proof/fra/fraLcr.c b/src/proof/fra/fraLcr.c index b9e2ccb42f..e2d4ed0f76 100644 --- a/src/proof/fra/fraLcr.c +++ b/src/proof/fra/fraLcr.c @@ -208,8 +208,8 @@ int Fra_LcrNodesAreEqual( Aig_Obj_t * pObj0, Aig_Obj_t * pObj1 ) assert( Aig_ObjIsCi(pObj0) ); assert( Aig_ObjIsCi(pObj1) ); // find the partition to which these nodes belong - nPart0 = pLcr->pInToOutPart[(long)pObj0->pNext]; - nPart1 = pLcr->pInToOutPart[(long)pObj1->pNext]; + nPart0 = pLcr->pInToOutPart[(ABC_PTRINT_T)pObj0->pNext]; + nPart1 = pLcr->pInToOutPart[(ABC_PTRINT_T)pObj1->pNext]; // if this is the result of refinement of the class created const-1 nodes // the nodes may end up in different partions - we assume them equivalent if ( nPart0 != nPart1 ) @@ -220,8 +220,8 @@ int Fra_LcrNodesAreEqual( Aig_Obj_t * pObj0, Aig_Obj_t * pObj1 ) assert( nPart0 == nPart1 ); pFraig = (Aig_Man_t *)Vec_PtrEntry( pLcr->vFraigs, nPart0 ); // get the fraig outputs - pOut0 = Aig_ManCo( pFraig, pLcr->pInToOutNum[(long)pObj0->pNext] ); - pOut1 = Aig_ManCo( pFraig, pLcr->pInToOutNum[(long)pObj1->pNext] ); + pOut0 = Aig_ManCo( pFraig, pLcr->pInToOutNum[(ABC_PTRINT_T)pObj0->pNext] ); + pOut1 = Aig_ManCo( pFraig, pLcr->pInToOutNum[(ABC_PTRINT_T)pObj1->pNext] ); return Aig_ObjFanin0(pOut0) == Aig_ObjFanin0(pOut1); } @@ -245,10 +245,10 @@ int Fra_LcrNodeIsConst( Aig_Obj_t * pObj ) int nPart; assert( Aig_ObjIsCi(pObj) ); // find the partition to which these nodes belong - nPart = pLcr->pInToOutPart[(long)pObj->pNext]; + nPart = pLcr->pInToOutPart[(ABC_PTRINT_T)pObj->pNext]; pFraig = (Aig_Man_t *)Vec_PtrEntry( pLcr->vFraigs, nPart ); // get the fraig outputs - pOut = Aig_ManCo( pFraig, pLcr->pInToOutNum[(long)pObj->pNext] ); + pOut = Aig_ManCo( pFraig, pLcr->pInToOutNum[(ABC_PTRINT_T)pObj->pNext] ); return Aig_ObjFanin0(pOut) == Aig_ManConst1(pFraig); } @@ -316,7 +316,7 @@ Aig_Man_t * Fra_LcrDeriveAigForPartitioning( Fra_Lcr_t * pLcr ) for ( c = 0; ppClass[c]; c++ ) { assert( Aig_ObjIsCi(ppClass[c]) ); - pObjPo = Aig_ManCo( pLcr->pAig, Offset+(long)ppClass[c]->pNext ); + pObjPo = Aig_ManCo( pLcr->pAig, Offset+(ABC_PTRINT_T)ppClass[c]->pNext ); pObjNew = Fra_LcrManDup_rec( pNew, pLcr->pAig, Aig_ObjFanin0(pObjPo) ); pMiter = Aig_Exor( pNew, pMiter, pObjNew ); } @@ -326,7 +326,7 @@ Aig_Man_t * Fra_LcrDeriveAigForPartitioning( Fra_Lcr_t * pLcr ) Vec_PtrForEachEntry( Aig_Obj_t *, pLcr->pCla->vClasses1, pObj, i ) { assert( Aig_ObjIsCi(pObj) ); - pObjPo = Aig_ManCo( pLcr->pAig, Offset+(long)pObj->pNext ); + pObjPo = Aig_ManCo( pLcr->pAig, Offset+(ABC_PTRINT_T)pObj->pNext ); pMiter = Fra_LcrManDup_rec( pNew, pLcr->pAig, Aig_ObjFanin0(pObjPo) ); Aig_ObjCreateCo( pNew, pMiter ); } @@ -361,17 +361,17 @@ void Fra_LcrRemapPartitions( Vec_Ptr_t * vParts, Fra_Cla_t * pCla, int * pInToOu ppClass = (Aig_Obj_t **)Vec_PtrEntry( pCla->vClasses, Out ); for ( c = 0; ppClass[c]; c++ ) { - pInToOutPart[(long)ppClass[c]->pNext] = i; - pInToOutNum[(long)ppClass[c]->pNext] = Vec_IntSize(vOneNew); - Vec_IntPush( vOneNew, Offset+(long)ppClass[c]->pNext ); + pInToOutPart[(ABC_PTRINT_T)ppClass[c]->pNext] = i; + pInToOutNum[(ABC_PTRINT_T)ppClass[c]->pNext] = Vec_IntSize(vOneNew); + Vec_IntPush( vOneNew, Offset+(ABC_PTRINT_T)ppClass[c]->pNext ); } } else { pObjPi = (Aig_Obj_t *)Vec_PtrEntry( pCla->vClasses1, Out - Vec_PtrSize(pCla->vClasses) ); - pInToOutPart[(long)pObjPi->pNext] = i; - pInToOutNum[(long)pObjPi->pNext] = Vec_IntSize(vOneNew); - Vec_IntPush( vOneNew, Offset+(long)pObjPi->pNext ); + pInToOutPart[(ABC_PTRINT_T)pObjPi->pNext] = i; + pInToOutNum[(ABC_PTRINT_T)pObjPi->pNext] = Vec_IntSize(vOneNew); + Vec_IntPush( vOneNew, Offset+(ABC_PTRINT_T)pObjPi->pNext ); } } // replace the class @@ -471,14 +471,14 @@ void Fra_ClassNodesMark( Fra_Lcr_t * p ) // mark the nodes remaining in the classes Vec_PtrForEachEntry( Aig_Obj_t *, p->pCla->vClasses1, pObj, i ) { - pObj = Aig_ManCo( p->pCla->pAig, Offset+(long)pObj->pNext ); + pObj = Aig_ManCo( p->pCla->pAig, Offset+(ABC_PTRINT_T)pObj->pNext ); pObj->fMarkA = 1; } Vec_PtrForEachEntry( Aig_Obj_t **, p->pCla->vClasses, ppClass, i ) { for ( c = 0; ppClass[c]; c++ ) { - pObj = Aig_ManCo( p->pCla->pAig, Offset+(long)ppClass[c]->pNext ); + pObj = Aig_ManCo( p->pCla->pAig, Offset+(ABC_PTRINT_T)ppClass[c]->pNext ); pObj->fMarkA = 1; } } @@ -504,14 +504,14 @@ void Fra_ClassNodesUnmark( Fra_Lcr_t * p ) // mark the nodes remaining in the classes Vec_PtrForEachEntry( Aig_Obj_t *, p->pCla->vClasses1, pObj, i ) { - pObj = Aig_ManCo( p->pCla->pAig, Offset+(long)pObj->pNext ); + pObj = Aig_ManCo( p->pCla->pAig, Offset+(ABC_PTRINT_T)pObj->pNext ); pObj->fMarkA = 0; } Vec_PtrForEachEntry( Aig_Obj_t **, p->pCla->vClasses, ppClass, i ) { for ( c = 0; ppClass[c]; c++ ) { - pObj = Aig_ManCo( p->pCla->pAig, Offset+(long)ppClass[c]->pNext ); + pObj = Aig_ManCo( p->pCla->pAig, Offset+(ABC_PTRINT_T)ppClass[c]->pNext ); pObj->fMarkA = 0; } } diff --git a/tox.ini b/tox.ini index aa4ae9ef30..3f2fbba8f8 100644 --- a/tox.ini +++ b/tox.ini @@ -5,9 +5,9 @@ skipsdist = true [base] setenv = - {abc,tests}: CFLAGS=-O2 -g -DNDEBUG - {abc,tests}: CXXFLAGS={env:CFLAGS:-O2 -g -DNDEBUG} - {abc,tests}: LDFLAGS={env:CFLAGS:-O2 -g -DNDEBUG} + {abc,tests}: CFLAGS=-march=native -O2 -g -DNDEBUG + {abc,tests}: CXXFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} + {abc,tests}: LDFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG -Wl,-O1 -Wl,--as-needed} {build}: PREFIX={env:PREFIX:./install} passenv = @@ -55,8 +55,8 @@ commands_pre = {build,clang}: mkdir -p {toxinidir}/build commands = - abc: make -j4 ABC_USE_NO_CUDD=1 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} abc - tests: make -j4 ABC_USE_NO_CUDD=1 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} test + abc: make -j4 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} abc + tests: make -j4 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} test clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DCMAKE_TOOLCHAIN_FILE=../tools/clang_toolchain.cmake ..' build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_PREFIX=$PREFIX ..' {build,clang}: bash -c 'cmake --build . --target abc -j $(nproc)' From 63fb48c3b056fc09230a6cc31f315517c8f3dff8 Mon Sep 17 00:00:00 2001 From: Anonymous Maarten Date: Tue, 13 Nov 2018 23:41:18 +0100 Subject: [PATCH 07/35] Silence warning about unused variables The assert is disabled in release builds. --- src/misc/util/utilDouble.h | 4 ++-- src/misc/util/utilTruth.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/misc/util/utilDouble.h b/src/misc/util/utilDouble.h index 0d02378183..ab32d33c05 100644 --- a/src/misc/util/utilDouble.h +++ b/src/misc/util/utilDouble.h @@ -179,8 +179,8 @@ static inline void Xdbl_Test() xdbl b = Xdbl_FromDouble(10.28828287); xdbl ab = Xdbl_Mul(a, b); - xdbl ten100 = Xdbl_FromDouble( 1e100 ); - xdbl ten100_ = ABC_CONST(0x014c924d692ca61b); + xdbl ten100 ___unused = Xdbl_FromDouble( 1e100 ); + xdbl ten100_ ___unused = ABC_CONST(0x014c924d692ca61b); assert( ten100 == ten100_ ); diff --git a/src/misc/util/utilTruth.h b/src/misc/util/utilTruth.h index cf3d6cedf6..28a899988e 100644 --- a/src/misc/util/utilTruth.h +++ b/src/misc/util/utilTruth.h @@ -1800,7 +1800,7 @@ static inline int Abc_TtCheckCondDep2( word * pTruth, int nVars, int nSuppLim ) } static inline int Abc_TtCheckCondDep( word * pTruth, int nVars, int nSuppLim ) { - int nVarsMax = 13; + int nVarsMax ___unused = 13; word Cof0[128], Cof1[128]; // pow( 2, nVarsMax-6 ) int v, d, nWords = Abc_TtWordNum(nVars); assert( nVars <= nVarsMax ); From 9f25a1e02a21b0e7f8dd1800b5b89919269d4f5f Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Tue, 9 Nov 2021 18:37:48 -0800 Subject: [PATCH 08/35] new: dev: demonstrate tox/ci workflow options, cleanup build cfg * define HAVE_STRUCT_TIMESPEC and _XKEYCHECK_H on msvc * avoid LIBSTDCXX linking (msvc only), pass build config to all steps * add optional lto support; note clang lto requires llvm-config and lld * add llvm source-based coverage build, fix uninitialzed variable * update cmake-posix workflow configure, bin path, emulate in tox * add conda devenv file and workflow => use platform compilers and Ninja * update build instructions in readme file, cleanup tox/ci files Signed-off-by: Stephen L Arnold --- .github/workflows/build-posix-cmake.yml | 21 ++- .github/workflows/build-posix.yml | 5 +- .github/workflows/ci.yml | 93 ++++++++---- .github/workflows/conda-dev.yml | 86 ++++++++++++ .github/workflows/win.yml | 1 + .gitignore | 4 +- CMakeLists.txt | 114 ++++++++++++--- Makefile | 32 +++-- README.md | 89 +++++++++++- cmake/coverage.cmake | 125 +++++++++++++++++ environment.devenv.yml | 13 ++ src/aig/aig/CMakeLists.txt | 46 +++--- src/aig/gia/CMakeLists.txt | 179 ++++++++++++------------ src/aig/gia/giaKf.c | 2 +- src/aig/hop/CMakeLists.txt | 12 +- src/aig/ioa/CMakeLists.txt | 4 +- src/aig/ivy/CMakeLists.txt | 28 ++-- src/aig/saig/CMakeLists.txt | 38 ++--- src/base/abc/CMakeLists.txt | 34 ++--- src/base/abci/CMakeLists.txt | 124 ++++++++-------- src/base/acb/CMakeLists.txt | 10 +- src/base/bac/CMakeLists.txt | 22 +-- src/base/cba/CMakeLists.txt | 10 +- src/base/cmd/CMakeLists.txt | 10 +- src/base/cmd/cmdAuto.c | 2 +- src/base/cmd/cmdStarter.c | 2 +- src/base/exor/CMakeLists.txt | 6 +- src/base/io/CMakeLists.txt | 46 +++--- src/base/main/CMakeLists.txt | 19 +-- src/base/main/abcapis.h | 2 + src/base/pla/CMakeLists.txt | 10 +- src/base/ver/CMakeLists.txt | 4 +- src/base/wlc/CMakeLists.txt | 28 ++-- src/base/wlc/wlcPth.c | 2 +- src/base/wlc/wlcReadSmt.c | 2 +- src/base/wln/CMakeLists.txt | 11 +- src/bdd/bbr/CMakeLists.txt | 4 +- src/bdd/cudd/CMakeLists.txt | 100 ++++++------- src/bdd/dsd/CMakeLists.txt | 4 +- src/bdd/extrab/CMakeLists.txt | 16 +-- src/bdd/llb/CMakeLists.txt | 30 ++-- src/bdd/reo/CMakeLists.txt | 12 +- src/bool/bdc/CMakeLists.txt | 4 +- src/bool/dec/CMakeLists.txt | 6 +- src/bool/kit/CMakeLists.txt | 8 +- src/bool/lucky/CMakeLists.txt | 6 +- src/bool/rsb/CMakeLists.txt | 2 +- src/map/amap/CMakeLists.txt | 18 +-- src/map/cov/CMakeLists.txt | 6 +- src/map/fpga/CMakeLists.txt | 16 +-- src/map/if/CMakeLists.txt | 32 ++--- src/map/if/ifDsd.c | 2 +- src/map/if/ifTest.c | 2 +- src/map/mapper/CMakeLists.txt | 20 +-- src/map/mio/CMakeLists.txt | 8 +- src/map/mpm/CMakeLists.txt | 14 +- src/map/scl/CMakeLists.txt | 16 +-- src/map/super/CMakeLists.txt | 4 +- src/misc/bzlib/CMakeLists.txt | 10 +- src/misc/espresso/CMakeLists.txt | 60 ++++---- src/misc/extra/CMakeLists.txt | 22 +-- src/misc/mvc/CMakeLists.txt | 20 +-- src/misc/nm/CMakeLists.txt | 2 +- src/misc/tim/CMakeLists.txt | 4 +- src/misc/util/CMakeLists.txt | 6 +- src/misc/zlib/CMakeLists.txt | 20 +-- src/opt/cgt/CMakeLists.txt | 2 +- src/opt/csw/CMakeLists.txt | 2 +- src/opt/cut/CMakeLists.txt | 8 +- src/opt/dar/CMakeLists.txt | 8 +- src/opt/dau/CMakeLists.txt | 12 +- src/opt/fret/CMakeLists.txt | 4 +- src/opt/fsim/CMakeLists.txt | 2 +- src/opt/fxch/CMakeLists.txt | 2 +- src/opt/fxu/CMakeLists.txt | 10 +- src/opt/lpk/CMakeLists.txt | 12 +- src/opt/mfs/CMakeLists.txt | 8 +- src/opt/nwk/CMakeLists.txt | 18 +-- src/opt/res/CMakeLists.txt | 8 +- src/opt/ret/CMakeLists.txt | 10 +- src/opt/rwr/CMakeLists.txt | 8 +- src/opt/rwt/CMakeLists.txt | 2 +- src/opt/sbd/CMakeLists.txt | 10 +- src/opt/sfm/CMakeLists.txt | 12 +- src/opt/sim/CMakeLists.txt | 12 +- src/phys/place/CMakeLists.txt | 8 +- src/proof/abs/CMakeLists.txt | 22 +-- src/proof/abs/absPth.c | 6 +- src/proof/acec/CMakeLists.txt | 26 ++-- src/proof/cec/CMakeLists.txt | 25 ++-- src/proof/cec/cecSplit.c | 2 +- src/proof/dch/CMakeLists.txt | 10 +- src/proof/fra/CMakeLists.txt | 22 +-- src/proof/fraig/CMakeLists.txt | 16 +-- src/proof/int/CMakeLists.txt | 8 +- src/proof/int2/CMakeLists.txt | 4 +- src/proof/live/CMakeLists.txt | 12 +- src/proof/pdr/CMakeLists.txt | 14 +- src/proof/ssc/CMakeLists.txt | 2 +- src/proof/ssw/CMakeLists.txt | 26 ++-- src/sat/bmc/CMakeLists.txt | 46 +++--- src/sat/bmc/bmcBmcS.c | 2 +- src/sat/bsat/CMakeLists.txt | 20 +-- src/sat/bsat2/CMakeLists.txt | 8 +- src/sat/cnf/CMakeLists.txt | 10 +- src/sat/glucose/CMakeLists.txt | 8 +- src/sat/glucose2/CMakeLists.txt | 8 +- src/sat/msat/CMakeLists.txt | 18 +-- src/sat/satoko/CMakeLists.txt | 2 +- src/sat/xsat/CMakeLists.txt | 2 +- tox.ini | 73 +++++++--- 111 files changed, 1366 insertions(+), 894 deletions(-) create mode 100644 .github/workflows/conda-dev.yml create mode 100644 cmake/coverage.cmake create mode 100644 environment.devenv.yml diff --git a/.github/workflows/build-posix-cmake.yml b/.github/workflows/build-posix-cmake.yml index 50f9ef902f..9d4dc6ef6a 100644 --- a/.github/workflows/build-posix-cmake.yml +++ b/.github/workflows/build-posix-cmake.yml @@ -13,6 +13,9 @@ jobs: use_namespace: [false, true] runs-on: ${{ matrix.os }} + defaults: + run: + shell: bash env: CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} @@ -24,7 +27,10 @@ jobs: - name: Git Checkout uses: actions/checkout@v4 with: - submodules: recursive + fetch-depth: 0 + + - name: Update CMake + uses: jwlawson/actions-setup-cmake@v1.8 - name: Install brew dependencies run: | @@ -37,8 +43,12 @@ jobs: if: ${{ !contains(matrix.os, 'macos') }} - name: Configure CMake - run: | - cmake -G Ninja -DCMAKE_BUILD_TYPE=Release ${CMAKE_ARGS} -B build + run: > + cmake -S . -B build + -G Ninja + ${CMAKE_ARGS} + -DCMAKE_BUILD_TYPE=Release + -DCMAKE_INSTALL_PREFIX=./staging - name: Build CMake run: | @@ -50,7 +60,7 @@ jobs: - name: Test Executable run: | - ./build/abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" + ./build/src/base/main/abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" - name: Test Library run: | @@ -60,8 +70,7 @@ jobs: - name: Stage Executable run: | - mkdir staging - cp build/abc build/libabc.a staging/ + cmake --build build --target install - name: Upload pacakge artifact uses: actions/upload-artifact@v4 diff --git a/.github/workflows/build-posix.yml b/.github/workflows/build-posix.yml index 080c6e0453..6469425ac7 100644 --- a/.github/workflows/build-posix.yml +++ b/.github/workflows/build-posix.yml @@ -33,12 +33,13 @@ jobs: - name: Install APT dependencies run: | - sudo apt install -y libreadline-dev + sudo apt-get -y -qq update + sudo apt-get install -y libreadline-dev if: ${{ !contains(matrix.os, 'macos') }} - name: Build Executable run: | - make -j3 ${MAKE_ARGS} abc + make -j3 ABC_USE_PIC=1 ${MAKE_ARGS} abc - name: Test Executable run: | diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e365685b38..89738ac311 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,7 @@ on: push: branches: - master + - develop paths-ignore: - '**.md' - '**.rst' @@ -22,22 +23,27 @@ jobs: strategy: fail-fast: false matrix: - python-version: [3.8] + python-version: [3.9] name: [ + windows-2019-cl, ubuntu-20.04-gcc, ubuntu-20.04-clang, - ubuntu-18.04-gcc, - macOS-10.15-gcc, - macOS-10.15-clang, + ubuntu-22.04-clang, + macOS-11-gcc, + macOS-11-clang, ] include: + - name: windows-2019-cl + os: windows-2019 + compiler: cl + - name: ubuntu-20.04-gcc os: ubuntu-20.04 compiler: gcc - version: "10" - toxcmd: build + version: "11" + toxcmd: soname,tests - name: ubuntu-20.04-clang os: ubuntu-20.04 @@ -45,23 +51,23 @@ jobs: version: "10" toxcmd: clang - - name: ubuntu-18.04-gcc - os: ubuntu-18.04 - compiler: gcc - version: "9" - toxcmd: abc,tests + - name: ubuntu-22.04-clang + os: ubuntu-22.04 + compiler: clang + version: "12" + toxcmd: build - - name: macOS-10.15-gcc - os: macOS-10.15 + - name: macOS-11-gcc + os: macOS-11 compiler: gcc version: "11" - toxcmd: ctest + toxcmd: abc,tests - - name: macOS-10.15-clang - os: macOS-10.15 + - name: macOS-11-clang + os: macOS-11 compiler: xcode - version: "12.3" - toxcmd: clang + version: "12.4" + toxcmd: "base Xcode" steps: - uses: actions/checkout@v2 @@ -72,6 +78,9 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Update CMake + uses: jwlawson/actions-setup-cmake@v1.8 + - name: Install Tox run: | python -m pip install --upgrade pip @@ -82,12 +91,12 @@ jobs: run: | sudo apt-get -y -qq update sudo apt-get install -y libreadline-dev ncurses-dev - if [ "${{ matrix.compiler }}" = "gcc" ]; then + if [ "${{ matrix.compiler }}" = gcc ]; then sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV else - sudo apt-get install -y clang-${{ matrix.version }} g++-multilib + sudo apt-get install -y clang-${{ matrix.version }} llvm-${{ matrix.version }} lld-${{ matrix.version }} g++-multilib echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV fi @@ -97,27 +106,59 @@ jobs: env: CC: ${{ env.CC }} CXX: ${{ env.CXX }} + PREFIX: ../staging run: | tox -e ${{ matrix.toxcmd }} + - uses: actions/upload-artifact@v2 + if: matrix.name == 'ubuntu-20.04-clang' + with: + name: src_coverage_data + path: | + build/coverage/html + build/coverage/lcov.info + - name: Install and setup MacOS packages if: runner.os == 'macOS' run: | - if [ "${{ matrix.compiler }}" = "gcc" ]; then + if [ "${{ matrix.compiler }}" = gcc ]; then brew install gcc@${{ matrix.version }} echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV else ls -ls /Applications/ sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.app - echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV - echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV fi - name: Build and test MacOS if: runner.os == 'macOS' + run: | + if [ "${{ matrix.compiler }}" = gcc ]; then + CC=${{ env.CC }} CXX=${{ env.CXX }} tox -e ${{ matrix.toxcmd }} + else + tox -e ${{ matrix.toxcmd }} + fi + + - name: Configure Windows + if: runner.os == 'Windows' + run: > + cmake -S . -B build + -DBUILD_SHARED_LIBS=ON + -DABC_USE_NO_PTHREADS=ON + -DABC_USE_NO_READLINE=ON + -DCMAKE_BUILD_TYPE=Release + -DCMAKE_INSTALL_PREFIX=${{ env.PREFIX }} env: - CC: ${{ env.CC }} - CXX: ${{ env.CXX }} + CC: cl + CXX: cl + PREFIX: staging + + - name: Build Windows + if: runner.os == 'Windows' + run: cmake --build build --config Release -j 2 --target install + + - name: Test Windows + if: runner.os == 'Windows' run: | - tox -e ${{ matrix.toxcmd }} + ctest -V -C Release --test-dir build/ + ls -lh staging/ || true diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml new file mode 100644 index 0000000000..6e7c6379c3 --- /dev/null +++ b/.github/workflows/conda-dev.yml @@ -0,0 +1,86 @@ +name: CondaDev + +on: + workflow_dispatch: + pull_request: + push: + branches: + - master + - develop + +jobs: + build: + name: abc ${{ matrix.python-version }} ${{ matrix.os }} + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + python-version: ['3.9'] + use_namespace: [false, true] + include: + - os: 'ubuntu-22.04' + generator: 'Ninja' + build_type: 'Release' + - os: 'ubuntu-20.04' + generator: 'Ninja' + build_type: 'RelWithDebInfo' + - os: 'macOS-11' + generator: 'Ninja' + build_type: 'Release' + - os: 'windows-2019' + generator: 'Ninja' + build_type: 'Release' + extra_args: '-DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON' + env: + OS: ${{ matrix.os }} + PYTHON: ${{ matrix.python-version }} + PYTHONIOENCODING: utf-8 + CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} + + steps: + - uses: actions/checkout@v2 + + - name: Setup base python + uses: actions/setup-python@v2 + with: + python-version: '3.x' + + - name: Cache conda + id: cache + uses: actions/cache@v2 + env: + # Increase this value to reset cache if environment.devenv.yml has not changed + CACHE_NUMBER: 1 + with: + path: ~/conda_pkgs_dir + key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} + + - uses: conda-incubator/setup-miniconda@v2 + with: + auto-update-conda: true + python-version: ${{ matrix.python-version }} + channels: conda-forge + channel-priority: strict + use-only-tar-bz2: true + + - name: Configure condadev environment + shell: bash -l {0} + env: + PY_VER: ${{ matrix.python-version }} + run: | + conda config --set always_yes yes --set changeps1 no + conda config --add channels conda-forge + conda install conda-devenv=2.1.1 + conda devenv + + - name: Build and test + shell: bash -l {0} + env: + PY_VER: ${{ matrix.python-version }} + run: | + source activate abc-test + ctest --build-generator "${{ matrix.generator }}" \ + --build-and-test . build \ + --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ + -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ + --test-command ctest --rerun-failed --output-on-failure -V diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 39c2972029..855fd6820c 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -6,6 +6,7 @@ on: push: branches: - master + - develop jobs: msys2-build: diff --git a/.gitignore b/.gitignore index 9bd049424a..bdccf70966 100644 --- a/.gitignore +++ b/.gitignore @@ -61,6 +61,8 @@ tags /arch_flags -/cmake /cscope abc.history + +.tox/ +staging/ diff --git a/CMakeLists.txt b/CMakeLists.txt index 2b480eaf39..2333ae19e3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,7 @@ -cmake_minimum_required(VERSION 3.5.0 FATAL_ERROR) +cmake_minimum_required(VERSION 3.10.0 FATAL_ERROR) + +# Add cmake modules of this project to the module path +list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) # with at least one base tag, this can have dynamic (git) versioning: # git describe last tag = 1.1.0 @@ -48,13 +51,34 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_CXX_STANDARD 17 CACHE STRING "the C++ standard to use for this project") set(CMAKE_CXX_STANDARD_REQUIRED ON) +# LTO requires cmake min version 3.9 and clang LTO requires lld +if(ABC_ENABLE_LTO AND CMAKE_BUILD_TYPE MATCHES "Release") + if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") + find_package(LLVM CONFIG) + endif() + + include(CheckIPOSupported) + check_ipo_supported(RESULT ipo_supported OUTPUT error) + + if(ipo_supported) + message(STATUS "IPO / LTO supported") + set(CMAKE_INTERPROCEDURAL_OPTIMIZATION TRUE) + else() + message(WARNING "IPO / LTO not supported: <${error}>") + endif() +endif() + set(ABC_USE_NAMESPACE "" CACHE STRING "ABC namespace") option(ABC_USE_STDINT_H "Use C99 stdint.h header for platform-dependent types") option(ABC_USE_NO_CUDD "Compile CUDD with ABC") option(ABC_USE_NO_READLINE "Whether to use libreadline") -option(ABC_USE_NO_PTHREADS "Whether to compile with thread support") +option(ABC_USE_NO_PTHREADS "Whether to compile with pthread support") option(ABC_USE_PIC "Whether to compile into position independent code") option(ABC_USE_LIBSTDCXX "Link explicitly to stdc++") +option(ABC_USE_SONAME "Set library soname") +option(BUILD_TESTING "Build and run tests" ON) +option(COVERAGE_BUILD "Enable source-based LLVM code coverage" OFF) +option(ABC_SKIP_EXE "Skip building executable (build libs only)" OFF) add_library(abc_interface INTERFACE) @@ -93,6 +117,14 @@ set(ABC_MODULES src/aig/miniaig ) +if(NOT ABC_SKIP_EXE) + message(STATUS "Building abc main executable") + set(BUILD_MAIN_EXE + TRUE + CACHE BOOL "Building executable" FORCE + ) +endif() + file(GLOB "src/ext*" ABC_EXTERNAL_MODULES) if(ABC_EXTERNAL_MODULES) @@ -107,9 +139,7 @@ target_include_directories( $ ) -target_link_libraries(abc_interface - INTERFACE ${CMAKE_DL_LIBS} -) +target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS}) if(NOT ABC_USE_NO_CUDD) message(STATUS "Compiling with CUDD") @@ -121,7 +151,7 @@ endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND NOT (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "4.6.0")) target_compile_options(abc_interface - INTERFACE -Wno-unused-but-set-variable + INTERFACE -fno-aggressive-loop-optimizations -Wno-unused-but-set-variable ) endif() @@ -145,6 +175,8 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") "_MBCS" "_SCL_SECURE_NO_WARNINGS" "_CRT_SECURE_NO_WARNINGS" + "HAVE_STRUCT_TIMESPEC" + "_XKEYCHECK_H" ) endif() if(WIN32) @@ -267,8 +299,11 @@ if(NOT ABC_USE_NO_PTHREADS) if(NOT ABC_PTHREAD_INCLUDES OR NOT ABC_PTHREAD_LIBRARIES) message(FATAL_ERROR "Could not find pthread") endif() - target_include_directories(abc_interface INTERFACE "${ABC_PTHREAD_INCLUDES}") - target_link_libraries(abc_interface INTERFACE "${ABC_PTHREAD_LIBRARIES}") + target_include_directories( + abc_interface + INTERFACE $ + ) + target_link_libraries(abc_interface INTERFACE ${ABC_PTHREAD_LIBRARIES}) else() set(CMAKE_THREAD_PREFER_PTHREAD ON) set(THREADS_PREFER_PTHREAD_FLAG ON) @@ -285,10 +320,12 @@ if(ABC_USE_PIC) endif() if(ABC_USE_LIBSTDCXX OR NOT ABC_USE_NAMESPACE) - message(STATUS "Using explicit -lstdc++") - target_link_libraries(abc_interface - INTERFACE stdc++ - ) + if(NOT CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") + message(STATUS "Using explicit -lstdc++") + target_link_libraries(abc_interface + INTERFACE stdc++ + ) + endif() endif() define_property(GLOBAL @@ -353,15 +390,17 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") endif() if(BUILD_SHARED_LIBS) - set_target_properties( - libabc PROPERTIES VERSION ${LIBRARY_VERSION} - SOVERSION ${LIBRARY_SOVERSION} - WINDOWS_EXPORT_ALL_SYMBOLS TRUE - ) + if(ABC_USE_SONAME) + set_target_properties( + libabc PROPERTIES VERSION ${LIBRARY_VERSION} + SOVERSION ${LIBRARY_SOVERSION} + WINDOWS_EXPORT_ALL_SYMBOLS TRUE + ) + endif() endif() install(FILES ${ABC_HEADERS} - DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/abc + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/abc ) install( @@ -383,11 +422,40 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") endif() endif() -enable_testing() -add_test(NAME base_i10 - COMMAND abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" - WORKING_DIRECTORY "${abc_SOURCE_DIR}" -) +if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") + if(ABC_ENABLE_LTO AND ipo_supported) + set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=lld") + set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fuse-ld=lld") + endif() +endif() + +if(BUILD_TESTING) + set(test_SRCS src/demo.c) + if(ABC_USE_NAMESPACE) + set_source_files_properties(${test_SRCS} PROPERTIES LANGUAGE CXX) + endif() + add_executable(base_test ${test_SRCS}) + target_link_libraries(base_test PUBLIC libabc) + + enable_testing() + add_test(NAME base_test + COMMAND base_test i10.aig + WORKING_DIRECTORY "${abc_SOURCE_DIR}" + ) + + # Add source-based llvm code coverage targets. + # Note this requires recent clang/llvm tooling. + if(COVERAGE_BUILD) + add_test(NAME main_test + COMMAND abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" + WORKING_DIRECTORY "${abc_SOURCE_DIR}" + ) + + include(coverage) + add_coverage(abc) + add_coverage(base_test) + endif() +endif() add_custom_target(etags etags ${LIBABC_SOURCES} ${ABC_SOURCES} diff --git a/Makefile b/Makefile index 6b35774028..52c9744438 100644 --- a/Makefile +++ b/Makefile @@ -168,7 +168,7 @@ CXXFLAGS += $(CFLAGS) -std=c++17 -fno-exceptions $(info $(MSG_PREFIX)Using CXXFLAGS=$(CXXFLAGS)) SRC := -GARBAGE := core core.* *.stackdump ./tags $(PROG) demo arch_flags result.blif +GARBAGE := core core.* *.stackdump ./tags $(PROG) demo* arch_flags result.blif .PHONY: all default tags clean docs cmake_info @@ -181,7 +181,6 @@ OBJ := \ $(patsubst %.y, %.o, $(filter %.y, $(SRC))) LIBOBJ := $(filter-out src/base/main/main.o,$(OBJ)) -MAINOBJ := src/base/main/main.o DEMOOBJ := src/demo.o DEP := $(OBJ:.o=.d) @@ -233,32 +232,35 @@ clean: tags: etags `find . -type f -regex '.*\.\(c\|h\)'` -lib: lib$(PROG).so.$(VERSION) - -test: demo - ./demo i10.aig - -demo: $(DEMOOBJ) lib$(PROG).a - @echo "$(MSG_PREFIX)\`\` Linking binary:" $(notdir $@) - +$(VERBOSE)$(LD) -o $@ $(DEMOOBJ) lib$(PROG).a $(LDFLAGS) $(DLIBS) $(LIBS) +test: $(PROG) + ./abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" -$(PROG): $(MAINOBJ) lib$(PROG).so - @echo "$(MSG_PREFIX)\`\` Linking binary:" $(notdir $@) - +$(VERBOSE)$(LD) -o $@ $(MAINOBJ) -L. -l$(PROG) $(LDFLAGS) $(LIBS) +$(PROG): $(OBJ) + @echo "$(MSG_PREFIX)\`\` Building binary:" $(notdir $@) + $(VERBOSE)$(LD) -o $@ $^ $(LDFLAGS) $(LIBS) lib$(PROG).a: $(LIBOBJ) @echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@) $(VERBOSE)$(AR) rsv $@ $? +ifdef ABC_USE_SONAME +lib: lib$(PROG).so.$(VERSION) + lib$(PROG).so.$(VERSION): $(LIBOBJ) @echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@) +$(VERBOSE)$(LD) -shared -Wl,-soname=$(SONAME) -o $@ $^ $(LIBS) - -lib$(PROG).so: lib$(PROG).so.$(VERSION) ldconfig -v -n . @$(LN) -sf lib$(PROG).so.$(VERSION) lib$(PROG).so @$(LN) -sf lib$(PROG).so.$(VERSION) $(SONAME) +else +lib: lib$(PROG).so + +lib$(PROG).so: $(LIBOBJ) + @echo "$(MSG_PREFIX)\`\` Linking:" $(notdir $@) + +$(VERBOSE)$(LD) -shared -o $@ $^ $(LIBS) +endif + docs: @echo "$(MSG_PREFIX)\`\` Building documentation." $(notdir $@) $(VERBOSE)doxygen doxygen.conf diff --git a/README.md b/README.md index 2bb34cd036..46a8657692 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,14 @@ +# ABC: System for Sequential Logic Synthesis and Formal Verification + +[![ci](https://github.com/sarnold/abc-fork/actions/workflows/ci.yml/badge.svg)](https://github.com/sarnold/abc-fork/actions/workflows/ci.yml) +[![msystem](https://github.com/sarnold/abc-fork/actions/workflows/win.yml/badge.svg)](https://github.com/sarnold/abc-fork/actions/workflows/win.yml) +[![CondaDev](https://github.com/sarnold/abc-fork/actions/workflows/conda-dev.yml/badge.svg)](https://github.com/sarnold/abc-fork/actions/workflows/conda-dev.yml) + [![.github/workflows/build-posix.yml](https://github.com/berkeley-abc/abc/actions/workflows/build-posix.yml/badge.svg)](https://github.com/berkeley-abc/abc/actions/workflows/build-posix.yml) [![.github/workflows/build-windows.yml](https://github.com/berkeley-abc/abc/actions/workflows/build-windows.yml/badge.svg)](https://github.com/berkeley-abc/abc/actions/workflows/build-windows.yml) [![.github/workflows/build-posix-cmake.yml](https://github.com/berkeley-abc/abc/actions/workflows/build-posix-cmake.yml/badge.svg)](https://github.com/berkeley-abc/abc/actions/workflows/build-posix-cmake.yml) -# ABC: System for Sequential Logic Synthesis and Formal Verification +## Requirements: ABC is always changing but the current snapshot is believed to be stable. @@ -18,10 +24,77 @@ References: [1] L. Fan and C. Wu, "FPGA technology mapping with adaptive gate decompostion", ACM/SIGDA FPGA International Symposium on FPGAs, 2023. -## Compiling: +Minimum desktop tools needed: + + * A recent toolchain for your platform: GNU/Clang/Xcode, MSVC/MSYS + * Make and/or CMake/Ninja: the latter can be installed via Tox + +Optional: + + * libstdc++ + * readline/ncurses + * pthreads + * If using Tox, a recent Python for your platform + * If using Conda, install `conda-devenv` and use the `environment.devenv.yml` file + +ABC can be built in multiple ways on each platform; see the github workflow +files for specific build methods and tools/packages. The easiest (local) build +workflow is to install a toolchain, make utilities, and Tox using your system +package manager; you *can* build from source on MacOS/Windows using the usual +developer tools, ie, Apple Xcode or Windows Visual Studio tools (as shown in +the `ci.yml` workflow and `tox.ini` files). + +For non-Linux platforms, if you don't have tools installed yet, an (extra) +package manager should be used to install GNU tools and dependencies. Note +this is exactly what the Github workflow runners use: + + * Windows: `Chocolatey` or `MSYS2` + * MacOS: `brew` + +### Build and test with Tox -To compile ABC as a binary, download and unzip the code, then type `make`. +With at least Python 3.6 installed, install [![tox](tox)](https://github.com/tox-dev/tox) + +After cloning the repository, you can run the current tests using either +cmake or (just) make with the `tox` command. Tox will build a virtual +python environment with most of the build dependencies (except the shared +libraries above) and then run the tests. For cmake plus a simple unittest, +run something like the following: + + $ git clone https://github.com/berkeley-abc/abc.git + $ cd abc/ + $ tox -e ctest + +Note for some Tox targets, eg `demo` and `clang`, both `CC` and `CXX` should +either be set in the shell environment or passed on the command line, eg: + + $ CC=gcc CXX=g++ tox -e abc,demo --or-- + $ CC=clang CXX=clang++ tox -e clang + +There are several `tox -e` environment commands available in the current tox file: + +* Make-based args: + * `abc` - run make build => abc executable and static lib + * `soname` - run make build => shared lib with soname + * `tests` - build/run abc executable as simple test + * `demo` - build/run demo executable against static lib using make +* CMake-based args: + * `base` - run cmake Release build with namespace and staging dir install + * `build` - run cmake Debug build with shared libs, namespace, soname, LTO + * `clang` - run cmake RelWithDebInfo build with clang/LLVM source coverage, namespace, static lib + * `ctest` - build/run tests using ctest => static lib and "test" executable + * `grind` - run cmake Debug build with valgrind +* Misc utility commands: + * `clean` - clean the make build files + * `unbuild` - clean the cmake build/ directory/files + * `lint` - run cpplint style checks + +### Compiling manually: + +To compile ABC as a binary, clone/download and unzip the code, then type `make`. To compile ABC as a static library, type `make libabc.a`. +To compile ABC as a shared library, type `make lib`. +To compile ABC as a shared library with soname, type `ABC_USE_SONAME=1 make lib`. When ABC is used as a static library, two additional procedures, `Abc_Start()` and `Abc_Stop()`, are provided for starting and quitting the ABC framework in @@ -74,7 +147,15 @@ The current version of ABC can be compiled with C compiler or C++ compiler. * Compile the code as position-independent by adding `ABC_USE_PIC=1`. * Build the `libabc.so` target: - make ABC_USE_PIC=1 libabc.so + make ABC_USE_PIC=1 lib + +## Adding new source files + +For each module with new sources: + + * Add new source files to the corresponding `module.make` file + * Run `tools/mk-cmakelists.py` and then `git diff` to review changes + * Make sure new object files exist in your build ## Bug reporting: diff --git a/cmake/coverage.cmake b/cmake/coverage.cmake new file mode 100644 index 0000000000..57829c2df4 --- /dev/null +++ b/cmake/coverage.cmake @@ -0,0 +1,125 @@ +option(COVERAGE_TEXT "Show text summary of the coverage" OFF) +option(COVERAGE_LCOV "Export coverage data in lcov trace file" ON) +option(COVERAGE_HTML "Detailed html report of the coverage" ON) + +set(COVERAGE_EXCLUDE_REGEX "(lib/)") +set(COVERAGE_PATH ${PROJECT_BINARY_DIR}/coverage) + +if(COVERAGE_BUILD) + message( + STATUS + "Source coverage is enabled. TEXT=${COVERAGE_TEXT}, LCOV=${COVERAGE_LCOV}, HTML=${COVERAGE_HTML}" + ) + + find_package(LLVM REQUIRED CONFIG) + get_filename_component(LLVM_PREFIX "${LLVM_DIR}" DIRECTORY) + message(STATUS "Found llvm directory: ${LLVM_PREFIX}") + + find_program( + LLVM_COV_PATH + NAMES llvm-cov + HINTS ${LLVM_PREFIX} + PATH_SUFFIXES bin + ) + find_program( + LLVM_PROFDATA_PATH + NAMES llvm-profdata + HINTS ${LLVM_PREFIX} + PATH_SUFFIXES bin + ) + + if(LLVM_COV_PATH AND LLVM_PROFDATA_PATH) + set(ABC_HAVE_LLVM_COVERAGE_TOOLS TRUE) + + message(STATUS "Found llvm-cov: ${LLVM_COV_PATH}") + message(STATUS "Found llvm-profdata: ${LLVM_PROFDATA_PATH}") + else() + message(FATAL_ERROR "llvm-cov stack required for coverage!") + endif() + + set(CMAKE_C_FLAGS + "${CMAKE_C_FLAGS} -fprofile-instr-generate -fcoverage-mapping" + ) + set(CMAKE_CXX_FLAGS + "${CMAKE_CXX_FLAGS} -fprofile-instr-generate -fcoverage-mapping" + ) + + set(COVERAGE_TARGETS ${COVERAGE_PATH}/targets.list) + set(COVERAGE_PROFDATA ${COVERAGE_PATH}/all.profdata) + mark_as_advanced(COVERAGE_TARGETS COVERAGE_PROFDATA) +endif() + +function(add_coverage TARGET) + if(NOT COVERAGE_BUILD) + return() + endif() + + if(NOT TARGET coverage) + add_custom_target( + coverage-clear + COMMAND ${CMAKE_COMMAND} -E rm -rf ${COVERAGE_PATH} + COMMAND ${CMAKE_COMMAND} -E make_directory ${COVERAGE_PATH} + ) + + add_custom_target( + coverage-profdata + COMMAND + ${CMAKE_COMMAND} -E env + LLVM_PROFILE_FILE="${COVERAGE_PATH}/test_%p.profraw" + ${CMAKE_CTEST_COMMAND} ${CMAKE_CTEST_ARGUMENTS} + COMMAND ${LLVM_PROFDATA_PATH} merge -sparse + ${COVERAGE_PATH}/*.profraw -o ${COVERAGE_PROFDATA} + WORKING_DIRECTORY ${PROJECT_BINARY_DIR} + ) + + add_custom_target(coverage) + + if(COVERAGE_TEXT) + add_custom_target( + coverage-text + COMMAND + ${LLVM_COV_PATH} report `cat ${COVERAGE_TARGETS}` + -instr-profile=${COVERAGE_PROFDATA} + -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" + DEPENDS coverage-profdata + ) + add_dependencies(coverage coverage-text) + endif() + + if(COVERAGE_HTML) + add_custom_target( + coverage-html + COMMAND + ${LLVM_COV_PATH} show `cat ${COVERAGE_TARGETS}` + -instr-profile=${COVERAGE_PROFDATA} + -show-line-counts-or-regions + -output-dir=${COVERAGE_PATH}/html -format="html" + -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" + DEPENDS coverage-profdata + ) + add_dependencies(coverage coverage-html) + endif() + + if(COVERAGE_LCOV) + add_custom_target( + coverage-lcov + COMMAND + ${LLVM_COV_PATH} export `cat ${COVERAGE_TARGETS}` + -format="lcov" -instr-profile=${COVERAGE_PROFDATA} + -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" > + ${COVERAGE_PATH}/lcov.info + DEPENDS coverage-profdata + ) + add_dependencies(coverage coverage-lcov) + endif() + endif() + + add_custom_target( + coverage-${TARGET} + COMMAND ${CMAKE_COMMAND} -E echo "-object=$" >> + ${COVERAGE_TARGETS} + DEPENDS coverage-clear + ) + add_dependencies(coverage-profdata coverage-${TARGET}) + +endfunction() diff --git a/environment.devenv.yml b/environment.devenv.yml new file mode 100644 index 0000000000..a1d25367bf --- /dev/null +++ b/environment.devenv.yml @@ -0,0 +1,13 @@ +name: abc-test + +dependencies: + - python ={{ get_env("PY_VER", default="3.9") }} + - cmake>=3.18 + - ninja + - c-compiler + - cxx-compiler + - make # [unix] + - readline=8.1 # [unix] + - zlib + - libpng + - dirent # [win] diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt index 544a97338e..1db00e8266 100644 --- a/src/aig/aig/CMakeLists.txt +++ b/src/aig/aig/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME aig_aig SOURCES - aigRet.c - aigDup.c - aigPack.c - aigSplit.c - aigRetF.c - aigObj.c + aigCuts.c aigCheck.c - aigPartReg.c - aigTsim.c - aigJust.c - aigTiming.c - aigScl.c - aigTable.c - aigWin.c - aigShow.c - aigFanout.c + aigUtil.c aigOper.c - aigMffc.c - aigFrames.c aigMem.c + aigTable.c + aigMffc.c + aigInter.c + aigRepr.c + aigPack.c aigOrder.c + aigWin.c + aigRetF.c + aigSplit.c + aigPartSat.c + aigScl.c + aigDup.c aigPart.c - aigUtil.c aigCanon.c - aigDfs.c + aigPartReg.c + aigShow.c + aigFrames.c + aigJust.c + aigObj.c aigTruth.c - aigCuts.c - aigPartSat.c - aigRepr.c + aigTsim.c + aigRet.c + aigFanout.c + aigDfs.c + aigTiming.c aigMan.c - aigInter.c ) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index cb6421cb29..916941dc6b 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -1,110 +1,115 @@ abc_libabc_add_sources( NAME aig_gia SOURCES - giaSplit.c - giaHash.c - giaIso.c + giaRetime.c + giaCCof.c + giaSupp.c + giaEsop.c + giaCSatOld.c + giaPf.c + giaOf.c + giaDup.c + giaCTas.c + giaShrink.c giaSweeper.c - giaSim2.c - giaSupMin.c - giaSweep.c - giaCSat2.c - giaSatLut.c + giaIso.c + giaAigerExt.c giaKf.c - giaMini.c - giaCSat3.c - giaPat.c - giaDeep.c + giaQbf.c + giaUnate.c + giaBalLut.c + giaCone.c + giaSim2.c + giaFront.c + giaBalAig.c + giaTis.c giaAig.c - giaSatoko.c + giaSat3.c + giaSimBase.c giaGen.c giaMfs.c - giaReshape1.c - giaClp.c - giaUtil.c - giaGig.c - giaTruth.c - giaTsim.c - giaTim.c - giaShrink.c - giaSatMap.c - giaDfs.c - giaAgi.c - giaExist.c - giaMem.c - giaSwitch.c - giaSim.c - giaCut.c - giaShow.c - giaFalse.c - giaOf.c - giaBalLut.c - giaCof.c + giaIso2.c + giaCex.c + giaTtopt.cpp + giaScript.c + giaIf.c + giaReshape2.c + giaSatLut.c giaStr.c - giaPat2.c + giaMini.c + giaAgi.c + giaSif.c + giaFanout.c + giaTsim.c + giaSatSyn.c giaBalMap.c - giaMinLut.c - giaEmbed.c - giaSupps.c - giaAigerExt.c + giaFrames.c + giaExist.c + giaEra.c + giaSplit.c giaIiff.c - giaResub2.c - giaAiger.c - giaIff.c - giaRetime.c - giaGlitch.c - giaResub3.c - giaStg.c + giaEquiv.c + giaShow.c giaMan.c + giaHash.c + giaPat.c + giaIso3.c + giaFx.c + giaScl.c + giaResub6.c giaResub.c - giaFront.c - giaEra.c - giaPf.c - giaQbf.c - giaBidec.c - giaCex.c - giaCCof.c - giaDup.c - giaPack.c - giaEnable.c - giaCSat.c + giaSatLE.c + giaMuxes.c + giaTruth.c + giaGlitch.c giaSatEdge.c - giaSpeedup.c - giaSimBase.c - giaBalAig.c - giaFrames.c - giaScl.c - giaSupp.c - giaShrink7.c - giaFanout.c - giaEsop.c - giaSat3.c - giaForce.c - giaEra2.c giaSort.c - giaFx.c - giaSatLE.c - giaEquiv.c - giaIso2.c + giaFalse.c + giaResub2.c + giaGig.c giaMinLut2.c + giaBidec.c + giaSupps.c + giaSatMap.c + giaStg.c + giaEnable.c + giaCof.c + giaReshape1.c + giaMf.c + giaPack.c + giaSim.c + giaCSatP.c + giaUtil.c + giaDeep.c + giaRex.c + giaCSat3.c + giaEra2.c + giaIff.c + giaSpeedup.c + giaAiger.c gia.c + giaDfs.c + giaShrink7.c + giaMem.c + giaSupMin.c + giaStoch.c giaJf.c - giaNf.c - giaIf.c - giaScript.c + giaSatoko.c + giaResub3.c + giaCSat.c + giaTim.c giaEdge.c giaShrink6.c - giaIso3.c - giaMuxes.c giaLf.c - giaCSatOld.c - giaRex.c - giaMf.c - giaStoch.c - giaTis.c - giaCTas.c - giaCone.c - giaReshape2.c - giaUnate.c giaDecs.c + giaSwitch.c + giaForce.c + giaMinLut.c + giaCut.c + giaNf.c + giaCSat2.c + giaPat2.c + giaClp.c + giaEmbed.c + giaSweep.c ) diff --git a/src/aig/gia/giaKf.c b/src/aig/gia/giaKf.c index 6909851f1a..8ddd6511f5 100644 --- a/src/aig/gia/giaKf.c +++ b/src/aig/gia/giaKf.c @@ -29,7 +29,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt index 1db86faf3c..0e51ac19a9 100644 --- a/src/aig/hop/CMakeLists.txt +++ b/src/aig/hop/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME aig_hop SOURCES - hopUtil.c - hopOper.c - hopMem.c hopDfs.c - hopTruth.c + hopUtil.c + hopObj.c + hopCheck.c hopBalance.c hopTable.c - hopCheck.c - hopObj.c + hopOper.c + hopMem.c hopMan.c + hopTruth.c ) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt index 040b8625c8..c547a36b6c 100644 --- a/src/aig/ioa/CMakeLists.txt +++ b/src/aig/ioa/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME aig_ioa SOURCES - ioaWriteAig.c - ioaReadAig.c ioaUtil.c + ioaReadAig.c + ioaWriteAig.c ) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt index 4a70d8697b..2d341be20f 100644 --- a/src/aig/ivy/CMakeLists.txt +++ b/src/aig/ivy/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME aig_ivy SOURCES - ivyBalance.c ivyDsd.c - ivyCanon.c - ivyHaig.c - ivyCheck.c - ivyUtil.c + ivyBalance.c + ivyRwr.c + ivyMan.c ivyDfs.c - ivyObj.c + ivyShow.c ivyCutTrav.c + ivyHaig.c ivyFanout.c - ivyShow.c - ivySeq.c - ivyMem.c + ivyResyn.c + ivyFastMap.c + ivyObj.c + ivyCheck.c + ivyUtil.c ivyCut.c + ivyMulti.c + ivySeq.c ivyOper.c ivyFraig.c - ivyRwr.c - ivyMan.c - ivyResyn.c - ivyMulti.c - ivyFastMap.c ivyTable.c + ivyCanon.c + ivyMem.c ) diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt index 01625652db..f881487197 100644 --- a/src/aig/saig/CMakeLists.txt +++ b/src/aig/saig/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME aig_saig SOURCES - saigRetStep.c - saigSwitch.c - saigStrSim.c - saigMiter.c - saigConstr2.c - saigConstr.c - saigWnd.c - saigScl.c + saigIsoSlow.c + saigIoa.c + saigInd.c saigCone.c + saigSynch.c + saigWnd.c + saigDual.c + saigConstr.c + saigRetStep.c + saigTempor.c + saigIsoFast.c saigIso.c saigRetFwd.c + saigSimSeq.c saigSimFast.c - saigInd.c - saigDual.c - saigDup.c - saigTrans.c - saigSynch.c - saigIsoFast.c - saigIsoSlow.c saigOutDec.c - saigTempor.c - saigPhase.c - saigSimSeq.c + saigMiter.c saigSimMv.c + saigTrans.c + saigSwitch.c + saigConstr2.c saigRetMin.c - saigIoa.c + saigStrSim.c + saigPhase.c + saigScl.c + saigDup.c ) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt index e255c3300f..325293df30 100644 --- a/src/base/abc/CMakeLists.txt +++ b/src/base/abc/CMakeLists.txt @@ -1,27 +1,27 @@ abc_libabc_add_sources( NAME base_abc SOURCES - abcCheck.c - abcHieCec.c + abcFanio.c + abcNames.c + abcHieGia.c abcHie.c - abcLib.c - abcLatch.c abcNtk.c - abcFunc.c - abcFanOrder.c - abcObj.c - abcBarBuf.c + abcMinBase.c + abcHieNew.c abcBlifMv.c - abcAig.c - abcRefs.c - abcNetlist.c + abcHieCec.c + abcCheck.c abcUtil.c abcDfs.c - abcHieNew.c - abcFanio.c - abcNames.c - abcShow.c + abcFunc.c abcSop.c - abcMinBase.c - abcHieGia.c + abcAig.c + abcNetlist.c + abcLatch.c + abcBarBuf.c + abcRefs.c + abcObj.c + abcFanOrder.c + abcShow.c + abcLib.c ) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index be4f3ac226..8ffcbb7eee 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -1,80 +1,80 @@ abc_libabc_add_sources( NAME base_abci SOURCES - abcBalance.c + abcFx.c abcLutmin.c - abcLut.c - abcRunGen.c - abcSense.c - abcPart.c - abcDec.c - abcMulti.c + abcMap.c + abcExtract.c + abcBm.c + abcOrder.c + abcUnate.c abcQbf.c - abcRewrite.c - abcReconv.c - abcRr.c - abcCut.c + abcMulti.c + abcIvy.c + abcLog.c + abcCollapse.c + abcMerge.c + abcFxu.c + abcLut.c abcReach.c + abcCas.c + abcRpo.c + abcRec3.c abcSymm.c - abcSweep.c - abcDsd.c + abcDebug.c + abcScorr.c + abcEco.c + abcResub.c + abcReconv.c + abcIf.c + abcGen.c + abcTim.c + abcRestruct.c + abcExact.c + abcNtbdd.c + abcReorder.c + abcDress.c + abcHaig.c + abcQuant.c + abcDress3.c abcDress2.c - abcStrash.c + abcIfMux.c + abcDec.c + abcNpnSave.c + abcRr.c + abcAttach.c + abcNpn.c abcOdc.c - abcUnreach.c - abcRestruct.c - abc.c - abcMfs.c - abcGen.c + abcStrash.c + abcMini.c abcSaucy.c - abcHaig.c + abcDsd.c abcSpeedup.c - abcCas.c - abcDebug.c - abcRpo.c - abcExtract.c - abcDar.c + abcRewrite.c + abcMfs.c + abcDetect.c + abcBidec.c + abcFraig.c + abcMiter.c + abcPrint.c + abcSat.c abcXsim.c - abcReorder.c - abcEco.c - abcExact.c - abcIfif.c - abcCascade.c - abcBm.c - abcBmc.c abcRefactor.c - abcResub.c - abcIvy.c - abcFx.c - abcMap.c - abcDetect.c - abcMini.c - abcMerge.c - abcRec3.c + abcRunGen.c + abc.c + abcBalance.c + abcCascade.c + abcRenode.c + abcSweep.c + abcIfif.c abcProve.c + abcUnreach.c + abcBmc.c abcVerify.c - abcFxu.c - abcRenode.c - abcLog.c - abcDress.c + abcCut.c + abcPart.c abcTiming.c - abcOrder.c - abcBidec.c - abcSat.c - abcIf.c - abcPrint.c - abcUnate.c - abcFraig.c - abcScorr.c - abcMiter.c - abcTim.c - abcCollapse.c - abcAttach.c - abcNpn.c - abcDress3.c - abcNpnSave.c - abcIfMux.c - abcNtbdd.c - abcQuant.c + abcDar.c + abcSense.c abcAuto.c ) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt index 5d63a9bf83..1576b7687c 100644 --- a/src/base/acb/CMakeLists.txt +++ b/src/base/acb/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME base_acb SOURCES - acbTest.c - acbFunc.c - acbAbc.c acbCom.c + acbSets.c + acbAbc.c acbMfs.c acbAig.c - acbUtil.c - acbSets.c acbPush.c + acbTest.c + acbUtil.c + acbFunc.c ) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt index 74925d1834..36b6d7c7a4 100644 --- a/src/base/bac/CMakeLists.txt +++ b/src/base/bac/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME base_bac SOURCES - bacWriteVer.c - bacReadSmt.c - bacPrsTrans.c - bacPtr.c - bacBlast.c - bacReadVer.c + bacWriteBlif.c + bacBac.c + bacWriteSmt.c bacReadBlif.c - bacPtrAbc.c + bacReadSmt.c bacCom.c - bacWriteSmt.c - bacNtk.c - bacBac.c bacPrsBuild.c + bacPrsTrans.c bacLib.c - bacWriteBlif.c + bacPtrAbc.c + bacNtk.c + bacReadVer.c + bacPtr.c + bacWriteVer.c + bacBlast.c ) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt index 4a06959f45..befac34d35 100644 --- a/src/base/cba/CMakeLists.txt +++ b/src/base/cba/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME base_cba SOURCES - cbaBlast.c - cbaWriteBlif.c cbaNtk.c - cbaReadVer.c - cbaWriteVer.c - cbaReadBlif.c cbaCba.c cbaCom.c + cbaWriteVer.c + cbaBlast.c + cbaWriteBlif.c + cbaReadBlif.c + cbaReadVer.c ) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt index 834faf0a56..64d2799714 100644 --- a/src/base/cmd/CMakeLists.txt +++ b/src/base/cmd/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME base_cmd SOURCES + cmdHist.c cmd.c - cmdAuto.c + cmdUtils.c cmdStarter.c - cmdPlugin.c + cmdAuto.c cmdApi.c - cmdUtils.c - cmdAlias.c - cmdHist.c + cmdPlugin.c cmdLoad.c cmdFlag.c + cmdAlias.c ) diff --git a/src/base/cmd/cmdAuto.c b/src/base/cmd/cmdAuto.c index 8151c2e534..ecbe094362 100644 --- a/src/base/cmd/cmdAuto.c +++ b/src/base/cmd/cmdAuto.c @@ -29,7 +29,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/base/cmd/cmdStarter.c b/src/base/cmd/cmdStarter.c index bfbe5533d2..ef34ac8bc2 100644 --- a/src/base/cmd/cmdStarter.c +++ b/src/base/cmd/cmdStarter.c @@ -27,7 +27,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt index 0db3a82cb9..1b557068d6 100644 --- a/src/base/exor/CMakeLists.txt +++ b/src/base/exor/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME base_exor SOURCES - exorLink.c exorList.c - exorCubes.c exorBits.c - exor.c + exorCubes.c exorUtil.c + exor.c + exorLink.c ) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index 0198a6ec06..118c9f9d94 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -2,34 +2,34 @@ abc_libabc_add_sources( NAME base_io SOURCES ioReadAiger.c - ioWriteBlif.c - ioWriteBblif.c - ioWriteList.c + ioWriteGml.c + ioReadBlif.c + ioReadBlifMv.c + io.c + ioWriteBook.c + ioWriteBlifMv.c + ioReadEqn.c + ioReadBlifAig.c + ioWriteVerilog.c + ioReadPlaMo.c ioWritePla.c + ioWriteBaf.c + ioWriteBench.c + ioReadEdif.c ioJson.c - ioReadBench.c - ioWriteSmv.c - ioReadBlifAig.c - ioReadVerilog.c ioReadPla.c - ioReadBblif.c + ioWriteList.c + ioWriteEqn.c + ioUtil.c + ioReadBench.c ioWriteCnf.c - ioReadPlaMo.c + ioWriteBlif.c ioReadBaf.c - ioWriteAiger.c - ioWriteBook.c - ioReadBlif.c - ioReadBlifMv.c - ioWriteVerilog.c - ioWriteGml.c - ioWriteBlifMv.c - ioWriteEqn.c ioWriteDot.c - ioWriteBaf.c - ioReadEdif.c + ioReadVerilog.c + ioReadBblif.c + ioWriteSmv.c ioReadDsd.c - ioWriteBench.c - ioReadEqn.c - io.c - ioUtil.c + ioWriteAiger.c + ioWriteBblif.c ) diff --git a/src/base/main/CMakeLists.txt b/src/base/main/CMakeLists.txt index 4c5e9ae5c1..77c52564f1 100644 --- a/src/base/main/CMakeLists.txt +++ b/src/base/main/CMakeLists.txt @@ -9,15 +9,18 @@ abc_libabc_add_sources( mainUtils.c ) -abc_add_executable( - NAME abc - SOURCES - main.c -) +if(BUILD_MAIN_EXE) + abc_add_executable( + NAME abc + SOURCES + main.c + ) + + install(TARGETS abc + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" + ) +endif() -install(TARGETS abc - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" -) if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") install(FILES $ DESTINATION bin OPTIONAL) endif() diff --git a/src/base/main/abcapis.h b/src/base/main/abcapis.h index 1601cb301d..5c6bc66bac 100644 --- a/src/base/main/abcapis.h +++ b/src/base/main/abcapis.h @@ -57,6 +57,7 @@ typedef struct Abc_Frame_t_ Abc_Frame_t; #define ABC_DLL ABC_DLLIMPORT #endif +#pragma GCC visibility push(default) //////////////////////////////////////////////////////////////////////// /// FUNCTION DECLARATIONS /// //////////////////////////////////////////////////////////////////////// @@ -115,6 +116,7 @@ extern ABC_DLL void Abc_FrameSetRetimingData( Abc_Frame_t * pAbc, int * pRst, // procedure to return sequential equivalences extern ABC_DLL int * Abc_FrameReadMiniAigEquivClasses( Abc_Frame_t * pAbc ); +#pragma GCC visibility pop ABC_NAMESPACE_HEADER_END #endif diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt index b7ed90098b..982ab09501 100644 --- a/src/base/pla/CMakeLists.txt +++ b/src/base/pla/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME base_pla SOURCES - plaCom.c - plaWrite.c - plaSimple.c plaMerge.c - plaMan.c - plaHash.c plaRead.c + plaSimple.c + plaWrite.c + plaHash.c + plaMan.c + plaCom.c ) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt index 34272103a1..76cd3f567e 100644 --- a/src/base/ver/CMakeLists.txt +++ b/src/base/ver/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME base_ver SOURCES - verCore.c - verStream.c verFormula.c verParse.c + verStream.c + verCore.c ) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt index de2efee12f..0002d18251 100644 --- a/src/base/wlc/CMakeLists.txt +++ b/src/base/wlc/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME base_wlc SOURCES - wlcMem.c - wlcStdin.c + wlcBlast.c wlcAbs.c - wlcSim.c - wlcCom.c - wlcAbs2.c + wlcPth.c + wlcGraft.c + wlcShow.c wlcReadSmt.c - wlcReadVer.c + wlcUif.c + wlcStdin.c + wlcCom.c wlcJson.c - wlcWin.c + wlcNtk.c + wlcNdr.c + wlcSim.c + wlcReadVer.c + wlcMem.c + wlcAbs2.c wlcAbc.c - wlcPth.c - wlcBlast.c - wlcUif.c + wlcWin.c wlcWriteVer.c - wlcGraft.c - wlcNdr.c - wlcNtk.c - wlcShow.c ) diff --git a/src/base/wlc/wlcPth.c b/src/base/wlc/wlcPth.c index ddafab23ca..364f857cda 100644 --- a/src/base/wlc/wlcPth.c +++ b/src/base/wlc/wlcPth.c @@ -23,7 +23,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/base/wlc/wlcReadSmt.c b/src/base/wlc/wlcReadSmt.c index 768ceb3ee8..9a44f01fba 100644 --- a/src/base/wlc/wlcReadSmt.c +++ b/src/base/wlc/wlcReadSmt.c @@ -548,7 +548,7 @@ static inline char * Smt_GetHexFromDecimalString(char * pStr) for (k=0;k diff --git a/src/map/if/ifTest.c b/src/map/if/ifTest.c index fa9a644437..626cb9a6e6 100644 --- a/src/map/if/ifTest.c +++ b/src/map/if/ifTest.c @@ -23,7 +23,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt index 665145bd98..21a7465424 100644 --- a/src/map/mapper/CMakeLists.txt +++ b/src/map/mapper/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME map_mapper SOURCES - mapperTable.c - mapperTime.c mapperRefs.c - mapperSuper.c + mapperTime.c + mapperLib.c + mapperTable.c mapper.c + mapperUtils.c + mapperCutUtils.c + mapperTree.c + mapperTruth.c mapperCreate.c mapperSwitch.c mapperCore.c - mapperCanon.c - mapperTruth.c - mapperUtils.c - mapperLib.c + mapperCut.c mapperVec.c - mapperTree.c - mapperCutUtils.c + mapperSuper.c mapperMatch.c - mapperCut.c + mapperCanon.c ) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt index 72d5e71ad9..c727791989 100644 --- a/src/map/mio/CMakeLists.txt +++ b/src/map/mio/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_mio SOURCES - mioSop.c mioParse.c - mioFunc.c mioRead.c - mioApi.c - mioUtils.c mio.c + mioUtils.c + mioSop.c + mioApi.c + mioFunc.c ) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt index 6ca6eab7ce..80b8eedeee 100644 --- a/src/map/mpm/CMakeLists.txt +++ b/src/map/mpm/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_mpm SOURCES - mpmMan.c + mpmUtil.c + mpmAbc.c + mpmPre.c mpmDsd.c - mpmLib.c mpmMig.c - mpmUtil.c - mpmTruth.c + mpmGates.c + mpmMan.c mpmMap.c + mpmLib.c mpmCore.c - mpmGates.c - mpmPre.c - mpmAbc.c + mpmTruth.c ) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt index 5e95dbf1c4..196bf147be 100644 --- a/src/map/scl/CMakeLists.txt +++ b/src/map/scl/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_scl SOURCES - sclLiberty.c - sclLibScl.c - sclBuffer.c - sclLibUtil.c + sclLoad.c scl.c - sclUpsize.c - sclBufSize.c sclSize.c - sclUtil.c - sclLoad.c sclDnsize.c + sclLibUtil.c + sclUpsize.c + sclUtil.c + sclLibScl.c + sclBufSize.c + sclBuffer.c + sclLiberty.c ) diff --git a/src/map/super/CMakeLists.txt b/src/map/super/CMakeLists.txt index 97828f5a50..f827cecf65 100644 --- a/src/map/super/CMakeLists.txt +++ b/src/map/super/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME map_super SOURCES - superGate.c - superAnd.c super.c + superAnd.c + superGate.c ) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt index 0f45852e56..c81fe80bf0 100644 --- a/src/misc/bzlib/CMakeLists.txt +++ b/src/misc/bzlib/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME misc_bzlib SOURCES - huffman.c - compress.c decompress.c - bzlib.c - blocksort.c - randtable.c crctable.c + randtable.c + compress.c + blocksort.c + bzlib.c + huffman.c ) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt index 8aec1478ce..2c96cbb42c 100644 --- a/src/misc/espresso/CMakeLists.txt +++ b/src/misc/espresso/CMakeLists.txt @@ -1,43 +1,43 @@ abc_libabc_add_sources( NAME misc_espresso SOURCES - cols.c - matrix.c - sminterf.c - cvrmisc.c - unate.c - essen.c - gasp.c - sharp.c - map.c - indep.c - reduce.c - expand.c setc.c exact.c - cofactor.c - cubehack.c - gimpel.c - globals.c equiv.c - cvrin.c - verify.c - compl.c - solution.c - rows.c - mincov.c - cvrm.c + sparse.c + essen.c + globals.c + cvrmisc.c cvrout.c - opo.c + indep.c + primes.c part.c - sparse.c - contain.c + expand.c + cvrm.c + unate.c + espresso.c + rows.c + reduce.c + map.c + cols.c + irred.c + cubehack.c + cvrin.c pair.c + sminterf.c hack.c - primes.c - set.c - espresso.c + matrix.c cubestr.c + contain.c + set.c + sharp.c + mincov.c + gasp.c + gimpel.c + opo.c dominate.c - irred.c + cofactor.c + verify.c + compl.c + solution.c ) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt index 2454afd7d4..76484819d6 100644 --- a/src/misc/extra/CMakeLists.txt +++ b/src/misc/extra/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME misc_extra SOURCES - extraUtilFile.c - extraUtilGen.c + extraUtilTruth.c extraUtilMaj.c - extraUtilEnum.c - extraUtilCube.c + extraUtilMemory.c + extraUtilProgress.c extraUtilUtil.c extraUtilReader.c - extraUtilTruth.c - extraUtilMacc.c + extraUtilPath.c + extraUtilBitMatrix.c + extraUtilGen.c extraUtilCanon.c extraUtilDsd.c extraUtilCfs.c - extraUtilPath.c - extraUtilPerm.c - extraUtilProgress.c + extraUtilEnum.c extraUtilMisc.c + extraUtilFile.c extraUtilMult.c - extraUtilBitMatrix.c - extraUtilMemory.c + extraUtilMacc.c + extraUtilCube.c extraUtilSupp.c + extraUtilPerm.c ) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt index 8900ec3707..496140f9f2 100644 --- a/src/misc/mvc/CMakeLists.txt +++ b/src/misc/mvc/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_mvc SOURCES + mvcApi.c + mvcOpAlg.c mvcMan.c - mvcCover.c + mvcCompare.c + mvcPrint.c + mvcDivide.c + mvcLits.c mvcDivisor.c - mvcOpAlg.c + mvcList.c + mvcOpBool.c mvcContain.c - mvcLits.c + mvcSort.c mvcUtils.c mvcCube.c - mvcCompare.c - mvcOpBool.c - mvcPrint.c - mvcSort.c - mvcList.c - mvcApi.c - mvcDivide.c + mvcCover.c ) diff --git a/src/misc/nm/CMakeLists.txt b/src/misc/nm/CMakeLists.txt index ef2789c4fd..bf4706f5fd 100644 --- a/src/misc/nm/CMakeLists.txt +++ b/src/misc/nm/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME misc_nm SOURCES - nmApi.c nmTable.c + nmApi.c ) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt index f430ed9557..d3cd3dd31b 100644 --- a/src/misc/tim/CMakeLists.txt +++ b/src/misc/tim/CMakeLists.txt @@ -2,8 +2,8 @@ abc_libabc_add_sources( NAME misc_tim SOURCES timDump.c - timTrav.c - timTime.c timMan.c timBox.c + timTime.c + timTrav.c ) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt index b38e24dafd..d187da49b5 100644 --- a/src/misc/util/CMakeLists.txt +++ b/src/misc/util/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME misc_util SOURCES - utilColor.c utilIsop.c + utilNam.c + utilFile.c utilSort.c utilCex.c - utilNam.c utilSignal.c + utilColor.c utilBridge.c - utilFile.c ) diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt index a661bb86d5..22adb0ee78 100644 --- a/src/misc/zlib/CMakeLists.txt +++ b/src/misc/zlib/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_zlib SOURCES - zutil.c + deflate.c + compress_.c inflate.c - inftrees.c - gzclose.c - crc32.c - inffast.c - gzlib.c - infback.c uncompr.c - compress_.c - deflate.c + gzclose.c gzread.c - trees.c + inftrees.c + inffast.c + crc32.c adler32.c gzwrite.c + zutil.c + trees.c + gzlib.c + infback.c ) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt index bd10d557e0..09618127a4 100644 --- a/src/opt/cgt/CMakeLists.txt +++ b/src/opt/cgt/CMakeLists.txt @@ -2,8 +2,8 @@ abc_libabc_add_sources( NAME opt_cgt SOURCES cgtCore.c - cgtMan.c cgtSat.c cgtAig.c + cgtMan.c cgtDecide.c ) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt index e24c9df53e..ec48bba053 100644 --- a/src/opt/csw/CMakeLists.txt +++ b/src/opt/csw/CMakeLists.txt @@ -2,7 +2,7 @@ abc_libabc_add_sources( NAME opt_csw SOURCES cswCut.c + cswTable.c cswCore.c cswMan.c - cswTable.c ) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt index dfc052ed2c..8720329caa 100644 --- a/src/opt/cut/CMakeLists.txt +++ b/src/opt/cut/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_cut SOURCES - cutSeq.c - cutNode.c + cutPre22.c cutCut.c - cutMerge.c cutApi.c cutOracle.c + cutNode.c + cutMerge.c cutTruth.c - cutPre22.c + cutSeq.c cutMan.c ) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt index f9f62f3607..f391522599 100644 --- a/src/opt/dar/CMakeLists.txt +++ b/src/opt/dar/CMakeLists.txt @@ -3,11 +3,11 @@ abc_libabc_add_sources( SOURCES darCore.c darPrec.c + darData.c + darCut.c darBalance.c + darRefact.c + darMan.c darLib.c darScript.c - darCut.c - darData.c - darMan.c - darRefact.c ) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt index e60a257016..7df058a12f 100644 --- a/src/opt/dau/CMakeLists.txt +++ b/src/opt/dau/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_dau SOURCES - dauTree.c dauDsd.c - dauEnum.c - dauNonDsd.c - dauCount.c dauDivs.c + dauCore.c + dauGia.c dauCanon.c + dauNonDsd.c dauMerge.c - dauGia.c - dauCore.c + dauTree.c + dauCount.c + dauEnum.c dauNpn.c dauNpn2.c ) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt index d01604ac6d..14a14d03a4 100644 --- a/src/opt/fret/CMakeLists.txt +++ b/src/opt/fret/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fret SOURCES - fretMain.c fretInit.c - fretFlow.c fretTime.c + fretMain.c + fretFlow.c ) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt index cdae7250d8..ea8a9d3b17 100644 --- a/src/opt/fsim/CMakeLists.txt +++ b/src/opt/fsim/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME opt_fsim SOURCES + fsimFront.c fsimSwitch.c fsimCore.c fsimSim.c - fsimFront.c fsimMan.c fsimTsim.c ) diff --git a/src/opt/fxch/CMakeLists.txt b/src/opt/fxch/CMakeLists.txt index bd218f1522..1ba0e72e8c 100644 --- a/src/opt/fxch/CMakeLists.txt +++ b/src/opt/fxch/CMakeLists.txt @@ -2,7 +2,7 @@ abc_libabc_add_sources( NAME opt_fxch SOURCES Fxch.c + FxchDiv.c FxchSCHashTable.c FxchMan.c - FxchDiv.c ) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt index ec59dcfba5..c8dac35096 100644 --- a/src/opt/fxu/CMakeLists.txt +++ b/src/opt/fxu/CMakeLists.txt @@ -2,15 +2,15 @@ abc_libabc_add_sources( NAME opt_fxu SOURCES fxuHeapD.c - fxuPair.c - fxuUpdate.c + fxuHeapS.c fxuList.c - fxuPrint.c + fxuMatrix.c + fxuUpdate.c fxuSelect.c + fxuPrint.c fxuCreate.c fxu.c - fxuHeapS.c fxuReduce.c + fxuPair.c fxuSingle.c - fxuMatrix.c ) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt index 1688146617..3a9e5e8cb3 100644 --- a/src/opt/lpk/CMakeLists.txt +++ b/src/opt/lpk/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME opt_lpk SOURCES - lpkMux.c + lpkCore.c + lpkMan.c lpkSets.c + lpkAbcUtil.c lpkAbcDsd.c - lpkAbcDec.c - lpkCore.c lpkMulti.c - lpkAbcUtil.c - lpkMan.c lpkCut.c - lpkAbcMux.c lpkMap.c + lpkAbcMux.c + lpkMux.c + lpkAbcDec.c ) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt index ee2d4a1ec6..1c62f0f68b 100644 --- a/src/opt/mfs/CMakeLists.txt +++ b/src/opt/mfs/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME opt_mfs SOURCES - mfsStrash.c + mfsSat.c + mfsResub.c mfsWin.c + mfsStrash.c mfsCore.c mfsMan.c - mfsDiv.c - mfsSat.c mfsInter.c - mfsResub.c + mfsDiv.c ) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt index 75b7caa0f1..9d31400c50 100644 --- a/src/opt/nwk/CMakeLists.txt +++ b/src/opt/nwk/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME opt_nwk SOURCES - nwkStrash.c - nwkDfs.c - nwkFlow.c - nwkFanio.c + nwkAig.c nwkMap.c - nwkObj.c nwkTiming.c - nwkMerge.c + nwkFanio.c + nwkFlow.c + nwkCheck.c nwkUtil.c - nwkAig.c nwkSpeedup.c - nwkCheck.c - nwkMan.c + nwkMerge.c nwkBidec.c + nwkObj.c + nwkDfs.c + nwkMan.c + nwkStrash.c ) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt index 0ea35b4a1a..34a95ca143 100644 --- a/src/opt/res/CMakeLists.txt +++ b/src/opt/res/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_res SOURCES - resWin.c - resStrash.c resSat.c + resDivs.c + resFilter.c + resStrash.c + resWin.c resSim.c resCore.c - resFilter.c - resDivs.c ) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt index fa28ff4566..f8833f0255 100644 --- a/src/opt/ret/CMakeLists.txt +++ b/src/opt/ret/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_ret SOURCES - retInit.c - retIncrem.c - retLvalue.c - retDelay.c + retCore.c retArea.c + retLvalue.c retFlow.c - retCore.c + retDelay.c + retIncrem.c + retInit.c ) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt index f04575f099..102e1b3495 100644 --- a/src/opt/rwr/CMakeLists.txt +++ b/src/opt/rwr/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_rwr SOURCES - rwrLib.c + rwrPrint.c + rwrDec.c rwrExp.c rwrEva.c - rwrDec.c - rwrMan.c + rwrLib.c rwrUtil.c - rwrPrint.c + rwrMan.c ) diff --git a/src/opt/rwt/CMakeLists.txt b/src/opt/rwt/CMakeLists.txt index eef2fd3fd4..29f1e55cf4 100644 --- a/src/opt/rwt/CMakeLists.txt +++ b/src/opt/rwt/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME opt_rwt SOURCES - rwtDec.c rwtMan.c + rwtDec.c rwtUtil.c ) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt index a2fc55d484..0259254c8b 100644 --- a/src/opt/sbd/CMakeLists.txt +++ b/src/opt/sbd/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sbd SOURCES - sbdLut.c - sbdSat.c - sbdCut2.c - sbdCnf.c - sbdCore.c sbdWin.c sbdPath.c + sbdCut2.c sbd.c + sbdCnf.c + sbdLut.c sbdCut.c + sbdSat.c + sbdCore.c ) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt index a4200e0143..3d033d67d6 100644 --- a/src/opt/sfm/CMakeLists.txt +++ b/src/opt/sfm/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME opt_sfm SOURCES - sfmNtk.c - sfmArea.c - sfmMit.c - sfmTim.c - sfmDec.c sfmCore.c + sfmDec.c + sfmTim.c sfmSat.c - sfmCnf.c sfmLib.c + sfmNtk.c + sfmArea.c sfmWin.c + sfmMit.c + sfmCnf.c ) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt index d7ae044c12..126a3863e2 100644 --- a/src/opt/sim/CMakeLists.txt +++ b/src/opt/sim/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sim SOURCES - simSymSat.c - simMan.c simSwitch.c - simSymStr.c + simSymSat.c + simSymSim.c simSym.c - simSupp.c - simUtils.c + simMan.c simSeq.c - simSymSim.c + simUtils.c + simSupp.c + simSymStr.c ) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt index a58875f98b..0b92918631 100644 --- a/src/phys/place/CMakeLists.txt +++ b/src/phys/place/CMakeLists.txt @@ -3,12 +3,12 @@ abc_libabc_add_sources( SOURCES place_bin.c place_genqp.c - place_base.c - place_inc.c - place_io.c place_legalize.c + place_partition.c + place_base.c place_gordian.c + place_inc.c place_qpsolver.c + place_io.c place_pads.c - place_partition.c ) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt index d9991ddb5d..4544c4e3f9 100644 --- a/src/proof/abs/CMakeLists.txt +++ b/src/proof/abs/CMakeLists.txt @@ -1,20 +1,20 @@ abc_libabc_add_sources( NAME proof_abs SOURCES - absRpm.c - absVta.c - absPth.c absIter.c + absRefSelect.c + absOut.c + absGla.c + absOldSim.c absOldRef.c - absRef.c - absUtil.c absOldCex.c - absGla.c - absRpmOld.c - absOut.c absDup.c - absOldSim.c - absGlaOld.c - absRefSelect.c + absPth.c + absRef.c + absUtil.c + absVta.c absOldSat.c + absGlaOld.c + absRpm.c + absRpmOld.c ) diff --git a/src/proof/abs/absPth.c b/src/proof/abs/absPth.c index f04a20d1c6..cd2301a2d8 100644 --- a/src/proof/abs/absPth.c +++ b/src/proof/abs/absPth.c @@ -17,7 +17,7 @@ Revision [$Id: absPth.c,v 1.00 2005/06/20 00:00:00 alanmi Exp $] ***********************************************************************/ - + #include "abs.h" #include "proof/pdr/pdr.h" #include "proof/ssw/ssw.h" @@ -25,7 +25,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include @@ -34,7 +34,7 @@ #endif -ABC_NAMESPACE_IMPL_START +ABC_NAMESPACE_IMPL_START //////////////////////////////////////////////////////////////////////// /// DECLARATIONS /// diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt index adc4690ad4..bb8185d450 100644 --- a/src/proof/acec/CMakeLists.txt +++ b/src/proof/acec/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME proof_acec SOURCES - acecRe.c - acecNorm.c - acecTree.c - acecPa.c - acecUtil.c acecCl.c acec2Mult.c - acecOrder.c - acecMult.c - acecSt.c + acecCore.c + acecXor.c + acecPo.c acecPool.c + acecUtil.c + acecSt.c + acecRe.c acecBo.c - acecCover.c - acecPo.c - acecFadds.c - acecCore.c acecCo.c - acecXor.c + acecNorm.c + acecPa.c + acecTree.c + acecFadds.c + acecCover.c + acecMult.c acecPolyn.c + acecOrder.c ) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt index 3e001162f0..fd15a4a94d 100644 --- a/src/proof/cec/CMakeLists.txt +++ b/src/proof/cec/CMakeLists.txt @@ -1,22 +1,23 @@ abc_libabc_add_sources( NAME proof_cec SOURCES - cecSat.c - cecSynth.c + cecSatG3.c cecSim.c - cecCec.c - cecChoice.c - cecSatG2.c cecCorr.c + cecSynth.c + cecIso.c + cecMan.c + cecPat.c + cecSatG2.c + cecSeq.c cecSatG.c - cecClass.c + cecSweep.c cecSolve.c + cecSat.c + cecChoice.c + cecSolveG.c + cecCec.c cecCore.c - cecSweep.c - cecPat.c + cecClass.c cecSplit.c - cecSeq.c - cecMan.c - cecSolveG.c - cecIso.c ) diff --git a/src/proof/cec/cecSplit.c b/src/proof/cec/cecSplit.c index 34a635b88f..30168e4902 100644 --- a/src/proof/cec/cecSplit.c +++ b/src/proof/cec/cecSplit.c @@ -28,7 +28,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt index be96316bf1..e32871b935 100644 --- a/src/proof/dch/CMakeLists.txt +++ b/src/proof/dch/CMakeLists.txt @@ -2,13 +2,13 @@ abc_libabc_add_sources( NAME proof_dch SOURCES dchSweep.c + dchChoice.c dchAig.c - dchSimSat.c - dchMan.c - dchClass.c dchSim.c + dchSat.c dchCnf.c + dchClass.c dchCore.c - dchChoice.c - dchSat.c + dchMan.c + dchSimSat.c ) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt index 17750074cf..7e4755bb4c 100644 --- a/src/proof/fra/CMakeLists.txt +++ b/src/proof/fra/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME proof_fra SOURCES + fraSat.c fraImp.c - fraClass.c - fraSim.c - fraHot.c + fraSec.c + fraLcr.c fraBmc.c + fraSim.c + fraClass.c + fraClaus.c fraCec.c - fraCore.c - fraLcr.c + fraMan.c + fraInd.c fraPart.c + fraHot.c + fraIndVer.c + fraCore.c fraClau.c - fraMan.c fraCnf.c - fraClaus.c - fraIndVer.c - fraSat.c - fraSec.c - fraInd.c ) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt index 5fadae228a..1238302f0d 100644 --- a/src/proof/fraig/CMakeLists.txt +++ b/src/proof/fraig/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME proof_fraig SOURCES - fraigMan.c - fraigCanon.c - fraigFeed.c - fraigVec.c fraigUtil.c - fraigMem.c - fraigTable.c + fraigFanout.c + fraigFeed.c + fraigMan.c fraigNode.c - fraigPrime.c fraigApi.c - fraigFanout.c + fraigVec.c + fraigPrime.c + fraigCanon.c fraigSat.c + fraigMem.c + fraigTable.c ) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt index 7a425b6495..d83124a90e 100644 --- a/src/proof/int/CMakeLists.txt +++ b/src/proof/int/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_int SOURCES + intFrames.c + intInter.c intCore.c - intDup.c intM114.c intUtil.c + intDup.c intCtrex.c - intMan.c intContain.c - intFrames.c intCheck.c - intInter.c + intMan.c ) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt index b8e15c4de5..e76bac5087 100644 --- a/src/proof/int2/CMakeLists.txt +++ b/src/proof/int2/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME proof_int2 SOURCES - int2Bmc.c + int2Core.c int2Util.c int2Refine.c - int2Core.c + int2Bmc.c ) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt index a2385f68b2..aa92acb388 100644 --- a/src/proof/live/CMakeLists.txt +++ b/src/proof/live/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME proof_live SOURCES - combination.c - liveness.c - liveness_sim.c - disjunctiveMonotone.c arenaViolation.c - kliveness.c - monotone.c + disjunctiveMonotone.c kLiveConstraints.c + monotone.c + liveness.c ltl_parser.c + liveness_sim.c + combination.c + kliveness.c ) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt index 06d7edfbf5..9cd811b3d9 100644 --- a/src/proof/pdr/CMakeLists.txt +++ b/src/proof/pdr/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_pdr SOURCES - pdrMan.c - pdrIncr.c - pdrSat.c - pdrCore.c - pdrInv.c - pdrUtil.c pdrCnf.c - pdrTsim3.c pdrTsim.c + pdrTsim3.c + pdrSat.c pdrTsim2.c + pdrMan.c + pdrUtil.c + pdrInv.c + pdrCore.c + pdrIncr.c ) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt index a90d29d189..441c4730ea 100644 --- a/src/proof/ssc/CMakeLists.txt +++ b/src/proof/ssc/CMakeLists.txt @@ -3,7 +3,7 @@ abc_libabc_add_sources( SOURCES sscCore.c sscSat.c - sscUtil.c sscSim.c + sscUtil.c sscClass.c ) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt index 8eb301fee6..e42b02517d 100644 --- a/src/proof/ssw/CMakeLists.txt +++ b/src/proof/ssw/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_ssw SOURCES - sswClass.c + sswDyn.c sswCnf.c - sswSimSat.c - sswConstr.c + sswAig.c sswPart.c sswRarity.c - sswFilter.c - sswAig.c - sswCore.c + sswSimSat.c sswMan.c - sswDyn.c - sswSemi.c - sswSat.c - sswUnique.c sswLcorr.c - sswBmc.c + sswPairs.c + sswSemi.c + sswSweep.c sswIslands.c sswSim.c - sswSweep.c - sswPairs.c + sswConstr.c + sswUnique.c + sswClass.c + sswCore.c + sswFilter.c + sswSat.c + sswBmc.c ) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt index dfd7e3b23b..545fd83c6e 100644 --- a/src/sat/bmc/CMakeLists.txt +++ b/src/sat/bmc/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME sat_bmc SOURCES - bmcClp.c - bmcCexDepth.c + bmcCexTools.c + bmcMaj3.c + bmcUnroll.c + bmcEco.c + bmcMaj.c + bmcInse.c bmcChain.c - bmcBmcS.c - bmcMaxi.c - bmcBmc.c + bmcClp.c + bmcGen.c + bmcCexMin2.c + bmcBmcG.c + bmcBCore.c bmcCexMin1.c - bmcMesh2.c - bmcInse.c - bmcMesh.c - bmcMaj.c + bmcMaxi.c bmcExpand.c - bmcBmc3.c - bmcEco.c - bmcCexTools.c bmcBmci.c - bmcCexMin2.c - bmcGen.c - bmcICheck.c - bmcCexCut.c - bmcBmc2.c - bmcFault.c bmcLoad.c + bmcFx.c + bmcCexDepth.c + bmcBmc.c bmcMaj2.c - bmcUnroll.c + bmcFault.c + bmcBmc2.c bmcMulti.c - bmcBCore.c + bmcBmc3.c bmcCexCare.c - bmcBmcG.c bmcBmcAnd.c - bmcFx.c - bmcMaj3.c + bmcMesh.c + bmcCexCut.c + bmcBmcS.c + bmcMesh2.c + bmcICheck.c ) diff --git a/src/sat/bmc/bmcBmcS.c b/src/sat/bmc/bmcBmcS.c index 8bfda56ba7..039527967d 100644 --- a/src/sat/bmc/bmcBmcS.c +++ b/src/sat/bmc/bmcBmcS.c @@ -48,7 +48,7 @@ #ifdef ABC_USE_PTHREADS -#ifdef _WIN32 +#ifdef _MSC_VER #include "../lib/pthread.h" #else #include diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt index d279844ada..2ef211b455 100644 --- a/src/sat/bsat/CMakeLists.txt +++ b/src/sat/bsat/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME sat_bsat SOURCES - satMem.c - satTrace.c - satProof.c - satSolver2.c - satSolver3.c + satInter.c satStore.c + satSolver2.c + satInterA.c + satSolver.c satUtil.c + satSolver2i.c + satInterP.c satTruth.c + satMem.c satInterB.c - satInterA.c - satInterP.c - satInter.c - satSolver2i.c - satSolver.c + satSolver3.c + satProof.c + satTrace.c ) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt index a40ee9595c..d097c47460 100644 --- a/src/sat/bsat2/CMakeLists.txt +++ b/src/sat/bsat2/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME sat_bsat2 SOURCES - System.cpp + MainSat.cpp + Options.cpp AbcApi.cpp SimpSolver.cpp - Options.cpp - MainSimp.cpp - MainSat.cpp Solver.cpp + System.cpp + MainSimp.cpp ) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt index 5ab43ddd76..2f068190a8 100644 --- a/src/sat/cnf/CMakeLists.txt +++ b/src/sat/cnf/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME sat_cnf SOURCES - cnfUtil.c - cnfWrite.c - cnfData.c - cnfCore.c + cnfFast.c cnfMap.c + cnfCore.c + cnfData.c + cnfUtil.c cnfMan.c cnfCut.c + cnfWrite.c cnfPost.c - cnfFast.c ) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt index 5922ee85ba..aea0027648 100644 --- a/src/sat/glucose/CMakeLists.txt +++ b/src/sat/glucose/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose SOURCES - System.cpp + AbcGlucose.cpp + Options.cpp + SimpSolver.cpp Glucose.cpp + System.cpp AbcGlucoseCmd.cpp - SimpSolver.cpp - Options.cpp - AbcGlucose.cpp ) diff --git a/src/sat/glucose2/CMakeLists.txt b/src/sat/glucose2/CMakeLists.txt index 8f0dd551d3..9c00826407 100644 --- a/src/sat/glucose2/CMakeLists.txt +++ b/src/sat/glucose2/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose2 SOURCES - SimpSolver2.cpp - Options2.cpp - AbcGlucose2.cpp + AbcGlucoseCmd2.cpp System2.cpp + AbcGlucose2.cpp Glucose2.cpp - AbcGlucoseCmd2.cpp + Options2.cpp + SimpSolver2.cpp ) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt index e5c1f5fe2c..6c7fd78ccc 100644 --- a/src/sat/msat/CMakeLists.txt +++ b/src/sat/msat/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME sat_msat SOURCES - msatSolverApi.c - msatOrderH.c - msatRead.c - msatQueue.c - msatSolverSearch.c msatClauseVec.c + msatSolverSearch.c + msatSolverApi.c msatVec.c - msatClause.c - msatMem.c + msatSolverIo.c msatSort.c - msatSolverCore.c + msatMem.c + msatClause.c + msatOrderH.c + msatQueue.c + msatRead.c msatActivity.c - msatSolverIo.c + msatSolverCore.c ) diff --git a/src/sat/satoko/CMakeLists.txt b/src/sat/satoko/CMakeLists.txt index a45c747644..564d8938e3 100644 --- a/src/sat/satoko/CMakeLists.txt +++ b/src/sat/satoko/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_satoko SOURCES - cnf_reader.c solver_api.c + cnf_reader.c solver.c ) diff --git a/src/sat/xsat/CMakeLists.txt b/src/sat/xsat/CMakeLists.txt index 4a2aa655c6..97cc44e5d3 100644 --- a/src/sat/xsat/CMakeLists.txt +++ b/src/sat/xsat/CMakeLists.txt @@ -2,6 +2,6 @@ abc_libabc_add_sources( NAME sat_xsat SOURCES xsatCnfReader.c - xsatSolver.c xsatSolverAPI.c + xsatSolver.c ) diff --git a/tox.ini b/tox.ini index 3f2fbba8f8..6b1d87bf7e 100644 --- a/tox.ini +++ b/tox.ini @@ -5,14 +5,25 @@ skipsdist = true [base] setenv = - {abc,tests}: CFLAGS=-march=native -O2 -g -DNDEBUG - {abc,tests}: CXXFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} - {abc,tests}: LDFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG -Wl,-O1 -Wl,--as-needed} - {build}: PREFIX={env:PREFIX:./install} + {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} + {abc,demo,soname,tests}: CXXFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} + {abc,demo,soname,tests}: LDFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG -Wl,-O1 -Wl,--as-needed} + {base,build,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} + {base,build,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} + {base,build,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} + base: PREFIX={env:PREFIX:staging} + build: PREFIX={env:PREFIX:../staging} + build: BUILD_TYPE={env:BUILD_TYPE:Release} + clang: BUILD_TYPE={env:BUILD_TYPE:RelWithDebInfo} + ctest: BUILD_TYPE={env:BUILD_TYPE:Release} + ctestwin: BUILD_TYPE={env:BUILD_TYPE:Debug} passenv = CC CXX + LD + AR + NM PYTHON DISPLAY XAUTHORITY @@ -30,44 +41,60 @@ skip_install = true setenv = {abc,tests}: {[base]setenv} - {build}: {[base]setenv} + {build,base}: {[base]setenv} passenv = {[base]passenv} -whitelist_externals = - {abc,tests,lint,build,clang,ctest,grind,unbuild}: bash - {abc,tests,clean}: make - {build,clang}: mkdir +allowlist_externals = + {abc,demo,soname,tests,lint,base,build,clang,ctest,grind,unbuild}: bash + {abc,demo,soname,tests,clean}: make changedir = {build,clang}: build deps = - {abc,tests,lint,build,clang,ctest,grind}: pip>=21.3 - {abc,tests}: this-cli - {build,clang,ctest,grind}: cmake - {build,clang,ctest,grind}: ninja + {abc,demo,soname,tests,lint,base,build,clang,ctest,grind,ctestwin}: pip>=21.3 + {abc,demo,soname,tests}: this-cli + {base,build,clang,ctest,grind,ctestwin}: cmake + {base,build,clang,ctest,grind,ctestwin}: ninja lint: cpplint grind: ValgrindCI + lcov: lcov_cobertura commands_pre = - {build,clang}: mkdir -p {toxinidir}/build + {build,clang}: cmake -E make_directory {toxinidir}/build commands = - abc: make -j4 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} abc - tests: make -j4 ABC_USE_PIC=1 {posargs:'ABC_USE_NAMESPACE=xxx'} test - clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DCMAKE_TOOLCHAIN_FILE=../tools/clang_toolchain.cmake ..' - build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE=xxx -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_PREFIX=$PREFIX ..' - {build,clang}: bash -c 'cmake --build . --target abc -j $(nproc)' - {build,clang}: bash -c 'ctest -V --test-dir ./' + abc: make -j4 ABC_USE_PIC=1 {posargs} abc + abc: make -j4 {posargs} libabc.a + soname: make -j4 ABC_USE_PIC=1 ABC_USE_SONAME=1 {posargs} lib + tests: make test + # demo requires CC, CXX set in environment or on cmd line + # eg: CC=gcc CXX=g++ tox -e demo + demo: bash -c '$CC {posargs} -Wall -c src/demo.c -o demo.o' + demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' + demo: ./demo i10.aig + {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' + base: bash -c 'cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX=$PREFIX -S . -B build' + base: cmake --build build --target install + build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=$ABC_USE_SONAME -DCMAKE_INSTALL_PREFIX=$PREFIX ..' + clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF ..' + {build}: bash -c 'cmake --build . -j $(nproc)' + {clang}: bash -c 'cmake --build . --target coverage -j $(nproc)' + {build}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' + {clang}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' + lcov: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml build: cmake --build . --target install - ctest: bash -c 'ctest -j $(nproc) --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=xxx -DCMAKE_BUILD_TYPE=Debug --test-command ctest --rerun-failed --output-on-failure -V' + {base,build}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' + ctest: bash -c 'ctest -j $(nproc) --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE=$BUILD_TYPE --test-command ctest --rerun-failed --output-on-failure -V' + ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V + ctest: bash -c 'ls -lh build/base_test build/libabc.* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' - grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DABC_USE_NAMESPACE=xxx -DCMAKE_BUILD_TYPE=Debug' + grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DCMAKE_BUILD_TYPE=Debug' grind: bash -c 'cmake --build build --target abc -j $(nproc)' grind: bash -c 'valgrind --tool=memcheck --xml=yes --xml-file=abc_check.xml --leak-check=full --show-leak-kinds=definite,possible --error-exitcode=127 ./build/src/base/main/abc "-c" "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"' grind: valgrind-ci abc_check.xml --number-of-errors grind: valgrind-ci abc_check.xml --summary - unbuild: bash -c 'rm -rf build/ abc_check.xml' + unbuild: bash -c 'rm -rf build/ *.xml *.blif *.profraw' clean: make clean From 5bb52d2d8cac8be4d8f5b9328e74242fc38ee9a7 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 22 Jul 2023 19:18:00 -0700 Subject: [PATCH 09/35] fix: dev: run manual cmake commands from build dir on macos * remove the linker optimization arg for gnu on macos * remove GH workflow warning annotations, bump action versions Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 9 +++++---- .github/workflows/conda-dev.yml | 6 +++--- .github/workflows/win.yml | 2 +- tox.ini | 21 ++++++++++----------- 4 files changed, 19 insertions(+), 19 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 89738ac311..f47c0e1c76 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -70,16 +70,17 @@ jobs: toxcmd: "base Xcode" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 with: fetch-depth: 0 - - uses: actions/setup-python@v2 + - uses: actions/setup-python@v4 with: python-version: ${{ matrix.python-version }} - name: Update CMake - uses: jwlawson/actions-setup-cmake@v1.8 + uses: jwlawson/actions-setup-cmake@v1 + if: runner.os == 'Windows' - name: Install Tox run: | @@ -110,7 +111,7 @@ jobs: run: | tox -e ${{ matrix.toxcmd }} - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v3 if: matrix.name == 'ubuntu-20.04-clang' with: name: src_coverage_data diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 6e7c6379c3..1d9e9ecef5 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -38,16 +38,16 @@ jobs: CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Setup base python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 with: python-version: '3.x' - name: Cache conda id: cache - uses: actions/cache@v2 + uses: actions/cache@v3 env: # Increase this value to reset cache if environment.devenv.yml has not changed CACHE_NUMBER: 1 diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 855fd6820c..6acb67c1e3 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -23,7 +23,7 @@ jobs: run: shell: msys2 {0} steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Setup MinGW native environment uses: msys2/setup-msys2@v2 diff --git a/tox.ini b/tox.ini index 6b1d87bf7e..31076b1983 100644 --- a/tox.ini +++ b/tox.ini @@ -6,8 +6,8 @@ skipsdist = true [base] setenv = {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} - {abc,demo,soname,tests}: CXXFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} - {abc,demo,soname,tests}: LDFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG -Wl,-O1 -Wl,--as-needed} + {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-march=native -O2 -g -DNDEBUG} + {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-march=native -O2 -g -DNDEBUG} {base,build,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} {base,build,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} {base,build,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} @@ -51,7 +51,7 @@ allowlist_externals = {abc,demo,soname,tests,clean}: make changedir = - {build,clang}: build + {base,build,clang}: {toxinidir}/build deps = {abc,demo,soname,tests,lint,base,build,clang,ctest,grind,ctestwin}: pip>=21.3 @@ -60,10 +60,10 @@ deps = {base,build,clang,ctest,grind,ctestwin}: ninja lint: cpplint grind: ValgrindCI - lcov: lcov_cobertura + clang: lcov_cobertura commands_pre = - {build,clang}: cmake -E make_directory {toxinidir}/build + {base,build,clang}: cmake -E make_directory {toxinidir}/build commands = abc: make -j4 ABC_USE_PIC=1 {posargs} abc @@ -76,16 +76,15 @@ commands = demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' demo: ./demo i10.aig {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' - base: bash -c 'cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX=$PREFIX -S . -B build' - base: cmake --build build --target install + base: bash -c 'cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX=$PREFIX ..' + base: bash -c 'cmake --build . --target install -j $(nproc)' build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=$ABC_USE_SONAME -DCMAKE_INSTALL_PREFIX=$PREFIX ..' clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF ..' {build}: bash -c 'cmake --build . -j $(nproc)' {clang}: bash -c 'cmake --build . --target coverage -j $(nproc)' - {build}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' - {clang}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' - lcov: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml - build: cmake --build . --target install + {build,clang}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' + clang: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml + {base,build}: cmake --build . --target install {base,build}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: bash -c 'ctest -j $(nproc) --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE=$BUILD_TYPE --test-command ctest --rerun-failed --output-on-failure -V' ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V From eb22baca6657843b8b87fb7526fa4322b1f33da4 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 22 Jul 2023 17:15:52 -0700 Subject: [PATCH 10/35] post-rebase generate/update CMakeLists.txt files, update tox file * updates tox argument syntax on macos * also restores missing OS list in conda-dev workflow Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 2 +- .github/workflows/conda-dev.yml | 1 + src/aig/gia/CMakeLists.txt | 2 ++ src/base/abci/CMakeLists.txt | 1 + src/base/io/CMakeLists.txt | 1 + tox.ini | 2 +- 6 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f47c0e1c76..445f190627 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -67,7 +67,7 @@ jobs: os: macOS-11 compiler: xcode version: "12.4" - toxcmd: "base Xcode" + toxcmd: "base -- Xcode" steps: - uses: actions/checkout@v3 diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 1d9e9ecef5..912d5f31f0 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -15,6 +15,7 @@ jobs: strategy: fail-fast: false matrix: + os: ['ubuntu-22.04', 'ubuntu-20.04', 'macOS-11', 'windows-2019'] python-version: ['3.9'] use_namespace: [false, true] include: diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index 916941dc6b..c148415eb6 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -85,12 +85,14 @@ abc_libabc_add_sources( giaCSat3.c giaEra2.c giaIff.c + giaTranStoch.c giaSpeedup.c giaAiger.c gia.c giaDfs.c giaShrink7.c giaMem.c + giaTransduction.cpp giaSupMin.c giaStoch.c giaJf.c diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index 8ffcbb7eee..32fc0bde14 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -3,6 +3,7 @@ abc_libabc_add_sources( SOURCES abcFx.c abcLutmin.c + abcOrchestration.c abcMap.c abcExtract.c abcBm.c diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index 118c9f9d94..30f90ab904 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -13,6 +13,7 @@ abc_libabc_add_sources( ioWriteVerilog.c ioReadPlaMo.c ioWritePla.c + ioWriteEdgelist.c ioWriteBaf.c ioWriteBench.c ioReadEdif.c diff --git a/tox.ini b/tox.ini index 31076b1983..2a1d18bc1f 100644 --- a/tox.ini +++ b/tox.ini @@ -74,7 +74,7 @@ commands = # eg: CC=gcc CXX=g++ tox -e demo demo: bash -c '$CC {posargs} -Wall -c src/demo.c -o demo.o' demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' - demo: ./demo i10.aig + demo: bash -c './demo i10.aig' {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' base: bash -c 'cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX=$PREFIX ..' base: bash -c 'cmake --build . --target install -j $(nproc)' From e8e2bad43dc3b2bc33a2742947f46c48dc117fcd Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 23 Jul 2023 11:24:58 -0700 Subject: [PATCH 11/35] fix timespec redefinition errors on windows * win pthreads module tries to define timespec if HAVE_STRUCT_TIMESPEC is not defined except msys/mingw already defines it Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2333ae19e3..e5c4cbd308 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -175,16 +175,16 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") "_MBCS" "_SCL_SECURE_NO_WARNINGS" "_CRT_SECURE_NO_WARNINGS" - "HAVE_STRUCT_TIMESPEC" "_XKEYCHECK_H" ) endif() if(WIN32) if(MINGW OR MSYS) - add_definitions(-DWIN32 -D__MINGW32__) + add_definitions(-DWIN32 -D__MINGW32__ -DHAVE_STRUCT_TIMESPEC) endif() target_compile_definitions(abc_interface INTERFACE + $<$:HAVE_STRUCT_TIMESPEC> $<$:ABC_DLL=ABC_DLLEXPORT> $<$>:WIN32_NO_DLL> $<$>:ABC_NO_DYNAMIC_LINKING> From 1b30a60a22e2c3887884b4c10e88ad5ca165d68f Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Thu, 30 Nov 2023 18:37:00 -0800 Subject: [PATCH 12/35] chg: dev: add (new) generated cmake sources Signed-off-by: Stephen L Arnold --- src/aig/aig/CMakeLists.txt | 48 ++++---- src/aig/gia/CMakeLists.txt | 186 +++++++++++++++---------------- src/aig/hop/CMakeLists.txt | 14 +-- src/aig/ioa/CMakeLists.txt | 4 +- src/aig/ivy/CMakeLists.txt | 30 ++--- src/aig/saig/CMakeLists.txt | 38 +++---- src/base/abc/CMakeLists.txt | 28 ++--- src/base/abci/CMakeLists.txt | 128 ++++++++++----------- src/base/acb/CMakeLists.txt | 10 +- src/base/bac/CMakeLists.txt | 18 +-- src/base/cba/CMakeLists.txt | 6 +- src/base/cmd/CMakeLists.txt | 12 +- src/base/exor/CMakeLists.txt | 6 +- src/base/io/CMakeLists.txt | 50 ++++----- src/base/pla/CMakeLists.txt | 6 +- src/base/ver/CMakeLists.txt | 4 +- src/base/wlc/CMakeLists.txt | 22 ++-- src/base/wln/CMakeLists.txt | 16 +-- src/bdd/bbr/CMakeLists.txt | 2 +- src/bdd/cudd/CMakeLists.txt | 94 ++++++++-------- src/bdd/dsd/CMakeLists.txt | 6 +- src/bdd/extrab/CMakeLists.txt | 14 +-- src/bdd/llb/CMakeLists.txt | 30 ++--- src/bdd/mtr/CMakeLists.txt | 2 +- src/bdd/reo/CMakeLists.txt | 12 +- src/bool/bdc/CMakeLists.txt | 4 +- src/bool/dec/CMakeLists.txt | 4 +- src/bool/kit/CMakeLists.txt | 16 +-- src/bool/lucky/CMakeLists.txt | 8 +- src/bool/rsb/CMakeLists.txt | 2 +- src/map/amap/CMakeLists.txt | 16 +-- src/map/cov/CMakeLists.txt | 6 +- src/map/fpga/CMakeLists.txt | 16 +-- src/map/if/CMakeLists.txt | 34 +++--- src/map/mapper/CMakeLists.txt | 20 ++-- src/map/mio/CMakeLists.txt | 10 +- src/map/mpm/CMakeLists.txt | 12 +- src/map/scl/CMakeLists.txt | 10 +- src/map/super/CMakeLists.txt | 4 +- src/misc/bzlib/CMakeLists.txt | 6 +- src/misc/espresso/CMakeLists.txt | 58 +++++----- src/misc/extra/CMakeLists.txt | 26 ++--- src/misc/mvc/CMakeLists.txt | 16 +-- src/misc/tim/CMakeLists.txt | 2 +- src/misc/util/CMakeLists.txt | 8 +- src/misc/zlib/CMakeLists.txt | 20 ++-- src/opt/cgt/CMakeLists.txt | 6 +- src/opt/csw/CMakeLists.txt | 2 +- src/opt/cut/CMakeLists.txt | 8 +- src/opt/dar/CMakeLists.txt | 8 +- src/opt/dau/CMakeLists.txt | 14 +-- src/opt/fret/CMakeLists.txt | 2 +- src/opt/fsim/CMakeLists.txt | 8 +- src/opt/fxch/CMakeLists.txt | 4 +- src/opt/fxu/CMakeLists.txt | 14 +-- src/opt/lpk/CMakeLists.txt | 10 +- src/opt/mfs/CMakeLists.txt | 8 +- src/opt/nwk/CMakeLists.txt | 18 +-- src/opt/res/CMakeLists.txt | 6 +- src/opt/ret/CMakeLists.txt | 8 +- src/opt/rwr/CMakeLists.txt | 6 +- src/opt/rwt/CMakeLists.txt | 2 +- src/opt/sbd/CMakeLists.txt | 12 +- src/opt/sfm/CMakeLists.txt | 12 +- src/opt/sim/CMakeLists.txt | 10 +- src/phys/place/CMakeLists.txt | 10 +- src/proof/abs/CMakeLists.txt | 22 ++-- src/proof/acec/CMakeLists.txt | 24 ++-- src/proof/cec/CMakeLists.txt | 27 ++--- src/proof/dch/CMakeLists.txt | 8 +- src/proof/fra/CMakeLists.txt | 24 ++-- src/proof/fraig/CMakeLists.txt | 14 +-- src/proof/int/CMakeLists.txt | 14 +-- src/proof/int2/CMakeLists.txt | 2 +- src/proof/live/CMakeLists.txt | 10 +- src/proof/pdr/CMakeLists.txt | 10 +- src/proof/ssc/CMakeLists.txt | 6 +- src/proof/ssw/CMakeLists.txt | 26 ++--- src/sat/bmc/CMakeLists.txt | 50 ++++----- src/sat/bsat/CMakeLists.txt | 16 +-- src/sat/bsat2/CMakeLists.txt | 10 +- src/sat/cnf/CMakeLists.txt | 10 +- src/sat/glucose/CMakeLists.txt | 4 +- src/sat/glucose2/CMakeLists.txt | 6 +- src/sat/msat/CMakeLists.txt | 16 +-- 85 files changed, 776 insertions(+), 775 deletions(-) diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt index 1db00e8266..2676c786fa 100644 --- a/src/aig/aig/CMakeLists.txt +++ b/src/aig/aig/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME aig_aig SOURCES - aigCuts.c - aigCheck.c - aigUtil.c - aigOper.c - aigMem.c - aigTable.c - aigMffc.c + aigPartReg.c + aigCanon.c + aigDfs.c + aigSplit.c + aigTruth.c aigInter.c - aigRepr.c - aigPack.c - aigOrder.c + aigTable.c aigWin.c - aigRetF.c - aigSplit.c + aigTsim.c + aigUtil.c aigPartSat.c - aigScl.c - aigDup.c - aigPart.c - aigCanon.c - aigPartReg.c - aigShow.c - aigFrames.c - aigJust.c aigObj.c - aigTruth.c - aigTsim.c - aigRet.c + aigPack.c + aigMem.c aigFanout.c - aigDfs.c aigTiming.c + aigPart.c + aigShow.c + aigRet.c + aigDup.c + aigScl.c + aigRepr.c + aigCheck.c + aigOper.c aigMan.c + aigFrames.c + aigMffc.c + aigJust.c + aigRetF.c + aigOrder.c + aigCuts.c ) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index c148415eb6..113b169d12 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -1,117 +1,117 @@ abc_libabc_add_sources( NAME aig_gia SOURCES - giaRetime.c + giaMuxes.c + giaFx.c + giaSatLut.c + giaShow.c + giaIiff.c + giaLf.c + giaCut.c + giaSupps.c + giaAiger.c + giaAgi.c + giaCSat2.c + giaAig.c + giaBalAig.c + giaSatEdge.c giaCCof.c - giaSupp.c - giaEsop.c - giaCSatOld.c - giaPf.c - giaOf.c - giaDup.c - giaCTas.c - giaShrink.c - giaSweeper.c - giaIso.c - giaAigerExt.c + gia.c + giaExist.c giaKf.c - giaQbf.c - giaUnate.c - giaBalLut.c giaCone.c - giaSim2.c - giaFront.c - giaBalAig.c - giaTis.c - giaAig.c - giaSat3.c - giaSimBase.c - giaGen.c - giaMfs.c giaIso2.c - giaCex.c + giaReshape1.c + giaSpeedup.c + giaMf.c + giaFalse.c + giaAigerExt.c + giaOf.c + giaCSatP.c + giaEra2.c giaTtopt.cpp - giaScript.c - giaIf.c - giaReshape2.c - giaSatLut.c - giaStr.c - giaMini.c - giaAgi.c + giaShrink.c giaSif.c - giaFanout.c - giaTsim.c - giaSatSyn.c - giaBalMap.c - giaFrames.c - giaExist.c + giaResub2.c + giaCSat.c + giaFront.c + giaTis.c + giaTim.c + giaDup.c + giaGlitch.c + giaCof.c + giaScl.c + giaRex.c + giaSatLE.c + giaBidec.c giaEra.c - giaSplit.c - giaIiff.c - giaEquiv.c - giaShow.c + giaUnate.c + giaDecs.c + giaQbf.c + giaCTas.c + giaSweep.c + giaMini.c + giaReshape2.c + giaForce.c + giaTransduction.cpp + giaJf.c + giaGig.c giaMan.c - giaHash.c + giaSupMin.c + giaResub3.c + giaDeep.c giaPat.c + giaCSat3.c + giaMinLut2.c + giaShrink6.c giaIso3.c - giaFx.c - giaScl.c + giaStr.c + giaSwitch.c + giaUtil.c giaResub6.c giaResub.c - giaSatLE.c - giaMuxes.c - giaTruth.c - giaGlitch.c - giaSatEdge.c - giaSort.c - giaFalse.c - giaResub2.c - giaGig.c - giaMinLut2.c - giaBidec.c - giaSupps.c + giaEdge.c + giaSupp.c + giaSatSyn.c + giaScript.c + giaEmbed.c + giaMinLut.c + giaSim2.c + giaSweeper.c + giaCex.c giaSatMap.c + giaMfs.c + giaTranStoch.c + giaTruth.c + giaNf.c + giaSat3.c + giaIf.c giaStg.c giaEnable.c - giaCof.c - giaReshape1.c - giaMf.c + giaEsop.c + giaSimBase.c + giaHash.c + giaCSatOld.c + giaMem.c giaPack.c + giaFanout.c + giaSplit.c giaSim.c - giaCSatP.c - giaUtil.c - giaDeep.c - giaRex.c - giaCSat3.c - giaEra2.c - giaIff.c - giaTranStoch.c - giaSpeedup.c - giaAiger.c - gia.c - giaDfs.c - giaShrink7.c - giaMem.c - giaTransduction.cpp - giaSupMin.c - giaStoch.c - giaJf.c giaSatoko.c - giaResub3.c - giaCSat.c - giaTim.c - giaEdge.c - giaShrink6.c - giaLf.c - giaDecs.c - giaSwitch.c - giaForce.c - giaMinLut.c - giaCut.c - giaNf.c - giaCSat2.c + giaIff.c giaPat2.c + giaTsim.c + giaStoch.c + giaRetime.c + giaGen.c + giaEquiv.c + giaDfs.c + giaFrames.c giaClp.c - giaEmbed.c - giaSweep.c + giaBalLut.c + giaSort.c + giaPf.c + giaBalMap.c + giaShrink7.c + giaIso.c ) diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt index 0e51ac19a9..b7c69c6653 100644 --- a/src/aig/hop/CMakeLists.txt +++ b/src/aig/hop/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME aig_hop SOURCES + hopTruth.c + hopTable.c + hopMan.c + hopMem.c hopDfs.c - hopUtil.c - hopObj.c - hopCheck.c hopBalance.c - hopTable.c + hopCheck.c hopOper.c - hopMem.c - hopMan.c - hopTruth.c + hopObj.c + hopUtil.c ) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt index c547a36b6c..040b8625c8 100644 --- a/src/aig/ioa/CMakeLists.txt +++ b/src/aig/ioa/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME aig_ioa SOURCES - ioaUtil.c - ioaReadAig.c ioaWriteAig.c + ioaReadAig.c + ioaUtil.c ) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt index 2d341be20f..ce757b4fdb 100644 --- a/src/aig/ivy/CMakeLists.txt +++ b/src/aig/ivy/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME aig_ivy SOURCES - ivyDsd.c - ivyBalance.c - ivyRwr.c + ivySeq.c + ivyMem.c ivyMan.c - ivyDfs.c + ivyMulti.c + ivyFraig.c ivyShow.c + ivyFastMap.c ivyCutTrav.c - ivyHaig.c - ivyFanout.c + ivyUtil.c + ivyCanon.c ivyResyn.c - ivyFastMap.c - ivyObj.c + ivyOper.c + ivyFanout.c + ivyHaig.c + ivyBalance.c + ivyRwr.c ivyCheck.c - ivyUtil.c + ivyObj.c ivyCut.c - ivyMulti.c - ivySeq.c - ivyOper.c - ivyFraig.c + ivyDsd.c + ivyDfs.c ivyTable.c - ivyCanon.c - ivyMem.c ) diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt index f881487197..81024309bf 100644 --- a/src/aig/saig/CMakeLists.txt +++ b/src/aig/saig/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME aig_saig SOURCES - saigIsoSlow.c - saigIoa.c - saigInd.c - saigCone.c - saigSynch.c + saigSimFast.c saigWnd.c - saigDual.c - saigConstr.c - saigRetStep.c + saigCone.c saigTempor.c - saigIsoFast.c - saigIso.c + saigSynch.c + saigScl.c + saigConstr2.c + saigRetMin.c saigRetFwd.c + saigIoa.c + saigInd.c + saigSimMv.c + saigSwitch.c + saigIsoFast.c saigSimSeq.c - saigSimFast.c + saigDual.c saigOutDec.c + saigIsoSlow.c + saigDup.c + saigPhase.c + saigRetStep.c + saigStrSim.c saigMiter.c - saigSimMv.c + saigIso.c + saigConstr.c saigTrans.c - saigSwitch.c - saigConstr2.c - saigRetMin.c - saigStrSim.c - saigPhase.c - saigScl.c - saigDup.c ) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt index 325293df30..88794c8e85 100644 --- a/src/base/abc/CMakeLists.txt +++ b/src/base/abc/CMakeLists.txt @@ -1,27 +1,27 @@ abc_libabc_add_sources( NAME base_abc SOURCES + abcFanOrder.c abcFanio.c - abcNames.c abcHieGia.c - abcHie.c + abcFunc.c + abcLib.c abcNtk.c - abcMinBase.c - abcHieNew.c - abcBlifMv.c - abcHieCec.c - abcCheck.c - abcUtil.c abcDfs.c - abcFunc.c abcSop.c - abcAig.c + abcBlifMv.c + abcShow.c + abcCheck.c abcNetlist.c + abcRefs.c + abcUtil.c + abcHieNew.c abcLatch.c + abcHie.c + abcAig.c + abcHieCec.c + abcNames.c abcBarBuf.c - abcRefs.c + abcMinBase.c abcObj.c - abcFanOrder.c - abcShow.c - abcLib.c ) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index 32fc0bde14..5e506b1197 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -1,81 +1,81 @@ abc_libabc_add_sources( NAME base_abci SOURCES + abcDress3.c + abcFxu.c + abcTiming.c + abcBalance.c + abcDec.c + abcNpn.c + abcIfMux.c abcFx.c - abcLutmin.c - abcOrchestration.c - abcMap.c - abcExtract.c + abcAttach.c + abcQuant.c abcBm.c - abcOrder.c - abcUnate.c - abcQbf.c - abcMulti.c - abcIvy.c + abcBidec.c + abcPart.c abcLog.c - abcCollapse.c - abcMerge.c - abcFxu.c - abcLut.c - abcReach.c - abcCas.c - abcRpo.c + abcUnreach.c + abcFraig.c + abcProve.c + abcRefactor.c abcRec3.c - abcSymm.c + abcSweep.c + abcRunGen.c + abcLutmin.c + abcReorder.c abcDebug.c - abcScorr.c - abcEco.c + abcXsim.c + abcUnate.c + abcRestruct.c abcResub.c + abcRpo.c + abcMiter.c + abcMulti.c + abcEco.c abcReconv.c - abcIf.c - abcGen.c - abcTim.c - abcRestruct.c - abcExact.c - abcNtbdd.c - abcReorder.c - abcDress.c - abcHaig.c - abcQuant.c - abcDress3.c - abcDress2.c - abcIfMux.c - abcDec.c - abcNpnSave.c - abcRr.c - abcAttach.c - abcNpn.c - abcOdc.c - abcStrash.c + abcMerge.c abcMini.c - abcSaucy.c - abcDsd.c - abcSpeedup.c - abcRewrite.c - abcMfs.c - abcDetect.c - abcBidec.c - abcFraig.c - abcMiter.c + abcStrash.c abcPrint.c - abcSat.c - abcXsim.c - abcRefactor.c - abcRunGen.c - abc.c - abcBalance.c - abcCascade.c + abcRr.c abcRenode.c - abcSweep.c - abcIfif.c - abcProve.c - abcUnreach.c - abcBmc.c abcVerify.c - abcCut.c - abcPart.c - abcTiming.c + abcQbf.c + abcBmc.c + abcSymm.c + abcHaig.c + abcScorr.c + abc.c + abcDetect.c + abcAuto.c + abcMap.c + abcSat.c + abcGen.c + abcDsd.c abcDar.c + abcLut.c + abcIfif.c + abcCollapse.c + abcNpnSave.c + abcNtbdd.c + abcExtract.c + abcOrder.c + abcSaucy.c + abcCascade.c + abcOrchestration.c + abcOdc.c + abcDress.c + abcExact.c + abcCut.c + abcTim.c + abcIvy.c + abcCas.c + abcDress2.c abcSense.c - abcAuto.c + abcMfs.c + abcSpeedup.c + abcReach.c + abcIf.c + abcRewrite.c ) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt index 1576b7687c..e75177562a 100644 --- a/src/base/acb/CMakeLists.txt +++ b/src/base/acb/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME base_acb SOURCES + acbPush.c + acbFunc.c + acbUtil.c acbCom.c - acbSets.c acbAbc.c + acbTest.c acbMfs.c + acbSets.c acbAig.c - acbPush.c - acbTest.c - acbUtil.c - acbFunc.c ) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt index 36b6d7c7a4..b05a4d3ade 100644 --- a/src/base/bac/CMakeLists.txt +++ b/src/base/bac/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME base_bac SOURCES - bacWriteBlif.c - bacBac.c - bacWriteSmt.c + bacPtr.c + bacCom.c bacReadBlif.c bacReadSmt.c - bacCom.c - bacPrsBuild.c bacPrsTrans.c + bacWriteBlif.c bacLib.c - bacPtrAbc.c - bacNtk.c bacReadVer.c - bacPtr.c - bacWriteVer.c + bacPtrAbc.c bacBlast.c + bacWriteSmt.c + bacPrsBuild.c + bacWriteVer.c + bacNtk.c + bacBac.c ) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt index befac34d35..2877965c93 100644 --- a/src/base/cba/CMakeLists.txt +++ b/src/base/cba/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME base_cba SOURCES - cbaNtk.c cbaCba.c cbaCom.c + cbaReadVer.c + cbaReadBlif.c cbaWriteVer.c cbaBlast.c cbaWriteBlif.c - cbaReadBlif.c - cbaReadVer.c + cbaNtk.c ) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt index 64d2799714..56c4f7d648 100644 --- a/src/base/cmd/CMakeLists.txt +++ b/src/base/cmd/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME base_cmd SOURCES - cmdHist.c - cmd.c + cmdAlias.c + cmdAuto.c cmdUtils.c cmdStarter.c - cmdAuto.c - cmdApi.c - cmdPlugin.c + cmd.c + cmdHist.c cmdLoad.c + cmdApi.c cmdFlag.c - cmdAlias.c + cmdPlugin.c ) diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt index 1b557068d6..d33e750390 100644 --- a/src/base/exor/CMakeLists.txt +++ b/src/base/exor/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME base_exor SOURCES - exorList.c + exor.c exorBits.c - exorCubes.c exorUtil.c - exor.c + exorList.c + exorCubes.c exorLink.c ) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index 30f90ab904..f7a73f69c4 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME base_io SOURCES - ioReadAiger.c - ioWriteGml.c - ioReadBlif.c - ioReadBlifMv.c - io.c - ioWriteBook.c - ioWriteBlifMv.c - ioReadEqn.c - ioReadBlifAig.c + ioReadBench.c + ioReadEdif.c ioWriteVerilog.c - ioReadPlaMo.c + ioWriteBench.c ioWritePla.c - ioWriteEdgelist.c + ioWriteGml.c + ioReadBblif.c + ioReadVerilog.c ioWriteBaf.c - ioWriteBench.c - ioReadEdif.c - ioJson.c - ioReadPla.c + ioReadDsd.c + ioWriteDot.c + io.c + ioWriteEdgelist.c + ioReadPlaMo.c + ioReadBaf.c ioWriteList.c - ioWriteEqn.c + ioJson.c + ioWriteAiger.c + ioWriteBook.c + ioWriteBblif.c + ioReadBlifMv.c + ioReadEqn.c ioUtil.c - ioReadBench.c + ioReadBlif.c + ioWriteEqn.c + ioReadPla.c + ioReadAiger.c + ioReadBlifAig.c ioWriteCnf.c - ioWriteBlif.c - ioReadBaf.c - ioWriteDot.c - ioReadVerilog.c - ioReadBblif.c + ioWriteBlifMv.c ioWriteSmv.c - ioReadDsd.c - ioWriteAiger.c - ioWriteBblif.c + ioWriteBlif.c ) diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt index 982ab09501..0211d0918d 100644 --- a/src/base/pla/CMakeLists.txt +++ b/src/base/pla/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME base_pla SOURCES + plaCom.c plaMerge.c + plaHash.c plaRead.c plaSimple.c - plaWrite.c - plaHash.c plaMan.c - plaCom.c + plaWrite.c ) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt index 76cd3f567e..a1ccc153bc 100644 --- a/src/base/ver/CMakeLists.txt +++ b/src/base/ver/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME base_ver SOURCES - verFormula.c verParse.c - verStream.c verCore.c + verStream.c + verFormula.c ) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt index 0002d18251..cdd41267ae 100644 --- a/src/base/wlc/CMakeLists.txt +++ b/src/base/wlc/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME base_wlc SOURCES - wlcBlast.c - wlcAbs.c + wlcNdr.c wlcPth.c - wlcGraft.c - wlcShow.c - wlcReadSmt.c - wlcUif.c - wlcStdin.c + wlcAbc.c wlcCom.c wlcJson.c - wlcNtk.c - wlcNdr.c - wlcSim.c + wlcStdin.c wlcReadVer.c + wlcNtk.c + wlcAbs.c + wlcBlast.c wlcMem.c + wlcReadSmt.c + wlcSim.c + wlcShow.c wlcAbs2.c - wlcAbc.c wlcWin.c wlcWriteVer.c + wlcGraft.c + wlcUif.c ) diff --git a/src/base/wln/CMakeLists.txt b/src/base/wln/CMakeLists.txt index 939486d31b..de52a9b46a 100644 --- a/src/base/wln/CMakeLists.txt +++ b/src/base/wln/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME base_wln SOURCES + wlnRetime.c wlnRead.c + wlnWlc.c + wlnRtl.c wlnMem.c - wlnNtk.c wlnWriteVer.c - wlnCom.c + wlnNtk.c + wln.c + wlnGuide.c wlnObj.c - wlnNdr.c - wlnRtl.c wlnBlast.c - wlnGuide.c - wln.c - wlnRetime.c - wlnWlc.c + wlnNdr.c + wlnCom.c ) diff --git a/src/bdd/bbr/CMakeLists.txt b/src/bdd/bbr/CMakeLists.txt index bd867b8e39..95c8128eb1 100644 --- a/src/bdd/bbr/CMakeLists.txt +++ b/src/bdd/bbr/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME bdd_bbr SOURCES + bbrImage.c bbrCex.c bbrReach.c bbrNtbdd.c - bbrImage.c ) diff --git a/src/bdd/cudd/CMakeLists.txt b/src/bdd/cudd/CMakeLists.txt index c34556fbda..3741da9129 100644 --- a/src/bdd/cudd/CMakeLists.txt +++ b/src/bdd/cudd/CMakeLists.txt @@ -1,65 +1,65 @@ abc_libabc_add_sources( NAME bdd_cudd SOURCES - cuddGenCof.c + cuddSat.c + cuddMatMult.c + cuddWindow.c + cuddInteract.c cuddZddSetop.c + cuddZddIsop.c + cuddCompose.c cuddInit.c - cuddAPI.c - cuddGenetic.c - cuddLinear.c - cuddCache.c - cuddClip.c - cuddAddInv.c - cuddZddReord.c - cuddAddFind.c cuddSolve.c - cuddApa.c + cuddBddCorr.c + cuddZddPort.c + cuddZddGroup.c + cuddBddIte.c + cuddAndAbs.c + cuddSubsetHB.c + cuddReorder.c + cuddLinear.c + cuddGenCof.c cuddAnneal.c - cuddExact.c - cuddLiteral.c - cuddBddAbs.c - cuddWindow.c cuddAddAbs.c - cuddLCache.c - cuddZddPort.c - cuddHarwell.c + cuddAddFind.c + cuddUtil.c + cuddCof.c cuddLevelQ.c - cuddZddLin.c + cuddEssent.c + cuddClip.c + cuddCheck.c + cuddApa.c cuddSplit.c + cuddApprox.c + cuddZddUtil.c + cuddGroup.c + cuddZddLin.c + cuddHarwell.c cuddDecomp.c - cuddExport.c cuddAddNeg.c - cuddGroup.c - cuddSymmetry.c - cuddZddMisc.c - cuddBddIte.c - cuddPriority.c - cuddEssent.c cuddSubsetSP.c - cuddZddCount.c - cuddCheck.c - cuddZddGroup.c - cuddBddCorr.c - cuddAddApply.c - cuddCompose.c - cuddSubsetHB.c - cuddSat.c - cuddRef.c - cuddUtil.c - cuddCof.c - cuddZddIsop.c - cuddZddFuncs.c cuddAddWalsh.c - cuddApprox.c - cuddZddUtil.c - cuddSign.c - cuddTable.c + cuddAddApply.c + cuddCache.c + cuddGenetic.c + cuddExport.c + cuddZddMisc.c + cuddExact.c cuddBridge.c - cuddMatMult.c - cuddReorder.c + cuddZddCount.c + cuddAddIte.c cuddZddSymm.c - cuddInteract.c - cuddAndAbs.c + cuddLiteral.c + cuddZddReord.c + cuddSign.c + cuddBddAbs.c + cuddZddFuncs.c + cuddSymmetry.c + cuddAPI.c + cuddPriority.c + cuddRef.c + cuddLCache.c + cuddAddInv.c + cuddTable.c cuddRead.c - cuddAddIte.c ) diff --git a/src/bdd/dsd/CMakeLists.txt b/src/bdd/dsd/CMakeLists.txt index faf03444ba..93d42de977 100644 --- a/src/bdd/dsd/CMakeLists.txt +++ b/src/bdd/dsd/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME bdd_dsd SOURCES - dsdCheck.c - dsdProc.c - dsdTree.c dsdMan.c dsdLocal.c dsdApi.c + dsdTree.c + dsdCheck.c + dsdProc.c ) diff --git a/src/bdd/extrab/CMakeLists.txt b/src/bdd/extrab/CMakeLists.txt index f88ff090de..7fb972cd5d 100644 --- a/src/bdd/extrab/CMakeLists.txt +++ b/src/bdd/extrab/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME bdd_extrab SOURCES - extraBddTime.c - extraBddMisc.c + extraBddAuto.c extraBddImage.c - extraBddThresh.c extraBddCas.c - extraBddSymm.c - extraBddMaxMin.c - extraBddAuto.c extraBddUnate.c - extraBddKmap.c extraBddSet.c + extraBddMisc.c + extraBddSymm.c + extraBddKmap.c + extraBddTime.c + extraBddMaxMin.c + extraBddThresh.c ) diff --git a/src/bdd/llb/CMakeLists.txt b/src/bdd/llb/CMakeLists.txt index 2034129eb7..2ccd3b3561 100644 --- a/src/bdd/llb/CMakeLists.txt +++ b/src/bdd/llb/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME bdd_llb SOURCES - llb1Matrix.c - llb1Hint.c - llb1Constr.c - llb1Core.c - llb1Cluster.c + llb2Driver.c llb1Reach.c - llb2Image.c + llb1Cluster.c + llb1Core.c llb1Sched.c - llb2Driver.c - llb2Dump.c + llb3Nonlin.c + llb1Hint.c llb4Cex.c - llb2Flow.c - llb4Image.c llb4Nonlin.c - llb1Pivot.c + llb4Sweep.c llb3Image.c - llb1Group.c llb2Bad.c - llb3Nonlin.c - llb4Sweep.c - llb2Core.c + llb1Matrix.c + llb2Flow.c + llb1Group.c + llb2Image.c + llb1Pivot.c + llb1Constr.c + llb4Image.c llb1Man.c + llb2Core.c + llb2Dump.c ) diff --git a/src/bdd/mtr/CMakeLists.txt b/src/bdd/mtr/CMakeLists.txt index 634875995a..cf84703ef8 100644 --- a/src/bdd/mtr/CMakeLists.txt +++ b/src/bdd/mtr/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bdd_mtr SOURCES - mtrBasic.c mtrGroup.c + mtrBasic.c ) diff --git a/src/bdd/reo/CMakeLists.txt b/src/bdd/reo/CMakeLists.txt index 092b78496d..44e01f199b 100644 --- a/src/bdd/reo/CMakeLists.txt +++ b/src/bdd/reo/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME bdd_reo SOURCES - reoApi.c - reoProfile.c - reoSwap.c - reoUnits.c - reoCore.c reoShuffle.c - reoSift.c reoTransfer.c + reoSift.c + reoSwap.c + reoCore.c + reoUnits.c + reoProfile.c + reoApi.c ) diff --git a/src/bool/bdc/CMakeLists.txt b/src/bool/bdc/CMakeLists.txt index 77b3c7d009..bab8aecab8 100644 --- a/src/bool/bdc/CMakeLists.txt +++ b/src/bool/bdc/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME bool_bdc SOURCES - bdcSpfd.c bdcCore.c - bdcDec.c bdcTable.c + bdcSpfd.c + bdcDec.c ) diff --git a/src/bool/dec/CMakeLists.txt b/src/bool/dec/CMakeLists.txt index 7cc9dc51fe..dfbecf7c91 100644 --- a/src/bool/dec/CMakeLists.txt +++ b/src/bool/dec/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME bool_dec SOURCES + decMan.c decFactor.c - decAbc.c decPrint.c - decMan.c + decAbc.c decUtil.c ) diff --git a/src/bool/kit/CMakeLists.txt b/src/bool/kit/CMakeLists.txt index 74749640d2..0b256cf481 100644 --- a/src/bool/kit/CMakeLists.txt +++ b/src/bool/kit/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME bool_kit SOURCES - kitBdd.c + kitDsd.c + kitTruth.c kitCloud.c - kitGraph.c + kitBdd.c kitIsop.c - kitSop.c - kitHop.c - kitTruth.c - kitPla.c - kitDsd.c kitFactor.c - kitAig.c cloud.c + kitAig.c + kitPla.c + kitSop.c + kitHop.c + kitGraph.c ) diff --git a/src/bool/lucky/CMakeLists.txt b/src/bool/lucky/CMakeLists.txt index f51bb325cc..b186e342e3 100644 --- a/src/bool/lucky/CMakeLists.txt +++ b/src/bool/lucky/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME bool_lucky SOURCES - luckyRead.c - lucky.c + luckyFast16.c luckySimple.c + luckySwapIJ.c + luckyRead.c luckyFast6.c luckySwap.c - luckyFast16.c - luckySwapIJ.c + lucky.c ) diff --git a/src/bool/rsb/CMakeLists.txt b/src/bool/rsb/CMakeLists.txt index 7c3157ada7..57bf6b8fa0 100644 --- a/src/bool/rsb/CMakeLists.txt +++ b/src/bool/rsb/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bool_rsb SOURCES - rsbDec6.c rsbMan.c + rsbDec6.c ) diff --git a/src/map/amap/CMakeLists.txt b/src/map/amap/CMakeLists.txt index 864929dea1..912f4241ed 100644 --- a/src/map/amap/CMakeLists.txt +++ b/src/map/amap/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_amap SOURCES + amapOutput.c + amapCore.c amapRead.c - amapMatch.c - amapRule.c - amapGraph.c + amapMan.c amapLib.c + amapLiberty.c amapMerge.c + amapMatch.c amapPerm.c - amapUniq.c - amapLiberty.c amapParse.c - amapOutput.c - amapMan.c - amapCore.c + amapGraph.c + amapRule.c + amapUniq.c ) diff --git a/src/map/cov/CMakeLists.txt b/src/map/cov/CMakeLists.txt index 7933c77ad1..6d2f0106e4 100644 --- a/src/map/cov/CMakeLists.txt +++ b/src/map/cov/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_cov SOURCES + covMinSop.c + covMinEsop.c + covMinUtil.c covBuild.c covMinMan.c - covMinUtil.c - covMinEsop.c - covMinSop.c covCore.c covMan.c ) diff --git a/src/map/fpga/CMakeLists.txt b/src/map/fpga/CMakeLists.txt index 16eff7ce3d..cc5b96ba8c 100644 --- a/src/map/fpga/CMakeLists.txt +++ b/src/map/fpga/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_fpga SOURCES - fpgaUtils.c + fpgaFanout.c fpga.c - fpgaCreate.c - fpgaTime.c - fpgaLib.c fpgaTruth.c - fpgaSwitch.c - fpgaCutUtils.c - fpgaFanout.c - fpgaCut.c + fpgaLib.c fpgaMatch.c + fpgaCreate.c + fpgaTime.c fpgaVec.c + fpgaUtils.c + fpgaCut.c fpgaCore.c + fpgaCutUtils.c + fpgaSwitch.c ) diff --git a/src/map/if/CMakeLists.txt b/src/map/if/CMakeLists.txt index 8330f1770a..1572039fb9 100644 --- a/src/map/if/CMakeLists.txt +++ b/src/map/if/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME map_if SOURCES - ifTruth.c + ifDsd.c + ifLibLut.c + ifSeq.c + ifCut.c ifLibBox.c + ifMatch2.c ifTest.c - ifCore.c - ifCache.c ifSelect.c - ifDsd.c - ifTune.c - ifUtil.c + ifCore.c + ifTime.c ifData2.c ifReduce.c + ifCom.c + ifDec07.c + ifDec08.c ifDec16.c + ifDec75.c + ifTune.c + ifTruth.c ifDec10.c - ifDec08.c - ifSat.c + ifMap.c ifMan.c - ifLibLut.c - ifDec75.c + ifCache.c + ifSat.c + ifUtil.c ifDelay.c - ifSeq.c - ifDec07.c - ifCut.c - ifMatch2.c - ifTime.c - ifCom.c - ifMap.c ) diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt index 21a7465424..168154e6ec 100644 --- a/src/map/mapper/CMakeLists.txt +++ b/src/map/mapper/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME map_mapper SOURCES + mapperMatch.c + mapper.c + mapperSuper.c + mapperTable.c mapperRefs.c mapperTime.c - mapperLib.c - mapperTable.c - mapper.c - mapperUtils.c - mapperCutUtils.c - mapperTree.c mapperTruth.c + mapperCore.c mapperCreate.c + mapperCutUtils.c mapperSwitch.c - mapperCore.c mapperCut.c - mapperVec.c - mapperSuper.c - mapperMatch.c mapperCanon.c + mapperUtils.c + mapperTree.c + mapperLib.c + mapperVec.c ) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt index c727791989..ae9ecee8e0 100644 --- a/src/map/mio/CMakeLists.txt +++ b/src/map/mio/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_mio SOURCES - mioParse.c - mioRead.c - mio.c - mioUtils.c + mioFunc.c mioSop.c mioApi.c - mioFunc.c + mioUtils.c + mioParse.c + mio.c + mioRead.c ) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt index 80b8eedeee..27990a653c 100644 --- a/src/map/mpm/CMakeLists.txt +++ b/src/map/mpm/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_mpm SOURCES - mpmUtil.c - mpmAbc.c - mpmPre.c - mpmDsd.c - mpmMig.c + mpmTruth.c mpmGates.c + mpmAbc.c mpmMan.c + mpmMig.c + mpmUtil.c + mpmDsd.c mpmMap.c mpmLib.c + mpmPre.c mpmCore.c - mpmTruth.c ) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt index 196bf147be..ceb7aa6b14 100644 --- a/src/map/scl/CMakeLists.txt +++ b/src/map/scl/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_scl SOURCES - sclLoad.c - scl.c - sclSize.c sclDnsize.c + sclBufSize.c sclLibUtil.c + scl.c + sclSize.c + sclBuffer.c sclUpsize.c + sclLoad.c sclUtil.c sclLibScl.c - sclBufSize.c - sclBuffer.c sclLiberty.c ) diff --git a/src/map/super/CMakeLists.txt b/src/map/super/CMakeLists.txt index f827cecf65..97828f5a50 100644 --- a/src/map/super/CMakeLists.txt +++ b/src/map/super/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME map_super SOURCES - super.c - superAnd.c superGate.c + superAnd.c + super.c ) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt index c81fe80bf0..cf5ec56f60 100644 --- a/src/misc/bzlib/CMakeLists.txt +++ b/src/misc/bzlib/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME misc_bzlib SOURCES - decompress.c - crctable.c + huffman.c randtable.c compress.c + decompress.c blocksort.c bzlib.c - huffman.c + crctable.c ) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt index 2c96cbb42c..27d62c182a 100644 --- a/src/misc/espresso/CMakeLists.txt +++ b/src/misc/espresso/CMakeLists.txt @@ -1,43 +1,43 @@ abc_libabc_add_sources( NAME misc_espresso SOURCES - setc.c - exact.c - equiv.c - sparse.c - essen.c - globals.c - cvrmisc.c - cvrout.c - indep.c - primes.c - part.c + sminterf.c expand.c - cvrm.c + gasp.c + cofactor.c + cubehack.c + dominate.c unate.c - espresso.c - rows.c - reduce.c - map.c - cols.c + cvrm.c + equiv.c irred.c - cubehack.c - cvrin.c + cols.c + compl.c + part.c + exact.c + contain.c + matrix.c + cvrout.c pair.c - sminterf.c + indep.c + rows.c hack.c - matrix.c - cubestr.c - contain.c + setc.c set.c - sharp.c + essen.c + espresso.c mincov.c - gasp.c gimpel.c + globals.c + solution.c + sparse.c + primes.c + map.c + reduce.c opo.c - dominate.c - cofactor.c + cubestr.c + sharp.c + cvrmisc.c + cvrin.c verify.c - compl.c - solution.c ) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt index 76484819d6..56779e92c8 100644 --- a/src/misc/extra/CMakeLists.txt +++ b/src/misc/extra/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME misc_extra SOURCES - extraUtilTruth.c - extraUtilMaj.c - extraUtilMemory.c - extraUtilProgress.c - extraUtilUtil.c + extraUtilCfs.c extraUtilReader.c + extraUtilDsd.c extraUtilPath.c - extraUtilBitMatrix.c + extraUtilUtil.c extraUtilGen.c - extraUtilCanon.c - extraUtilDsd.c - extraUtilCfs.c + extraUtilPerm.c extraUtilEnum.c - extraUtilMisc.c - extraUtilFile.c - extraUtilMult.c + extraUtilBitMatrix.c + extraUtilTruth.c extraUtilMacc.c + extraUtilMult.c + extraUtilCanon.c + extraUtilFile.c + extraUtilMisc.c + extraUtilMaj.c + extraUtilProgress.c extraUtilCube.c extraUtilSupp.c - extraUtilPerm.c + extraUtilMemory.c ) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt index 496140f9f2..264d321b46 100644 --- a/src/misc/mvc/CMakeLists.txt +++ b/src/misc/mvc/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_mvc SOURCES + mvcUtils.c mvcApi.c - mvcOpAlg.c - mvcMan.c - mvcCompare.c - mvcPrint.c + mvcSort.c mvcDivide.c + mvcPrint.c mvcLits.c - mvcDivisor.c + mvcOpAlg.c + mvcCompare.c mvcList.c - mvcOpBool.c mvcContain.c - mvcSort.c - mvcUtils.c mvcCube.c + mvcOpBool.c + mvcMan.c mvcCover.c + mvcDivisor.c ) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt index d3cd3dd31b..e77b041b7e 100644 --- a/src/misc/tim/CMakeLists.txt +++ b/src/misc/tim/CMakeLists.txt @@ -3,7 +3,7 @@ abc_libabc_add_sources( SOURCES timDump.c timMan.c + timTrav.c timBox.c timTime.c - timTrav.c ) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt index d187da49b5..d64f7e0e47 100644 --- a/src/misc/util/CMakeLists.txt +++ b/src/misc/util/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME misc_util SOURCES - utilIsop.c - utilNam.c - utilFile.c utilSort.c - utilCex.c + utilIsop.c utilSignal.c utilColor.c + utilNam.c utilBridge.c + utilCex.c + utilFile.c ) diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt index 22adb0ee78..3f393228c0 100644 --- a/src/misc/zlib/CMakeLists.txt +++ b/src/misc/zlib/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_zlib SOURCES - deflate.c - compress_.c - inflate.c - uncompr.c - gzclose.c - gzread.c - inftrees.c inffast.c - crc32.c - adler32.c gzwrite.c + inftrees.c + adler32.c + crc32.c + gzlib.c + deflate.c zutil.c + inflate.c + gzclose.c trees.c - gzlib.c + gzread.c infback.c + uncompr.c + compress_.c ) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt index 09618127a4..3419470b54 100644 --- a/src/opt/cgt/CMakeLists.txt +++ b/src/opt/cgt/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME opt_cgt SOURCES - cgtCore.c - cgtSat.c - cgtAig.c cgtMan.c cgtDecide.c + cgtAig.c + cgtCore.c + cgtSat.c ) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt index ec48bba053..4f2566b766 100644 --- a/src/opt/csw/CMakeLists.txt +++ b/src/opt/csw/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_csw SOURCES - cswCut.c cswTable.c + cswCut.c cswCore.c cswMan.c ) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt index 8720329caa..c9902c61b2 100644 --- a/src/opt/cut/CMakeLists.txt +++ b/src/opt/cut/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_cut SOURCES - cutPre22.c - cutCut.c - cutApi.c cutOracle.c + cutApi.c cutNode.c + cutSeq.c + cutPre22.c cutMerge.c cutTruth.c - cutSeq.c + cutCut.c cutMan.c ) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt index f391522599..654d57dab0 100644 --- a/src/opt/dar/CMakeLists.txt +++ b/src/opt/dar/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_dar SOURCES + darCut.c + darScript.c + darRefact.c darCore.c - darPrec.c darData.c - darCut.c darBalance.c - darRefact.c darMan.c darLib.c - darScript.c + darPrec.c ) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt index 7df058a12f..7989632238 100644 --- a/src/opt/dau/CMakeLists.txt +++ b/src/opt/dau/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_dau SOURCES + dauNpn.c dauDsd.c - dauDivs.c - dauCore.c dauGia.c - dauCanon.c + dauCount.c dauNonDsd.c + dauDivs.c + dauNpn2.c + dauCore.c dauMerge.c - dauTree.c - dauCount.c dauEnum.c - dauNpn.c - dauNpn2.c + dauCanon.c + dauTree.c ) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt index 14a14d03a4..8774bb4908 100644 --- a/src/opt/fret/CMakeLists.txt +++ b/src/opt/fret/CMakeLists.txt @@ -2,7 +2,7 @@ abc_libabc_add_sources( NAME opt_fret SOURCES fretInit.c + fretFlow.c fretTime.c fretMain.c - fretFlow.c ) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt index ea8a9d3b17..53b06a2a8a 100644 --- a/src/opt/fsim/CMakeLists.txt +++ b/src/opt/fsim/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME opt_fsim SOURCES - fsimFront.c - fsimSwitch.c + fsimTsim.c fsimCore.c - fsimSim.c + fsimSwitch.c fsimMan.c - fsimTsim.c + fsimFront.c + fsimSim.c ) diff --git a/src/opt/fxch/CMakeLists.txt b/src/opt/fxch/CMakeLists.txt index 1ba0e72e8c..def3fcbf7a 100644 --- a/src/opt/fxch/CMakeLists.txt +++ b/src/opt/fxch/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fxch SOURCES - Fxch.c - FxchDiv.c FxchSCHashTable.c + FxchDiv.c + Fxch.c FxchMan.c ) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt index c8dac35096..c361a3cbe2 100644 --- a/src/opt/fxu/CMakeLists.txt +++ b/src/opt/fxu/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_fxu SOURCES - fxuHeapD.c fxuHeapS.c - fxuList.c - fxuMatrix.c - fxuUpdate.c fxuSelect.c - fxuPrint.c - fxuCreate.c + fxuUpdate.c + fxuList.c + fxuHeapD.c fxu.c + fxuSingle.c fxuReduce.c fxuPair.c - fxuSingle.c + fxuPrint.c + fxuCreate.c + fxuMatrix.c ) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt index 3a9e5e8cb3..0ec4669889 100644 --- a/src/opt/lpk/CMakeLists.txt +++ b/src/opt/lpk/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME opt_lpk SOURCES + lpkAbcMux.c lpkCore.c - lpkMan.c + lpkMulti.c lpkSets.c - lpkAbcUtil.c lpkAbcDsd.c - lpkMulti.c + lpkAbcUtil.c + lpkAbcDec.c lpkCut.c lpkMap.c - lpkAbcMux.c lpkMux.c - lpkAbcDec.c + lpkMan.c ) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt index 1c62f0f68b..333b317e7d 100644 --- a/src/opt/mfs/CMakeLists.txt +++ b/src/opt/mfs/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME opt_mfs SOURCES - mfsSat.c + mfsCore.c + mfsStrash.c mfsResub.c + mfsDiv.c mfsWin.c - mfsStrash.c - mfsCore.c mfsMan.c mfsInter.c - mfsDiv.c + mfsSat.c ) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt index 9d31400c50..ba9918990b 100644 --- a/src/opt/nwk/CMakeLists.txt +++ b/src/opt/nwk/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME opt_nwk SOURCES - nwkAig.c - nwkMap.c + nwkBidec.c + nwkStrash.c nwkTiming.c + nwkMan.c nwkFanio.c - nwkFlow.c - nwkCheck.c nwkUtil.c + nwkDfs.c + nwkMap.c + nwkFlow.c + nwkObj.c + nwkAig.c nwkSpeedup.c + nwkCheck.c nwkMerge.c - nwkBidec.c - nwkObj.c - nwkDfs.c - nwkMan.c - nwkStrash.c ) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt index 34a95ca143..260474a9ce 100644 --- a/src/opt/res/CMakeLists.txt +++ b/src/opt/res/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_res SOURCES + resStrash.c resSat.c - resDivs.c resFilter.c - resStrash.c resWin.c - resSim.c resCore.c + resSim.c + resDivs.c ) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt index f8833f0255..16514479ce 100644 --- a/src/opt/ret/CMakeLists.txt +++ b/src/opt/ret/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_ret SOURCES + retDelay.c retCore.c - retArea.c + retInit.c retLvalue.c - retFlow.c - retDelay.c retIncrem.c - retInit.c + retArea.c + retFlow.c ) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt index 102e1b3495..b7ef5b1166 100644 --- a/src/opt/rwr/CMakeLists.txt +++ b/src/opt/rwr/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_rwr SOURCES - rwrPrint.c rwrDec.c rwrExp.c - rwrEva.c rwrLib.c - rwrUtil.c + rwrPrint.c + rwrEva.c rwrMan.c + rwrUtil.c ) diff --git a/src/opt/rwt/CMakeLists.txt b/src/opt/rwt/CMakeLists.txt index 29f1e55cf4..a3c389875f 100644 --- a/src/opt/rwt/CMakeLists.txt +++ b/src/opt/rwt/CMakeLists.txt @@ -2,6 +2,6 @@ abc_libabc_add_sources( NAME opt_rwt SOURCES rwtMan.c - rwtDec.c rwtUtil.c + rwtDec.c ) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt index 0259254c8b..b618e8367b 100644 --- a/src/opt/sbd/CMakeLists.txt +++ b/src/opt/sbd/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sbd SOURCES - sbdWin.c - sbdPath.c - sbdCut2.c + sbdCore.c sbd.c - sbdCnf.c - sbdLut.c sbdCut.c + sbdCut2.c + sbdWin.c sbdSat.c - sbdCore.c + sbdPath.c + sbdLut.c + sbdCnf.c ) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt index 3d033d67d6..c03b1c141e 100644 --- a/src/opt/sfm/CMakeLists.txt +++ b/src/opt/sfm/CMakeLists.txt @@ -2,13 +2,13 @@ abc_libabc_add_sources( NAME opt_sfm SOURCES sfmCore.c - sfmDec.c - sfmTim.c - sfmSat.c + sfmMit.c sfmLib.c - sfmNtk.c - sfmArea.c sfmWin.c - sfmMit.c + sfmArea.c sfmCnf.c + sfmTim.c + sfmNtk.c + sfmDec.c + sfmSat.c ) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt index 126a3863e2..ae09e3c40d 100644 --- a/src/opt/sim/CMakeLists.txt +++ b/src/opt/sim/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sim SOURCES - simSwitch.c - simSymSat.c - simSymSim.c - simSym.c - simMan.c simSeq.c + simSymSim.c simUtils.c simSupp.c + simMan.c + simSwitch.c simSymStr.c + simSymSat.c + simSym.c ) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt index 0b92918631..841cd830f2 100644 --- a/src/phys/place/CMakeLists.txt +++ b/src/phys/place/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME phys_place SOURCES - place_bin.c + place_inc.c + place_qpsolver.c + place_pads.c place_genqp.c place_legalize.c place_partition.c + place_io.c + place_bin.c place_base.c place_gordian.c - place_inc.c - place_qpsolver.c - place_io.c - place_pads.c ) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt index 4544c4e3f9..2ad429538d 100644 --- a/src/proof/abs/CMakeLists.txt +++ b/src/proof/abs/CMakeLists.txt @@ -1,20 +1,20 @@ abc_libabc_add_sources( NAME proof_abs SOURCES - absIter.c - absRefSelect.c - absOut.c - absGla.c - absOldSim.c + absGlaOld.c + absPth.c absOldRef.c + absOldSim.c + absVta.c + absOldSat.c + absIter.c + absUtil.c + absRpmOld.c absOldCex.c + absGla.c absDup.c - absPth.c absRef.c - absUtil.c - absVta.c - absOldSat.c - absGlaOld.c absRpm.c - absRpmOld.c + absOut.c + absRefSelect.c ) diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt index bb8185d450..3df6fa529a 100644 --- a/src/proof/acec/CMakeLists.txt +++ b/src/proof/acec/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME proof_acec SOURCES - acecCl.c acec2Mult.c - acecCore.c - acecXor.c acecPo.c + acecOrder.c + acecSt.c + acecCl.c + acecMult.c + acecPolyn.c + acecPa.c acecPool.c acecUtil.c - acecSt.c - acecRe.c - acecBo.c + acecCore.c + acecTree.c acecCo.c acecNorm.c - acecPa.c - acecTree.c - acecFadds.c + acecBo.c acecCover.c - acecMult.c - acecPolyn.c - acecOrder.c + acecFadds.c + acecRe.c + acecXor.c ) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt index fd15a4a94d..869ca471ae 100644 --- a/src/proof/cec/CMakeLists.txt +++ b/src/proof/cec/CMakeLists.txt @@ -1,23 +1,24 @@ abc_libabc_add_sources( NAME proof_cec SOURCES + cecChoice.c + cecSolve.c cecSatG3.c - cecSim.c - cecCorr.c - cecSynth.c - cecIso.c cecMan.c - cecPat.c - cecSatG2.c - cecSeq.c cecSatG.c - cecSweep.c - cecSolve.c - cecSat.c - cecChoice.c - cecSolveG.c cecCec.c + cecProve.c cecCore.c - cecClass.c cecSplit.c + cecPat.c + cecSolveG.c + cecSweep.c + cecSeq.c + cecCorr.c + cecSynth.c + cecSatG2.c + cecSat.c + cecIso.c + cecSim.c + cecClass.c ) diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt index e32871b935..926db08cde 100644 --- a/src/proof/dch/CMakeLists.txt +++ b/src/proof/dch/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_dch SOURCES - dchSweep.c - dchChoice.c dchAig.c + dchSimSat.c dchSim.c dchSat.c + dchSweep.c + dchCore.c dchCnf.c dchClass.c - dchCore.c + dchChoice.c dchMan.c - dchSimSat.c ) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt index 7e4755bb4c..885e684f5f 100644 --- a/src/proof/fra/CMakeLists.txt +++ b/src/proof/fra/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME proof_fra SOURCES - fraSat.c - fraImp.c - fraSec.c - fraLcr.c - fraBmc.c fraSim.c - fraClass.c - fraClaus.c + fraInd.c fraCec.c + fraSec.c + fraClau.c + fraBmc.c + fraImp.c + fraCnf.c + fraLcr.c fraMan.c - fraInd.c - fraPart.c - fraHot.c + fraClass.c fraIndVer.c + fraSat.c fraCore.c - fraClau.c - fraCnf.c + fraPart.c + fraHot.c + fraClaus.c ) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt index 1238302f0d..fb6c1e991e 100644 --- a/src/proof/fraig/CMakeLists.txt +++ b/src/proof/fraig/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME proof_fraig SOURCES + fraigCanon.c + fraigApi.c + fraigTable.c fraigUtil.c fraigFanout.c - fraigFeed.c + fraigMem.c + fraigPrime.c + fraigVec.c fraigMan.c + fraigFeed.c fraigNode.c - fraigApi.c - fraigVec.c - fraigPrime.c - fraigCanon.c fraigSat.c - fraigMem.c - fraigTable.c ) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt index d83124a90e..358d240af1 100644 --- a/src/proof/int/CMakeLists.txt +++ b/src/proof/int/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_int SOURCES - intFrames.c - intInter.c + intContain.c + intMan.c + intCtrex.c + intUtil.c + intCheck.c intCore.c intM114.c - intUtil.c + intFrames.c + intInter.c intDup.c - intCtrex.c - intContain.c - intCheck.c - intMan.c ) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt index e76bac5087..eeb9632275 100644 --- a/src/proof/int2/CMakeLists.txt +++ b/src/proof/int2/CMakeLists.txt @@ -3,6 +3,6 @@ abc_libabc_add_sources( SOURCES int2Core.c int2Util.c - int2Refine.c int2Bmc.c + int2Refine.c ) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt index aa92acb388..36871b807a 100644 --- a/src/proof/live/CMakeLists.txt +++ b/src/proof/live/CMakeLists.txt @@ -3,11 +3,11 @@ abc_libabc_add_sources( SOURCES arenaViolation.c disjunctiveMonotone.c - kLiveConstraints.c - monotone.c - liveness.c - ltl_parser.c - liveness_sim.c combination.c + ltl_parser.c + kLiveConstraints.c kliveness.c + liveness_sim.c + liveness.c + monotone.c ) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt index 9cd811b3d9..d523b5ea31 100644 --- a/src/proof/pdr/CMakeLists.txt +++ b/src/proof/pdr/CMakeLists.txt @@ -3,12 +3,12 @@ abc_libabc_add_sources( SOURCES pdrCnf.c pdrTsim.c - pdrTsim3.c - pdrSat.c - pdrTsim2.c - pdrMan.c + pdrIncr.c pdrUtil.c + pdrTsim2.c pdrInv.c pdrCore.c - pdrIncr.c + pdrMan.c + pdrSat.c + pdrTsim3.c ) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt index 441c4730ea..bff9a89169 100644 --- a/src/proof/ssc/CMakeLists.txt +++ b/src/proof/ssc/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME proof_ssc SOURCES - sscCore.c - sscSat.c sscSim.c - sscUtil.c sscClass.c + sscUtil.c + sscSat.c + sscCore.c ) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt index e42b02517d..1493995bf2 100644 --- a/src/proof/ssw/CMakeLists.txt +++ b/src/proof/ssw/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_ssw SOURCES - sswDyn.c - sswCnf.c - sswAig.c + sswConstr.c + sswIslands.c + sswLcorr.c sswPart.c - sswRarity.c - sswSimSat.c + sswBmc.c sswMan.c - sswLcorr.c - sswPairs.c - sswSemi.c + sswAig.c sswSweep.c - sswIslands.c sswSim.c - sswConstr.c - sswUnique.c + sswCnf.c sswClass.c + sswSimSat.c + sswDyn.c + sswPairs.c sswCore.c - sswFilter.c sswSat.c - sswBmc.c + sswUnique.c + sswSemi.c + sswRarity.c + sswFilter.c ) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt index 545fd83c6e..20a72e89a1 100644 --- a/src/sat/bmc/CMakeLists.txt +++ b/src/sat/bmc/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME sat_bmc SOURCES - bmcCexTools.c - bmcMaj3.c - bmcUnroll.c - bmcEco.c - bmcMaj.c + bmcCexCut.c + bmcBmc2.c bmcInse.c - bmcChain.c - bmcClp.c - bmcGen.c - bmcCexMin2.c - bmcBmcG.c - bmcBCore.c - bmcCexMin1.c + bmcBmc.c bmcMaxi.c - bmcExpand.c - bmcBmci.c + bmcBmcS.c + bmcBmc3.c bmcLoad.c + bmcBmci.c bmcFx.c - bmcCexDepth.c - bmcBmc.c - bmcMaj2.c + bmcMesh2.c + bmcICheck.c + bmcClp.c + bmcBCore.c + bmcMaj3.c + bmcGen.c + bmcCexMin2.c + bmcMaj.c + bmcCexCare.c bmcFault.c - bmcBmc2.c + bmcUnroll.c + bmcMaj2.c + bmcExpand.c + bmcCexMin1.c + bmcEco.c bmcMulti.c - bmcBmc3.c - bmcCexCare.c - bmcBmcAnd.c bmcMesh.c - bmcCexCut.c - bmcBmcS.c - bmcMesh2.c - bmcICheck.c + bmcCexTools.c + bmcCexDepth.c + bmcChain.c + bmcBmcAnd.c + bmcBmcG.c ) diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt index 2ef211b455..5485a9421c 100644 --- a/src/sat/bsat/CMakeLists.txt +++ b/src/sat/bsat/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME sat_bsat SOURCES - satInter.c + satSolver3.c satStore.c - satSolver2.c - satInterA.c - satSolver.c + satInter.c satUtil.c - satSolver2i.c - satInterP.c satTruth.c satMem.c + satInterA.c + satSolver2i.c satInterB.c - satSolver3.c - satProof.c + satSolver.c + satInterP.c satTrace.c + satProof.c + satSolver2.c ) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt index d097c47460..af83775db7 100644 --- a/src/sat/bsat2/CMakeLists.txt +++ b/src/sat/bsat2/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME sat_bsat2 SOURCES - MainSat.cpp - Options.cpp - AbcApi.cpp SimpSolver.cpp - Solver.cpp - System.cpp + AbcApi.cpp + Options.cpp + MainSat.cpp MainSimp.cpp + System.cpp + Solver.cpp ) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt index 2f068190a8..d1bb810f9c 100644 --- a/src/sat/cnf/CMakeLists.txt +++ b/src/sat/cnf/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME sat_cnf SOURCES - cnfFast.c + cnfCut.c cnfMap.c - cnfCore.c - cnfData.c cnfUtil.c + cnfFast.c + cnfData.c + cnfPost.c cnfMan.c - cnfCut.c cnfWrite.c - cnfPost.c + cnfCore.c ) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt index aea0027648..82e57750d3 100644 --- a/src/sat/glucose/CMakeLists.txt +++ b/src/sat/glucose/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose SOURCES - AbcGlucose.cpp - Options.cpp SimpSolver.cpp Glucose.cpp + Options.cpp System.cpp + AbcGlucose.cpp AbcGlucoseCmd.cpp ) diff --git a/src/sat/glucose2/CMakeLists.txt b/src/sat/glucose2/CMakeLists.txt index 9c00826407..b96cee7c71 100644 --- a/src/sat/glucose2/CMakeLists.txt +++ b/src/sat/glucose2/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose2 SOURCES + AbcGlucose2.cpp AbcGlucoseCmd2.cpp System2.cpp - AbcGlucose2.cpp - Glucose2.cpp - Options2.cpp SimpSolver2.cpp + Options2.cpp + Glucose2.cpp ) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt index 6c7fd78ccc..50378dfe88 100644 --- a/src/sat/msat/CMakeLists.txt +++ b/src/sat/msat/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME sat_msat SOURCES - msatClauseVec.c - msatSolverSearch.c msatSolverApi.c - msatVec.c + msatActivity.c + msatRead.c + msatSolverSearch.c msatSolverIo.c - msatSort.c + msatVec.c + msatSolverCore.c + msatOrderH.c msatMem.c + msatClauseVec.c msatClause.c - msatOrderH.c + msatSort.c msatQueue.c - msatRead.c - msatActivity.c - msatSolverCore.c ) From 4d9c870ec057dc549bc1b69488275106904b5f9d Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Thu, 30 Nov 2023 19:36:20 -0800 Subject: [PATCH 13/35] chg: dev: update python versions, add CPUS env var to tox file Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 2 +- .github/workflows/conda-dev.yml | 2 +- tox.ini | 27 ++++++++++++++------------- 3 files changed, 16 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 445f190627..ccd31508ab 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: strategy: fail-fast: false matrix: - python-version: [3.9] + python-version: ['3.10'] name: [ windows-2019-cl, diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 912d5f31f0..8d1539c56a 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -16,7 +16,7 @@ jobs: fail-fast: false matrix: os: ['ubuntu-22.04', 'ubuntu-20.04', 'macOS-11', 'windows-2019'] - python-version: ['3.9'] + python-version: ['3.11'] use_namespace: [false, true] include: - os: 'ubuntu-22.04' diff --git a/tox.ini b/tox.ini index 2a1d18bc1f..3f5c459c61 100644 --- a/tox.ini +++ b/tox.ini @@ -1,10 +1,11 @@ [tox] -envlist = py3{6,7,8,9}-build +envlist = py3{7,8,9,10,11}-build skip_missing_interpreters = true skipsdist = true [base] setenv = + CPUS={env:CPUS:4} {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-march=native -O2 -g -DNDEBUG} @@ -66,9 +67,9 @@ commands_pre = {base,build,clang}: cmake -E make_directory {toxinidir}/build commands = - abc: make -j4 ABC_USE_PIC=1 {posargs} abc - abc: make -j4 {posargs} libabc.a - soname: make -j4 ABC_USE_PIC=1 ABC_USE_SONAME=1 {posargs} lib + abc: make -j{env:CPUS} ABC_USE_PIC=1 {posargs} abc + abc: make -j{env:CPUS} {posargs} libabc.a + soname: make -j{env:CPUS} ABC_USE_PIC=1 ABC_USE_SONAME=1 {posargs} lib tests: make test # demo requires CC, CXX set in environment or on cmd line # eg: CC=gcc CXX=g++ tox -e demo @@ -76,22 +77,22 @@ commands = demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' demo: bash -c './demo i10.aig' {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' - base: bash -c 'cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX=$PREFIX ..' - base: bash -c 'cmake --build . --target install -j $(nproc)' - build: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=$ABC_USE_SONAME -DCMAKE_INSTALL_PREFIX=$PREFIX ..' - clang: bash -c 'cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF ..' - {build}: bash -c 'cmake --build . -j $(nproc)' - {clang}: bash -c 'cmake --build . --target coverage -j $(nproc)' - {build,clang}: bash -c 'ctest -V -C $BUILD_TYPE --test-dir ./' + base: cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + base: cmake --build . --target install -j {env:CPUS} + build: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=$ABC_USE_SONAME -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + clang: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF .. + {build}: cmake --build . -j {env:CPUS} + {clang}: cmake --build . --target coverage -j {env:CPUS} + {build,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ clang: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml {base,build}: cmake --build . --target install {base,build}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' - ctest: bash -c 'ctest -j $(nproc) --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE=$BUILD_TYPE --test-command ctest --rerun-failed --output-on-failure -V' + ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE=$BUILD_TYPE --test-command ctest --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/base_test build/libabc.* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DCMAKE_BUILD_TYPE=Debug' - grind: bash -c 'cmake --build build --target abc -j $(nproc)' + grind: bash -c 'cmake --build build --target abc -j $CPUS' grind: bash -c 'valgrind --tool=memcheck --xml=yes --xml-file=abc_check.xml --leak-check=full --show-leak-kinds=definite,possible --error-exitcode=127 ./build/src/base/main/abc "-c" "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"' grind: valgrind-ci abc_check.xml --number-of-errors grind: valgrind-ci abc_check.xml --summary From 5da957b2e94512b72d63f625c7496a63b35d2b16 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Fri, 1 Dec 2023 11:50:13 -0800 Subject: [PATCH 14/35] fix: dev: address toolchain requirement changes * use more specific if check for windows includes * add missing win32 link library * move extern Io_MvLoadFileBz2 to header, use hdr in cmd.c Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 6 +- src/base/cmd/cmd.c | 41 +++++----- src/base/cmd/cmd.h | 5 +- src/base/io/ioInt.h | 4 +- src/base/io/ioReadBlifMv.c | 163 ++++++++++++++++++------------------- 5 files changed, 111 insertions(+), 108 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e5c4cbd308..d3ff7a82ed 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -139,7 +139,11 @@ target_include_directories( $ ) -target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS}) +if(MINGW) + target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS} shlwapi) +else() + target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS}) +endif() if(NOT ABC_USE_NO_CUDD) message(STATUS "Compiling with CUDD") diff --git a/src/base/cmd/cmd.c b/src/base/cmd/cmd.c index 20d0f0c38f..119c57a7a9 100644 --- a/src/base/cmd/cmd.c +++ b/src/base/cmd/cmd.c @@ -9,7 +9,7 @@ Synopsis [Command file.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -18,14 +18,15 @@ ***********************************************************************/ -#ifdef WIN32 +#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) #include #else -#include #include +#include #endif #include "base/abc/abc.h" +#include "base/io/ioInt.h" #include "base/main/mainInt.h" #include "cmdInt.h" #include "misc/util/utilSignal.h" @@ -51,7 +52,7 @@ static int CmdCommandUnsetVariable ( Abc_Frame_t * pAbc, int argc, char ** argv static int CmdCommandUndo ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandRecall ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandEmpty ( Abc_Frame_t * pAbc, int argc, char ** argv ); -#if defined(WIN32) +#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) static int CmdCommandScanDir ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandRenameFiles ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandLs ( Abc_Frame_t * pAbc, int argc, char ** argv ); @@ -105,7 +106,7 @@ void Cmd_Init( Abc_Frame_t * pAbc ) Cmd_CommandAdd( pAbc, "Basic", "undo", CmdCommandUndo, 0 ); Cmd_CommandAdd( pAbc, "Basic", "recall", CmdCommandRecall, 0 ); Cmd_CommandAdd( pAbc, "Basic", "empty", CmdCommandEmpty, 0 ); -#if defined(WIN32) +#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) Cmd_CommandAdd( pAbc, "Basic", "scandir", CmdCommandScanDir, 0 ); Cmd_CommandAdd( pAbc, "Basic", "renamefiles", CmdCommandRenameFiles, 0 ); Cmd_CommandAdd( pAbc, "Basic", "ls", CmdCommandLs, 0 ); @@ -1217,7 +1218,7 @@ int CmdCommandUndo( Abc_Frame_t * pAbc, int argc, char **argv ) #endif -#if defined(WIN32) +#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) #include #include @@ -1905,7 +1906,7 @@ int CmdCommandScrGen( Abc_Frame_t * pAbc, int argc, char **argv ) #else -Vec_Ptr_t * CmdReturnFileNames( char * pDirStr ) +Vec_Ptr_t * CmdReturnFileNames( char * pDirStr ) { Vec_Ptr_t * vRes = Vec_PtrAlloc( 100 ); struct dirent **namelist; @@ -1917,7 +1918,7 @@ Vec_Ptr_t * CmdReturnFileNames( char * pDirStr ) for (int i = 0; i < num_files; i++) { char * pExt = strstr(namelist[i]->d_name, "."); if ( !pExt || !strcmp(pExt, ".") || !strcmp(pExt, "..") || !strcmp(pExt, ".s") || !strcmp(pExt, ".txt") ) - continue; + continue; Vec_PtrPush( vRes, Abc_UtilStrsav(namelist[i]->d_name) ); free(namelist[i]); } @@ -1933,7 +1934,7 @@ int CmdCommandScrGenLinux( Abc_Frame_t * pAbc, int argc, char **argv ) char * pDirStr = (char *)"."; char * pComStr = (char *)"ps"; char * pWriteStr = NULL; - char * pWriteExt = NULL; + char * pWriteExt = NULL; char Line[2000], * pName; int nFileNameMax; int fBatch = 0; @@ -1988,7 +1989,7 @@ int CmdCommandScrGenLinux( Abc_Frame_t * pAbc, int argc, char **argv ) } pWriteExt = argv[globalUtilOptind]; globalUtilOptind++; - break; + break; case 'b': fBatch ^= 1; break; @@ -2018,8 +2019,8 @@ int CmdCommandScrGenLinux( Abc_Frame_t * pAbc, int argc, char **argv ) int fAndSpace = pComStr[0] == '&'; fprintf( pFile, "# Script file produced by ABC on %s\n", Extra_TimeStamp() ); fprintf( pFile, "# Command line was: scrgen -F %s -D %s -C \"%s\"%s%s%s%s\n", - pFileStr, pDirStr, pComStr, - pWriteStr?" -W ":"", pWriteStr?pWriteStr:"", + pFileStr, pDirStr, pComStr, + pWriteStr?" -W ":"", pWriteStr?pWriteStr:"", pWriteExt?" -E ":"", pWriteExt?pWriteExt:"" ); Vec_PtrForEachEntry( char *, vNames, pName, k ) { char * pExt = strstr(pName, "."); @@ -2057,7 +2058,7 @@ int CmdCommandScrGenLinux( Abc_Frame_t * pAbc, int argc, char **argv ) fprintf( pAbc->Err, "\t-C str : the sequence of commands to run [default = \"ps\"]\n" ); fprintf( pAbc->Err, "\t-W str : the directory to write the resulting files [default = no writing]\n" ); fprintf( pAbc->Err, "\t-E str : the output files extension (with \".\") [default = the same as input files]\n" ); - fprintf( pAbc->Err, "\t-b : toggles adding batch mode support [default = %s]\n", fBatch? "yes": "no" ); + fprintf( pAbc->Err, "\t-b : toggles adding batch mode support [default = %s]\n", fBatch? "yes": "no" ); fprintf( pAbc->Err, "\t-h : print the command usage\n\n"); fprintf( pAbc->Err, "\tExample : scrgen -F test1.s -R a/in -C \"ps; st; ps\" -W a/out -E .blif\n" ); return 1; @@ -2614,7 +2615,7 @@ int CmdCommandCapo( Abc_Frame_t * pAbc, int argc, char **argv ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -2641,7 +2642,7 @@ int CmdCommandStarter( Abc_Frame_t * pAbc, int argc, char ** argv ) } nCores = atoi(argv[globalUtilOptind]); globalUtilOptind++; - if ( nCores < 0 ) + if ( nCores < 0 ) goto usage; break; case 'C': @@ -2699,7 +2700,7 @@ int CmdCommandStarter( Abc_Frame_t * pAbc, int argc, char ** argv ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -2727,7 +2728,7 @@ int CmdCommandAutoTuner( Abc_Frame_t * pAbc, int argc, char ** argv ) } nCores = atoi(argv[globalUtilOptind]); globalUtilOptind++; - if ( nCores < 0 ) + if ( nCores < 0 ) goto usage; break; case 'C': @@ -2848,7 +2849,7 @@ int CmdCommandVersion( Abc_Frame_t * pAbc, int argc, char **argv ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -2873,7 +2874,7 @@ int CmdCommandSGen( Abc_Frame_t * pAbc, int argc, char ** argv ) } nParts = atoi(argv[globalUtilOptind]); globalUtilOptind++; - if ( nParts < 0 ) + if ( nParts < 0 ) goto usage; break; case 'I': @@ -2899,7 +2900,7 @@ int CmdCommandSGen( Abc_Frame_t * pAbc, int argc, char ** argv ) Abc_Print( -2, "There is no current network.\n" ); return 1; } - if ( !Abc_NtkIsStrash(Abc_FrameReadNtk(pAbc)) ) + if ( !Abc_NtkIsStrash(Abc_FrameReadNtk(pAbc)) ) { Abc_Print( -2, "The current network is not an AIG.\n" ); return 1; diff --git a/src/base/cmd/cmd.h b/src/base/cmd/cmd.h index 4d412bac80..e2b56c283c 100644 --- a/src/base/cmd/cmd.h +++ b/src/base/cmd/cmd.h @@ -9,7 +9,7 @@ Synopsis [External declarations of the command package.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -60,7 +60,7 @@ extern char * Cmd_FlagReadByName( Abc_Frame_t * pAbc, char * flag ); extern void Cmd_FlagDeleteByName( Abc_Frame_t * pAbc, const char * key ); extern void Cmd_FlagUpdateValue( Abc_Frame_t * pAbc, const char * key, char * value ); /*=== cmdHist.c ========================================================*/ -extern void Cmd_HistoryAddCommand( Abc_Frame_t * pAbc, const char * command ); +extern void Cmd_HistoryAddCommand( Abc_Frame_t * pAbc, const char * command ); extern void Cmd_HistoryRead( Abc_Frame_t * p ); extern void Cmd_HistoryWrite( Abc_Frame_t * p, int Limit ); extern void Cmd_HistoryPrint( Abc_Frame_t * p, int Limit ); @@ -78,4 +78,3 @@ ABC_NAMESPACE_HEADER_END //////////////////////////////////////////////////////////////////////// /// END OF FILE /// //////////////////////////////////////////////////////////////////////// - diff --git a/src/base/io/ioInt.h b/src/base/io/ioInt.h index fed639a477..383683e32d 100644 --- a/src/base/io/ioInt.h +++ b/src/base/io/ioInt.h @@ -9,7 +9,7 @@ Synopsis [External declarations.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -45,6 +45,7 @@ ABC_NAMESPACE_HEADER_START /// FUNCTION DECLARATIONS /// //////////////////////////////////////////////////////////////////////// +extern char * Io_MvLoadFileBz2( char * pFileName, int * pnFileSize ); ABC_NAMESPACE_HEADER_END @@ -54,4 +55,3 @@ ABC_NAMESPACE_HEADER_END //////////////////////////////////////////////////////////////////////// /// END OF FILE /// //////////////////////////////////////////////////////////////////////// - diff --git a/src/base/io/ioReadBlifMv.c b/src/base/io/ioReadBlifMv.c index 77ae184151..deb5e6d33b 100644 --- a/src/base/io/ioReadBlifMv.c +++ b/src/base/io/ioReadBlifMv.c @@ -9,7 +9,7 @@ Synopsis [Procedures to read BLIF-MV file.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - January 8, 2007.] @@ -41,7 +41,7 @@ Vec_Ptr_t *vGlobalLtlArray; struct Io_MvVar_t_ { - int nValues; // the number of values + int nValues; // the number of values char ** pNames; // the value names }; @@ -63,10 +63,10 @@ struct Io_MvMod_t_ Vec_Ptr_t * vLtlProperties; int fBlackBox; // indicates blackbox model // the resulting network - Abc_Ntk_t * pNtk; - Abc_Obj_t * pResetLatch; + Abc_Ntk_t * pNtk; + Abc_Obj_t * pResetLatch; // the parent manager - Io_MvMan_t * pMan; + Io_MvMan_t * pMan; }; struct Io_MvMan_t_ @@ -89,7 +89,7 @@ struct Io_MvMan_t_ Vec_Str_t * vFunc; // the local function // error reporting char sError[512]; // the error string generated during parsing - // statistics + // statistics int nTablesRead; // the number of processed tables int nTablesLeft; // the number of dangling tables }; @@ -133,7 +133,7 @@ extern void Abc_NtkStartMvVars( Abc_Ntk_t * pNtk ); Synopsis [Reads the network from the BLIF or BLIF-MV file.] Description [] - + SideEffects [] SeeAlso [] @@ -144,7 +144,7 @@ Abc_Ntk_t * Io_ReadBlifMv( char * pFileName, int fBlifMv, int fCheck ) FILE * pFile; Io_MvMan_t * p; Abc_Ntk_t * pNtk, * pExdc; - Abc_Des_t * pDesign = NULL; + Abc_Des_t * pDesign = NULL; char * pDesignName; int RetValue, i; char * pLtlProp; @@ -260,7 +260,7 @@ Abc_Ntk_t * Io_ReadBlifMv( char * pFileName, int fBlifMv, int fCheck ) Synopsis [Allocates the BLIF parsing structure.] Description [] - + SideEffects [] SeeAlso [] @@ -284,7 +284,7 @@ static Io_MvMan_t * Io_MvAlloc() Synopsis [Frees the BLIF parsing structure.] Description [] - + SideEffects [] SeeAlso [] @@ -296,7 +296,7 @@ static void Io_MvFree( Io_MvMan_t * p ) int i; if ( p->pDesign ) Abc_DesFree( p->pDesign, NULL ); - if ( p->pBuffer ) + if ( p->pBuffer ) ABC_FREE( p->pBuffer ); if ( p->vLines ) Vec_PtrFree( p->vLines ); @@ -317,7 +317,7 @@ static void Io_MvFree( Io_MvMan_t * p ) Synopsis [Allocates the BLIF parsing structure for one model.] Description [] - + SideEffects [] SeeAlso [] @@ -348,7 +348,7 @@ static Io_MvMod_t * Io_MvModAlloc() Synopsis [Allocates the BLIF parsing structure for one model.] Description [] - + SideEffects [] SeeAlso [] @@ -380,7 +380,7 @@ static void Io_MvModFree( Io_MvMod_t * p ) Synopsis [Counts the number of given chars.] Description [] - + SideEffects [] SeeAlso [] @@ -401,7 +401,7 @@ static int Io_MvCountChars( char * pLine, char Char ) Synopsis [Returns the place where the arrow is hiding.] Description [] - + SideEffects [] SeeAlso [] @@ -425,7 +425,7 @@ static char * Io_MvFindArrow( char * pLine ) Synopsis [Collects the already split tokens.] Description [] - + SideEffects [] SeeAlso [] @@ -449,7 +449,7 @@ static void Io_MvCollectTokens( Vec_Ptr_t * vTokens, char * pInput, char * pOutp Synopsis [Splits the line into tokens.] Description [] - + SideEffects [] SeeAlso [] @@ -471,7 +471,7 @@ static void Io_MvSplitIntoTokens( Vec_Ptr_t * vTokens, char * pLine, char Stop ) Synopsis [Splits the line into tokens when .default may be present.] Description [] - + SideEffects [] SeeAlso [] @@ -493,7 +493,7 @@ static void Io_MvSplitIntoTokensMv( Vec_Ptr_t * vTokens, char * pLine ) Synopsis [Splits the line into tokens.] Description [] - + SideEffects [] SeeAlso [] @@ -515,7 +515,7 @@ static void Io_MvSplitIntoTokensAndClear( Vec_Ptr_t * vTokens, char * pLine, cha Synopsis [Returns the 1-based number of the line in which the token occurs.] Description [] - + SideEffects [] SeeAlso [] @@ -536,7 +536,7 @@ static int Io_MvGetLine( Io_MvMan_t * p, char * pToken ) Synopsis [Reads the file into a character buffer.] Description [] - + SideEffects [] SeeAlso [] @@ -604,7 +604,7 @@ char * Io_MvLoadFileBz2( char * pFileName, long * pnFileSize ) pContents = ABC_ALLOC( char, nFileSize + 10 ); rewind( pFile ); RetValue = fread( pContents, nFileSize, 1, pFile ); - } else { + } else { // Some other error. Abc_Print( -1, "Io_MvLoadFileBz2(): Unable to read the compressed BLIF.\n" ); return NULL; @@ -622,7 +622,7 @@ char * Io_MvLoadFileBz2( char * pFileName, long * pnFileSize ) Synopsis [Reads the file into a character buffer.] Description [] - + SideEffects [] SeeAlso [] @@ -635,7 +635,7 @@ static char * Io_MvLoadFileGz( char * pFileName, long * pnFileSize ) char * pContents; long amtRead, readBlock, nFileSize = READ_BLOCK_SIZE; pFile = gzopen( pFileName, "rb" ); // if pFileName doesn't end in ".gz" then this acts as a passthrough to fopen - pContents = ABC_ALLOC( char, nFileSize ); + pContents = ABC_ALLOC( char, nFileSize ); readBlock = 0; while ((amtRead = gzread(pFile, pContents + readBlock * READ_BLOCK_SIZE, READ_BLOCK_SIZE)) == READ_BLOCK_SIZE) { //Abc_Print( 1,"%d: read %d bytes\n", readBlock, amtRead); @@ -656,7 +656,7 @@ static char * Io_MvLoadFileGz( char * pFileName, long * pnFileSize ) Synopsis [Reads the file into a character buffer.] Description [] - + SideEffects [] SeeAlso [] @@ -678,8 +678,8 @@ static char * Io_MvLoadFile( char * pFileName ) printf( "Io_MvLoadFile(): The file is unavailable (absent or open).\n" ); return NULL; } - fseek( pFile, 0, SEEK_END ); - nFileSize = ftell( pFile ); + fseek( pFile, 0, SEEK_END ); + nFileSize = ftell( pFile ); if ( nFileSize == 0 ) { fclose( pFile ); @@ -707,7 +707,7 @@ static char * Io_MvLoadFile( char * pFileName ) - Estimates the number of objects. - Allocates room for the objects. - Allocates room for the hash table.] - + SideEffects [] SeeAlso [] @@ -786,7 +786,7 @@ static void Io_MvReadPreparse( Io_MvMan_t * p ) Vec_PtrPush( p->pLatest->vConstrs, pCur ); else if ( !strncmp(pCur, "blackbox", 8) ) p->pLatest->fBlackBox = 1; - else if ( !strncmp(pCur, "model", 5) ) + else if ( !strncmp(pCur, "model", 5) ) { p->pLatest = Io_MvModAlloc(); p->pLatest->pName = pCur; @@ -837,7 +837,7 @@ static void Io_MvReadPreparse( Io_MvMan_t * p ) Synopsis [Parses interfaces of the models.] Description [] - + SideEffects [] SeeAlso [] @@ -880,7 +880,7 @@ static int Io_MvReadInterfaces( Io_MvMan_t * p ) // report the results #ifdef IO_VERBOSE_OUTPUT if ( Vec_PtrSize(p->vModels) > 1 ) - printf( "Parsed %-32s: PI =%6d PO =%6d ND =%8d FF =%6d B =%6d\n", + printf( "Parsed %-32s: PI =%6d PO =%6d ND =%8d FF =%6d B =%6d\n", pMod->pNtk->pName, Abc_NtkPiNum(pMod->pNtk), Abc_NtkPoNum(pMod->pNtk), Vec_PtrSize(pMod->vNames), Vec_PtrSize(pMod->vLatches), Vec_PtrSize(pMod->vSubckts) ); #endif @@ -894,7 +894,7 @@ static int Io_MvReadInterfaces( Io_MvMan_t * p ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -908,7 +908,7 @@ static Abc_Des_t * Io_MvParse( Io_MvMan_t * p ) int i, k; // iterate through the models Vec_PtrForEachEntry( Io_MvMod_t *, p->vModels, pMod, i ) - { + { #ifdef IO_VERBOSE_OUTPUT if ( Vec_PtrSize(p->vModels) > 1 ) printf( "Parsing model %s...\n", pMod->pNtk->pName ); @@ -926,12 +926,12 @@ static Abc_Des_t * Io_MvParse( Io_MvMan_t * p ) { if ( Vec_PtrSize(pMod->vLatches) != Vec_PtrSize(pMod->vResets) ) { - sprintf( p->sError, "Line %d: Model %s has different number of latches (%d) and reset nodes (%d).", + sprintf( p->sError, "Line %d: Model %s has different number of latches (%d) and reset nodes (%d).", Io_MvGetLine(p, pMod->pName), Abc_NtkName(pMod->pNtk), Vec_PtrSize(pMod->vLatches), Vec_PtrSize(pMod->vResets) ); return NULL; } // create binary latch with 1-data and 0-init - if ( p->fUseReset ) + if ( p->fUseReset ) pMod->pResetLatch = Io_ReadCreateResetLatch( pMod->pNtk, p->fBlifMv ); } // parse the flops @@ -984,7 +984,7 @@ static Abc_Des_t * Io_MvParse( Io_MvMan_t * p ) // read the one-hotness lines if ( Vec_PtrSize(pMod->vOnehots) > 0 ) { - Vec_Int_t * vLine; + Vec_Int_t * vLine; Abc_Obj_t * pObj; // set register numbers Abc_NtkForEachLatch( pMod->pNtk, pObj, k ) @@ -1007,8 +1007,8 @@ static Abc_Des_t * Io_MvParse( Io_MvMan_t * p ) Vec_PtrForEachEntry( Vec_Int_t *, pMod->pNtk->vOnehots, vLine, k ) printf( "%d ", Vec_IntSize(vLine) ); printf( "}\n" ); - printf( "The total number of 1-hot registers = %d. (%.2f %%)\n", - Vec_VecSizeSize( (Vec_Vec_t *)pMod->pNtk->vOnehots ), + printf( "The total number of 1-hot registers = %d. (%.2f %%)\n", + Vec_VecSizeSize( (Vec_Vec_t *)pMod->pNtk->vOnehots ), 100.0 * Vec_VecSizeSize( (Vec_Vec_t *)pMod->pNtk->vOnehots ) / Abc_NtkLatchNum(pMod->pNtk) ); { extern void Abc_GenOneHotIntervals( char * pFileName, int nPis, int nRegs, Vec_Ptr_t * vOnehots ); @@ -1038,7 +1038,7 @@ static Abc_Des_t * Io_MvParse( Io_MvMan_t * p ) Synopsis [Parses the model line.] Description [] - + SideEffects [] SeeAlso [] @@ -1066,7 +1066,7 @@ static int Io_MvParseLineModel( Io_MvMod_t * p, char * pLine ) p->pNtk = Abc_NtkAlloc( ABC_NTK_NETLIST, ABC_FUNC_BLACKBOX, 1 ); else if ( p->pMan->fBlifMv ) p->pNtk = Abc_NtkAlloc( ABC_NTK_NETLIST, ABC_FUNC_BLIFMV, 1 ); - else + else p->pNtk = Abc_NtkAlloc( ABC_NTK_NETLIST, ABC_FUNC_SOP, 1 ); // for ( pPivot = pToken = Vec_PtrEntry(vTokens, 1); *pToken; pToken++ ) // if ( *pToken == '/' || *pToken == '\\' ) @@ -1081,7 +1081,7 @@ static int Io_MvParseLineModel( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the inputs line.] Description [] - + SideEffects [] SeeAlso [] @@ -1105,7 +1105,7 @@ static int Io_MvParseLineInputs( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the outputs line.] Description [] - + SideEffects [] SeeAlso [] @@ -1129,7 +1129,7 @@ static int Io_MvParseLineOutputs( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the outputs line.] Description [] - + SideEffects [] SeeAlso [] @@ -1153,7 +1153,7 @@ static int Io_MvParseLineConstrs( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the LTL property line.] Description [] - + SideEffects [] SeeAlso [] @@ -1196,7 +1196,7 @@ static int Io_MvParseLineLtlProperty( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the latches line.] Description [] - + SideEffects [] SeeAlso [] @@ -1226,8 +1226,8 @@ static int Io_MvParseLineLatch( Io_MvMod_t * p, char * pLine ) else { if ( Vec_PtrSize(vTokens) > 6 ) - printf( "Warning: Line %d has .latch directive with unrecognized entries (the total of %d entries).\n", - Io_MvGetLine(p->pMan, pToken), Vec_PtrSize(vTokens) ); + printf( "Warning: Line %d has .latch directive with unrecognized entries (the total of %d entries).\n", + Io_MvGetLine(p->pMan, pToken), Vec_PtrSize(vTokens) ); if ( Vec_PtrSize(vTokens) > 3 ) Init = atoi( (char *)Vec_PtrEntryLast(vTokens) ); else @@ -1264,7 +1264,7 @@ static int Io_MvParseLineLatch( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the latches line.] Description [] - + SideEffects [] SeeAlso [] @@ -1339,7 +1339,7 @@ static int Io_MvParseLineFlop( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the subckt line.] Description [] - + SideEffects [] SeeAlso [] @@ -1381,7 +1381,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) // check if the number of tokens is correct if ( nEquals != Abc_NtkPiNum(pModel) + Abc_NtkPoNum(pModel) ) { - sprintf( p->pMan->sError, "Line %d: The number of ports (%d) in .subckt differs from the sum of PIs and POs of the model (%d).", + sprintf( p->pMan->sError, "Line %d: The number of ports (%d) in .subckt differs from the sum of PIs and POs of the model (%d).", Io_MvGetLine(p->pMan, pToken), nEquals, Abc_NtkPiNum(pModel) + Abc_NtkPoNum(pModel) ); return 0; } @@ -1400,7 +1400,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) // go through formal inputs Last = 0; Abc_NtkForEachPi( pModel, pTerm, i ) - { + { // find this terminal among the actual inputs of the subcircuit pName2 = NULL; pName = Abc_ObjName(Abc_ObjFanout0(pTerm)); @@ -1414,7 +1414,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) if ( k == nEquals ) { - sprintf( p->pMan->sError, "Line %d: Cannot find PI \"%s\" of the model \"%s\" as a formal input of the subcircuit.", + sprintf( p->pMan->sError, "Line %d: Cannot find PI \"%s\" of the model \"%s\" as a formal input of the subcircuit.", Io_MvGetLine(p->pMan, pToken), pName, Abc_NtkName(pModel) ); return 0; } @@ -1431,7 +1431,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) continue; } assert( pName2 != NULL ); - + // create the BI with the actual name pNet = Abc_NtkFindOrCreateNet( p->pNtk, pName2 ); pTerm = Abc_NtkCreateBi( p->pNtk ); @@ -1455,7 +1455,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) /* if ( k == nEquals ) { - sprintf( p->pMan->sError, "Line %d: Cannot find PO \"%s\" of the modell \"%s\" as a formal output of the subcircuit.", + sprintf( p->pMan->sError, "Line %d: Cannot find PO \"%s\" of the modell \"%s\" as a formal output of the subcircuit.", Io_MvGetLine(p->pMan, pToken), pName, Abc_NtkName(pModel) ); return 0; } @@ -1475,7 +1475,7 @@ static int Io_MvParseLineSubckt( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the subckt line.] Description [] - + SideEffects [] SeeAlso [] @@ -1505,7 +1505,7 @@ static Vec_Int_t * Io_MvParseLineOnehot( Io_MvMod_t * p, char * pLine ) pNet = Abc_NtkFindNet( p->pNtk, pToken ); if ( pNet == NULL ) { - sprintf( p->pMan->sError, "Line %d: Signal with name \"%s\" does not exist in the model \"%s\".", + sprintf( p->pMan->sError, "Line %d: Signal with name \"%s\" does not exist in the model \"%s\".", Io_MvGetLine(p->pMan, pToken), pToken, Abc_NtkName(p->pNtk) ); return NULL; } @@ -1513,7 +1513,7 @@ static Vec_Int_t * Io_MvParseLineOnehot( Io_MvMod_t * p, char * pLine ) pTerm = Abc_ObjFanin0( pNet ); if ( pTerm == NULL || Abc_ObjFanin0(pTerm) == NULL || !Abc_ObjIsLatch(Abc_ObjFanin0(pTerm)) ) { - sprintf( p->pMan->sError, "Line %d: Signal with name \"%s\" is not a register in the model \"%s\".", + sprintf( p->pMan->sError, "Line %d: Signal with name \"%s\" is not a register in the model \"%s\".", Io_MvGetLine(p->pMan, pToken), pToken, Abc_NtkName(p->pNtk) ); return NULL; } @@ -1533,7 +1533,7 @@ static Vec_Int_t * Io_MvParseLineOnehot( Io_MvMod_t * p, char * pLine ) Synopsis [Parses the mv line.] Description [] - + SideEffects [] SeeAlso [] @@ -1561,7 +1561,7 @@ static int Io_MvParseLineMv( Io_MvMod_t * p, char * pLine ) nValues = atoi( (char *)Vec_PtrEntry(vTokens,nCommas+2) ); if ( nValues < 2 || nValues > IO_BLIFMV_MAXVALUES ) { - sprintf( p->pMan->sError, "Line %d: The number of values (%d) is incorrect (should be >= 2 and <= %d).", + sprintf( p->pMan->sError, "Line %d: The number of values (%d) is incorrect (should be >= 2 and <= %d).", Io_MvGetLine(p->pMan, pName), nValues, IO_BLIFMV_MAXVALUES ); return 0; } @@ -1570,7 +1570,7 @@ static int Io_MvParseLineMv( Io_MvMod_t * p, char * pLine ) return 1; if ( Vec_PtrSize(vTokens) > nCommas + 3 && Vec_PtrSize(vTokens) - (nCommas + 3) != nValues ) { - sprintf( p->pMan->sError, "Line %d: Wrong number (%d) of symbolic value names (should be %d).", + sprintf( p->pMan->sError, "Line %d: Wrong number (%d) of symbolic value names (should be %d).", Io_MvGetLine(p->pMan, pName), Vec_PtrSize(vTokens) - (nCommas + 3), nValues ); return 0; } @@ -1606,7 +1606,7 @@ static int Io_MvParseLineMv( Io_MvMod_t * p, char * pLine ) if ( !strcmp(pVar->pNames[i], pVar->pNames[k]) ) { pName = (char *)Vec_PtrEntry(vTokens,0); - sprintf( p->pMan->sError, "Line %d: Symbolic value name \"%s\" is repeated in .mv line.", + sprintf( p->pMan->sError, "Line %d: Symbolic value name \"%s\" is repeated in .mv line.", Io_MvGetLine(p->pMan, pName), pVar->pNames[i] ); return 0; } @@ -1619,7 +1619,7 @@ static int Io_MvParseLineMv( Io_MvMod_t * p, char * pLine ) Synopsis [Writes the values into the BLIF-MV representation for the node.] Description [] - + SideEffects [] SeeAlso [] @@ -1649,7 +1649,7 @@ static int Io_MvWriteValues( Abc_Obj_t * pNode, Vec_Str_t * vFunc ) Synopsis [Translated one literal.] Description [] - + SideEffects [] SeeAlso [] @@ -1671,7 +1671,7 @@ static int Io_MvParseLiteralMv( Io_MvMod_t * p, Abc_Obj_t * pNode, char * pToken break; if ( i == Abc_ObjFaninNum(pNode) ) { - sprintf( p->pMan->sError, "Line %d: Node name in the table \"%s\" cannot be found on .names line.", + sprintf( p->pMan->sError, "Line %d: Node name in the table \"%s\" cannot be found on .names line.", Io_MvGetLine(p->pMan, pToken), pToken + 1 ); return 0; } @@ -1711,7 +1711,7 @@ static int Io_MvParseLiteralMv( Io_MvMod_t * p, Abc_Obj_t * pNode, char * pToken if ( i == pVar->nValues ) { *pNext = 0; - sprintf( p->pMan->sError, "Line %d: Cannot find value name \"%s\" among the value names of variable \"%s\".", + sprintf( p->pMan->sError, "Line %d: Cannot find value name \"%s\" among the value names of variable \"%s\".", Io_MvGetLine(p->pMan, pToken), pCur, Abc_ObjName(pNet) ); return 0; } @@ -1730,7 +1730,7 @@ static int Io_MvParseLiteralMv( Io_MvMod_t * p, Abc_Obj_t * pNode, char * pToken Synopsis [Constructs the MV-SOP cover from the file parsing info.] Description [] - + SideEffects [] SeeAlso [] @@ -1774,7 +1774,7 @@ static char * Io_MvParseTableMv( Io_MvMod_t * p, Abc_Obj_t * pNode, Vec_Ptr_t * return NULL; // update the counter iStart += nInputs + nOutputs; - } + } Vec_StrPush( vFunc, '\0' ); return Vec_StrArray( vFunc ); } @@ -1784,7 +1784,7 @@ static char * Io_MvParseTableMv( Io_MvMod_t * p, Abc_Obj_t * pNode, Vec_Ptr_t * Synopsis [Adds reset circuitry corresponding to latch with pName.] Description [Returns the reset node's net.] - + SideEffects [] SeeAlso [] @@ -1838,7 +1838,7 @@ static Abc_Obj_t * Io_MvParseAddResetCircuit( Io_MvMod_t * p, char * pName ) Synopsis [Parses the nodes line.] Description [] - + SideEffects [] SeeAlso [] @@ -1896,7 +1896,7 @@ static int Io_MvParseLineNamesMvOne( Io_MvMod_t * p, Vec_Ptr_t * vTokens, Vec_Pt Synopsis [Parses the nodes line.] Description [] - + SideEffects [] SeeAlso [] @@ -1912,7 +1912,7 @@ static int Io_MvParseLineNamesMv( Io_MvMod_t * p, char * pLine, int fReset ) assert( p->pMan->fBlifMv ); // get the arrow if it is present pArrow = Io_MvFindArrow( pLine ); - if ( !p->pMan->fBlifMv && pArrow ) + if ( !p->pMan->fBlifMv && pArrow ) { sprintf( p->pMan->sError, "Line %d: Multi-output node symbol (->) in binary BLIF file.", Io_MvGetLine(p->pMan, pLine) ); return 0; @@ -1991,7 +1991,7 @@ static int Io_MvParseLineNamesMv( Io_MvMod_t * p, char * pLine, int fReset ) Synopsis [Constructs the SOP cover from the file parsing info.] Description [] - + SideEffects [] SeeAlso [] @@ -2050,7 +2050,7 @@ static char * Io_MvParseTableBlif( Io_MvMod_t * p, char * pTable, int nFanins ) sprintf( p->pMan->sError, "Line %d: Output value \"%s\" differs from the value in the first line of the table (%d).", Io_MvGetLine(p->pMan, pProduct), pOutput, Polarity ); return NULL; } - // parse one product + // parse one product Vec_StrPrintStr( vFunc, pProduct ); Vec_StrPush( vFunc, ' ' ); Vec_StrPush( vFunc, pOutput[0] ); @@ -2065,7 +2065,7 @@ static char * Io_MvParseTableBlif( Io_MvMod_t * p, char * pTable, int nFanins ) Synopsis [Parses the nodes line.] Description [] - + SideEffects [] SeeAlso [] @@ -2113,7 +2113,7 @@ ABC_NAMESPACE_IMPL_START Synopsis [Parses the nodes line.] Description [] - + SideEffects [] SeeAlso [] @@ -2145,7 +2145,7 @@ static int Io_MvParseLineShortBlif( Io_MvMod_t * p, char * pLine ) // parse the table of this node if ( p->pNtk->ntkFunc == ABC_FUNC_MAP ) { - Mio_Library_t * pGenlib; + Mio_Library_t * pGenlib; Mio_Gate_t * pGate; // check that the library is available pGenlib = (Mio_Library_t *)Abc_FrameReadLibGen(); @@ -2173,7 +2173,7 @@ static int Io_MvParseLineShortBlif( Io_MvMod_t * p, char * pLine ) Synopsis [Duplicate the MV variable.] Description [] - + SideEffects [] SeeAlso [] @@ -2207,7 +2207,7 @@ Io_MvVar_t * Abc_NtkMvVarDup( Abc_Ntk_t * pNtk, Io_MvVar_t * pVar ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -2228,7 +2228,7 @@ static char * Io_ReadBlifCleanName( char * pName ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -2237,7 +2237,7 @@ static char * Io_ReadBlifCleanName( char * pName ) static int Io_MvParseLineGateBlif( Io_MvMod_t * p, Vec_Ptr_t * vTokens ) { extern int Io_ReadBlifReorderFormalNames( Vec_Ptr_t * vTokens, Mio_Gate_t * pGate, Mio_Gate_t * pTwin ); - Mio_Library_t * pGenlib; + Mio_Library_t * pGenlib; Mio_Gate_t * pGate; Abc_Obj_t * pNode; char ** ppNames, * pName; @@ -2343,7 +2343,7 @@ static int Io_MvParseLineGateBlif( Io_MvMod_t * p, Vec_Ptr_t * vTokens ) Synopsis [Box mapping procedures.] Description [] - + SideEffects [] SeeAlso [] @@ -2374,4 +2374,3 @@ static inline int Abc_MapBox2Prev( Vec_Ptr_t * vDrivers, Vec_Int_t * vMapIn, Vec ABC_NAMESPACE_IMPL_END - From cc1e5621c73566f7c1c41f2c533eb6bc4a7577e6 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 2 Dec 2023 17:21:26 -0800 Subject: [PATCH 15/35] fix: dev: cleanup desktop and ci workflows * msys/mingw has incomplete dirent so disable namespace * refactor cmake config, update dirent pkg spec in conda env * try cheap ENV hack to find dirent header in conda Signed-off-by: Stephen L Arnold --- .github/workflows/win.yml | 1 - CMakeLists.txt | 12 +++++++----- environment.devenv.yml | 2 +- tox.ini | 13 +++++-------- 4 files changed, 13 insertions(+), 15 deletions(-) diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 6acb67c1e3..2cbd8c0bdf 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -44,7 +44,6 @@ jobs: -Wdev -B build -DBUILD_SHARED_LIBS=ON - -DABC_USE_NAMESPACE=xxx -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=$PWD/_dist diff --git a/CMakeLists.txt b/CMakeLists.txt index d3ff7a82ed..c50607bea7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -139,11 +139,7 @@ target_include_directories( $ ) -if(MINGW) - target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS} shlwapi) -else() - target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS}) -endif() +target_link_libraries(abc_interface INTERFACE ${CMAKE_DL_LIBS}) if(NOT ABC_USE_NO_CUDD) message(STATUS "Compiling with CUDD") @@ -185,6 +181,11 @@ endif() if(WIN32) if(MINGW OR MSYS) add_definitions(-DWIN32 -D__MINGW32__ -DHAVE_STRUCT_TIMESPEC) + if(DEFINED ENV{CONDA_PREFIX}) + target_include_directories(abc_interface + INTERFACE $ENV{CONDA_PREFIX}/include + ) + endif() endif() target_compile_definitions(abc_interface INTERFACE @@ -193,6 +194,7 @@ if(WIN32) $<$>:WIN32_NO_DLL> $<$>:ABC_NO_DYNAMIC_LINKING> ) + target_link_libraries(abc_interface INTERFACE shlwapi) endif() if(ABC_USE_NAMESPACE) diff --git a/environment.devenv.yml b/environment.devenv.yml index a1d25367bf..7943367fe4 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -10,4 +10,4 @@ dependencies: - readline=8.1 # [unix] - zlib - libpng - - dirent # [win] + - dirent >=1.21,<2.0 # [win] diff --git a/tox.ini b/tox.ini index 3f5c459c61..09c3cf1092 100644 --- a/tox.ini +++ b/tox.ini @@ -12,12 +12,9 @@ setenv = {base,build,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} {base,build,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} {base,build,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} + BUILD_TYPE={env:BUILD_TYPE:Release} base: PREFIX={env:PREFIX:staging} build: PREFIX={env:PREFIX:../staging} - build: BUILD_TYPE={env:BUILD_TYPE:Release} - clang: BUILD_TYPE={env:BUILD_TYPE:RelWithDebInfo} - ctest: BUILD_TYPE={env:BUILD_TYPE:Release} - ctestwin: BUILD_TYPE={env:BUILD_TYPE:Debug} passenv = CC @@ -42,7 +39,7 @@ skip_install = true setenv = {abc,tests}: {[base]setenv} - {build,base}: {[base]setenv} + {base,build,clang,ctest,ctestwin}: {[base]setenv} passenv = {[base]passenv} @@ -79,15 +76,15 @@ commands = {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' base: cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. base: cmake --build . --target install -j {env:CPUS} - build: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=$ABC_USE_SONAME -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. - clang: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF .. + build: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + clang: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF .. {build}: cmake --build . -j {env:CPUS} {clang}: cmake --build . --target coverage -j {env:CPUS} {build,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ clang: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml {base,build}: cmake --build . --target install {base,build}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' - ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE=$BUILD_TYPE --test-command ctest --rerun-failed --output-on-failure -V + ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/base_test build/libabc.* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' From e532ae18207cc1a1a71ffe0740805045e0ea9bfe Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 3 Dec 2023 10:28:54 -0800 Subject: [PATCH 16/35] chg: usr: update devenv file and conda-dev workflow, update win path * update setup-miniconda config to get latest pkg versions * add more workflow output, reset cache number * list envs, revert to previous with some info output, back to v2 Signed-off-by: Stephen L Arnold --- .github/workflows/conda-dev.yml | 18 +++++++++++------- .gitignore | 1 + CMakeLists.txt | 2 +- environment.devenv.yml | 13 ++++++++++--- 4 files changed, 23 insertions(+), 11 deletions(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 8d1539c56a..6f492258c1 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -12,6 +12,9 @@ jobs: build: name: abc ${{ matrix.python-version }} ${{ matrix.os }} runs-on: ${{ matrix.os }} + defaults: + run: + shell: bash -el {0} strategy: fail-fast: false matrix: @@ -59,27 +62,28 @@ jobs: - uses: conda-incubator/setup-miniconda@v2 with: auto-update-conda: true + auto-activate-base: true python-version: ${{ matrix.python-version }} channels: conda-forge - channel-priority: strict - use-only-tar-bz2: true + channel-priority: flexible - name: Configure condadev environment - shell: bash -l {0} env: PY_VER: ${{ matrix.python-version }} run: | conda config --set always_yes yes --set changeps1 no - conda config --add channels conda-forge conda install conda-devenv=2.1.1 - conda devenv + conda info + conda list - name: Build and test - shell: bash -l {0} env: PY_VER: ${{ matrix.python-version }} run: | - source activate abc-test + conda devenv + conda info --envs + source activate abc + conda list dirent ctest --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ diff --git a/.gitignore b/.gitignore index bdccf70966..eeef69c758 100644 --- a/.gitignore +++ b/.gitignore @@ -66,3 +66,4 @@ abc.history .tox/ staging/ +environment.yml diff --git a/CMakeLists.txt b/CMakeLists.txt index c50607bea7..85a0236342 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -183,7 +183,7 @@ if(WIN32) add_definitions(-DWIN32 -D__MINGW32__ -DHAVE_STRUCT_TIMESPEC) if(DEFINED ENV{CONDA_PREFIX}) target_include_directories(abc_interface - INTERFACE $ENV{CONDA_PREFIX}/include + INTERFACE $ENV{CONDA_PREFIX}/Library/include ) endif() endif() diff --git a/environment.devenv.yml b/environment.devenv.yml index 7943367fe4..3098713675 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -1,7 +1,7 @@ -name: abc-test +name: abc dependencies: - - python ={{ get_env("PY_VER", default="3.9") }} + - python ={{ get_env("PY_VER", default="3.10") }} - cmake>=3.18 - ninja - c-compiler @@ -10,4 +10,11 @@ dependencies: - readline=8.1 # [unix] - zlib - libpng - - dirent >=1.21,<2.0 # [win] + - dirent # [win] + +environment: + CPATH: + - $CONDA_PREFIX/include # [unix] + - $CONDA_PREFIX/Library/include # [win] + + LD_LIBRARY_PATH: $CONDA_PREFIX/lib # [unix] From 0d70dabf26e82779cc2fbd1495959d477da8d21b Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Fri, 8 Dec 2023 18:08:12 -0800 Subject: [PATCH 17/35] chg: revert to latest action and package versions * leave default PY_VER but do not specify version for action * use proper activate command workflow in build step * add some path and prefix introspection, try find/which * bump windows ci runner version, list env, cat dirent.h * do not use jinja compier templates, revert to py39/win2019 default Signed-off-by: Stephen L Arnold --- .github/workflows/conda-dev.yml | 25 ++++++++++++++----------- environment.devenv.yml | 5 +++-- 2 files changed, 17 insertions(+), 13 deletions(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 6f492258c1..4987b44c08 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -12,14 +12,11 @@ jobs: build: name: abc ${{ matrix.python-version }} ${{ matrix.os }} runs-on: ${{ matrix.os }} - defaults: - run: - shell: bash -el {0} strategy: fail-fast: false matrix: os: ['ubuntu-22.04', 'ubuntu-20.04', 'macOS-11', 'windows-2019'] - python-version: ['3.11'] + python-version: ['3.9'] use_namespace: [false, true] include: - os: 'ubuntu-22.04' @@ -37,7 +34,7 @@ jobs: extra_args: '-DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON' env: OS: ${{ matrix.os }} - PYTHON: ${{ matrix.python-version }} + PY_VER: ${{ matrix.python-version }} PYTHONIOENCODING: utf-8 CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} @@ -54,36 +51,42 @@ jobs: uses: actions/cache@v3 env: # Increase this value to reset cache if environment.devenv.yml has not changed - CACHE_NUMBER: 1 + CACHE_NUMBER: 2 with: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} - - uses: conda-incubator/setup-miniconda@v2 + - uses: conda-incubator/setup-miniconda@v3 with: auto-update-conda: true auto-activate-base: true - python-version: ${{ matrix.python-version }} + activate-environment: '' channels: conda-forge channel-priority: flexible - name: Configure condadev environment + shell: bash -l {0} env: PY_VER: ${{ matrix.python-version }} run: | conda config --set always_yes yes --set changeps1 no - conda install conda-devenv=2.1.1 + conda install conda-devenv=3.2.0 conda info conda list - name: Build and test + shell: bash -l {0} env: PY_VER: ${{ matrix.python-version }} run: | conda devenv + conda activate abc conda info --envs - source activate abc - conda list dirent + conda list + echo $CONDA_PREFIX + find $CONDA_PREFIX -maxdepth 2 -type d -name bin + cat $(find $CONDA_PREFIX -maxdepth 5 -type f -name dirent.h) || true + echo $PATH ctest --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ diff --git a/environment.devenv.yml b/environment.devenv.yml index 3098713675..252434ab01 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -4,8 +4,9 @@ dependencies: - python ={{ get_env("PY_VER", default="3.10") }} - cmake>=3.18 - ninja - - c-compiler - - cxx-compiler + - gxx_linux-64 # [linux] + - ccache # [not win] + - clcache # [win] - make # [unix] - readline=8.1 # [unix] - zlib From 992ed274a16daba716461c9ba4d8690685514a51 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 9 Dec 2023 17:04:39 -0800 Subject: [PATCH 18/35] fix: dev: relax ifdef check in cmd.c and make it windows-specific * cleanup initial extern hacks and use ioAbc.h for missing symbol * remove superfluous dirent dep on windows Signed-off-by: Stephen L Arnold --- .github/workflows/conda-dev.yml | 5 ---- environment.devenv.yml | 1 - src/base/cmd/cmd.c | 9 +++---- src/base/cmd/cmdInt.h | 8 +++--- src/base/io/ioAbc.h | 48 ++++++++++++++++----------------- src/base/io/ioInt.h | 2 -- src/base/io/ioReadBlifMv.c | 2 +- 7 files changed, 33 insertions(+), 42 deletions(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 4987b44c08..79e4792e23 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -82,11 +82,6 @@ jobs: conda devenv conda activate abc conda info --envs - conda list - echo $CONDA_PREFIX - find $CONDA_PREFIX -maxdepth 2 -type d -name bin - cat $(find $CONDA_PREFIX -maxdepth 5 -type f -name dirent.h) || true - echo $PATH ctest --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ diff --git a/environment.devenv.yml b/environment.devenv.yml index 252434ab01..d445458706 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -11,7 +11,6 @@ dependencies: - readline=8.1 # [unix] - zlib - libpng - - dirent # [win] environment: CPATH: diff --git a/src/base/cmd/cmd.c b/src/base/cmd/cmd.c index 119c57a7a9..ce27393597 100644 --- a/src/base/cmd/cmd.c +++ b/src/base/cmd/cmd.c @@ -18,7 +18,7 @@ ***********************************************************************/ -#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) +#if (defined(WIN32) || defined(__MINGW32__)) #include #else #include @@ -26,7 +26,6 @@ #endif #include "base/abc/abc.h" -#include "base/io/ioInt.h" #include "base/main/mainInt.h" #include "cmdInt.h" #include "misc/util/utilSignal.h" @@ -52,7 +51,7 @@ static int CmdCommandUnsetVariable ( Abc_Frame_t * pAbc, int argc, char ** argv static int CmdCommandUndo ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandRecall ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandEmpty ( Abc_Frame_t * pAbc, int argc, char ** argv ); -#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) +#if (defined(WIN32) || defined(__MINGW32__)) static int CmdCommandScanDir ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandRenameFiles ( Abc_Frame_t * pAbc, int argc, char ** argv ); static int CmdCommandLs ( Abc_Frame_t * pAbc, int argc, char ** argv ); @@ -106,7 +105,7 @@ void Cmd_Init( Abc_Frame_t * pAbc ) Cmd_CommandAdd( pAbc, "Basic", "undo", CmdCommandUndo, 0 ); Cmd_CommandAdd( pAbc, "Basic", "recall", CmdCommandRecall, 0 ); Cmd_CommandAdd( pAbc, "Basic", "empty", CmdCommandEmpty, 0 ); -#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) +#if (defined(WIN32) || defined(__MINGW32__)) Cmd_CommandAdd( pAbc, "Basic", "scandir", CmdCommandScanDir, 0 ); Cmd_CommandAdd( pAbc, "Basic", "renamefiles", CmdCommandRenameFiles, 0 ); Cmd_CommandAdd( pAbc, "Basic", "ls", CmdCommandLs, 0 ); @@ -1218,7 +1217,7 @@ int CmdCommandUndo( Abc_Frame_t * pAbc, int argc, char **argv ) #endif -#if (defined(WIN32) || defined(__MINGW32__)) && !defined(__cplusplus) +#if (defined(WIN32) || defined(__MINGW32__)) #include #include diff --git a/src/base/cmd/cmdInt.h b/src/base/cmd/cmdInt.h index dc6a46f659..dffdd27944 100644 --- a/src/base/cmd/cmdInt.h +++ b/src/base/cmd/cmdInt.h @@ -9,7 +9,7 @@ Synopsis [Internal declarations of the command package.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -26,6 +26,7 @@ /// INCLUDES /// //////////////////////////////////////////////////////////////////////// +#include "base/io/ioAbc.h" #include "base/main/mainInt.h" #include "cmd.h" @@ -42,8 +43,8 @@ ABC_NAMESPACE_HEADER_START struct MvCommand { - char * sName; // the command name - char * sGroup; // the group name + char * sName; // the command name + char * sGroup; // the group name Cmd_CommandFuncType pFunc; // the function to execute the command int fChange; // set to 1 to mark that the network is changed }; @@ -89,4 +90,3 @@ extern void CmdPrintTable( st__table * tTable, int fAliases ); ABC_NAMESPACE_HEADER_END #endif - diff --git a/src/base/io/ioAbc.h b/src/base/io/ioAbc.h index 77c7dc2920..b5ebcae476 100644 --- a/src/base/io/ioAbc.h +++ b/src/base/io/ioAbc.h @@ -9,7 +9,7 @@ Synopsis [External declarations.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -44,28 +44,28 @@ ABC_NAMESPACE_HEADER_START //////////////////////////////////////////////////////////////////////// // network functionality -typedef enum { - IO_FILE_NONE = 0, - IO_FILE_AIGER, - IO_FILE_BAF, - IO_FILE_BBLIF, - IO_FILE_BLIF, - IO_FILE_BLIFMV, - IO_FILE_BENCH, +typedef enum { + IO_FILE_NONE = 0, + IO_FILE_AIGER, + IO_FILE_BAF, + IO_FILE_BBLIF, + IO_FILE_BLIF, + IO_FILE_BLIFMV, + IO_FILE_BENCH, IO_FILE_BOOK, - IO_FILE_CNF, - IO_FILE_DOT, - IO_FILE_EDIF, - IO_FILE_EQN, + IO_FILE_CNF, + IO_FILE_DOT, + IO_FILE_EDIF, + IO_FILE_EQN, IO_FILE_GML, - IO_FILE_HMETIS, - IO_FILE_JSON, - IO_FILE_LIST, - IO_FILE_PLA, - IO_FILE_MOPLA, - IO_FILE_SMV, - IO_FILE_VERILOG, - IO_FILE_UNKNOWN + IO_FILE_HMETIS, + IO_FILE_JSON, + IO_FILE_LIST, + IO_FILE_PLA, + IO_FILE_MOPLA, + IO_FILE_SMV, + IO_FILE_VERILOG, + IO_FILE_UNKNOWN } Io_FileType_t; //////////////////////////////////////////////////////////////////////// @@ -111,7 +111,7 @@ extern void Io_WriteBlifLogic( Abc_Ntk_t * pNtk, char * pFileName, extern void Io_WriteBlif( Abc_Ntk_t * pNtk, char * pFileName, int fWriteLatches, int fBb2Wb, int fSeq ); extern void Io_WriteTimingInfo( FILE * pFile, Abc_Ntk_t * pNtk ); extern void Io_WriteBlifSpecial( Abc_Ntk_t * pNtk, char * FileName, char * pLutStruct, int fUseHie ); -/*=== abcWriteBlifMv.c ==========================================================*/ +/*=== abcWriteBlifMv.c ==========================================================*/ extern void Io_WriteBlifMv( Abc_Ntk_t * pNtk, char * FileName ); /*=== abcWriteBench.c =========================================================*/ extern int Io_WriteBench( Abc_Ntk_t * pNtk, const char * FileName ); @@ -162,7 +162,8 @@ extern FILE * Io_FileOpen( const char * FileName, const char * PathV /*=== ioJson.c ===========================================================*/ extern void Io_ReadJson( char * pFileName ); extern void Io_WriteJson( char * pFileName ); - +/*=== ioReadBlifMv.c =====================================================*/ +extern char * Io_MvLoadFileBz2( char * pFileName, long * pnFileSize ); ABC_NAMESPACE_HEADER_END @@ -174,4 +175,3 @@ ABC_NAMESPACE_HEADER_END //////////////////////////////////////////////////////////////////////// /// END OF FILE /// //////////////////////////////////////////////////////////////////////// - diff --git a/src/base/io/ioInt.h b/src/base/io/ioInt.h index 383683e32d..b902c587cb 100644 --- a/src/base/io/ioInt.h +++ b/src/base/io/ioInt.h @@ -45,8 +45,6 @@ ABC_NAMESPACE_HEADER_START /// FUNCTION DECLARATIONS /// //////////////////////////////////////////////////////////////////////// -extern char * Io_MvLoadFileBz2( char * pFileName, int * pnFileSize ); - ABC_NAMESPACE_HEADER_END diff --git a/src/base/io/ioReadBlifMv.c b/src/base/io/ioReadBlifMv.c index deb5e6d33b..f437a3d102 100644 --- a/src/base/io/ioReadBlifMv.c +++ b/src/base/io/ioReadBlifMv.c @@ -115,7 +115,7 @@ static int Io_MvParseLineMv( Io_MvMod_t * p, char * pLine ); static int Io_MvParseLineNamesMv( Io_MvMod_t * p, char * pLine, int fReset ); static int Io_MvParseLineNamesBlif( Io_MvMod_t * p, char * pLine ); static int Io_MvParseLineShortBlif( Io_MvMod_t * p, char * pLine ); -static int Io_MvParseLineLtlProperty( Io_MvMod_t * p, char * pLine ); +static int Io_MvParseLineLtlProperty( Io_MvMod_t * p, char * pLine ); static int Io_MvParseLineGateBlif( Io_MvMod_t * p, Vec_Ptr_t * vTokens ); static Io_MvVar_t * Abc_NtkMvVarDup( Abc_Ntk_t * pNtk, Io_MvVar_t * pVar ); From 3ef8651779c57268885e2830ec8073b815c20c74 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 2 Feb 2025 17:25:22 -0800 Subject: [PATCH 19/35] chg: dev: cleanup coverage, .gitignore, and tox cmds Signed-off-by: Stephen L Arnold --- .gitignore | 3 +++ CMakeLists.txt | 2 +- cmake/coverage.cmake | 24 ++++++++++++------------ tox.ini | 42 +++++++++++++++++++++--------------------- 4 files changed, 37 insertions(+), 34 deletions(-) diff --git a/.gitignore b/.gitignore index eeef69c758..f383e5b3f8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,6 @@ +default.profraw +result.blif + DebugLib/ DebugExe/ DebugExt/ diff --git a/CMakeLists.txt b/CMakeLists.txt index 85a0236342..5a42a43c0b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -23,7 +23,7 @@ project( set(CMAKE_EXPORT_COMPILE_COMMANDS ON) set(CMAKE_VERBOSE_MAKEFILE ON) -set(CMAKE_CXX_STANDARD 11) +set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_EXTENSIONS OFF) diff --git a/cmake/coverage.cmake b/cmake/coverage.cmake index 57829c2df4..eb2c5e42eb 100644 --- a/cmake/coverage.cmake +++ b/cmake/coverage.cmake @@ -74,18 +74,6 @@ function(add_coverage TARGET) add_custom_target(coverage) - if(COVERAGE_TEXT) - add_custom_target( - coverage-text - COMMAND - ${LLVM_COV_PATH} report `cat ${COVERAGE_TARGETS}` - -instr-profile=${COVERAGE_PROFDATA} - -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" - DEPENDS coverage-profdata - ) - add_dependencies(coverage coverage-text) - endif() - if(COVERAGE_HTML) add_custom_target( coverage-html @@ -112,6 +100,18 @@ function(add_coverage TARGET) ) add_dependencies(coverage coverage-lcov) endif() + + if(COVERAGE_TEXT) + add_custom_target( + coverage-text + COMMAND + ${LLVM_COV_PATH} report `cat ${COVERAGE_TARGETS}` + -instr-profile=${COVERAGE_PROFDATA} + -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" + DEPENDS coverage-profdata + ) + add_dependencies(coverage coverage-text) + endif() endif() add_custom_target( diff --git a/tox.ini b/tox.ini index 09c3cf1092..faad77da60 100644 --- a/tox.ini +++ b/tox.ini @@ -9,12 +9,12 @@ setenv = {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-march=native -O2 -g -DNDEBUG} - {base,build,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} - {base,build,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} - {base,build,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} + {base,libs,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} + {base,libs,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} + {base,libs,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} BUILD_TYPE={env:BUILD_TYPE:Release} base: PREFIX={env:PREFIX:staging} - build: PREFIX={env:PREFIX:../staging} + libs: PREFIX={env:PREFIX:../staging} passenv = CC @@ -39,29 +39,29 @@ skip_install = true setenv = {abc,tests}: {[base]setenv} - {base,build,clang,ctest,ctestwin}: {[base]setenv} + {base,libs,clang,ctest,ctestwin}: {[base]setenv} passenv = {[base]passenv} allowlist_externals = - {abc,demo,soname,tests,lint,base,build,clang,ctest,grind,unbuild}: bash + {abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,cclean}: bash {abc,demo,soname,tests,clean}: make changedir = - {base,build,clang}: {toxinidir}/build + {base,libs,clang}: {toxinidir}/build deps = - {abc,demo,soname,tests,lint,base,build,clang,ctest,grind,ctestwin}: pip>=21.3 + {abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,ctestwin}: pip>=21.3 {abc,demo,soname,tests}: this-cli - {base,build,clang,ctest,grind,ctestwin}: cmake - {base,build,clang,ctest,grind,ctestwin}: ninja + {base,libs,clang,ctest,grind,ctestwin}: cmake + {base,libs,clang,ctest,grind,ctestwin}: ninja lint: cpplint grind: ValgrindCI - clang: lcov_cobertura + clang: https://github.com/sarnold/lcov-to-cobertura-xml/releases/download/2.0.3/lcov_cobertura-2.0.3-py3-none-any.whl commands_pre = - {base,build,clang}: cmake -E make_directory {toxinidir}/build + {base,libs,clang}: cmake -E make_directory {toxinidir}/build commands = abc: make -j{env:CPUS} ABC_USE_PIC=1 {posargs} abc @@ -73,17 +73,17 @@ commands = demo: bash -c '$CC {posargs} -Wall -c src/demo.c -o demo.o' demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' demo: bash -c './demo i10.aig' - {abc,soname,tests}: bash -c 'ls -lh *abc* demo || true' + {abc,soname,tests}: bash -c 'ls -lh *abc* || true' base: cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. base: cmake --build . --target install -j {env:CPUS} - build: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. - clang: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DCOVERAGE_BUILD=ON -DBUILD_SHARED_LIBS=OFF .. - {build}: cmake --build . -j {env:CPUS} + libs: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + clang: cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DCOVERAGE_BUILD=ON -DCOVERAGE_TEXT=ON -DBUILD_SHARED_LIBS=OFF .. + {libs}: cmake --build . -j {env:CPUS} {clang}: cmake --build . --target coverage -j {env:CPUS} - {build,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ - clang: lcov_cobertura build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml - {base,build}: cmake --build . --target install - {base,build}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' + {libs,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ + clang: lcov_cobertura {toxinidir}/build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml + {base,libs}: cmake --build . --target install + {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/base_test build/libabc.* || true' @@ -93,5 +93,5 @@ commands = grind: bash -c 'valgrind --tool=memcheck --xml=yes --xml-file=abc_check.xml --leak-check=full --show-leak-kinds=definite,possible --error-exitcode=127 ./build/src/base/main/abc "-c" "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec"' grind: valgrind-ci abc_check.xml --number-of-errors grind: valgrind-ci abc_check.xml --summary - unbuild: bash -c 'rm -rf build/ *.xml *.blif *.profraw' + cclean: bash -c 'rm -rf build/ *.xml *.blif *.profraw staging/' clean: make clean From cad2565abed3165f5b103afbc3914b21cc90cadf Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 2 Feb 2025 22:30:04 -0800 Subject: [PATCH 20/35] chg: dev: (re)generate, update all cmake build files Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 2 +- src/aig/aig/CMakeLists.txt | 44 +++---- src/aig/gia/CMakeLists.txt | 199 ++++++++++++++++--------------- src/aig/hop/CMakeLists.txt | 10 +- src/aig/ioa/CMakeLists.txt | 2 +- src/aig/ivy/CMakeLists.txt | 30 ++--- src/aig/saig/CMakeLists.txt | 40 +++---- src/base/abc/CMakeLists.txt | 34 +++--- src/base/abci/CMakeLists.txt | 126 +++++++++---------- src/base/acb/CMakeLists.txt | 6 +- src/base/bac/CMakeLists.txt | 22 ++-- src/base/cba/CMakeLists.txt | 10 +- src/base/cmd/CMakeLists.txt | 12 +- src/base/exor/CMakeLists.txt | 8 +- src/base/io/CMakeLists.txt | 45 +++---- src/base/pla/CMakeLists.txt | 8 +- src/base/ver/CMakeLists.txt | 4 +- src/base/wlc/CMakeLists.txt | 26 ++-- src/base/wln/CMakeLists.txt | 18 +-- src/bdd/bbr/CMakeLists.txt | 2 +- src/bdd/cas/CMakeLists.txt | 2 +- src/bdd/cudd/CMakeLists.txt | 96 +++++++-------- src/bdd/dsd/CMakeLists.txt | 4 +- src/bdd/extrab/CMakeLists.txt | 14 +-- src/bdd/llb/CMakeLists.txt | 28 ++--- src/bdd/reo/CMakeLists.txt | 10 +- src/bool/bdc/CMakeLists.txt | 2 +- src/bool/dec/CMakeLists.txt | 4 +- src/bool/kit/CMakeLists.txt | 14 +-- src/bool/lucky/CMakeLists.txt | 8 +- src/bool/rsb/CMakeLists.txt | 2 +- src/map/amap/CMakeLists.txt | 18 +-- src/map/cov/CMakeLists.txt | 8 +- src/map/fpga/CMakeLists.txt | 18 +-- src/map/if/CMakeLists.txt | 35 +++--- src/map/if/acd/CMakeLists.txt | 5 + src/map/mapper/CMakeLists.txt | 24 ++-- src/map/mio/CMakeLists.txt | 8 +- src/map/mpm/CMakeLists.txt | 12 +- src/map/scl/CMakeLists.txt | 14 +-- src/map/super/CMakeLists.txt | 2 +- src/misc/bzlib/CMakeLists.txt | 6 +- src/misc/espresso/CMakeLists.txt | 58 ++++----- src/misc/extra/CMakeLists.txt | 24 ++-- src/misc/mvc/CMakeLists.txt | 14 +-- src/misc/parse/CMakeLists.txt | 2 +- src/misc/st/CMakeLists.txt | 2 +- src/misc/tim/CMakeLists.txt | 4 +- src/misc/util/CMakeLists.txt | 8 +- src/misc/zlib/CMakeLists.txt | 20 ++-- src/opt/cgt/CMakeLists.txt | 4 +- src/opt/csw/CMakeLists.txt | 4 +- src/opt/cut/CMakeLists.txt | 10 +- src/opt/dar/CMakeLists.txt | 10 +- src/opt/dau/CMakeLists.txt | 12 +- src/opt/fret/CMakeLists.txt | 2 +- src/opt/fsim/CMakeLists.txt | 4 +- src/opt/fxch/CMakeLists.txt | 4 +- src/opt/fxu/CMakeLists.txt | 12 +- src/opt/lpk/CMakeLists.txt | 16 +-- src/opt/mfs/CMakeLists.txt | 12 +- src/opt/nwk/CMakeLists.txt | 18 +-- src/opt/res/CMakeLists.txt | 10 +- src/opt/ret/CMakeLists.txt | 6 +- src/opt/rwr/CMakeLists.txt | 8 +- src/opt/rwt/CMakeLists.txt | 2 +- src/opt/sbd/CMakeLists.txt | 10 +- src/opt/sfm/CMakeLists.txt | 12 +- src/opt/sim/CMakeLists.txt | 12 +- src/phys/place/CMakeLists.txt | 10 +- src/proof/abs/CMakeLists.txt | 22 ++-- src/proof/acec/CMakeLists.txt | 26 ++-- src/proof/cec/CMakeLists.txt | 26 ++-- src/proof/dch/CMakeLists.txt | 10 +- src/proof/fra/CMakeLists.txt | 22 ++-- src/proof/fraig/CMakeLists.txt | 14 +-- src/proof/int/CMakeLists.txt | 16 +-- src/proof/int2/CMakeLists.txt | 4 +- src/proof/live/CMakeLists.txt | 10 +- src/proof/pdr/CMakeLists.txt | 8 +- src/proof/ssc/CMakeLists.txt | 4 +- src/proof/ssw/CMakeLists.txt | 30 ++--- src/sat/bmc/CMakeLists.txt | 48 ++++---- src/sat/bsat/CMakeLists.txt | 22 ++-- src/sat/bsat2/CMakeLists.txt | 8 +- src/sat/cnf/CMakeLists.txt | 10 +- src/sat/glucose/CMakeLists.txt | 6 +- src/sat/glucose2/CMakeLists.txt | 8 +- src/sat/msat/CMakeLists.txt | 10 +- src/sat/satoko/CMakeLists.txt | 2 +- src/sat/xsat/CMakeLists.txt | 4 +- 91 files changed, 806 insertions(+), 796 deletions(-) create mode 100644 src/map/if/acd/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index 5a42a43c0b..0cdbb88744 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -100,7 +100,7 @@ set(abc_INCLUDE_DIR set(ABC_MODULES src/base/abc src/base/abci src/base/cmd src/base/io src/base/main src/base/exor src/base/ver src/base/wlc src/base/wln src/base/acb src/base/bac src/base/cba src/base/pla src/base/test - src/map/mapper src/map/mio src/map/super src/map/if + src/map/mapper src/map/mio src/map/super src/map/if/acd src/map/if src/map/amap src/map/cov src/map/scl src/map/mpm src/misc/extra src/misc/mvc src/misc/st src/misc/util src/misc/nm src/misc/vec src/misc/hash src/misc/tim src/misc/bzlib src/misc/zlib diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt index 2676c786fa..902a762954 100644 --- a/src/aig/aig/CMakeLists.txt +++ b/src/aig/aig/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME aig_aig SOURCES - aigPartReg.c - aigCanon.c - aigDfs.c - aigSplit.c - aigTruth.c - aigInter.c aigTable.c + aigJust.c + aigOper.c + aigScl.c + aigDfs.c + aigPart.c + aigShow.c + aigFanout.c + aigPartReg.c aigWin.c - aigTsim.c - aigUtil.c - aigPartSat.c aigObj.c - aigPack.c - aigMem.c - aigFanout.c + aigCanon.c aigTiming.c - aigPart.c - aigShow.c - aigRet.c - aigDup.c - aigScl.c + aigOrder.c aigRepr.c + aigMem.c + aigPack.c aigCheck.c - aigOper.c + aigCuts.c + aigTruth.c aigMan.c + aigInter.c + aigSplit.c aigFrames.c - aigMffc.c - aigJust.c + aigUtil.c aigRetF.c - aigOrder.c - aigCuts.c + aigPartSat.c + aigDup.c + aigTsim.c + aigMffc.c + aigRet.c ) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index 113b169d12..4b56918def 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -1,117 +1,120 @@ abc_libabc_add_sources( NAME aig_gia SOURCES - giaMuxes.c - giaFx.c + giaSupp.c + giaCSat.c + giaIso3.c + giaIff.c + giaCTas.c giaSatLut.c - giaShow.c - giaIiff.c - giaLf.c - giaCut.c - giaSupps.c - giaAiger.c - giaAgi.c - giaCSat2.c - giaAig.c - giaBalAig.c - giaSatEdge.c - giaCCof.c - gia.c giaExist.c - giaKf.c - giaCone.c - giaIso2.c - giaReshape1.c - giaSpeedup.c - giaMf.c - giaFalse.c - giaAigerExt.c - giaOf.c - giaCSatP.c - giaEra2.c - giaTtopt.cpp - giaShrink.c - giaSif.c - giaResub2.c - giaCSat.c - giaFront.c - giaTis.c - giaTim.c - giaDup.c - giaGlitch.c - giaCof.c - giaScl.c - giaRex.c - giaSatLE.c - giaBidec.c giaEra.c - giaUnate.c - giaDecs.c - giaQbf.c - giaCTas.c - giaSweep.c - giaMini.c - giaReshape2.c - giaForce.c + giaStr.c + giaResub.c + giaBalMap.c + giaTruth.c + giaPat2.c + giaMinLut.c + giaBalAig.c giaTransduction.cpp - giaJf.c + giaSif.c + giaRetime.c + giaCex.c + giaTsim.c + giaSweeper.c + giaCSatOld.c + giaFrames.c + giaDfs.c giaGig.c - giaMan.c - giaSupMin.c - giaResub3.c - giaDeep.c - giaPat.c - giaCSat3.c - giaMinLut2.c - giaShrink6.c - giaIso3.c - giaStr.c - giaSwitch.c - giaUtil.c + giaSatoko.c + giaAiger.c + giaBalLut.c giaResub6.c - giaResub.c + giaAig.c + giaUnate.c giaEdge.c - giaSupp.c - giaSatSyn.c - giaScript.c + giaSimBase.c + giaMuxes.c + giaResub2.c + giaShrink7.c giaEmbed.c - giaMinLut.c - giaSim2.c - giaSweeper.c - giaCex.c + giaScl.c giaSatMap.c - giaMfs.c + giaHash.c + giaShrink.c + giaSplit.c + giaTim.c + giaCone.c + giaUtil.c + giaCut.c + giaSweep.c giaTranStoch.c - giaTruth.c + giaPack.c + giaMulFind.c + giaLf.c + giaGlitch.c + giaMfs.c giaNf.c + giaForce.c + giaClp.c + giaAgi.c + giaMf.c + giaCof.c + giaPf.c + giaMini.c + giaSatLE.c + giaRex.c + giaFx.c + giaMan.c + giaCSat3.c + giaFront.c + giaShow.c + giaDup.c + giaTis.c + giaResub3.c + giaReshape1.c + giaIso.c + giaEra2.c + giaIso2.c + giaCCof.c + giaSim2.c + giaSatSyn.c + giaDeep.c + giaSim.c giaSat3.c - giaIf.c - giaStg.c - giaEnable.c - giaEsop.c - giaSimBase.c - giaHash.c - giaCSatOld.c - giaMem.c - giaPack.c + giaBound.c + giaSwitch.c giaFanout.c - giaSplit.c - giaSim.c - giaSatoko.c - giaIff.c - giaPat2.c - giaTsim.c - giaStoch.c - giaRetime.c - giaGen.c + giaQbf.c giaEquiv.c - giaDfs.c - giaFrames.c - giaClp.c - giaBalLut.c + giaSpeedup.c + giaShrink6.c + gia.c + giaMem.c + giaBidec.c + giaMinLut2.c + giaPat.c + giaStg.c + giaReshape2.c + giaSupps.c + giaGen.c + giaRrr.cpp + giaOf.c + giaSupMin.c + giaKf.c + giaDecs.c + giaEsop.c + giaAigerExt.c giaSort.c - giaPf.c - giaBalMap.c - giaShrink7.c - giaIso.c + giaFalse.c + giaCSatP.c + giaIiff.c + giaTtopt.cpp + giaStoch.c + giaCSat2.c + giaScript.c + giaSatEdge.c + giaEnable.c + giaIf.c + giaJf.c ) diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt index b7c69c6653..ae6aaa0d22 100644 --- a/src/aig/hop/CMakeLists.txt +++ b/src/aig/hop/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME aig_hop SOURCES - hopTruth.c - hopTable.c + hopBalance.c hopMan.c + hopUtil.c hopMem.c + hopOper.c hopDfs.c - hopBalance.c hopCheck.c - hopOper.c hopObj.c - hopUtil.c + hopTable.c + hopTruth.c ) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt index 040b8625c8..3cb61395d2 100644 --- a/src/aig/ioa/CMakeLists.txt +++ b/src/aig/ioa/CMakeLists.txt @@ -2,6 +2,6 @@ abc_libabc_add_sources( NAME aig_ioa SOURCES ioaWriteAig.c - ioaReadAig.c ioaUtil.c + ioaReadAig.c ) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt index ce757b4fdb..890e10cb42 100644 --- a/src/aig/ivy/CMakeLists.txt +++ b/src/aig/ivy/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME aig_ivy SOURCES - ivySeq.c - ivyMem.c + ivyUtil.c ivyMan.c - ivyMulti.c - ivyFraig.c - ivyShow.c - ivyFastMap.c + ivyDfs.c + ivyMem.c + ivySeq.c ivyCutTrav.c - ivyUtil.c + ivyObj.c ivyCanon.c - ivyResyn.c - ivyOper.c - ivyFanout.c - ivyHaig.c ivyBalance.c + ivyHaig.c + ivyShow.c + ivyDsd.c ivyRwr.c - ivyCheck.c - ivyObj.c ivyCut.c - ivyDsd.c - ivyDfs.c + ivyMulti.c + ivyFraig.c + ivyResyn.c + ivyFastMap.c + ivyFanout.c ivyTable.c + ivyCheck.c + ivyOper.c ) diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt index 81024309bf..1a6d6825b5 100644 --- a/src/aig/saig/CMakeLists.txt +++ b/src/aig/saig/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME aig_saig SOURCES - saigSimFast.c - saigWnd.c - saigCone.c saigTempor.c - saigSynch.c + saigConstr.c + saigStrSim.c + saigIoa.c + saigIsoSlow.c + saigIso.c + saigRetMin.c + saigTrans.c + saigDual.c + saigMiter.c + saigPhase.c + saigRetStep.c + saigOutDec.c saigScl.c + saigSwitch.c saigConstr2.c - saigRetMin.c - saigRetFwd.c - saigIoa.c + saigCone.c saigInd.c - saigSimMv.c - saigSwitch.c + saigWnd.c + saigSimFast.c + saigSynch.c + saigRetFwd.c saigIsoFast.c - saigSimSeq.c - saigDual.c - saigOutDec.c - saigIsoSlow.c saigDup.c - saigPhase.c - saigRetStep.c - saigStrSim.c - saigMiter.c - saigIso.c - saigConstr.c - saigTrans.c + saigSimMv.c + saigSimSeq.c ) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt index 88794c8e85..844d997de2 100644 --- a/src/base/abc/CMakeLists.txt +++ b/src/base/abc/CMakeLists.txt @@ -1,27 +1,27 @@ abc_libabc_add_sources( NAME base_abc SOURCES - abcFanOrder.c - abcFanio.c - abcHieGia.c - abcFunc.c + abcMinBase.c + abcHieNew.c + abcAig.c abcLib.c + abcFunc.c + abcNames.c + abcHieGia.c abcNtk.c - abcDfs.c - abcSop.c - abcBlifMv.c + abcNetlist.c abcShow.c + abcBarBuf.c + abcDfs.c abcCheck.c - abcNetlist.c - abcRefs.c - abcUtil.c - abcHieNew.c + abcBlifMv.c + abcFanOrder.c + abcObj.c abcLatch.c - abcHie.c - abcAig.c + abcSop.c abcHieCec.c - abcNames.c - abcBarBuf.c - abcMinBase.c - abcObj.c + abcRefs.c + abcHie.c + abcFanio.c + abcUtil.c ) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index 5e506b1197..420cb182e0 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -1,81 +1,81 @@ abc_libabc_add_sources( NAME base_abci SOURCES - abcDress3.c - abcFxu.c - abcTiming.c - abcBalance.c - abcDec.c - abcNpn.c - abcIfMux.c - abcFx.c + abcExtract.c abcAttach.c - abcQuant.c - abcBm.c - abcBidec.c - abcPart.c - abcLog.c + abcOdc.c + abcCollapse.c + abcNtbdd.c + abcDsd.c abcUnreach.c - abcFraig.c - abcProve.c - abcRefactor.c - abcRec3.c - abcSweep.c - abcRunGen.c - abcLutmin.c - abcReorder.c - abcDebug.c abcXsim.c - abcUnate.c - abcRestruct.c - abcResub.c - abcRpo.c - abcMiter.c - abcMulti.c - abcEco.c + abcDar.c + abcDress.c + abcExact.c + abcReach.c + abcIfif.c + abc.c + abcQbf.c + abcDec.c + abcDress3.c + abcScorr.c + abcBidec.c + abcCas.c + abcBmc.c abcReconv.c + abcLog.c abcMerge.c - abcMini.c - abcStrash.c - abcPrint.c + abcEco.c + abcDetect.c + abcDress2.c + abcGen.c + abcResub.c + abcSense.c + abcBm.c abcRr.c - abcRenode.c - abcVerify.c - abcQbf.c - abcBmc.c - abcSymm.c + abcQuant.c abcHaig.c - abcScorr.c - abc.c - abcDetect.c + abcBalance.c + abcPrint.c + abcRewrite.c abcAuto.c - abcMap.c - abcSat.c - abcGen.c - abcDsd.c - abcDar.c + abcSweep.c + abcMulti.c + abcIf.c abcLut.c - abcIfif.c - abcCollapse.c + abcRestruct.c + abcSymm.c + abcPart.c + abcMini.c + abcProve.c + abcRenode.c + abcCascade.c + abcSaucy.c + abcStrash.c + abcIvy.c + abcDebug.c abcNpnSave.c - abcNtbdd.c - abcExtract.c + abcRunGen.c + abcMap.c + abcCut.c + abcUnate.c + abcMiter.c + abcLutmin.c abcOrder.c - abcSaucy.c - abcCascade.c abcOrchestration.c - abcOdc.c - abcDress.c - abcExact.c - abcCut.c - abcTim.c - abcIvy.c - abcCas.c - abcDress2.c - abcSense.c + abcFxu.c abcMfs.c + abcFraig.c + abcTim.c + abcIfMux.c + abcReorder.c abcSpeedup.c - abcReach.c - abcIf.c - abcRewrite.c + abcRpo.c + abcRec3.c + abcVerify.c + abcFx.c + abcTiming.c + abcRefactor.c + abcNpn.c + abcSat.c ) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt index e75177562a..5dd0429f93 100644 --- a/src/base/acb/CMakeLists.txt +++ b/src/base/acb/CMakeLists.txt @@ -3,11 +3,11 @@ abc_libabc_add_sources( SOURCES acbPush.c acbFunc.c - acbUtil.c + acbTest.c acbCom.c acbAbc.c - acbTest.c + acbAig.c + acbUtil.c acbMfs.c acbSets.c - acbAig.c ) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt index b05a4d3ade..8494cc7e99 100644 --- a/src/base/bac/CMakeLists.txt +++ b/src/base/bac/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME base_bac SOURCES - bacPtr.c - bacCom.c bacReadBlif.c - bacReadSmt.c - bacPrsTrans.c + bacPrsBuild.c + bacWriteSmt.c bacWriteBlif.c - bacLib.c - bacReadVer.c + bacPtr.c + bacBac.c bacPtrAbc.c - bacBlast.c - bacWriteSmt.c - bacPrsBuild.c - bacWriteVer.c + bacReadSmt.c bacNtk.c - bacBac.c + bacWriteVer.c + bacReadVer.c + bacLib.c + bacPrsTrans.c + bacBlast.c + bacCom.c ) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt index 2877965c93..694f1a20b2 100644 --- a/src/base/cba/CMakeLists.txt +++ b/src/base/cba/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME base_cba SOURCES - cbaCba.c - cbaCom.c + cbaNtk.c cbaReadVer.c cbaReadBlif.c - cbaWriteVer.c - cbaBlast.c + cbaCba.c cbaWriteBlif.c - cbaNtk.c + cbaCom.c + cbaBlast.c + cbaWriteVer.c ) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt index 56c4f7d648..b423e48e0a 100644 --- a/src/base/cmd/CMakeLists.txt +++ b/src/base/cmd/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME base_cmd SOURCES - cmdAlias.c - cmdAuto.c - cmdUtils.c - cmdStarter.c cmd.c cmdHist.c cmdLoad.c - cmdApi.c - cmdFlag.c + cmdUtils.c + cmdStarter.c + cmdAuto.c cmdPlugin.c + cmdAlias.c + cmdFlag.c + cmdApi.c ) diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt index d33e750390..cb02c515d6 100644 --- a/src/base/exor/CMakeLists.txt +++ b/src/base/exor/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME base_exor SOURCES - exor.c - exorBits.c - exorUtil.c - exorList.c exorCubes.c exorLink.c + exorList.c + exor.c + exorUtil.c + exorBits.c ) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index f7a73f69c4..80f16182ef 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -1,36 +1,37 @@ abc_libabc_add_sources( NAME base_io SOURCES - ioReadBench.c - ioReadEdif.c - ioWriteVerilog.c - ioWriteBench.c - ioWritePla.c - ioWriteGml.c + ioWriteHMetis.c + ioReadBlifMv.c + ioWriteBblif.c ioReadBblif.c - ioReadVerilog.c - ioWriteBaf.c - ioReadDsd.c - ioWriteDot.c io.c - ioWriteEdgelist.c - ioReadPlaMo.c - ioReadBaf.c - ioWriteList.c - ioJson.c - ioWriteAiger.c ioWriteBook.c - ioWriteBblif.c - ioReadBlifMv.c - ioReadEqn.c ioUtil.c + ioJson.c + ioWriteBlifMv.c + ioWriteVerilog.c + ioWriteBlif.c ioReadBlif.c + ioReadDsd.c ioWriteEqn.c + ioWriteList.c + ioWriteBaf.c + ioReadEqn.c + ioReadVerilog.c ioReadPla.c + ioReadBench.c ioReadAiger.c ioReadBlifAig.c - ioWriteCnf.c - ioWriteBlifMv.c + ioReadEdif.c + ioWriteBench.c + ioWriteDot.c + ioWritePla.c + ioWriteEdgelist.c ioWriteSmv.c - ioWriteBlif.c + ioWriteCnf.c + ioWriteAiger.c + ioReadPlaMo.c + ioWriteGml.c + ioReadBaf.c ) diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt index 0211d0918d..867a19c6a9 100644 --- a/src/base/pla/CMakeLists.txt +++ b/src/base/pla/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME base_pla SOURCES - plaCom.c + plaSimple.c + plaRead.c plaMerge.c plaHash.c - plaRead.c - plaSimple.c - plaMan.c plaWrite.c + plaCom.c + plaMan.c ) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt index a1ccc153bc..00a5a9df31 100644 --- a/src/base/ver/CMakeLists.txt +++ b/src/base/ver/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME base_ver SOURCES + verFormula.c + verStream.c verParse.c verCore.c - verStream.c - verFormula.c ) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt index cdd41267ae..6fcd44e0e7 100644 --- a/src/base/wlc/CMakeLists.txt +++ b/src/base/wlc/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME base_wlc SOURCES - wlcNdr.c - wlcPth.c - wlcAbc.c wlcCom.c + wlcPth.c wlcJson.c - wlcStdin.c - wlcReadVer.c + wlcWriteVer.c + wlcWin.c + wlcUif.c + wlcSim.c + wlcAbc.c + wlcAbs2.c wlcNtk.c - wlcAbs.c - wlcBlast.c - wlcMem.c wlcReadSmt.c - wlcSim.c + wlcBlast.c + wlcReadVer.c wlcShow.c - wlcAbs2.c - wlcWin.c - wlcWriteVer.c wlcGraft.c - wlcUif.c + wlcAbs.c + wlcStdin.c + wlcNdr.c + wlcMem.c ) diff --git a/src/base/wln/CMakeLists.txt b/src/base/wln/CMakeLists.txt index de52a9b46a..fe8d18d8ea 100644 --- a/src/base/wln/CMakeLists.txt +++ b/src/base/wln/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME base_wln SOURCES - wlnRetime.c - wlnRead.c - wlnWlc.c - wlnRtl.c - wlnMem.c wlnWriteVer.c - wlnNtk.c wln.c - wlnGuide.c - wlnObj.c - wlnBlast.c + wlnNtk.c wlnNdr.c + wlnObj.c wlnCom.c + wlnGuide.c + wlnRead.c + wlnWlc.c + wlnMem.c + wlnBlast.c + wlnRtl.c + wlnRetime.c ) diff --git a/src/bdd/bbr/CMakeLists.txt b/src/bdd/bbr/CMakeLists.txt index 95c8128eb1..b1863602c2 100644 --- a/src/bdd/bbr/CMakeLists.txt +++ b/src/bdd/bbr/CMakeLists.txt @@ -3,6 +3,6 @@ abc_libabc_add_sources( SOURCES bbrImage.c bbrCex.c - bbrReach.c bbrNtbdd.c + bbrReach.c ) diff --git a/src/bdd/cas/CMakeLists.txt b/src/bdd/cas/CMakeLists.txt index 7d0d295b7e..1ffcad65ec 100644 --- a/src/bdd/cas/CMakeLists.txt +++ b/src/bdd/cas/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bdd_cas SOURCES - casCore.c casDec.c + casCore.c ) diff --git a/src/bdd/cudd/CMakeLists.txt b/src/bdd/cudd/CMakeLists.txt index 3741da9129..4f7f18eecb 100644 --- a/src/bdd/cudd/CMakeLists.txt +++ b/src/bdd/cudd/CMakeLists.txt @@ -1,65 +1,65 @@ abc_libabc_add_sources( NAME bdd_cudd SOURCES - cuddSat.c - cuddMatMult.c - cuddWindow.c - cuddInteract.c - cuddZddSetop.c - cuddZddIsop.c - cuddCompose.c - cuddInit.c - cuddSolve.c - cuddBddCorr.c - cuddZddPort.c - cuddZddGroup.c cuddBddIte.c - cuddAndAbs.c - cuddSubsetHB.c - cuddReorder.c - cuddLinear.c - cuddGenCof.c - cuddAnneal.c + cuddZddMisc.c + cuddSubsetSP.c + cuddExport.c + cuddLCache.c + cuddCache.c + cuddGroup.c + cuddInit.c + cuddZddReord.c cuddAddAbs.c + cuddTable.c + cuddAddInv.c + cuddSubsetHB.c + cuddRef.c cuddAddFind.c + cuddZddIsop.c + cuddZddSetop.c + cuddLiteral.c + cuddApprox.c cuddUtil.c - cuddCof.c - cuddLevelQ.c - cuddEssent.c - cuddClip.c + cuddReorder.c + cuddWindow.c + cuddAddApply.c + cuddGenCof.c + cuddSolve.c + cuddZddFuncs.c + cuddMatMult.c cuddCheck.c cuddApa.c - cuddSplit.c - cuddApprox.c - cuddZddUtil.c - cuddGroup.c - cuddZddLin.c + cuddZddPort.c cuddHarwell.c - cuddDecomp.c - cuddAddNeg.c - cuddSubsetSP.c - cuddAddWalsh.c - cuddAddApply.c - cuddCache.c - cuddGenetic.c - cuddExport.c - cuddZddMisc.c - cuddExact.c + cuddSymmetry.c + cuddAnneal.c + cuddZddGroup.c + cuddZddLin.c + cuddInteract.c + cuddBddAbs.c cuddBridge.c + cuddCof.c cuddZddCount.c + cuddSplit.c + cuddEssent.c + cuddRead.c + cuddBddCorr.c + cuddLinear.c + cuddExact.c + cuddAddNeg.c + cuddLevelQ.c + cuddGenetic.c cuddAddIte.c + cuddPriority.c + cuddSat.c cuddZddSymm.c - cuddLiteral.c - cuddZddReord.c + cuddDecomp.c + cuddAddWalsh.c + cuddCompose.c + cuddZddUtil.c + cuddAndAbs.c cuddSign.c - cuddBddAbs.c - cuddZddFuncs.c - cuddSymmetry.c cuddAPI.c - cuddPriority.c - cuddRef.c - cuddLCache.c - cuddAddInv.c - cuddTable.c - cuddRead.c + cuddClip.c ) diff --git a/src/bdd/dsd/CMakeLists.txt b/src/bdd/dsd/CMakeLists.txt index 93d42de977..2ab912109f 100644 --- a/src/bdd/dsd/CMakeLists.txt +++ b/src/bdd/dsd/CMakeLists.txt @@ -2,9 +2,9 @@ abc_libabc_add_sources( NAME bdd_dsd SOURCES dsdMan.c - dsdLocal.c - dsdApi.c dsdTree.c + dsdLocal.c dsdCheck.c dsdProc.c + dsdApi.c ) diff --git a/src/bdd/extrab/CMakeLists.txt b/src/bdd/extrab/CMakeLists.txt index 7fb972cd5d..0aaa0f32c2 100644 --- a/src/bdd/extrab/CMakeLists.txt +++ b/src/bdd/extrab/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME bdd_extrab SOURCES - extraBddAuto.c - extraBddImage.c - extraBddCas.c extraBddUnate.c - extraBddSet.c - extraBddMisc.c + extraBddMaxMin.c + extraBddAuto.c extraBddSymm.c + extraBddImage.c + extraBddThresh.c extraBddKmap.c + extraBddMisc.c + extraBddCas.c extraBddTime.c - extraBddMaxMin.c - extraBddThresh.c + extraBddSet.c ) diff --git a/src/bdd/llb/CMakeLists.txt b/src/bdd/llb/CMakeLists.txt index 2ccd3b3561..8d0ed0fe0d 100644 --- a/src/bdd/llb/CMakeLists.txt +++ b/src/bdd/llb/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME bdd_llb SOURCES - llb2Driver.c + llb2Image.c llb1Reach.c - llb1Cluster.c - llb1Core.c - llb1Sched.c llb3Nonlin.c - llb1Hint.c - llb4Cex.c - llb4Nonlin.c llb4Sweep.c - llb3Image.c llb2Bad.c - llb1Matrix.c - llb2Flow.c + llb4Image.c + llb3Image.c + llb4Cex.c + llb1Hint.c llb1Group.c - llb2Image.c - llb1Pivot.c + llb2Core.c + llb1Cluster.c llb1Constr.c - llb4Image.c + llb1Pivot.c llb1Man.c - llb2Core.c + llb4Nonlin.c + llb2Flow.c + llb1Sched.c + llb2Driver.c + llb1Core.c + llb1Matrix.c llb2Dump.c ) diff --git a/src/bdd/reo/CMakeLists.txt b/src/bdd/reo/CMakeLists.txt index 44e01f199b..8cc6d12660 100644 --- a/src/bdd/reo/CMakeLists.txt +++ b/src/bdd/reo/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME bdd_reo SOURCES - reoShuffle.c + reoProfile.c reoTransfer.c - reoSift.c - reoSwap.c - reoCore.c reoUnits.c - reoProfile.c reoApi.c + reoShuffle.c + reoCore.c + reoSwap.c + reoSift.c ) diff --git a/src/bool/bdc/CMakeLists.txt b/src/bool/bdc/CMakeLists.txt index bab8aecab8..32dd14d87c 100644 --- a/src/bool/bdc/CMakeLists.txt +++ b/src/bool/bdc/CMakeLists.txt @@ -2,7 +2,7 @@ abc_libabc_add_sources( NAME bool_bdc SOURCES bdcCore.c + bdcDec.c bdcTable.c bdcSpfd.c - bdcDec.c ) diff --git a/src/bool/dec/CMakeLists.txt b/src/bool/dec/CMakeLists.txt index dfbecf7c91..563637f8f8 100644 --- a/src/bool/dec/CMakeLists.txt +++ b/src/bool/dec/CMakeLists.txt @@ -2,8 +2,8 @@ abc_libabc_add_sources( NAME bool_dec SOURCES decMan.c + decUtil.c decFactor.c - decPrint.c decAbc.c - decUtil.c + decPrint.c ) diff --git a/src/bool/kit/CMakeLists.txt b/src/bool/kit/CMakeLists.txt index 0b256cf481..cb6d75e4be 100644 --- a/src/bool/kit/CMakeLists.txt +++ b/src/bool/kit/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME bool_kit SOURCES - kitDsd.c kitTruth.c - kitCloud.c - kitBdd.c - kitIsop.c - kitFactor.c - cloud.c kitAig.c kitPla.c kitSop.c - kitHop.c + cloud.c + kitBdd.c kitGraph.c + kitDsd.c + kitHop.c + kitFactor.c + kitIsop.c + kitCloud.c ) diff --git a/src/bool/lucky/CMakeLists.txt b/src/bool/lucky/CMakeLists.txt index b186e342e3..8c6e3e913b 100644 --- a/src/bool/lucky/CMakeLists.txt +++ b/src/bool/lucky/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME bool_lucky SOURCES - luckyFast16.c - luckySimple.c - luckySwapIJ.c luckyRead.c + luckySwapIJ.c + lucky.c luckyFast6.c luckySwap.c - lucky.c + luckySimple.c + luckyFast16.c ) diff --git a/src/bool/rsb/CMakeLists.txt b/src/bool/rsb/CMakeLists.txt index 57bf6b8fa0..7c3157ada7 100644 --- a/src/bool/rsb/CMakeLists.txt +++ b/src/bool/rsb/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bool_rsb SOURCES - rsbMan.c rsbDec6.c + rsbMan.c ) diff --git a/src/map/amap/CMakeLists.txt b/src/map/amap/CMakeLists.txt index 912f4241ed..0d3b8a1564 100644 --- a/src/map/amap/CMakeLists.txt +++ b/src/map/amap/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_amap SOURCES - amapOutput.c - amapCore.c - amapRead.c - amapMan.c amapLib.c - amapLiberty.c - amapMerge.c - amapMatch.c - amapPerm.c - amapParse.c amapGraph.c + amapParse.c + amapPerm.c + amapMerge.c + amapMan.c + amapLiberty.c + amapRead.c + amapCore.c amapRule.c + amapOutput.c amapUniq.c + amapMatch.c ) diff --git a/src/map/cov/CMakeLists.txt b/src/map/cov/CMakeLists.txt index 6d2f0106e4..aad831cdab 100644 --- a/src/map/cov/CMakeLists.txt +++ b/src/map/cov/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_cov SOURCES - covMinSop.c - covMinEsop.c - covMinUtil.c - covBuild.c covMinMan.c covCore.c + covMinUtil.c + covMinSop.c + covBuild.c + covMinEsop.c covMan.c ) diff --git a/src/map/fpga/CMakeLists.txt b/src/map/fpga/CMakeLists.txt index cc5b96ba8c..1699fa799e 100644 --- a/src/map/fpga/CMakeLists.txt +++ b/src/map/fpga/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_fpga SOURCES - fpgaFanout.c - fpga.c - fpgaTruth.c - fpgaLib.c - fpgaMatch.c + fpgaCutUtils.c fpgaCreate.c - fpgaTime.c - fpgaVec.c fpgaUtils.c + fpgaLib.c + fpgaVec.c + fpgaTruth.c + fpgaTime.c + fpgaSwitch.c fpgaCut.c + fpgaMatch.c + fpga.c + fpgaFanout.c fpgaCore.c - fpgaCutUtils.c - fpgaSwitch.c ) diff --git a/src/map/if/CMakeLists.txt b/src/map/if/CMakeLists.txt index 1572039fb9..442376309f 100644 --- a/src/map/if/CMakeLists.txt +++ b/src/map/if/CMakeLists.txt @@ -1,30 +1,31 @@ abc_libabc_add_sources( NAME map_if SOURCES - ifDsd.c + ifSat.c + ifDelay.c + ifReduce.c + ifCom.c ifLibLut.c - ifSeq.c + ifDec07.c ifCut.c - ifLibBox.c ifMatch2.c ifTest.c - ifSelect.c - ifCore.c - ifTime.c + ifDec16.c + ifDec66.c + ifMan.c + ifLibBox.c + ifDsd.c + ifDec10.c + ifTruth.c ifData2.c - ifReduce.c - ifCom.c - ifDec07.c + ifCache.c + ifSeq.c ifDec08.c - ifDec16.c + ifSelect.c + ifTime.c + ifMap.c + ifCore.c ifDec75.c ifTune.c - ifTruth.c - ifDec10.c - ifMap.c - ifMan.c - ifCache.c - ifSat.c ifUtil.c - ifDelay.c ) diff --git a/src/map/if/acd/CMakeLists.txt b/src/map/if/acd/CMakeLists.txt new file mode 100644 index 0000000000..4884dd1228 --- /dev/null +++ b/src/map/if/acd/CMakeLists.txt @@ -0,0 +1,5 @@ +abc_libabc_add_sources( + NAME map_if_acd + SOURCES + ac_wrapper.cpp +) diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt index 168154e6ec..18ceff8628 100644 --- a/src/map/mapper/CMakeLists.txt +++ b/src/map/mapper/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME map_mapper SOURCES - mapperMatch.c - mapper.c + mapperSwitch.c + mapperCanon.c + mapperCore.c + mapperCut.c mapperSuper.c - mapperTable.c + mapperTree.c + mapperVec.c mapperRefs.c - mapperTime.c + mapperLib.c mapperTruth.c - mapperCore.c - mapperCreate.c + mapper.c mapperCutUtils.c - mapperSwitch.c - mapperCut.c - mapperCanon.c + mapperTime.c + mapperMatch.c + mapperTable.c mapperUtils.c - mapperTree.c - mapperLib.c - mapperVec.c + mapperCreate.c ) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt index ae9ecee8e0..c0a5156c79 100644 --- a/src/map/mio/CMakeLists.txt +++ b/src/map/mio/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_mio SOURCES - mioFunc.c - mioSop.c mioApi.c - mioUtils.c mioParse.c - mio.c mioRead.c + mioSop.c + mioUtils.c + mioFunc.c + mio.c ) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt index 27990a653c..b6bc6001d6 100644 --- a/src/map/mpm/CMakeLists.txt +++ b/src/map/mpm/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_mpm SOURCES - mpmTruth.c + mpmPre.c + mpmMap.c mpmGates.c + mpmTruth.c + mpmMig.c mpmAbc.c + mpmDsd.c mpmMan.c - mpmMig.c mpmUtil.c - mpmDsd.c - mpmMap.c - mpmLib.c - mpmPre.c mpmCore.c + mpmLib.c ) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt index ceb7aa6b14..c52a750465 100644 --- a/src/map/scl/CMakeLists.txt +++ b/src/map/scl/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_scl SOURCES + sclBuffer.c sclDnsize.c - sclBufSize.c - sclLibUtil.c - scl.c sclSize.c - sclBuffer.c - sclUpsize.c - sclLoad.c + sclLibUtil.c sclUtil.c - sclLibScl.c + sclLoad.c + sclBufSize.c sclLiberty.c + sclUpsize.c + sclLibScl.c + scl.c ) diff --git a/src/map/super/CMakeLists.txt b/src/map/super/CMakeLists.txt index 97828f5a50..f7192746fc 100644 --- a/src/map/super/CMakeLists.txt +++ b/src/map/super/CMakeLists.txt @@ -2,6 +2,6 @@ abc_libabc_add_sources( NAME map_super SOURCES superGate.c - superAnd.c super.c + superAnd.c ) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt index cf5ec56f60..06182a305a 100644 --- a/src/misc/bzlib/CMakeLists.txt +++ b/src/misc/bzlib/CMakeLists.txt @@ -2,10 +2,10 @@ abc_libabc_add_sources( NAME misc_bzlib SOURCES huffman.c - randtable.c - compress.c decompress.c - blocksort.c + compress.c + randtable.c bzlib.c crctable.c + blocksort.c ) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt index 27d62c182a..a107d8b092 100644 --- a/src/misc/espresso/CMakeLists.txt +++ b/src/misc/espresso/CMakeLists.txt @@ -1,43 +1,43 @@ abc_libabc_add_sources( NAME misc_espresso SOURCES + hack.c + cvrout.c + cvrin.c + setc.c + primes.c + set.c + irred.c sminterf.c - expand.c - gasp.c - cofactor.c + contain.c + globals.c + cvrmisc.c + mincov.c + sparse.c + espresso.c cubehack.c - dominate.c - unate.c + gasp.c + matrix.c + solution.c + cubestr.c cvrm.c - equiv.c - irred.c - cols.c - compl.c + essen.c part.c - exact.c - contain.c - matrix.c - cvrout.c + verify.c pair.c + reduce.c + unate.c + compl.c + sharp.c + cofactor.c + cols.c + expand.c indep.c rows.c - hack.c - setc.c - set.c - essen.c - espresso.c - mincov.c gimpel.c - globals.c - solution.c - sparse.c - primes.c + equiv.c + dominate.c + exact.c map.c - reduce.c opo.c - cubestr.c - sharp.c - cvrmisc.c - cvrin.c - verify.c ) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt index 56779e92c8..67196e5991 100644 --- a/src/misc/extra/CMakeLists.txt +++ b/src/misc/extra/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME misc_extra SOURCES - extraUtilCfs.c - extraUtilReader.c - extraUtilDsd.c - extraUtilPath.c - extraUtilUtil.c - extraUtilGen.c extraUtilPerm.c - extraUtilEnum.c extraUtilBitMatrix.c - extraUtilTruth.c + extraUtilReader.c + extraUtilMemory.c + extraUtilCfs.c + extraUtilFile.c + extraUtilSupp.c extraUtilMacc.c + extraUtilTruth.c extraUtilMult.c + extraUtilProgress.c + extraUtilEnum.c extraUtilCanon.c - extraUtilFile.c + extraUtilPath.c extraUtilMisc.c + extraUtilGen.c + extraUtilDsd.c extraUtilMaj.c - extraUtilProgress.c extraUtilCube.c - extraUtilSupp.c - extraUtilMemory.c + extraUtilUtil.c ) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt index 264d321b46..76e54e031c 100644 --- a/src/misc/mvc/CMakeLists.txt +++ b/src/misc/mvc/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_mvc SOURCES - mvcUtils.c mvcApi.c - mvcSort.c mvcDivide.c + mvcList.c + mvcCompare.c mvcPrint.c - mvcLits.c + mvcOpBool.c + mvcSort.c mvcOpAlg.c - mvcCompare.c - mvcList.c - mvcContain.c mvcCube.c - mvcOpBool.c mvcMan.c mvcCover.c mvcDivisor.c + mvcLits.c + mvcUtils.c + mvcContain.c ) diff --git a/src/misc/parse/CMakeLists.txt b/src/misc/parse/CMakeLists.txt index b0436adc56..69b9471c5d 100644 --- a/src/misc/parse/CMakeLists.txt +++ b/src/misc/parse/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME misc_parse SOURCES - parseEqn.c parseStack.c + parseEqn.c ) diff --git a/src/misc/st/CMakeLists.txt b/src/misc/st/CMakeLists.txt index 8b0cdb9060..5bde0b50ab 100644 --- a/src/misc/st/CMakeLists.txt +++ b/src/misc/st/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME misc_st SOURCES - st.c stmm.c + st.c ) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt index e77b041b7e..1538b50007 100644 --- a/src/misc/tim/CMakeLists.txt +++ b/src/misc/tim/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME misc_tim SOURCES + timTime.c timDump.c - timMan.c timTrav.c timBox.c - timTime.c + timMan.c ) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt index d64f7e0e47..ab6ca1da2a 100644 --- a/src/misc/util/CMakeLists.txt +++ b/src/misc/util/CMakeLists.txt @@ -1,12 +1,14 @@ abc_libabc_add_sources( NAME misc_util SOURCES - utilSort.c utilIsop.c + utilFile.c + utilBSet.c + utilCex.c utilSignal.c + utilPth.c + utilSort.c utilColor.c utilNam.c utilBridge.c - utilCex.c - utilFile.c ) diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt index 3f393228c0..ae20c86b28 100644 --- a/src/misc/zlib/CMakeLists.txt +++ b/src/misc/zlib/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_zlib SOURCES - inffast.c - gzwrite.c inftrees.c - adler32.c + uncompr.c + trees.c + inflate.c crc32.c + infback.c + inffast.c gzlib.c - deflate.c - zutil.c - inflate.c gzclose.c - trees.c - gzread.c - infback.c - uncompr.c compress_.c + gzwrite.c + gzread.c + deflate.c + zutil.c + adler32.c ) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt index 3419470b54..4128222199 100644 --- a/src/opt/cgt/CMakeLists.txt +++ b/src/opt/cgt/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME opt_cgt SOURCES + cgtCore.c + cgtSat.c cgtMan.c cgtDecide.c cgtAig.c - cgtCore.c - cgtSat.c ) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt index 4f2566b766..256338a893 100644 --- a/src/opt/csw/CMakeLists.txt +++ b/src/opt/csw/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_csw SOURCES - cswTable.c + cswMan.c cswCut.c + cswTable.c cswCore.c - cswMan.c ) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt index c9902c61b2..2535cc9e7c 100644 --- a/src/opt/cut/CMakeLists.txt +++ b/src/opt/cut/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_cut SOURCES - cutOracle.c cutApi.c - cutNode.c - cutSeq.c - cutPre22.c + cutOracle.c cutMerge.c - cutTruth.c cutCut.c + cutNode.c cutMan.c + cutTruth.c + cutSeq.c + cutPre22.c ) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt index 654d57dab0..92b00f044f 100644 --- a/src/opt/dar/CMakeLists.txt +++ b/src/opt/dar/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_dar SOURCES - darCut.c - darScript.c - darRefact.c - darCore.c darData.c + darScript.c darBalance.c - darMan.c darLib.c + darMan.c darPrec.c + darCut.c + darRefact.c + darCore.c ) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt index 7989632238..c043c4369f 100644 --- a/src/opt/dau/CMakeLists.txt +++ b/src/opt/dau/CMakeLists.txt @@ -2,15 +2,15 @@ abc_libabc_add_sources( NAME opt_dau SOURCES dauNpn.c - dauDsd.c - dauGia.c - dauCount.c dauNonDsd.c - dauDivs.c dauNpn2.c dauCore.c dauMerge.c - dauEnum.c - dauCanon.c + dauDivs.c dauTree.c + dauCount.c + dauCanon.c + dauGia.c + dauEnum.c + dauDsd.c ) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt index 8774bb4908..d01604ac6d 100644 --- a/src/opt/fret/CMakeLists.txt +++ b/src/opt/fret/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fret SOURCES + fretMain.c fretInit.c fretFlow.c fretTime.c - fretMain.c ) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt index 53b06a2a8a..dd744e6588 100644 --- a/src/opt/fsim/CMakeLists.txt +++ b/src/opt/fsim/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME opt_fsim SOURCES + fsimFront.c + fsimSwitch.c fsimTsim.c fsimCore.c - fsimSwitch.c fsimMan.c - fsimFront.c fsimSim.c ) diff --git a/src/opt/fxch/CMakeLists.txt b/src/opt/fxch/CMakeLists.txt index def3fcbf7a..1ba0e72e8c 100644 --- a/src/opt/fxch/CMakeLists.txt +++ b/src/opt/fxch/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fxch SOURCES - FxchSCHashTable.c - FxchDiv.c Fxch.c + FxchDiv.c + FxchSCHashTable.c FxchMan.c ) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt index c361a3cbe2..d95fdbc203 100644 --- a/src/opt/fxu/CMakeLists.txt +++ b/src/opt/fxu/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_fxu SOURCES + fxuMatrix.c + fxuHeapD.c fxuHeapS.c + fxuPair.c fxuSelect.c fxuUpdate.c - fxuList.c - fxuHeapD.c fxu.c + fxuCreate.c + fxuList.c fxuSingle.c - fxuReduce.c - fxuPair.c fxuPrint.c - fxuCreate.c - fxuMatrix.c + fxuReduce.c ) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt index 0ec4669889..f00e5169a8 100644 --- a/src/opt/lpk/CMakeLists.txt +++ b/src/opt/lpk/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME opt_lpk SOURCES - lpkAbcMux.c - lpkCore.c - lpkMulti.c - lpkSets.c - lpkAbcDsd.c - lpkAbcUtil.c - lpkAbcDec.c - lpkCut.c lpkMap.c + lpkMulti.c lpkMux.c + lpkCut.c + lpkAbcDec.c lpkMan.c + lpkAbcDsd.c + lpkAbcUtil.c + lpkCore.c + lpkAbcMux.c + lpkSets.c ) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt index 333b317e7d..a2a325b5e9 100644 --- a/src/opt/mfs/CMakeLists.txt +++ b/src/opt/mfs/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME opt_mfs SOURCES - mfsCore.c - mfsStrash.c - mfsResub.c - mfsDiv.c + mfsSat.c + mfsInter.c mfsWin.c mfsMan.c - mfsInter.c - mfsSat.c + mfsDiv.c + mfsStrash.c + mfsResub.c + mfsCore.c ) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt index ba9918990b..0931631504 100644 --- a/src/opt/nwk/CMakeLists.txt +++ b/src/opt/nwk/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME opt_nwk SOURCES + nwkCheck.c + nwkSpeedup.c + nwkAig.c nwkBidec.c - nwkStrash.c - nwkTiming.c - nwkMan.c + nwkFlow.c nwkFanio.c - nwkUtil.c - nwkDfs.c nwkMap.c - nwkFlow.c + nwkStrash.c + nwkDfs.c nwkObj.c - nwkAig.c - nwkSpeedup.c - nwkCheck.c nwkMerge.c + nwkMan.c + nwkTiming.c + nwkUtil.c ) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt index 260474a9ce..d3d8467806 100644 --- a/src/opt/res/CMakeLists.txt +++ b/src/opt/res/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_res SOURCES - resStrash.c - resSat.c resFilter.c - resWin.c - resCore.c - resSim.c resDivs.c + resSim.c + resCore.c + resWin.c + resSat.c + resStrash.c ) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt index 16514479ce..a651c876f9 100644 --- a/src/opt/ret/CMakeLists.txt +++ b/src/opt/ret/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_ret SOURCES - retDelay.c + retFlow.c retCore.c - retInit.c retLvalue.c + retDelay.c + retInit.c retIncrem.c retArea.c - retFlow.c ) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt index b7ef5b1166..7a741a47e1 100644 --- a/src/opt/rwr/CMakeLists.txt +++ b/src/opt/rwr/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_rwr SOURCES + rwrUtil.c rwrDec.c - rwrExp.c - rwrLib.c - rwrPrint.c rwrEva.c + rwrPrint.c + rwrLib.c + rwrExp.c rwrMan.c - rwrUtil.c ) diff --git a/src/opt/rwt/CMakeLists.txt b/src/opt/rwt/CMakeLists.txt index a3c389875f..1a9d6fb7ec 100644 --- a/src/opt/rwt/CMakeLists.txt +++ b/src/opt/rwt/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME opt_rwt SOURCES - rwtMan.c rwtUtil.c rwtDec.c + rwtMan.c ) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt index b618e8367b..a7e8f9a52d 100644 --- a/src/opt/sbd/CMakeLists.txt +++ b/src/opt/sbd/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sbd SOURCES - sbdCore.c - sbd.c + sbdCnf.c sbdCut.c + sbdPath.c sbdCut2.c - sbdWin.c sbdSat.c - sbdPath.c + sbdWin.c sbdLut.c - sbdCnf.c + sbdCore.c + sbd.c ) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt index c03b1c141e..5e85451418 100644 --- a/src/opt/sfm/CMakeLists.txt +++ b/src/opt/sfm/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME opt_sfm SOURCES - sfmCore.c + sfmSat.c + sfmTim.c + sfmCnf.c + sfmArea.c sfmMit.c - sfmLib.c sfmWin.c - sfmArea.c - sfmCnf.c - sfmTim.c sfmNtk.c + sfmCore.c + sfmLib.c sfmDec.c - sfmSat.c ) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt index ae09e3c40d..3470c727b7 100644 --- a/src/opt/sim/CMakeLists.txt +++ b/src/opt/sim/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sim SOURCES - simSeq.c + simSwitch.c + simSym.c simSymSim.c + simSymSat.c simUtils.c - simSupp.c - simMan.c - simSwitch.c simSymStr.c - simSymSat.c - simSym.c + simMan.c + simSeq.c + simSupp.c ) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt index 841cd830f2..60cdf9f1b7 100644 --- a/src/phys/place/CMakeLists.txt +++ b/src/phys/place/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME phys_place SOURCES - place_inc.c - place_qpsolver.c place_pads.c - place_genqp.c - place_legalize.c + place_qpsolver.c place_partition.c - place_io.c + place_legalize.c place_bin.c + place_genqp.c place_base.c place_gordian.c + place_io.c + place_inc.c ) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt index 2ad429538d..d46922ea17 100644 --- a/src/proof/abs/CMakeLists.txt +++ b/src/proof/abs/CMakeLists.txt @@ -1,20 +1,20 @@ abc_libabc_add_sources( NAME proof_abs SOURCES - absGlaOld.c - absPth.c absOldRef.c - absOldSim.c - absVta.c - absOldSat.c - absIter.c absUtil.c - absRpmOld.c - absOldCex.c - absGla.c - absDup.c - absRef.c + absOldSat.c absRpm.c + absPth.c + absRpmOld.c + absGlaOld.c absOut.c + absIter.c + absRef.c + absDup.c + absGla.c + absOldSim.c + absOldCex.c + absVta.c absRefSelect.c ) diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt index 3df6fa529a..a1c0cc134c 100644 --- a/src/proof/acec/CMakeLists.txt +++ b/src/proof/acec/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME proof_acec SOURCES - acec2Mult.c - acecPo.c - acecOrder.c - acecSt.c - acecCl.c acecMult.c - acecPolyn.c - acecPa.c - acecPool.c - acecUtil.c acecCore.c + acecRe.c + acecFadds.c + acecPool.c + acecBo.c acecTree.c - acecCo.c + acecUtil.c acecNorm.c - acecBo.c + acecPolyn.c acecCover.c - acecFadds.c - acecRe.c + acecPa.c + acecCo.c + acecOrder.c acecXor.c + acecSt.c + acecPo.c + acec2Mult.c + acecCl.c ) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt index 869ca471ae..ff321b7e90 100644 --- a/src/proof/cec/CMakeLists.txt +++ b/src/proof/cec/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_cec SOURCES - cecChoice.c - cecSolve.c - cecSatG3.c - cecMan.c + cecProve.c cecSatG.c + cecSat.c + cecCorr.c + cecIso.c cecCec.c - cecProve.c cecCore.c - cecSplit.c + cecSweep.c cecPat.c cecSolveG.c - cecSweep.c - cecSeq.c - cecCorr.c - cecSynth.c - cecSatG2.c - cecSat.c - cecIso.c cecSim.c + cecSatG3.c + cecMan.c + cecSynth.c cecClass.c + cecSolve.c + cecChoice.c + cecSplit.c + cecSeq.c + cecSatG2.c ) diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt index 926db08cde..4730025863 100644 --- a/src/proof/dch/CMakeLists.txt +++ b/src/proof/dch/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_dch SOURCES + dchSweep.c dchAig.c + dchClass.c + dchSat.c dchSimSat.c dchSim.c - dchSat.c - dchSweep.c dchCore.c - dchCnf.c - dchClass.c - dchChoice.c dchMan.c + dchChoice.c + dchCnf.c ) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt index 885e684f5f..23d673330d 100644 --- a/src/proof/fra/CMakeLists.txt +++ b/src/proof/fra/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME proof_fra SOURCES - fraSim.c - fraInd.c - fraCec.c - fraSec.c + fraHot.c fraClau.c - fraBmc.c + fraMan.c + fraSim.c fraImp.c + fraCore.c + fraPart.c fraCnf.c + fraInd.c fraLcr.c - fraMan.c - fraClass.c - fraIndVer.c + fraBmc.c fraSat.c - fraCore.c - fraPart.c - fraHot.c + fraSec.c fraClaus.c + fraCec.c + fraIndVer.c + fraClass.c ) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt index fb6c1e991e..d84ee401f9 100644 --- a/src/proof/fraig/CMakeLists.txt +++ b/src/proof/fraig/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME proof_fraig SOURCES - fraigCanon.c - fraigApi.c - fraigTable.c - fraigUtil.c - fraigFanout.c - fraigMem.c fraigPrime.c - fraigVec.c + fraigUtil.c fraigMan.c fraigFeed.c + fraigFanout.c + fraigVec.c + fraigTable.c + fraigCanon.c + fraigApi.c + fraigMem.c fraigNode.c fraigSat.c ) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt index 358d240af1..b7d7b54158 100644 --- a/src/proof/int/CMakeLists.txt +++ b/src/proof/int/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_int SOURCES - intContain.c - intMan.c - intCtrex.c - intUtil.c + intDup.c intCheck.c - intCore.c - intM114.c - intFrames.c + intUtil.c intInter.c - intDup.c + intFrames.c + intMan.c + intM114.c + intCore.c + intContain.c + intCtrex.c ) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt index eeb9632275..2c2392b230 100644 --- a/src/proof/int2/CMakeLists.txt +++ b/src/proof/int2/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME proof_int2 SOURCES - int2Core.c - int2Util.c int2Bmc.c int2Refine.c + int2Core.c + int2Util.c ) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt index 36871b807a..6e942ebbd5 100644 --- a/src/proof/live/CMakeLists.txt +++ b/src/proof/live/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME proof_live SOURCES - arenaViolation.c disjunctiveMonotone.c + liveness_sim.c + arenaViolation.c + monotone.c combination.c - ltl_parser.c kLiveConstraints.c - kliveness.c - liveness_sim.c + ltl_parser.c liveness.c - monotone.c + kliveness.c ) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt index d523b5ea31..403198dd1a 100644 --- a/src/proof/pdr/CMakeLists.txt +++ b/src/proof/pdr/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_pdr SOURCES - pdrCnf.c + pdrCore.c pdrTsim.c + pdrSat.c + pdrCnf.c pdrIncr.c pdrUtil.c pdrTsim2.c - pdrInv.c - pdrCore.c pdrMan.c - pdrSat.c pdrTsim3.c + pdrInv.c ) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt index bff9a89169..f809a60d98 100644 --- a/src/proof/ssc/CMakeLists.txt +++ b/src/proof/ssc/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME proof_ssc SOURCES + sscUtil.c sscSim.c sscClass.c - sscUtil.c - sscSat.c sscCore.c + sscSat.c ) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt index 1493995bf2..b6d7892aa0 100644 --- a/src/proof/ssw/CMakeLists.txt +++ b/src/proof/ssw/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_ssw SOURCES - sswConstr.c - sswIslands.c - sswLcorr.c - sswPart.c - sswBmc.c - sswMan.c - sswAig.c - sswSweep.c - sswSim.c - sswCnf.c + sswSemi.c sswClass.c + sswCore.c + sswSim.c sswSimSat.c + sswSweep.c sswDyn.c - sswPairs.c - sswCore.c - sswSat.c + sswCnf.c + sswMan.c + sswConstr.c + sswPart.c + sswFilter.c sswUnique.c - sswSemi.c + sswSat.c + sswIslands.c + sswAig.c + sswLcorr.c + sswPairs.c + sswBmc.c sswRarity.c - sswFilter.c ) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt index 20a72e89a1..d041be1476 100644 --- a/src/sat/bmc/CMakeLists.txt +++ b/src/sat/bmc/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME sat_bmc SOURCES - bmcCexCut.c - bmcBmc2.c - bmcInse.c - bmcBmc.c - bmcMaxi.c - bmcBmcS.c - bmcBmc3.c - bmcLoad.c - bmcBmci.c - bmcFx.c bmcMesh2.c + bmcCexCut.c + bmcCexCare.c + bmcEco.c + bmcBmcAnd.c + bmcGen.c bmcICheck.c + bmcCexTools.c + bmcBmcS.c bmcClp.c - bmcBCore.c - bmcMaj3.c - bmcGen.c - bmcCexMin2.c - bmcMaj.c - bmcCexCare.c + bmcInse.c bmcFault.c - bmcUnroll.c - bmcMaj2.c - bmcExpand.c bmcCexMin1.c - bmcEco.c + bmcBmc.c + bmcMaj3.c bmcMulti.c - bmcMesh.c - bmcCexTools.c - bmcCexDepth.c + bmcMaj.c + bmcMaj2.c + bmcBmci.c + bmcUnroll.c + bmcBmc2.c + bmcMaxi.c + bmcBCore.c bmcChain.c - bmcBmcAnd.c + bmcCexDepth.c + bmcBmc3.c + bmcLoad.c bmcBmcG.c + bmcCexMin2.c + bmcMesh.c + bmcExpand.c + bmcFx.c ) diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt index 5485a9421c..8e1ad8338a 100644 --- a/src/sat/bsat/CMakeLists.txt +++ b/src/sat/bsat/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME sat_bsat SOURCES - satSolver3.c - satStore.c - satInter.c - satUtil.c - satTruth.c - satMem.c - satInterA.c + satProof.c + satInterP.c satSolver2i.c satInterB.c - satSolver.c - satInterP.c - satTrace.c - satProof.c + satMem.c + satInterA.c satSolver2.c + satStore.c + satTrace.c + satSolver3.c + satTruth.c + satUtil.c + satSolver.c + satInter.c ) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt index af83775db7..eb85f78270 100644 --- a/src/sat/bsat2/CMakeLists.txt +++ b/src/sat/bsat2/CMakeLists.txt @@ -1,11 +1,9 @@ abc_libabc_add_sources( NAME sat_bsat2 SOURCES + Solver.cpp SimpSolver.cpp - AbcApi.cpp - Options.cpp - MainSat.cpp - MainSimp.cpp System.cpp - Solver.cpp + Options.cpp + AbcApi.cpp ) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt index d1bb810f9c..a831dd32c6 100644 --- a/src/sat/cnf/CMakeLists.txt +++ b/src/sat/cnf/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME sat_cnf SOURCES - cnfCut.c - cnfMap.c cnfUtil.c + cnfMan.c + cnfMap.c cnfFast.c - cnfData.c cnfPost.c - cnfMan.c - cnfWrite.c + cnfData.c + cnfCut.c cnfCore.c + cnfWrite.c ) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt index 82e57750d3..6777e98a3a 100644 --- a/src/sat/glucose/CMakeLists.txt +++ b/src/sat/glucose/CMakeLists.txt @@ -2,9 +2,9 @@ abc_libabc_add_sources( NAME sat_glucose SOURCES SimpSolver.cpp - Glucose.cpp - Options.cpp + AbcGlucoseCmd.cpp System.cpp + Options.cpp AbcGlucose.cpp - AbcGlucoseCmd.cpp + Glucose.cpp ) diff --git a/src/sat/glucose2/CMakeLists.txt b/src/sat/glucose2/CMakeLists.txt index b96cee7c71..7654e71529 100644 --- a/src/sat/glucose2/CMakeLists.txt +++ b/src/sat/glucose2/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose2 SOURCES - AbcGlucose2.cpp - AbcGlucoseCmd2.cpp + Glucose2.cpp + Options2.cpp System2.cpp + AbcGlucose2.cpp SimpSolver2.cpp - Options2.cpp - Glucose2.cpp + AbcGlucoseCmd2.cpp ) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt index 50378dfe88..cc80678afa 100644 --- a/src/sat/msat/CMakeLists.txt +++ b/src/sat/msat/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME sat_msat SOURCES - msatSolverApi.c - msatActivity.c + msatSort.c msatRead.c + msatClauseVec.c msatSolverSearch.c - msatSolverIo.c msatVec.c + msatSolverApi.c msatSolverCore.c msatOrderH.c msatMem.c - msatClauseVec.c + msatActivity.c msatClause.c - msatSort.c msatQueue.c + msatSolverIo.c ) diff --git a/src/sat/satoko/CMakeLists.txt b/src/sat/satoko/CMakeLists.txt index 564d8938e3..77cbf21698 100644 --- a/src/sat/satoko/CMakeLists.txt +++ b/src/sat/satoko/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_satoko SOURCES - solver_api.c cnf_reader.c solver.c + solver_api.c ) diff --git a/src/sat/xsat/CMakeLists.txt b/src/sat/xsat/CMakeLists.txt index 97cc44e5d3..a027e76ffe 100644 --- a/src/sat/xsat/CMakeLists.txt +++ b/src/sat/xsat/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_xsat SOURCES - xsatCnfReader.c - xsatSolverAPI.c xsatSolver.c + xsatSolverAPI.c + xsatCnfReader.c ) From 518754ebb2c310d378a845abb5db4b9c1264db6d Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Fri, 14 Feb 2025 20:59:11 -0800 Subject: [PATCH 21/35] chg: dev: update workflow actions, add dependabot.yml, bump OS versions Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 57 +++++++++++++++++---------------- .github/workflows/conda-dev.yml | 21 ++++++------ .github/workflows/win.yml | 4 +-- tox.ini | 4 +-- 4 files changed, 45 insertions(+), 41 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ccd31508ab..a1d83cb852 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,15 +23,15 @@ jobs: strategy: fail-fast: false matrix: - python-version: ['3.10'] + python-version: ['3.11'] name: [ windows-2019-cl, - ubuntu-20.04-gcc, - ubuntu-20.04-clang, - ubuntu-22.04-clang, - macOS-11-gcc, - macOS-11-clang, + ubuntu-22.04-gcc-10, + ubuntu-24.04-gcc-13, + ubuntu-22.04-clang-14, + macOS-13-gcc, + macOS-14-clang, ] include: @@ -39,47 +39,47 @@ jobs: os: windows-2019 compiler: cl - - name: ubuntu-20.04-gcc - os: ubuntu-20.04 + - name: ubuntu-22.04-gcc-10 + os: ubuntu-22.04 compiler: gcc - version: "11" + version: "10" toxcmd: soname,tests - - name: ubuntu-20.04-clang - os: ubuntu-20.04 - compiler: clang - version: "10" - toxcmd: clang + - name: ubuntu-24.04-gcc-13 + os: ubuntu-24.04 + compiler: gcc + version: "13" + toxcmd: libs - - name: ubuntu-22.04-clang + - name: ubuntu-22.04-clang-14 os: ubuntu-22.04 compiler: clang - version: "12" - toxcmd: build + version: "14" + toxcmd: base - - name: macOS-11-gcc - os: macOS-11 + - name: macOS-13-gcc + os: macOS-13 compiler: gcc - version: "11" + version: "12" toxcmd: abc,tests - - name: macOS-11-clang - os: macOS-11 + - name: macOS-14-clang + os: macOS-14 compiler: xcode - version: "12.4" + version: "15.3" toxcmd: "base -- Xcode" steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: actions/setup-python@v4 + - uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - name: Update CMake - uses: jwlawson/actions-setup-cmake@v1 + uses: jwlawson/actions-setup-cmake@v2 if: runner.os == 'Windows' - name: Install Tox @@ -91,6 +91,9 @@ jobs: if: runner.os == 'Linux' run: | sudo apt-get -y -qq update + sudo apt-get install -yqq software-properties-common + sudo add-apt-repository ppa:ubuntu-toolchain-r/ppa + sudo apt-get -qq update sudo apt-get install -y libreadline-dev ncurses-dev if [ "${{ matrix.compiler }}" = gcc ]; then sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib @@ -111,7 +114,7 @@ jobs: run: | tox -e ${{ matrix.toxcmd }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 if: matrix.name == 'ubuntu-20.04-clang' with: name: src_coverage_data diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 79e4792e23..34e18b4c47 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -15,17 +15,17 @@ jobs: strategy: fail-fast: false matrix: - os: ['ubuntu-22.04', 'ubuntu-20.04', 'macOS-11', 'windows-2019'] - python-version: ['3.9'] + os: ['ubuntu-24.04', 'ubuntu-22.04', 'macOS-14', 'windows-2019'] use_namespace: [false, true] + python-version: ['3.9'] include: - os: 'ubuntu-22.04' generator: 'Ninja' build_type: 'Release' - - os: 'ubuntu-20.04' + - os: 'ubuntu-24.04' generator: 'Ninja' build_type: 'RelWithDebInfo' - - os: 'macOS-11' + - os: 'macOS-14' generator: 'Ninja' build_type: 'Release' - os: 'windows-2019' @@ -39,19 +39,19 @@ jobs: CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup base python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: - python-version: '3.x' + python-version: ${{ matrix.python-version }} - name: Cache conda id: cache - uses: actions/cache@v3 + uses: actions/cache@v4 env: # Increase this value to reset cache if environment.devenv.yml has not changed - CACHE_NUMBER: 2 + CACHE_NUMBER: 3 with: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} @@ -61,8 +61,9 @@ jobs: auto-update-conda: true auto-activate-base: true activate-environment: '' - channels: conda-forge + channels: conda-forge,defaults channel-priority: flexible + conda-remove-defaults: true - name: Configure condadev environment shell: bash -l {0} diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 2cbd8c0bdf..64a000c430 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -23,7 +23,7 @@ jobs: run: shell: msys2 {0} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup MinGW native environment uses: msys2/setup-msys2@v2 @@ -54,7 +54,7 @@ jobs: - name: Test run: ctest --test-dir build --output-on-failure --parallel -V - - uses: actions/upload-artifact@v1 + - uses: actions/upload-artifact@v4 if: failure() with: name: WindowsCMakeTestlog diff --git a/tox.ini b/tox.ini index faad77da60..cfeb60d3ce 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py3{7,8,9,10,11}-build +envlist = abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,ctestwin,cclean skip_missing_interpreters = true skipsdist = true @@ -82,7 +82,7 @@ commands = {clang}: cmake --build . --target coverage -j {env:CPUS} {libs,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ clang: lcov_cobertura {toxinidir}/build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml - {base,libs}: cmake --build . --target install + {libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V From a2fb71efd53336a8002416f834ace8c387e9111b Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 16 Feb 2025 22:49:27 -0800 Subject: [PATCH 22/35] chg: dev: cleanup cmake and tox files, include gia tests Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 38 ++++++++++++++++++++++++++++++++++---- test/gia/CMakeLists.txt | 6 ++++-- tox.ini | 20 ++++++++++---------- 3 files changed, 48 insertions(+), 16 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0cdbb88744..7fe4f30953 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,5 @@ -cmake_minimum_required(VERSION 3.10.0 FATAL_ERROR) +# pre-test discovery mode for gtest_discover_tests was added in 3.18 +cmake_minimum_required(VERSION 3.18) # Add cmake modules of this project to the module path list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) @@ -9,7 +10,7 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) # # for now, set -DSCM_VERSION_INFO in the build env to override if(NOT SCM_VERSION_INFO) - set(LIBRARY_VERSION 1.1.0) + set(LIBRARY_VERSION 1.2.0) set(SCM_VERSION_INFO ${LIBRARY_VERSION}) endif() set(LIBRARY_SOVERSION 1) @@ -158,7 +159,8 @@ endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") target_compile_options(abc_interface INTERFACE - -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare -Wno-deprecated + -Wall -Wno-unused-function -Wno-write-strings -Wno-sign-compare + -Wno-deprecated -Wno-unused-but-set-variable ) target_link_libraries(abc_interface INTERFACE m) if(WIN32 OR ABC_USE_NAMESPACE) @@ -435,13 +437,36 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") endif() endif() + +if(VENDOR_GTEST) + include(FetchContent) + # current tests are broken on Gtest >= 1.15 + FetchContent_Declare( + googletest + GIT_REPOSITORY https://github.com/google/googletest.git + GIT_TAG v1.14.0 + ) + set(gtest_force_shared_crt + ON + CACHE BOOL "" FORCE + ) + FetchContent_MakeAvailable(googletest) +endif() + if(BUILD_TESTING) + find_package(PkgConfig) + pkg_search_module(GTEST REQUIRED gtest_main) + pkg_search_module(GMOCK REQUIRED gmock) + set(test_SRCS src/demo.c) if(ABC_USE_NAMESPACE) set_source_files_properties(${test_SRCS} PROPERTIES LANGUAGE CXX) endif() add_executable(base_test ${test_SRCS}) - target_link_libraries(base_test PUBLIC libabc) + target_compile_options(base_test PUBLIC ${GTEST_CFLAGS}) + target_link_libraries( + base_test PUBLIC libabc gtest_main gtest ${CMAKE_THREAD_LIBS_INIT} + ) enable_testing() add_test(NAME base_test @@ -460,7 +485,12 @@ if(BUILD_TESTING) include(coverage) add_coverage(abc) add_coverage(base_test) + add_coverage(gia_test) endif() + + message(STATUS "test discovery enabled") + include(GoogleTest) + add_subdirectory(test) endif() add_custom_target(etags diff --git a/test/gia/CMakeLists.txt b/test/gia/CMakeLists.txt index c9022dc8c0..7f5e23f624 100644 --- a/test/gia/CMakeLists.txt +++ b/test/gia/CMakeLists.txt @@ -1,11 +1,13 @@ add_executable(gia_test gia_test.cc) -target_link_libraries(gia_test +target_link_libraries(gia_test PUBLIC gtest gtest_main libabc + ${CMAKE_THREAD_LIBS_INIT} ) +target_compile_options(gia_test PUBLIC ${GTEST_CFLAGS}) gtest_discover_tests(gia_test WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} -) \ No newline at end of file +) diff --git a/tox.ini b/tox.ini index cfeb60d3ce..9a9ba47b9d 100644 --- a/tox.ini +++ b/tox.ini @@ -5,7 +5,7 @@ skipsdist = true [base] setenv = - CPUS={env:CPUS:4} + CPUS={env:CPUS:8} {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-march=native -O2 -g -DNDEBUG} {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-march=native -O2 -g -DNDEBUG} @@ -45,8 +45,8 @@ passenv = {[base]passenv} allowlist_externals = - {abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,cclean}: bash - {abc,demo,soname,tests,clean}: make + {abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,cclean,clean}: bash + {abc,demo,soname,tests}: make changedir = {base,libs,clang}: {toxinidir}/build @@ -70,23 +70,23 @@ commands = tests: make test # demo requires CC, CXX set in environment or on cmd line # eg: CC=gcc CXX=g++ tox -e demo - demo: bash -c '$CC {posargs} -Wall -c src/demo.c -o demo.o' - demo: bash -c '$CXX -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' + demo: bash -c '{env:CC} {posargs} -Wall -c src/demo.c -o demo.o' + demo: bash -c '{env:CXX} -o demo demo.o libabc.a -lm -ldl -lreadline -lpthread' demo: bash -c './demo i10.aig' {abc,soname,tests}: bash -c 'ls -lh *abc* || true' - base: cmake -G {posargs:"Ninja"} -DABC_USE_NAMESPACE=$ABC_USE_NAMESPACE -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. - base: cmake --build . --target install -j {env:CPUS} + base: cmake -G {posargs:"Ninja"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + base: cmake --build . --target abc -j {env:CPUS} libs: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. clang: cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DCOVERAGE_BUILD=ON -DCOVERAGE_TEXT=ON -DBUILD_SHARED_LIBS=OFF .. {libs}: cmake --build . -j {env:CPUS} {clang}: cmake --build . --target coverage -j {env:CPUS} {libs,clang}: ctest -V -C {env:BUILD_TYPE} --test-dir ./ clang: lcov_cobertura {toxinidir}/build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml - {libs}: cmake --build . --target install + {base,libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V - ctest: bash -c 'ls -lh build/base_test build/libabc.* || true' + ctest: bash -c 'ls -lh build/*abc* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DCMAKE_BUILD_TYPE=Debug' grind: bash -c 'cmake --build build --target abc -j $CPUS' @@ -94,4 +94,4 @@ commands = grind: valgrind-ci abc_check.xml --number-of-errors grind: valgrind-ci abc_check.xml --summary cclean: bash -c 'rm -rf build/ *.xml *.blif *.profraw staging/' - clean: make clean + clean: bash -c 'make clean && rm -f demo' From 521322a3e6efb8992d0dabab9f770715db8c1b1e Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 17 Feb 2025 10:16:50 -0800 Subject: [PATCH 23/35] chg: dev: install or vendor googletest as needed, set gtest libs * apparently macos also needs gtest includes Signed-off-by: Stephen L Arnold --- .github/workflows/build-posix-cmake.yml | 1 + .github/workflows/ci.yml | 4 +++- .github/workflows/win.yml | 3 ++- CMakeLists.txt | 26 +++++++++++++++---------- environment.devenv.yml | 1 + test/gia/CMakeLists.txt | 7 +++---- tox.ini | 5 +++-- 7 files changed, 29 insertions(+), 18 deletions(-) diff --git a/.github/workflows/build-posix-cmake.yml b/.github/workflows/build-posix-cmake.yml index 9d4dc6ef6a..8b295e48a5 100644 --- a/.github/workflows/build-posix-cmake.yml +++ b/.github/workflows/build-posix-cmake.yml @@ -49,6 +49,7 @@ jobs: ${CMAKE_ARGS} -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=./staging + -DVENDOR_GTEST=ON - name: Build CMake run: | diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a1d83cb852..7c8040b3b7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -94,7 +94,7 @@ jobs: sudo apt-get install -yqq software-properties-common sudo add-apt-repository ppa:ubuntu-toolchain-r/ppa sudo apt-get -qq update - sudo apt-get install -y libreadline-dev ncurses-dev + sudo apt-get install -y libreadline-dev ncurses-dev libgtest-dev if [ "${{ matrix.compiler }}" = gcc ]; then sudo apt-get install -y g++-${{ matrix.version }} g++-${{ matrix.version }}-multilib echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV @@ -125,6 +125,7 @@ jobs: - name: Install and setup MacOS packages if: runner.os == 'macOS' run: | + brew install googletest if [ "${{ matrix.compiler }}" = gcc ]; then brew install gcc@${{ matrix.version }} echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV @@ -152,6 +153,7 @@ jobs: -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${{ env.PREFIX }} + -DVENDOR_GTEST=ON env: CC: cl CXX: cl diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 64a000c430..fdefd95b25 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -38,12 +38,13 @@ jobs: mingw-w64-${{ matrix.arch }}-ninja mingw-w64-${{ matrix.arch }}-pkgconf mingw-w64-${{ matrix.arch }}-readline + mingw-w64-${{ matrix.arch }}-gtest - run: >- cmake -Wdev -B build - -DBUILD_SHARED_LIBS=ON + -DBUILD_SHARED_LIBS=OFF -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=$PWD/_dist diff --git a/CMakeLists.txt b/CMakeLists.txt index 7fe4f30953..d570fc0fd4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -80,6 +80,7 @@ option(ABC_USE_SONAME "Set library soname") option(BUILD_TESTING "Build and run tests" ON) option(COVERAGE_BUILD "Enable source-based LLVM code coverage" OFF) option(ABC_SKIP_EXE "Skip building executable (build libs only)" OFF) +option(VENDOR_GTEST "download googletest" OFF) add_library(abc_interface INTERFACE) @@ -440,23 +441,30 @@ endif() if(VENDOR_GTEST) include(FetchContent) - # current tests are broken on Gtest >= 1.15 + option(BUILD_GMOCK OFF) + option(INSTALL_GTEST OFF) FetchContent_Declare( googletest - GIT_REPOSITORY https://github.com/google/googletest.git - GIT_TAG v1.14.0 + DOWNLOAD_EXTRACT_TIMESTAMP TRUE + URL "https://github.com/google/googletest/archive/refs/tags/v1.14.0.zip" + #GIT_REPOSITORY https://github.com/google/googletest.git + #GIT_TAG v1.14.0 ) set(gtest_force_shared_crt ON CACHE BOOL "" FORCE ) - FetchContent_MakeAvailable(googletest) endif() if(BUILD_TESTING) - find_package(PkgConfig) - pkg_search_module(GTEST REQUIRED gtest_main) - pkg_search_module(GMOCK REQUIRED gmock) + if(NOT VENDOR_GTEST) + find_package(GTest REQUIRED) + else() + FetchContent_MakeAvailable(googletest) + endif() + message(STATUS "test discovery enabled") + include(GoogleTest) + set(GTEST_LIBS gtest_main gtest "${CMAKE_THREAD_LIBS_INIT}") set(test_SRCS src/demo.c) if(ABC_USE_NAMESPACE) @@ -465,7 +473,7 @@ if(BUILD_TESTING) add_executable(base_test ${test_SRCS}) target_compile_options(base_test PUBLIC ${GTEST_CFLAGS}) target_link_libraries( - base_test PUBLIC libabc gtest_main gtest ${CMAKE_THREAD_LIBS_INIT} + base_test PUBLIC libabc ${GTEST_LIBS} ) enable_testing() @@ -488,8 +496,6 @@ if(BUILD_TESTING) add_coverage(gia_test) endif() - message(STATUS "test discovery enabled") - include(GoogleTest) add_subdirectory(test) endif() diff --git a/environment.devenv.yml b/environment.devenv.yml index d445458706..b57e483ba5 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -11,6 +11,7 @@ dependencies: - readline=8.1 # [unix] - zlib - libpng + - gtest environment: CPATH: diff --git a/test/gia/CMakeLists.txt b/test/gia/CMakeLists.txt index 7f5e23f624..7629b46e00 100644 --- a/test/gia/CMakeLists.txt +++ b/test/gia/CMakeLists.txt @@ -1,12 +1,11 @@ add_executable(gia_test gia_test.cc) +target_include_directories(gia_test PUBLIC ${GTEST_INCLUDE_DIRS}) +target_compile_options(gia_test PUBLIC ${GTEST_CFLAGS}) target_link_libraries(gia_test PUBLIC - gtest - gtest_main libabc - ${CMAKE_THREAD_LIBS_INIT} + ${GTEST_LIBS} ) -target_compile_options(gia_test PUBLIC ${GTEST_CFLAGS}) gtest_discover_tests(gia_test WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} diff --git a/tox.ini b/tox.ini index 9a9ba47b9d..b3d8abe1e2 100644 --- a/tox.ini +++ b/tox.ini @@ -12,6 +12,7 @@ setenv = {base,libs,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} {base,libs,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} {base,libs,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} + {base,libs,clang,ctest}: VENDOR_GTEST={env:VENDOR_GTEST:OFF} BUILD_TYPE={env:BUILD_TYPE:Release} base: PREFIX={env:PREFIX:staging} libs: PREFIX={env:PREFIX:../staging} @@ -76,7 +77,7 @@ commands = {abc,soname,tests}: bash -c 'ls -lh *abc* || true' base: cmake -G {posargs:"Ninja"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. base: cmake --build . --target abc -j {env:CPUS} - libs: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. + libs: cmake -G {posargs:"Unix Makefiles"} -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} -DVENDOR_GTEST={env:VENDOR_GTEST} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_ENABLE_LTO=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME={env:ABC_USE_SONAME} -DCMAKE_INSTALL_PREFIX={env:PREFIX} .. clang: cmake -G {posargs:"Unix Makefiles"} -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DCOVERAGE_BUILD=ON -DCOVERAGE_TEXT=ON -DBUILD_SHARED_LIBS=OFF .. {libs}: cmake --build . -j {env:CPUS} {clang}: cmake --build . --target coverage -j {env:CPUS} @@ -85,7 +86,7 @@ commands = {base,libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V - ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V + ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/*abc* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DCMAKE_BUILD_TYPE=Debug' From f8e6edfae4f14afbfde48f55c999f5bb3de72496 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Tue, 18 Feb 2025 18:03:57 -0800 Subject: [PATCH 24/35] fix: dev: adjust for workflow environments, fix gia_test working directory * update gia_test source with language property * update conda-dev env file and matrix xcode version * update workflows with push branches and less generic job names Signed-off-by: Stephen L Arnold --- .github/workflows/build-posix-cmake.yml | 2 ++ .github/workflows/build-posix.yml | 2 ++ .github/workflows/build-windows.yml | 2 ++ .github/workflows/ci.yml | 6 +++--- .github/workflows/conda-dev.yml | 15 ++++++++------- .github/workflows/win.yml | 2 +- CMakeLists.txt | 8 ++++++++ environment.devenv.yml | 16 ++++++++++++---- test/gia/CMakeLists.txt | 8 +++++++- 9 files changed, 45 insertions(+), 16 deletions(-) diff --git a/.github/workflows/build-posix-cmake.yml b/.github/workflows/build-posix-cmake.yml index 8b295e48a5..cd0b03d26d 100644 --- a/.github/workflows/build-posix-cmake.yml +++ b/.github/workflows/build-posix-cmake.yml @@ -2,6 +2,8 @@ name: Build Posix CMake on: push: + branches: + - master pull_request: jobs: diff --git a/.github/workflows/build-posix.yml b/.github/workflows/build-posix.yml index 6469425ac7..f7136ee8a0 100644 --- a/.github/workflows/build-posix.yml +++ b/.github/workflows/build-posix.yml @@ -2,6 +2,8 @@ name: Build Posix on: push: + branches: + - master pull_request: jobs: diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index 2d08943648..53f100172d 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -2,6 +2,8 @@ name: Build Windows on: push: + branches: + - master pull_request: jobs: diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7c8040b3b7..780ecc1a1f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,7 +13,7 @@ on: - '**.sh' jobs: - build: + ci_build: name: ${{ matrix.name }} runs-on: ${{ matrix.os }} defaults: @@ -66,7 +66,7 @@ jobs: - name: macOS-14-clang os: macOS-14 compiler: xcode - version: "15.3" + version: "15.4" toxcmd: "base -- Xcode" steps: @@ -148,7 +148,7 @@ jobs: if: runner.os == 'Windows' run: > cmake -S . -B build - -DBUILD_SHARED_LIBS=ON + -DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE=Release diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 34e18b4c47..17ae4343e8 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -9,7 +9,7 @@ on: - develop jobs: - build: + conda_build: name: abc ${{ matrix.python-version }} ${{ matrix.os }} runs-on: ${{ matrix.os }} strategy: @@ -51,7 +51,7 @@ jobs: uses: actions/cache@v4 env: # Increase this value to reset cache if environment.devenv.yml has not changed - CACHE_NUMBER: 3 + CACHE_NUMBER: 0 with: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} @@ -71,17 +71,18 @@ jobs: PY_VER: ${{ matrix.python-version }} run: | conda config --set always_yes yes --set changeps1 no - conda install conda-devenv=3.2.0 - conda info - conda list + conda config --add channels conda-forge + conda install conda-devenv + conda info -a + conda devenv - name: Build and test shell: bash -l {0} env: + CMAKE_PREFIX_PATH: ${{ github.workspace }} PY_VER: ${{ matrix.python-version }} run: | - conda devenv - conda activate abc + source activate abc-test conda info --envs ctest --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index fdefd95b25..51f847866c 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -9,7 +9,7 @@ on: - develop jobs: - msys2-build: + msys2_build: runs-on: windows-latest strategy: fail-fast: false diff --git a/CMakeLists.txt b/CMakeLists.txt index d570fc0fd4..03a0977520 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -82,6 +82,14 @@ option(COVERAGE_BUILD "Enable source-based LLVM code coverage" OFF) option(ABC_SKIP_EXE "Skip building executable (build libs only)" OFF) option(VENDOR_GTEST "download googletest" OFF) +if(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") + exec_program(/usr/bin/uname ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR RETURN_VALUE val) + # If we aren't cross-compiling then the two are equal. + if(NOT CMAKE_CROSSCOMPILING) + set(CMAKE_SYSTEM_PROCESSOR "${CMAKE_HOST_SYSTEM_PROCESSOR}") + endif() +endif() + add_library(abc_interface INTERFACE) set(ABC_HEADERS diff --git a/environment.devenv.yml b/environment.devenv.yml index b57e483ba5..f681af79ee 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -1,17 +1,25 @@ -name: abc +name: abc-test dependencies: - python ={{ get_env("PY_VER", default="3.10") }} - cmake>=3.18 - ninja - - gxx_linux-64 # [linux] - - ccache # [not win] - - clcache # [win] - make # [unix] + - pkg-config # [unix] - readline=8.1 # [unix] - zlib - libpng - gtest + - gmock + - libpcap + - boost + - boost-cpp + - lcov + - gcovr + - gcc_linux-64 # [linux] + - gxx_linux-64 # [linux] + - ccache # [unix] + - clcache # [win] environment: CPATH: diff --git a/test/gia/CMakeLists.txt b/test/gia/CMakeLists.txt index 7629b46e00..c2bab02d47 100644 --- a/test/gia/CMakeLists.txt +++ b/test/gia/CMakeLists.txt @@ -1,3 +1,7 @@ +if(ABC_USE_NAMESPACE) + set_source_files_properties(gia_test.cc PROPERTIES LANGUAGE CXX) +endif() + add_executable(gia_test gia_test.cc) target_include_directories(gia_test PUBLIC ${GTEST_INCLUDE_DIRS}) @@ -8,5 +12,7 @@ target_link_libraries(gia_test PUBLIC ) gtest_discover_tests(gia_test - WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} + # the traling directory below is a workaround for generators that append + # an extra directory name (build type) such as VS on windows + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR} ) From 1b0e36d78cb03f2d13d56590181b55c2b7437caf Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Thu, 20 Feb 2025 17:40:26 -0800 Subject: [PATCH 25/35] chg: dev: cleanup readme and xcode setup, use internal gtest for xcode * fix adhoc test command arg file path, remove redundant test * remove previous test path hacks, set xcode to Debug * update conda build step and environment file, add core gtest deps Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 22 ++++++++++-------- .github/workflows/conda-dev.yml | 14 ++++++----- CMakeLists.txt | 18 +++------------ README.md | 41 +++++++++++++++++---------------- environment.devenv.yml | 10 ++++---- test/gia/CMakeLists.txt | 2 +- tox.ini | 11 +++++---- 7 files changed, 56 insertions(+), 62 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 780ecc1a1f..e3e81b4d43 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,7 +31,7 @@ jobs: ubuntu-24.04-gcc-13, ubuntu-22.04-clang-14, macOS-13-gcc, - macOS-14-clang, + macOS-13-clang, ] include: @@ -63,11 +63,11 @@ jobs: version: "12" toxcmd: abc,tests - - name: macOS-14-clang - os: macOS-14 + - name: macOS-13-clang + os: macOS-13 compiler: xcode - version: "15.4" - toxcmd: "base -- Xcode" + version: "15.1" + toxcmd: "ctestwin -- Xcode" steps: - uses: actions/checkout@v4 @@ -125,14 +125,16 @@ jobs: - name: Install and setup MacOS packages if: runner.os == 'macOS' run: | - brew install googletest - if [ "${{ matrix.compiler }}" = gcc ]; then + brew update + #brew upgrade + if [ "${{ matrix.compiler }}" = xcode ]; then + sudo xcode-select -s /Applications/Xcode_${{ matrix.version }}.app/Contents/Developer + ls -ls /Applications/ + else brew install gcc@${{ matrix.version }} echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV - else - ls -ls /Applications/ - sudo xcode-select -switch /Applications/Xcode_${{ matrix.version }}.app + brew install googletest fi - name: Build and test MacOS diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 17ae4343e8..b33ebc5c72 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -27,7 +27,7 @@ jobs: build_type: 'RelWithDebInfo' - os: 'macOS-14' generator: 'Ninja' - build_type: 'Release' + build_type: 'Debug' - os: 'windows-2019' generator: 'Ninja' build_type: 'Release' @@ -51,7 +51,7 @@ jobs: uses: actions/cache@v4 env: # Increase this value to reset cache if environment.devenv.yml has not changed - CACHE_NUMBER: 0 + CACHE_NUMBER: 1 with: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} @@ -79,13 +79,15 @@ jobs: - name: Build and test shell: bash -l {0} env: - CMAKE_PREFIX_PATH: ${{ github.workspace }} PY_VER: ${{ matrix.python-version }} run: | source activate abc-test conda info --envs - ctest --build-generator "${{ matrix.generator }}" \ + ctest --build-config "${{ matrix.build_type }}" \ + --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ - -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \ - --test-command ctest --rerun-failed --output-on-failure -V + -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON -DCMAKE_PREFIX_PATH="$CONDA_PREFIX" \ + --test-command ctest -V \ + --build-config "${{ matrix.build_type }}" \ + --rerun-failed --output-on-failure diff --git a/CMakeLists.txt b/CMakeLists.txt index 03a0977520..6ae2af02a5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -82,14 +82,6 @@ option(COVERAGE_BUILD "Enable source-based LLVM code coverage" OFF) option(ABC_SKIP_EXE "Skip building executable (build libs only)" OFF) option(VENDOR_GTEST "download googletest" OFF) -if(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") - exec_program(/usr/bin/uname ARGS -m OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR RETURN_VALUE val) - # If we aren't cross-compiling then the two are equal. - if(NOT CMAKE_CROSSCOMPILING) - set(CMAKE_SYSTEM_PROCESSOR "${CMAKE_HOST_SYSTEM_PROCESSOR}") - endif() -endif() - add_library(abc_interface INTERFACE) set(ABC_HEADERS @@ -188,6 +180,7 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") "_CRT_SECURE_NO_WARNINGS" "_XKEYCHECK_H" ) + set(CMAKE_DEBUG_POSTFIX d) endif() if(WIN32) if(MINGW OR MSYS) @@ -486,18 +479,13 @@ if(BUILD_TESTING) enable_testing() add_test(NAME base_test - COMMAND base_test i10.aig - WORKING_DIRECTORY "${abc_SOURCE_DIR}" + COMMAND base_test "${abc_SOURCE_DIR}/i10.aig" + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} ) # Add source-based llvm code coverage targets. # Note this requires recent clang/llvm tooling. if(COVERAGE_BUILD) - add_test(NAME main_test - COMMAND abc -c "r i10.aig; b; ps; b; rw -l; rw -lz; b; rw -lz; b; ps; cec" - WORKING_DIRECTORY "${abc_SOURCE_DIR}" - ) - include(coverage) add_coverage(abc) add_coverage(base_test) diff --git a/README.md b/README.md index 46a8657692..56e29a6f37 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ The source code is provided for research and evaluation only. For commercial usa References: -[1] L. Fan and C. Wu, "FPGA technology mapping with adaptive gate decompostion", ACM/SIGDA FPGA International Symposium on FPGAs, 2023. +[1] L. Fan and C. Wu, "FPGA technology mapping with adaptive gate decompostion", ACM/SIGDA FPGA International Symposium on FPGAs, 2023. Minimum desktop tools needed: @@ -85,8 +85,8 @@ There are several `tox -e` environment commands available in the current tox fil * `ctest` - build/run tests using ctest => static lib and "test" executable * `grind` - run cmake Debug build with valgrind * Misc utility commands: - * `clean` - clean the make build files - * `unbuild` - clean the cmake build/ directory/files + * `clean` - clean the automake/autoconf build byproducts + * `cclean` - clean the cmake build/ directory/files * `lint` - run cpplint style checks ### Compiling manually: @@ -96,10 +96,10 @@ To compile ABC as a static library, type `make libabc.a`. To compile ABC as a shared library, type `make lib`. To compile ABC as a shared library with soname, type `ABC_USE_SONAME=1 make lib`. -When ABC is used as a static library, two additional procedures, `Abc_Start()` -and `Abc_Stop()`, are provided for starting and quitting the ABC framework in -the calling application. A simple demo program (file src/demo.c) shows how to -create a stand-alone program performing DAG-aware AIG rewriting, by calling +When ABC is used as a static library, two additional procedures, `Abc_Start()` +and `Abc_Stop()`, are provided for starting and quitting the ABC framework in +the calling application. A simple demo program (file src/demo.c) shows how to +create a stand-alone program performing DAG-aware AIG rewriting, by calling APIs of ABC compiled as a static library. To build the demo program @@ -138,15 +138,16 @@ or in the batch mode: The current version of ABC can be compiled with C compiler or C++ compiler. * To compile as C code (default): make sure that `CC=gcc` and `ABC_NAMESPACE` is not defined. - * To compile as C++ code without namespaces: make sure that `CC=g++` and `ABC_NAMESPACE` is not defined. + * To compile as C++ code without namespaces: make sure that `CC=g++` and `ABC_NAMESPACE` is not + defined (deprecated). * To compile as C++ code with namespaces: make sure that `CC=g++` and `ABC_NAMESPACE` is set to the name of the requested namespace. For example, add `-DABC_NAMESPACE=xxx` to OPTFLAGS. ## Building a shared library * Compile the code as position-independent by adding `ABC_USE_PIC=1`. - * Build the `libabc.so` target: - + * Build the `libabc.so` target: + make ABC_USE_PIC=1 lib ## Adding new source files @@ -159,10 +160,10 @@ For each module with new sources: ## Bug reporting: -Please try to reproduce all the reported bugs and unexpected features using the latest +Please try to reproduce all the reported bugs and unexpected features using the latest version of ABC available from https://github.com/berkeley-abc/abc -If the bug still persists, please provide the following information: +If the bug still persists, please provide the following information: 1. ABC version (when it was downloaded from GitHub) 1. Linux distribution and version (32-bit or 64-bit) @@ -173,7 +174,7 @@ If the bug still persists, please provide the following information: ## Troubleshooting: - 1. If compilation does not start because of the cyclic dependency check, + 1. If compilation does not start because of the cyclic dependency check, try touching all files as follows: `find ./ -type f -exec touch "{}" \;` 1. If compilation fails because readline is missing, install 'readline' library or compile with `make ABC_USE_NO_READLINE=1` @@ -188,11 +189,11 @@ compile with `make ABC_USE_NO_PTHREADS=1` The following comment was added by Krish Sundaresan: -"I found that the code does compile correctly on Solaris if gcc is used (instead of -g++ that I was using for some reason). Also readline which is not available by default -on most Sol10 systems, needs to be installed. I downloaded the readline-5.2 package -from sunfreeware.com and installed it locally. Also modified CFLAGS to add the local -include files for readline and LIBS to add the local libreadline.a. Perhaps you can +"I found that the code does compile correctly on Solaris if gcc is used (instead of +g++ that I was using for some reason). Also readline which is not available by default +on most Sol10 systems, needs to be installed. I downloaded the readline-5.2 package +from sunfreeware.com and installed it locally. Also modified CFLAGS to add the local +include files for readline and LIBS to add the local libreadline.a. Perhaps you can add these steps in the readme to help folks compiling this on Solaris." The following tutorial is kindly offered by Ana Petkovska from EPFL: @@ -200,7 +201,7 @@ https://www.dropbox.com/s/qrl9svlf0ylxy8p/ABC_GettingStarted.pdf ## Final remarks: -Unfortunately, there is no comprehensive regression test. Good luck! +Unfortunately, there is no comprehensive regression test. Good luck! -This system is maintained by Alan Mishchenko . Consider also +This system is maintained by Alan Mishchenko . Consider also using ZZ framework developed by Niklas Een: https://bitbucket.org/niklaseen/abc-zz (or https://github.com/berkeley-abc/abc-zz) diff --git a/environment.devenv.yml b/environment.devenv.yml index f681af79ee..e29738e1e2 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -11,15 +11,15 @@ dependencies: - libpng - gtest - gmock - - libpcap - - boost - - boost-cpp + - abseil-cpp + - re2 - lcov - gcovr - - gcc_linux-64 # [linux] - - gxx_linux-64 # [linux] + - c-compiler + - cxx-compiler - ccache # [unix] - clcache # [win] + - six environment: CPATH: diff --git a/test/gia/CMakeLists.txt b/test/gia/CMakeLists.txt index c2bab02d47..8bdc80d9a3 100644 --- a/test/gia/CMakeLists.txt +++ b/test/gia/CMakeLists.txt @@ -14,5 +14,5 @@ target_link_libraries(gia_test PUBLIC gtest_discover_tests(gia_test # the traling directory below is a workaround for generators that append # an extra directory name (build type) such as VS on windows - WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR} + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} ) diff --git a/tox.ini b/tox.ini index b3d8abe1e2..fc737f6718 100644 --- a/tox.ini +++ b/tox.ini @@ -6,14 +6,15 @@ skipsdist = true [base] setenv = CPUS={env:CPUS:8} - {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-march=native -O2 -g -DNDEBUG} - {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-march=native -O2 -g -DNDEBUG} - {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-march=native -O2 -g -DNDEBUG} + {abc,demo,soname,tests}: CFLAGS={env:CFLAGS:-O2 -g -DNDEBUG} + {abc,demo,soname,tests}: CXXFLAGS={env:CXXFLAGS:-O2 -g -DNDEBUG} + {abc,demo,soname,tests}: LDFLAGS={env:LDFLAGS:-O2 -g -DNDEBUG} {base,libs,clang,ctest}: ABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE:xxxx} {base,libs,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} {base,libs,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} {base,libs,clang,ctest}: VENDOR_GTEST={env:VENDOR_GTEST:OFF} - BUILD_TYPE={env:BUILD_TYPE:Release} + {base,libs,clang}: BUILD_TYPE={env:BUILD_TYPE:Release} + {ctest,ctestwin}: BUILD_TYPE={env:BUILD_TYPE:Debug} base: PREFIX={env:PREFIX:staging} libs: PREFIX={env:PREFIX:../staging} @@ -86,7 +87,7 @@ commands = {base,libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V - ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V + ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/*abc* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' grind: bash -c 'cmake -G {posargs:"Ninja"} -S . -B build -DCMAKE_BUILD_TYPE=Debug' From 7bb44c601d8abab3b856095671125d90099b7e62 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 22 Feb 2025 16:57:32 -0800 Subject: [PATCH 26/35] fix: dev: cleanup googletest bits for consistent paths to gtest libs * use includes from source dir when using VENDOR_GTEST * be sure and link against both gtest libs with either option Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 4 ++-- .github/workflows/conda-dev.yml | 9 ++++++--- CMakeLists.txt | 23 +++++++++++------------ test/gia/CMakeLists.txt | 5 +---- test/gia/gia_test.cc | 2 +- tox.ini | 2 +- 6 files changed, 22 insertions(+), 23 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e3e81b4d43..af380c1918 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -55,7 +55,7 @@ jobs: os: ubuntu-22.04 compiler: clang version: "14" - toxcmd: base + toxcmd: clang - name: macOS-13-gcc os: macOS-13 @@ -115,7 +115,7 @@ jobs: tox -e ${{ matrix.toxcmd }} - uses: actions/upload-artifact@v4 - if: matrix.name == 'ubuntu-20.04-clang' + if: matrix.name == 'ubuntu-22.04-clang-14' with: name: src_coverage_data path: | diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index b33ebc5c72..aec50e5afd 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -22,16 +22,19 @@ jobs: - os: 'ubuntu-22.04' generator: 'Ninja' build_type: 'Release' + extra_args: '-DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON' - os: 'ubuntu-24.04' generator: 'Ninja' build_type: 'RelWithDebInfo' + extra_args: '-DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON' - os: 'macOS-14' generator: 'Ninja' build_type: 'Debug' + extra_args: '-DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON' - os: 'windows-2019' generator: 'Ninja' - build_type: 'Release' - extra_args: '-DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON' + build_type: 'Debug' + extra_args: '-DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_READLINE=ON' env: OS: ${{ matrix.os }} PY_VER: ${{ matrix.python-version }} @@ -87,7 +90,7 @@ jobs: --build-generator "${{ matrix.generator }}" \ --build-and-test . build \ --build-options ${CMAKE_ARGS} ${{ matrix.extra_args }} \ - -DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON -DCMAKE_PREFIX_PATH="$CONDA_PREFIX" \ + -DCMAKE_PREFIX_PATH="$CONDA_PREFIX" \ --test-command ctest -V \ --build-config "${{ matrix.build_type }}" \ --rerun-failed --output-on-failure diff --git a/CMakeLists.txt b/CMakeLists.txt index 6ae2af02a5..f5be19a8ab 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -17,7 +17,7 @@ set(LIBRARY_SOVERSION 1) project( abc - LANGUAGES C CXX + LANGUAGES CXX C VERSION ${SCM_VERSION_INFO} ) @@ -439,10 +439,8 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") endif() endif() - if(VENDOR_GTEST) include(FetchContent) - option(BUILD_GMOCK OFF) option(INSTALL_GTEST OFF) FetchContent_Declare( googletest @@ -451,21 +449,22 @@ if(VENDOR_GTEST) #GIT_REPOSITORY https://github.com/google/googletest.git #GIT_TAG v1.14.0 ) - set(gtest_force_shared_crt - ON - CACHE BOOL "" FORCE - ) + set(gtest_force_shared_crt ON CACHE BOOL "Always use msvcrt.dll" FORCE) + FetchContent_MakeAvailable(googletest) + include_directories(${gtest_SOURCE_DIR}/include) + set(GTEST_LINK_LIBRARIES GTest::gtest GTest::gtest_main) endif() if(BUILD_TESTING) if(NOT VENDOR_GTEST) - find_package(GTest REQUIRED) - else() - FetchContent_MakeAvailable(googletest) + find_package(GTest 1.14 REQUIRED) + include_directories(${GTEST_INCLUDE_DIRS}) + set(GTEST_LINK_LIBRARIES ${GTEST_BOTH_LIBRARIES}) endif() + message(STATUS "GTest libraries: ${GTEST_LINK_LIBRARIES}") + message(STATUS "test discovery enabled") include(GoogleTest) - set(GTEST_LIBS gtest_main gtest "${CMAKE_THREAD_LIBS_INIT}") set(test_SRCS src/demo.c) if(ABC_USE_NAMESPACE) @@ -474,7 +473,7 @@ if(BUILD_TESTING) add_executable(base_test ${test_SRCS}) target_compile_options(base_test PUBLIC ${GTEST_CFLAGS}) target_link_libraries( - base_test PUBLIC libabc ${GTEST_LIBS} + base_test PUBLIC libabc ${GTEST_LINK_LIBRARIES} ) enable_testing() diff --git a/test/gia/CMakeLists.txt b/test/gia/CMakeLists.txt index 8bdc80d9a3..034fe3b9b7 100644 --- a/test/gia/CMakeLists.txt +++ b/test/gia/CMakeLists.txt @@ -4,15 +4,12 @@ endif() add_executable(gia_test gia_test.cc) -target_include_directories(gia_test PUBLIC ${GTEST_INCLUDE_DIRS}) target_compile_options(gia_test PUBLIC ${GTEST_CFLAGS}) target_link_libraries(gia_test PUBLIC libabc - ${GTEST_LIBS} + ${GTEST_LINK_LIBRARIES} ) gtest_discover_tests(gia_test - # the traling directory below is a workaround for generators that append - # an extra directory name (build type) such as VS on windows WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} ) diff --git a/test/gia/gia_test.cc b/test/gia/gia_test.cc index a6b288f791..ae88c34607 100644 --- a/test/gia/gia_test.cc +++ b/test/gia/gia_test.cc @@ -1,4 +1,4 @@ -#include "gtest/gtest.h" +#include #include "aig/gia/gia.h" diff --git a/tox.ini b/tox.ini index fc737f6718..1fb6dea74c 100644 --- a/tox.ini +++ b/tox.ini @@ -86,7 +86,7 @@ commands = clang: lcov_cobertura {toxinidir}/build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml {base,libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' - ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest --rerun-failed --output-on-failure -V + ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/*abc* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' From e10e71d552d273a6cd0a4e50a05836c0313964a5 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 22 Feb 2025 21:57:42 -0800 Subject: [PATCH 27/35] fix: dev: try fetching googletest on windows instead of conda pkgs Signed-off-by: Stephen L Arnold --- .github/workflows/conda-dev.yml | 2 +- environment.devenv.yml | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index aec50e5afd..61be008329 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -34,7 +34,7 @@ jobs: - os: 'windows-2019' generator: 'Ninja' build_type: 'Debug' - extra_args: '-DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_READLINE=ON' + extra_args: '-DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON -DABC_USE_NO_READLINE=ON -DVENDOR_GTEST=ON' env: OS: ${{ matrix.os }} PY_VER: ${{ matrix.python-version }} diff --git a/environment.devenv.yml b/environment.devenv.yml index e29738e1e2..55846b27e8 100644 --- a/environment.devenv.yml +++ b/environment.devenv.yml @@ -9,8 +9,7 @@ dependencies: - readline=8.1 # [unix] - zlib - libpng - - gtest - - gmock + - gtest=1.14.0 # [not win] - abseil-cpp - re2 - lcov From 6cad9b7397bc868b09fe74ec16bb16715d57008d Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sun, 23 Feb 2025 16:51:35 -0800 Subject: [PATCH 28/35] fix: dev: refactor symbol visibility, use ABC_DLL to expose public API * follow modern guidelines summarized in [1] * set default visibility and visibility-inlines to hidden when using C++ namespace * MSVC is hidden by default, so set GNU, LLVM, and AppleClang the same way * use abc header defines to apply visibility rules on non-win32 platforms * remove parallel args from tox Makefile commands in favor of posargs eg, ``tox -e abc -- -j4`` [1] https://gist.github.com/ax3l/ba17f4bb1edb5885a6bd01f58de4d542 Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 13 ++- Makefile | 6 +- src/aig/gia/gia.h | 213 +++++++++++++++++++------------------ src/base/acb/acbTest.c | 50 ++++----- src/base/main/abcapis.h | 77 +++++++------- src/base/main/main.c | 2 +- src/base/main/main.h | 198 +++++++++++++++++----------------- src/base/main/mainLib.c | 22 ++-- src/base/main/mainReal.c | 62 +++++------ src/demo.c | 10 +- src/misc/util/abc_global.h | 19 ++-- tox.ini | 6 +- 12 files changed, 350 insertions(+), 328 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index f5be19a8ab..ef38be16cb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -28,6 +28,13 @@ set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_EXTENSIONS OFF) +# MSVC has symbols hidden by default. On GCC and Clang we need to explicitly +# set the visibility to hidden to achieve the same result and then manually +# expose what we need. This results in smaller abc dynamic library and thus +# a shorter loading time and higher performance. +set(CMAKE_CXX_VISIBILITY_PRESET hidden) +set(CMAKE_VISIBILITY_INLINES_HIDDEN ON) + if(CMAKE_CXX_COMPILER_ID STREQUAL Clang) set(CLANG_DEFAULT_CXX_STDLIB libc++) set(CLANG_DEFAULT_RTLIB compiler-rt) @@ -82,6 +89,10 @@ option(COVERAGE_BUILD "Enable source-based LLVM code coverage" OFF) option(ABC_SKIP_EXE "Skip building executable (build libs only)" OFF) option(VENDOR_GTEST "download googletest" OFF) +#if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") + #add_definitions(-DABC_DLL=__attribute__\(\(visibility\(\"default\"\)\)\)) +#endif() + add_library(abc_interface INTERFACE) set(ABC_HEADERS @@ -168,7 +179,6 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang target_compile_options(abc_interface INTERFACE $<$:-fpermissive> - $<$:-fvisibility=hidden> ) endif() elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") @@ -179,6 +189,7 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") "_SCL_SECURE_NO_WARNINGS" "_CRT_SECURE_NO_WARNINGS" "_XKEYCHECK_H" + "_ALLOW_KEYWORD_MACROS=1" ) set(CMAKE_DEBUG_POSTFIX d) endif() diff --git a/Makefile b/Makefile index 52c9744438..f75dc60a5c 100644 --- a/Makefile +++ b/Makefile @@ -13,7 +13,7 @@ VPATH = $(ABCSRC) PROG := abc OS := $(shell uname -s) -VERSION ?= 1.1.0 +VERSION ?= 1.2.0 SOVERSION ?= 1 SONAME := lib$(PROG).so.$(SOVERSION) @@ -65,11 +65,13 @@ endif # compile ABC using the C++ compiler and put everything in the namespace $(ABC_NAMESPACE) ifdef ABC_USE_NAMESPACE - CFLAGS += -DABC_NAMESPACE=$(ABC_USE_NAMESPACE) -std=c++11 -fvisibility=hidden -fpermissive + CFLAGS += -DABC_DLL="__attribute__((visibility(\"default\")))" -DABC_NAMESPACE=$(ABC_USE_NAMESPACE) -std=c++17 -fvisibility=hidden -fvisibility-inlines-hidden -fpermissive + CXXFLAGS := $(CFLAGS) CC := $(CXX) DLIBS := -lstdc++ $(info $(MSG_PREFIX)Compiling in namespace $(ABC_NAMESPACE)) else + CXXFLAGS := $(CFLAGS) ABC_USE_LIBSTDCXX := 1 endif diff --git a/src/aig/gia/gia.h b/src/aig/gia/gia.h index b950da4be4..18355231cd 100644 --- a/src/aig/gia/gia.h +++ b/src/aig/gia/gia.h @@ -9,7 +9,7 @@ Synopsis [External declarations.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -17,7 +17,7 @@ Revision [$Id: gia.h,v 1.00 2005/06/20 00:00:00 alanmi Exp $] ***********************************************************************/ - + #ifndef ABC__aig__gia__gia_h #define ABC__aig__gia__gia_h @@ -31,6 +31,7 @@ #include #include +#include "misc/st/st.h" #include "misc/vec/vec.h" #include "misc/vec/vecWec.h" #include "misc/util/utilCex.h" @@ -49,9 +50,9 @@ ABC_NAMESPACE_HEADER_START /// BASIC TYPES /// //////////////////////////////////////////////////////////////////////// -typedef struct Gia_MmFixed_t_ Gia_MmFixed_t; -typedef struct Gia_MmFlex_t_ Gia_MmFlex_t; -typedef struct Gia_MmStep_t_ Gia_MmStep_t; +typedef struct Gia_MmFixed_t_ Gia_MmFixed_t; +typedef struct Gia_MmFlex_t_ Gia_MmFlex_t; +typedef struct Gia_MmStep_t_ Gia_MmStep_t; typedef struct Gia_Dat_t_ Gia_Dat_t; typedef struct Gia_Rpr_t_ Gia_Rpr_t; @@ -90,7 +91,7 @@ struct Gia_Obj_t_ }; // Value is currently used to store several types of information // - pointer to the next node in the hash table during structural hashing -// - pointer to the node copy during duplication +// - pointer to the node copy during duplication // new AIG manager typedef struct Gia_Man_t_ Gia_Man_t; @@ -105,7 +106,7 @@ struct Gia_Man_t_ Gia_Obj_t * pObjs; // the array of objects unsigned * pMuxes; // control signals of MUXes int nXors; // the number of XORs - int nMuxes; // the number of MUXes + int nMuxes; // the number of MUXes int nBufs; // the number of buffers Vec_Int_t * vCis; // the vector of CIs (PIs + LOs) Vec_Int_t * vCos; // the vector of COs (POs + LIs) @@ -121,13 +122,13 @@ struct Gia_Man_t_ int nLevels; // the mamixum level int nConstrs; // the number of constraints int nTravIds; // the current traversal ID - int nFront; // frontier size + int nFront; // frontier size int * pReprsOld; // representatives (for CIs and ANDs) Gia_Rpr_t * pReprs; // representatives (for CIs and ANDs) int * pNexts; // next nodes in the equivalence classes int * pSibls; // next nodes in the choice nodes int * pIso; // pairs of structurally isomorphic nodes - int nTerLoop; // the state where loop begins + int nTerLoop; // the state where loop begins int nTerStates; // the total number of ternary states int * pFanData; // the database to store fanout information int nFansAlloc; // the size of fanout representation @@ -135,7 +136,7 @@ struct Gia_Man_t_ Vec_Int_t * vFanout; // static fanout Vec_Int_t * vMapping; // mapping for each node Vec_Wec_t * vMapping2; // mapping for each node - Vec_Wec_t * vFanouts2; // mapping fanouts + Vec_Wec_t * vFanouts2; // mapping fanouts Vec_Int_t * vCellMapping; // mapping for each node void * pSatlutWinman; // windowing for SAT-based mapping Vec_Int_t * vPacking; // packing information @@ -172,13 +173,13 @@ struct Gia_Man_t_ Vec_Int_t * vCoArrs; // CO arrival times Vec_Int_t * vCoAttrs; // CO attributes Vec_Int_t * vWeights; // object attributes - int And2Delay; // delay of the AND gate + int And2Delay; // delay of the AND gate float DefInArrs; // default PI arrival times float DefOutReqs; // default PO required times Vec_Int_t * vSwitching; // switching activity int * pTravIds; // separate traversal ID representation int nTravIdsAlloc; // the number of trav IDs allocated - Vec_Ptr_t * vNamesIn; // the input names + Vec_Ptr_t * vNamesIn; // the input names Vec_Ptr_t * vNamesOut; // the output names Vec_Ptr_t * vNamesNode; // the node names Vec_Int_t * vUserPiIds; // numbers assigned to PIs by the user @@ -232,7 +233,7 @@ struct Gia_Man_t_ Vec_Wrd_t * vTtMemory; // truth tables for internal nodes // balancing Vec_Int_t * vSuper; // supergate - Vec_Int_t * vStore; // node storage + Vec_Int_t * vStore; // node storage // existential quantification int iSuppPi; // the number of support variables int nSuppWords; // the number of support words @@ -280,11 +281,11 @@ struct Emb_Par_t_ int nSols; // the number of solutions (typically, 2) int nIters; // the number of iterations of FORCE int fRefine; // use refinement by FORCE - int fCluster; // use clustered representation + int fCluster; // use clustered representation int fDump; // dump Gnuplot file int fDumpLarge; // dump Gnuplot file for large benchmarks int fShowImage; // shows image if Gnuplot is installed - int fVerbose; // verbose flag + int fVerbose; // verbose flag }; @@ -319,7 +320,7 @@ typedef struct Gia_ManSim_t_ Gia_ManSim_t; struct Gia_ManSim_t_ { Gia_Man_t * pAig; - Gia_ParSim_t * pPars; + Gia_ParSim_t * pPars; int nWords; Vec_Int_t * vCis2Ids; Vec_Int_t * vConsts; @@ -329,7 +330,7 @@ struct Gia_ManSim_t_ unsigned * pDataSimCos; // simulation data for COs }; -typedef struct Jf_Par_t_ Jf_Par_t; +typedef struct Jf_Par_t_ Jf_Par_t; struct Jf_Par_t_ { int nLutSize; @@ -475,9 +476,9 @@ static inline int Gia_ManBufNum( Gia_Man_t * p ) { return p->nBufs static inline int Gia_ManAndNotBufNum( Gia_Man_t * p ){ return Gia_ManAndNum(p) - Gia_ManBufNum(p); } static inline int Gia_ManCandNum( Gia_Man_t * p ) { return Gia_ManCiNum(p) + Gia_ManAndNum(p); } static inline int Gia_ManConstrNum( Gia_Man_t * p ) { return p->nConstrs; } -static inline void Gia_ManFlipVerbose( Gia_Man_t * p ) { p->fVerbose ^= 1; } -static inline int Gia_ManHasChoices( Gia_Man_t * p ) { return p->pSibls != NULL; } -static inline int Gia_ManChoiceNum( Gia_Man_t * p ) { int c = 0; if (p->pSibls) { int i; for (i = 0; i < p->nObjs; i++) c += (int)(p->pSibls[i] > 0); } return c; } +static inline void Gia_ManFlipVerbose( Gia_Man_t * p ) { p->fVerbose ^= 1; } +static inline int Gia_ManHasChoices( Gia_Man_t * p ) { return p->pSibls != NULL; } +static inline int Gia_ManChoiceNum( Gia_Man_t * p ) { int c = 0; if (p->pSibls) { int i; for (i = 0; i < p->nObjs; i++) c += (int)(p->pSibls[i] > 0); } return c; } static inline Gia_Obj_t * Gia_ManConst0( Gia_Man_t * p ) { return p->pObjs; } static inline Gia_Obj_t * Gia_ManConst1( Gia_Man_t * p ) { return Gia_Not(Gia_ManConst0(p)); } @@ -502,20 +503,20 @@ static inline char * Gia_ObjCoName( Gia_Man_t * p, int i ) { static inline char * Gia_ObjName( Gia_Man_t * p, int i ) { return p->vNamesNode ? (char*)Vec_PtrEntry(p->vNamesNode, i) : NULL; } static inline char * Gia_ObjNameObj( Gia_Man_t * p, Gia_Obj_t * pObj ) { return p->vNamesNode ? (char*)Vec_PtrEntry(p->vNamesNode, Gia_ObjId(p, pObj)) : NULL; } -static inline int Gia_ObjIsTerm( Gia_Obj_t * pObj ) { return pObj->fTerm; } -static inline int Gia_ObjIsAndOrConst0( Gia_Obj_t * pObj ) { return!pObj->fTerm; } -static inline int Gia_ObjIsCi( Gia_Obj_t * pObj ) { return pObj->fTerm && pObj->iDiff0 == GIA_NONE; } -static inline int Gia_ObjIsCo( Gia_Obj_t * pObj ) { return pObj->fTerm && pObj->iDiff0 != GIA_NONE; } -static inline int Gia_ObjIsAnd( Gia_Obj_t * pObj ) { return!pObj->fTerm && pObj->iDiff0 != GIA_NONE; } -static inline int Gia_ObjIsXor( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 < pObj->iDiff1; } -static inline int Gia_ObjIsMuxId( Gia_Man_t * p, int iObj ) { return p->pMuxes && p->pMuxes[iObj] > 0; } -static inline int Gia_ObjIsMux( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsMuxId( p, Gia_ObjId(p, pObj) ); } -static inline int Gia_ObjIsAndReal( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 > pObj->iDiff1 && !Gia_ObjIsMux(p, pObj); } -static inline int Gia_ObjIsBuf( Gia_Obj_t * pObj ) { return pObj->iDiff0 == pObj->iDiff1 && pObj->iDiff0 != GIA_NONE && !pObj->fTerm; } -static inline int Gia_ObjIsAndNotBuf( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 != pObj->iDiff1; } -static inline int Gia_ObjIsCand( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) || Gia_ObjIsCi(pObj); } -static inline int Gia_ObjIsConst0( Gia_Obj_t * pObj ) { return pObj->iDiff0 == GIA_NONE && pObj->iDiff1 == GIA_NONE; } -static inline int Gia_ManObjIsConst0( Gia_Man_t * p, Gia_Obj_t * pObj){ return pObj == p->pObjs; } +static inline int Gia_ObjIsTerm( Gia_Obj_t * pObj ) { return pObj->fTerm; } +static inline int Gia_ObjIsAndOrConst0( Gia_Obj_t * pObj ) { return!pObj->fTerm; } +static inline int Gia_ObjIsCi( Gia_Obj_t * pObj ) { return pObj->fTerm && pObj->iDiff0 == GIA_NONE; } +static inline int Gia_ObjIsCo( Gia_Obj_t * pObj ) { return pObj->fTerm && pObj->iDiff0 != GIA_NONE; } +static inline int Gia_ObjIsAnd( Gia_Obj_t * pObj ) { return!pObj->fTerm && pObj->iDiff0 != GIA_NONE; } +static inline int Gia_ObjIsXor( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 < pObj->iDiff1; } +static inline int Gia_ObjIsMuxId( Gia_Man_t * p, int iObj ) { return p->pMuxes && p->pMuxes[iObj] > 0; } +static inline int Gia_ObjIsMux( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsMuxId( p, Gia_ObjId(p, pObj) ); } +static inline int Gia_ObjIsAndReal( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 > pObj->iDiff1 && !Gia_ObjIsMux(p, pObj); } +static inline int Gia_ObjIsBuf( Gia_Obj_t * pObj ) { return pObj->iDiff0 == pObj->iDiff1 && pObj->iDiff0 != GIA_NONE && !pObj->fTerm; } +static inline int Gia_ObjIsAndNotBuf( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) && pObj->iDiff0 != pObj->iDiff1; } +static inline int Gia_ObjIsCand( Gia_Obj_t * pObj ) { return Gia_ObjIsAnd(pObj) || Gia_ObjIsCi(pObj); } +static inline int Gia_ObjIsConst0( Gia_Obj_t * pObj ) { return pObj->iDiff0 == GIA_NONE && pObj->iDiff1 == GIA_NONE; } +static inline int Gia_ManObjIsConst0( Gia_Man_t * p, Gia_Obj_t * pObj){ return pObj == p->pObjs; } static inline int Gia_Obj2Lit( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Abc_Var2Lit(Gia_ObjId(p, Gia_Regular(pObj)), Gia_IsComplement(pObj)); } static inline Gia_Obj_t * Gia_Lit2Obj( Gia_Man_t * p, int iLit ) { return Gia_NotCond(Gia_ManObj(p, Abc_Lit2Var(iLit)), Abc_LitIsCompl(iLit)); } @@ -525,14 +526,14 @@ static inline int Gia_ManIdToCioId( Gia_Man_t * p, int Id ) { static inline int Gia_ManCiIdToId( Gia_Man_t * p, int CiId ) { return Gia_ObjId( p, Gia_ManCi(p, CiId) ); } static inline int Gia_ManCoIdToId( Gia_Man_t * p, int CoId ) { return Gia_ObjId( p, Gia_ManCo(p, CoId) ); } -static inline int Gia_ObjIsPi( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCi(pObj) && Gia_ObjCioId(pObj) < Gia_ManPiNum(p); } -static inline int Gia_ObjIsPo( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCo(pObj) && Gia_ObjCioId(pObj) < Gia_ManPoNum(p); } -static inline int Gia_ObjIsRo( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCi(pObj) && Gia_ObjCioId(pObj) >= Gia_ManPiNum(p); } -static inline int Gia_ObjIsRi( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCo(pObj) && Gia_ObjCioId(pObj) >= Gia_ManPoNum(p); } +static inline int Gia_ObjIsPi( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCi(pObj) && Gia_ObjCioId(pObj) < Gia_ManPiNum(p); } +static inline int Gia_ObjIsPo( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCo(pObj) && Gia_ObjCioId(pObj) < Gia_ManPoNum(p); } +static inline int Gia_ObjIsRo( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCi(pObj) && Gia_ObjCioId(pObj) >= Gia_ManPiNum(p); } +static inline int Gia_ObjIsRi( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjIsCo(pObj) && Gia_ObjCioId(pObj) >= Gia_ManPoNum(p); } -static inline Gia_Obj_t * Gia_ObjRoToRi( Gia_Man_t * p, Gia_Obj_t * pObj ) { assert( Gia_ObjIsRo(p, pObj) ); return Gia_ManCo(p, Gia_ManCoNum(p) - Gia_ManCiNum(p) + Gia_ObjCioId(pObj)); } -static inline Gia_Obj_t * Gia_ObjRiToRo( Gia_Man_t * p, Gia_Obj_t * pObj ) { assert( Gia_ObjIsRi(p, pObj) ); return Gia_ManCi(p, Gia_ManCiNum(p) - Gia_ManCoNum(p) + Gia_ObjCioId(pObj)); } -static inline int Gia_ObjRoToRiId( Gia_Man_t * p, int ObjId ) { return Gia_ObjId( p, Gia_ObjRoToRi( p, Gia_ManObj(p, ObjId) ) ); } +static inline Gia_Obj_t * Gia_ObjRoToRi( Gia_Man_t * p, Gia_Obj_t * pObj ) { assert( Gia_ObjIsRo(p, pObj) ); return Gia_ManCo(p, Gia_ManCoNum(p) - Gia_ManCiNum(p) + Gia_ObjCioId(pObj)); } +static inline Gia_Obj_t * Gia_ObjRiToRo( Gia_Man_t * p, Gia_Obj_t * pObj ) { assert( Gia_ObjIsRi(p, pObj) ); return Gia_ManCi(p, Gia_ManCiNum(p) - Gia_ManCoNum(p) + Gia_ObjCioId(pObj)); } +static inline int Gia_ObjRoToRiId( Gia_Man_t * p, int ObjId ) { return Gia_ObjId( p, Gia_ObjRoToRi( p, Gia_ManObj(p, ObjId) ) ); } static inline int Gia_ObjRiToRoId( Gia_Man_t * p, int ObjId ) { return Gia_ObjId( p, Gia_ObjRiToRo( p, Gia_ManObj(p, ObjId) ) ); } static inline int Gia_ObjDiff0( Gia_Obj_t * pObj ) { return pObj->iDiff0; } @@ -673,9 +674,9 @@ static inline word * Gia_ObjSim( Gia_Man_t * p, int Id ) { static inline word * Gia_ObjSimObj( Gia_Man_t * p, Gia_Obj_t * pObj ) { return Gia_ObjSim( p, Gia_ObjId(p, pObj) ); } // AIG construction -extern void Gia_ObjAddFanout( Gia_Man_t * p, Gia_Obj_t * pObj, Gia_Obj_t * pFanout ); -static inline Gia_Obj_t * Gia_ManAppendObj( Gia_Man_t * p ) -{ +ABC_DLL extern void Gia_ObjAddFanout( Gia_Man_t * p, Gia_Obj_t * pObj, Gia_Obj_t * pFanout ); +static inline Gia_Obj_t * Gia_ManAppendObj( Gia_Man_t * p ) +{ if ( p->nObjs == p->nObjsAlloc ) { int nObjNew = Abc_MinInt( 2 * p->nObjsAlloc, (1 << 29) ); @@ -697,8 +698,8 @@ static inline Gia_Obj_t * Gia_ManAppendObj( Gia_Man_t * p ) if ( Vec_IntSize(&p->vHTable) ) Vec_IntPush( &p->vHash, 0 ); return Gia_ManObj( p, p->nObjs++ ); } -static inline int Gia_ManAppendCi( Gia_Man_t * p ) -{ +static inline int Gia_ManAppendCi( Gia_Man_t * p ) +{ Gia_Obj_t * pObj = Gia_ManAppendObj( p ); pObj->fTerm = 1; pObj->iDiff0 = GIA_NONE; @@ -707,11 +708,11 @@ static inline int Gia_ManAppendCi( Gia_Man_t * p ) return Gia_ObjId( p, pObj ) << 1; } -extern void Gia_ManQuantSetSuppAnd( Gia_Man_t * p, Gia_Obj_t * pObj ); -extern void Gia_ManBuiltInSimPerform( Gia_Man_t * p, int iObj ); +ABC_DLL extern void Gia_ManQuantSetSuppAnd( Gia_Man_t * p, Gia_Obj_t * pObj ); +ABC_DLL extern void Gia_ManBuiltInSimPerform( Gia_Man_t * p, int iObj ); -static inline int Gia_ManAppendAnd( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendAnd( Gia_Man_t * p, int iLit0, int iLit1 ) +{ Gia_Obj_t * pObj = Gia_ManAppendObj( p ); assert( iLit0 >= 0 && Abc_Lit2Var(iLit0) < Gia_ManObjNum(p) ); assert( iLit1 >= 0 && Abc_Lit2Var(iLit1) < Gia_ManObjNum(p) ); @@ -754,8 +755,8 @@ static inline int Gia_ManAppendAnd( Gia_Man_t * p, int iLit0, int iLit1 ) Gia_ManQuantSetSuppAnd( p, pObj ); return Gia_ObjId( p, pObj ) << 1; } -static inline int Gia_ManAppendXorReal( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendXorReal( Gia_Man_t * p, int iLit0, int iLit1 ) +{ Gia_Obj_t * pObj = Gia_ManAppendObj( p ); assert( iLit0 >= 0 && Abc_Lit2Var(iLit0) < Gia_ManObjNum(p) ); assert( iLit1 >= 0 && Abc_Lit2Var(iLit1) < Gia_ManObjNum(p) ); @@ -779,8 +780,8 @@ static inline int Gia_ManAppendXorReal( Gia_Man_t * p, int iLit0, int iLit1 ) p->nXors++; return Gia_ObjId( p, pObj ) << 1; } -static inline int Gia_ManAppendMuxReal( Gia_Man_t * p, int iLitC, int iLit1, int iLit0 ) -{ +static inline int Gia_ManAppendMuxReal( Gia_Man_t * p, int iLitC, int iLit1, int iLit0 ) +{ Gia_Obj_t * pObj = Gia_ManAppendObj( p ); assert( p->pMuxes != NULL ); assert( iLit0 >= 0 && Abc_Lit2Var(iLit0) < Gia_ManObjNum(p) ); @@ -809,8 +810,8 @@ static inline int Gia_ManAppendMuxReal( Gia_Man_t * p, int iLitC, int iLit1, int p->nMuxes++; return Gia_ObjId( p, pObj ) << 1; } -static inline int Gia_ManAppendBuf( Gia_Man_t * p, int iLit ) -{ +static inline int Gia_ManAppendBuf( Gia_Man_t * p, int iLit ) +{ Gia_Obj_t * pObj = Gia_ManAppendObj( p ); assert( iLit >= 0 && Abc_Lit2Var(iLit) < Gia_ManObjNum(p) ); pObj->iDiff0 = pObj->iDiff1 = Gia_ObjId(p, pObj) - Abc_Lit2Var(iLit); @@ -818,12 +819,12 @@ static inline int Gia_ManAppendBuf( Gia_Man_t * p, int iLit ) p->nBufs++; return Gia_ObjId( p, pObj ) << 1; } -static inline int Gia_ManAppendCo( Gia_Man_t * p, int iLit0 ) -{ +static inline int Gia_ManAppendCo( Gia_Man_t * p, int iLit0 ) +{ Gia_Obj_t * pObj; assert( iLit0 >= 0 && Abc_Lit2Var(iLit0) < Gia_ManObjNum(p) ); assert( !Gia_ObjIsCo(Gia_ManObj(p, Abc_Lit2Var(iLit0))) ); - pObj = Gia_ManAppendObj( p ); + pObj = Gia_ManAppendObj( p ); pObj->fTerm = 1; pObj->iDiff0 = Gia_ObjId(p, pObj) - Abc_Lit2Var(iLit0); pObj->fCompl0 = Abc_LitIsCompl(iLit0); @@ -837,26 +838,26 @@ static inline int Gia_ManAppendOr( Gia_Man_t * p, int iLit0, int iLit1 ) { return Abc_LitNot(Gia_ManAppendAnd( p, Abc_LitNot(iLit0), Abc_LitNot(iLit1) )); } -static inline int Gia_ManAppendMux( Gia_Man_t * p, int iCtrl, int iData1, int iData0 ) -{ +static inline int Gia_ManAppendMux( Gia_Man_t * p, int iCtrl, int iData1, int iData0 ) +{ int iTemp0 = Gia_ManAppendAnd( p, Abc_LitNot(iCtrl), iData0 ); int iTemp1 = Gia_ManAppendAnd( p, iCtrl, iData1 ); return Abc_LitNotCond( Gia_ManAppendAnd( p, Abc_LitNot(iTemp0), Abc_LitNot(iTemp1) ), 1 ); } -static inline int Gia_ManAppendMaj( Gia_Man_t * p, int iData0, int iData1, int iData2 ) -{ +static inline int Gia_ManAppendMaj( Gia_Man_t * p, int iData0, int iData1, int iData2 ) +{ int iTemp0 = Gia_ManAppendOr( p, iData1, iData2 ); int iTemp1 = Gia_ManAppendAnd( p, iData0, iTemp0 ); int iTemp2 = Gia_ManAppendAnd( p, iData1, iData2 ); return Gia_ManAppendOr( p, iTemp1, iTemp2 ); } -static inline int Gia_ManAppendXor( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendXor( Gia_Man_t * p, int iLit0, int iLit1 ) +{ return Gia_ManAppendMux( p, iLit0, Abc_LitNot(iLit1), iLit1 ); } -static inline int Gia_ManAppendAnd2( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendAnd2( Gia_Man_t * p, int iLit0, int iLit1 ) +{ if ( !p->fGiaSimple ) { if ( iLit0 < 2 ) @@ -874,26 +875,26 @@ static inline int Gia_ManAppendOr2( Gia_Man_t * p, int iLit0, int iLit1 ) { return Abc_LitNot(Gia_ManAppendAnd2( p, Abc_LitNot(iLit0), Abc_LitNot(iLit1) )); } -static inline int Gia_ManAppendMux2( Gia_Man_t * p, int iCtrl, int iData1, int iData0 ) -{ +static inline int Gia_ManAppendMux2( Gia_Man_t * p, int iCtrl, int iData1, int iData0 ) +{ int iTemp0 = Gia_ManAppendAnd2( p, Abc_LitNot(iCtrl), iData0 ); int iTemp1 = Gia_ManAppendAnd2( p, iCtrl, iData1 ); return Abc_LitNotCond( Gia_ManAppendAnd2( p, Abc_LitNot(iTemp0), Abc_LitNot(iTemp1) ), 1 ); } -static inline int Gia_ManAppendMaj2( Gia_Man_t * p, int iData0, int iData1, int iData2 ) -{ +static inline int Gia_ManAppendMaj2( Gia_Man_t * p, int iData0, int iData1, int iData2 ) +{ int iTemp0 = Gia_ManAppendOr2( p, iData1, iData2 ); int iTemp1 = Gia_ManAppendAnd2( p, iData0, iTemp0 ); int iTemp2 = Gia_ManAppendAnd2( p, iData1, iData2 ); return Gia_ManAppendOr2( p, iTemp1, iTemp2 ); } -static inline int Gia_ManAppendXor2( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendXor2( Gia_Man_t * p, int iLit0, int iLit1 ) +{ return Gia_ManAppendMux2( p, iLit0, Abc_LitNot(iLit1), iLit1 ); } -static inline int Gia_ManAppendXorReal2( Gia_Man_t * p, int iLit0, int iLit1 ) -{ +static inline int Gia_ManAppendXorReal2( Gia_Man_t * p, int iLit0, int iLit1 ) +{ if ( !p->fGiaSimple ) { if ( iLit0 < 2 ) @@ -908,7 +909,7 @@ static inline int Gia_ManAppendXorReal2( Gia_Man_t * p, int iLit0, int iLit1 ) return Gia_ManAppendXorReal( p, iLit0, iLit1 ); } -static inline void Gia_ManPatchCoDriver( Gia_Man_t * p, int iCoIndex, int iLit0 ) +static inline void Gia_ManPatchCoDriver( Gia_Man_t * p, int iCoIndex, int iLit0 ) { Gia_Obj_t * pObjCo = Gia_ManCo( p, iCoIndex ); assert( Gia_ObjId(p, pObjCo) > Abc_Lit2Var(iLit0) ); @@ -920,16 +921,16 @@ static inline void Gia_ManPatchCoDriver( Gia_Man_t * p, int iCoIndex, int iLit0 #define GIA_ONE 2 #define GIA_UND 3 -static inline int Gia_XsimNotCond( int Value, int fCompl ) -{ +static inline int Gia_XsimNotCond( int Value, int fCompl ) +{ if ( Value == GIA_UND ) return GIA_UND; if ( Value == GIA_ZER + fCompl ) return GIA_ZER; return GIA_ONE; } -static inline int Gia_XsimAndCond( int Value0, int fCompl0, int Value1, int fCompl1 ) -{ +static inline int Gia_XsimAndCond( int Value0, int fCompl0, int Value1, int fCompl1 ) +{ if ( Value0 == GIA_ZER + fCompl0 || Value1 == GIA_ZER + fCompl1 ) return GIA_ZER; if ( Value0 == GIA_UND || Value1 == GIA_UND ) @@ -963,7 +964,7 @@ static inline void Gia_ObjTerSimAnd( Gia_Obj_t * pObj ) Gia_ObjTerSimSet0( pObj ); else if ( Gia_ObjTerSimGet1Fanin0(pObj) && Gia_ObjTerSimGet1Fanin1(pObj) ) Gia_ObjTerSimSet1( pObj ); - else + else Gia_ObjTerSimSetX( pObj ); } static inline void Gia_ObjTerSimCo( Gia_Obj_t * pObj ) @@ -974,7 +975,7 @@ static inline void Gia_ObjTerSimCo( Gia_Obj_t * pObj ) Gia_ObjTerSimSet0( pObj ); else if ( Gia_ObjTerSimGet1Fanin0(pObj) ) Gia_ObjTerSimSet1( pObj ); - else + else Gia_ObjTerSimSetX( pObj ); } static inline void Gia_ObjTerSimRo( Gia_Man_t * p, Gia_Obj_t * pObj ) @@ -1346,11 +1347,11 @@ extern Gia_Man_t * Gia_ManDupOrderAiger( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupLastPis( Gia_Man_t * p, int nLastPis ); extern Gia_Man_t * Gia_ManDupFlip( Gia_Man_t * p, int * pInitState ); extern Gia_Man_t * Gia_ManDupCycled( Gia_Man_t * pAig, Abc_Cex_t * pCex, int nFrames ); -extern Gia_Man_t * Gia_ManDup( Gia_Man_t * p ); -extern Gia_Man_t * Gia_ManDupNoBuf( Gia_Man_t * p ); +extern Gia_Man_t * Gia_ManDup( Gia_Man_t * p ); +extern Gia_Man_t * Gia_ManDupNoBuf( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupMap( Gia_Man_t * p, Vec_Int_t * vMap ); extern Gia_Man_t * Gia_ManDup2( Gia_Man_t * p1, Gia_Man_t * p2 ); -extern Gia_Man_t * Gia_ManDupWithAttributes( Gia_Man_t * p ); +extern Gia_Man_t * Gia_ManDupWithAttributes( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupRemovePis( Gia_Man_t * p, int nRemPis ); extern Gia_Man_t * Gia_ManDupZero( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupPerm( Gia_Man_t * p, Vec_Int_t * vPiPerm ); @@ -1363,12 +1364,12 @@ extern Gia_Man_t * Gia_ManDupAppendCones( Gia_Man_t * p, Gia_Man_t ** pp extern Gia_Man_t * Gia_ManDupSelf( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupFlopClass( Gia_Man_t * p, int iClass ); extern Gia_Man_t * Gia_ManDupMarked( Gia_Man_t * p ); -extern Gia_Man_t * Gia_ManDupTimes( Gia_Man_t * p, int nTimes ); -extern Gia_Man_t * Gia_ManDupDfs( Gia_Man_t * p ); +extern Gia_Man_t * Gia_ManDupTimes( Gia_Man_t * p, int nTimes ); +extern Gia_Man_t * Gia_ManDupDfs( Gia_Man_t * p ); extern Gia_Man_t * Gia_ManDupDfsOnePo( Gia_Man_t * p, int iPo ); extern Gia_Man_t * Gia_ManDupDfsRehash( Gia_Man_t * p ); -extern Gia_Man_t * Gia_ManDupCofactorVar( Gia_Man_t * p, int iVar, int Value ); -extern Gia_Man_t * Gia_ManDupCofactorObj( Gia_Man_t * p, int iObj, int Value ); +extern Gia_Man_t * Gia_ManDupCofactorVar( Gia_Man_t * p, int iVar, int Value ); +extern Gia_Man_t * Gia_ManDupCofactorObj( Gia_Man_t * p, int iObj, int Value ); extern Gia_Man_t * Gia_ManDupMux( int iVar, Gia_Man_t * pCof1, Gia_Man_t * pCof0 ); extern Gia_Man_t * Gia_ManDupBlock( Gia_Man_t * p, int nBlock ); extern Gia_Man_t * Gia_ManDupExist( Gia_Man_t * p, int iVar ); @@ -1457,13 +1458,13 @@ extern int Gia_ManFilterEquivsForSpeculation( Gia_Man_t * pGia, extern int Gia_ManFilterEquivsUsingParts( Gia_Man_t * pGia, char * pName1, char * pName2 ); extern void Gia_ManFilterEquivsUsingLatches( Gia_Man_t * pGia, int fFlopsOnly, int fFlopsWith, int fUseRiDrivers ); /*=== giaExist.c =========================================================*/ -extern void Gia_ManQuantSetSuppStart( Gia_Man_t * p ); +ABC_DLL extern void Gia_ManQuantSetSuppStart( Gia_Man_t * p ); extern void Gia_ManQuantSetSuppZero( Gia_Man_t * p ); extern void Gia_ManQuantSetSuppCi( Gia_Man_t * p, Gia_Obj_t * pObj ); extern void Gia_ManQuantUpdateCiSupp( Gia_Man_t * p, int iObj ); extern int Gia_ManQuantExist( Gia_Man_t * p, int iLit, int(*pFuncCiToKeep)(void *, int), void * pData ); /*=== giaFanout.c =========================================================*/ -extern void Gia_ObjAddFanout( Gia_Man_t * p, Gia_Obj_t * pObj, Gia_Obj_t * pFanout ); +ABC_DLL extern void Gia_ObjAddFanout( Gia_Man_t * p, Gia_Obj_t * pObj, Gia_Obj_t * pFanout ); extern void Gia_ObjRemoveFanout( Gia_Man_t * p, Gia_Obj_t * pObj, Gia_Obj_t * pFanout ); extern void Gia_ManFanoutStart( Gia_Man_t * p ); extern void Gia_ManFanoutStop( Gia_Man_t * p ); @@ -1480,7 +1481,7 @@ extern void * Gia_ManUnrollAdd( void * pMan, int fMax ); extern void Gia_ManUnrollStop( void * pMan ); extern int Gia_ManUnrollLastLit( void * pMan ); extern void Gia_ManFraSetDefaultParams( Gia_ParFra_t * p ); -extern Gia_Man_t * Gia_ManFrames( Gia_Man_t * pAig, Gia_ParFra_t * pPars ); +extern Gia_Man_t * Gia_ManFrames( Gia_Man_t * pAig, Gia_ParFra_t * pPars ); extern Gia_Man_t * Gia_ManFramesInitSpecial( Gia_Man_t * pAig, int nFrames, int fVerbose ); /*=== giaFront.c ==========================================================*/ extern Gia_Man_t * Gia_ManFront( Gia_Man_t * p ); @@ -1488,14 +1489,14 @@ extern void Gia_ManFrontTest( Gia_Man_t * p ); /*=== giaFx.c ==========================================================*/ extern Gia_Man_t * Gia_ManPerformFx( Gia_Man_t * p, int nNewNodesMax, int LitCountMax, int fReverse, int fVerbose, int fVeryVerbose ); /*=== giaHash.c ===========================================================*/ -extern void Gia_ManHashAlloc( Gia_Man_t * p ); -extern void Gia_ManHashStart( Gia_Man_t * p ); +extern void Gia_ManHashAlloc( Gia_Man_t * p ); +extern void Gia_ManHashStart( Gia_Man_t * p ); extern void Gia_ManHashStop( Gia_Man_t * p ); extern int Gia_ManHashXorReal( Gia_Man_t * p, int iLit0, int iLit1 ); extern int Gia_ManHashMuxReal( Gia_Man_t * p, int iLitC, int iLit1, int iLit0 ); -extern int Gia_ManHashAnd( Gia_Man_t * p, int iLit0, int iLit1 ); -extern int Gia_ManHashOr( Gia_Man_t * p, int iLit0, int iLit1 ); -extern int Gia_ManHashXor( Gia_Man_t * p, int iLit0, int iLit1 ); +extern int Gia_ManHashAnd( Gia_Man_t * p, int iLit0, int iLit1 ); +extern int Gia_ManHashOr( Gia_Man_t * p, int iLit0, int iLit1 ); +extern int Gia_ManHashXor( Gia_Man_t * p, int iLit0, int iLit1 ); extern int Gia_ManHashMux( Gia_Man_t * p, int iCtrl, int iData1, int iData0 ); extern int Gia_ManHashMaj( Gia_Man_t * p, int iData0, int iData1, int iData2 ); extern int Gia_ManHashAndTry( Gia_Man_t * p, int iLit0, int iLit1 ); @@ -1516,7 +1517,7 @@ extern int Gia_ManLutNum( Gia_Man_t * p ); extern int Gia_ManLutLevel( Gia_Man_t * p, int ** ppLevels ); extern void Gia_ManLutParams( Gia_Man_t * p, int * pnCurLuts, int * pnCurEdges, int * pnCurLevels ); extern void Gia_ManSetRefsMapped( Gia_Man_t * p ); -extern void Gia_ManSetLutRefs( Gia_Man_t * p ); +extern void Gia_ManSetLutRefs( Gia_Man_t * p ); extern void Gia_ManSetIfParsDefault( void * pIfPars ); extern void Gia_ManMappingVerify( Gia_Man_t * p ); extern void Gia_ManTransferMapping( Gia_Man_t * p, Gia_Man_t * pGia ); @@ -1542,13 +1543,13 @@ extern Gia_Man_t * Gia_ManPerformLfMapping( Gia_Man_t * p, Jf_Par_t * pP extern void Gia_ManTestDistance( Gia_Man_t * p ); extern void Gia_ManSolveProblem( Gia_Man_t * pGia, Emb_Par_t * pPars ); /*=== giaMan.c ===========================================================*/ -extern Gia_Man_t * Gia_ManStart( int nObjsMax ); -extern void Gia_ManStop( Gia_Man_t * p ); -extern void Gia_ManStopP( Gia_Man_t ** p ); +ABC_DLL extern Gia_Man_t * Gia_ManStart( int nObjsMax ); +ABC_DLL extern void Gia_ManStop( Gia_Man_t * p ); +extern void Gia_ManStopP( Gia_Man_t ** p ); extern double Gia_ManMemory( Gia_Man_t * p ); -extern void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars ); -extern void Gia_ManPrintStatsShort( Gia_Man_t * p ); -extern void Gia_ManPrintMiterStatus( Gia_Man_t * p ); +extern void Gia_ManPrintStats( Gia_Man_t * p, Gps_Par_t * pPars ); +extern void Gia_ManPrintStatsShort( Gia_Man_t * p ); +extern void Gia_ManPrintMiterStatus( Gia_Man_t * p ); extern void Gia_ManPrintStatsMiter( Gia_Man_t * p, int fVerbose ); extern void Gia_ManSetRegNum( Gia_Man_t * p, int nRegs ); extern void Gia_ManReportImprovement( Gia_Man_t * p, Gia_Man_t * pNew ); @@ -1624,7 +1625,7 @@ extern void Gia_ManSimInfoInit( Gia_ManSim_t * p ); extern void Gia_ManSimInfoTransfer( Gia_ManSim_t * p ); extern void Gia_ManSimulateRound( Gia_ManSim_t * p ); extern void Gia_ManBuiltInSimStart( Gia_Man_t * p, int nWords, int nObjs ); -extern void Gia_ManBuiltInSimPerform( Gia_Man_t * p, int iObj ); +ABC_DLL extern void Gia_ManBuiltInSimPerform( Gia_Man_t * p, int iObj ); extern int Gia_ManBuiltInSimCheckOver( Gia_Man_t * p, int iLit0, int iLit1 ); extern int Gia_ManBuiltInSimCheckEqual( Gia_Man_t * p, int iLit0, int iLit1 ); extern void Gia_ManBuiltInSimResimulateCone( Gia_Man_t * p, int iLit0, int iLit1 ); @@ -1636,7 +1637,7 @@ extern int Gia_ManIncrSimCheckOver( Gia_Man_t * p, int iLit0, in extern int Gia_ManIncrSimCheckEqual( Gia_Man_t * p, int iLit0, int iLit1 ); /*=== giaSimBase.c ============================================================*/ extern Vec_Wrd_t * Gia_ManSimPatSim( Gia_Man_t * p ); -extern Vec_Wrd_t * Gia_ManSimPatSimOut( Gia_Man_t * pGia, Vec_Wrd_t * vSimsPi, int fOuts ); +ABC_DLL extern Vec_Wrd_t * Gia_ManSimPatSimOut( Gia_Man_t * pGia, Vec_Wrd_t * vSimsPi, int fOuts ); extern void Gia_ManSim2ArrayOne( Vec_Wrd_t * vSimsPi, Vec_Int_t * vRes ); extern Vec_Wec_t * Gia_ManSim2Array( Vec_Ptr_t * vSims ); extern Vec_Wrd_t * Gia_ManArray2SimOne( Vec_Int_t * vRes ); diff --git a/src/base/acb/acbTest.c b/src/base/acb/acbTest.c index fc450818ea..9eef818380 100644 --- a/src/base/acb/acbTest.c +++ b/src/base/acb/acbTest.c @@ -9,7 +9,7 @@ Synopsis [] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - July 21, 2015.] @@ -42,7 +42,7 @@ static int fForceZero = 0; Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -74,11 +74,11 @@ void Gia_ManSimTry( Gia_Man_t * pF, Gia_Man_t * pG ) int nBitsFx = Abc_TtCountOnesVec(pSimFx, nWords); int nBitsF1 = Abc_TtCountOnesVecMask(pSimFx, pSimFb, nWords, 1); int nBitsF0 = nWords*64 - nBitsFx - nBitsF1; - + int nBitsGx = Abc_TtCountOnesVec(pSimGx, nWords); int nBitsG1 = Abc_TtCountOnesVecMask(pSimGx, pSimGb, nWords, 1); int nBitsG0 = nWords*64 - nBitsGx - nBitsG1; - + printf( "Output %4d : ", i ); printf( " RF : " ); @@ -135,7 +135,7 @@ void Gia_ManSimTry( Gia_Man_t * pF, Gia_Man_t * pG ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -145,7 +145,7 @@ void Gia_ManDualNot( Gia_Man_t * p, int LitA[2], int LitZ[2] ) { LitZ[0] = Abc_LitNot(LitA[0]); LitZ[1] = LitA[1]; - + if ( fForceZero ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], Abc_LitNot(LitZ[1]) ); } // computes Z = XOR(A, B) where A, B, Z belong to {0,1,x} encoded as 0=00, 1=01, x=1- @@ -153,7 +153,7 @@ void Gia_ManDualXor2( Gia_Man_t * p, int LitA[2], int LitB[2], int LitZ[2] ) { LitZ[0] = Gia_ManHashXor( p, LitA[0], LitB[0] ); LitZ[1] = Gia_ManHashOr( p, LitA[1], LitB[1] ); - + if ( fForceZero ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], Abc_LitNot(LitZ[1]) ); } void Gia_ManDualXorN( Gia_Man_t * p, int * pLits, int n, int LitZ[2] ) @@ -192,7 +192,7 @@ void Gia_ManDualAndN( Gia_Man_t * p, int * pLits, int n, int LitZ[2] ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], pLits[2*i] ); } LitZ[1] = Gia_ManHashAnd( p, LitOne, Abc_LitNot(LitZero) ); - + if ( fForceZero ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], Abc_LitNot(LitZ[1]) ); } /* @@ -207,7 +207,7 @@ void Gia_ManDualDc( Gia_Man_t * p, int LitC[2], int LitD[2], int LitZ[2] ) LitZ[0] = LitC[0]; // LitZ[0] = Gia_ManHashMux( p, LitD[0], 0, LitC[0] ); LitZ[1] = Gia_ManHashOr(p, Gia_ManHashOr(p,LitD[0],LitD[1]), LitC[1] ); - + if ( fForceZero ) LitZ[0] = Gia_ManHashAnd( p, LitZ[0], Abc_LitNot(LitZ[1]) ); } void Gia_ManDualMux( Gia_Man_t * p, int LitC[2], int LitT[2], int LitE[2], int LitZ[2] ) @@ -248,7 +248,7 @@ int Gia_ManDualCompare( Gia_Man_t * p, unsigned int LitF[2], unsigned int LitS[2 Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -267,36 +267,36 @@ void Acb_ObjToGiaDual( Gia_Man_t * pNew, Acb_Ntk_t * p, int iObj, Vec_Int_t * vT Vec_IntPushTwo( vTemp, pLits[0], pLits[1] ); } Type = Acb_ObjType( p, iObj ); - if ( Type == ABC_OPER_CONST_F ) + if ( Type == ABC_OPER_CONST_F ) { pRes[0] = 0; pRes[1] = 0; return; } - if ( Type == ABC_OPER_CONST_T ) + if ( Type == ABC_OPER_CONST_T ) { pRes[0] = 1; pRes[1] = 0; return; } - if ( Type == ABC_OPER_CONST_X ) + if ( Type == ABC_OPER_CONST_X ) { pRes[0] = 0; pRes[1] = 1; return; } - if ( Type == ABC_OPER_BIT_BUF ) + if ( Type == ABC_OPER_BIT_BUF ) { pRes[0] = Vec_IntEntry(vTemp, 0); pRes[1] = Vec_IntEntry(vTemp, 1); return; } - if ( Type == ABC_OPER_BIT_INV ) + if ( Type == ABC_OPER_BIT_INV ) { Gia_ManDualNot( pNew, Vec_IntArray(vTemp), pRes ); return; } - if ( Type == ABC_OPER_TRI ) + if ( Type == ABC_OPER_TRI ) { // in the file inputs are ordered as follows: _DC \n6_5[9] ( .O(\108 ), .C(\96 ), .D(\107 )); // in this code, we expect them as follows: void Gia_ManDualDc( Gia_Man_t * p, int LitC[2], int LitD[2], int LitZ[2] ) @@ -304,7 +304,7 @@ void Acb_ObjToGiaDual( Gia_Man_t * pNew, Acb_Ntk_t * p, int iObj, Vec_Int_t * vT Gia_ManDualDc( pNew, Vec_IntArray(vTemp), Vec_IntArray(vTemp) + 2, pRes ); return; } - if ( Type == ABC_OPER_BIT_MUX ) + if ( Type == ABC_OPER_BIT_MUX ) { // in the file inputs are ordered as follows: _HMUX \U$1 ( .O(\282 ), .I0(1'b1), .I1(\277 ), .S(\281 )); // in this code, we expect them as follows: void Gia_ManDualMux( Gia_Man_t * p, int LitC[2], int LitT[2], int LitE[2], int LitZ[2] ) @@ -386,7 +386,7 @@ Gia_Man_t * Acb_NtkGiaDeriveDual( Acb_Ntk_t * p ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -443,7 +443,7 @@ Gia_Man_t * Acb_NtkGiaDeriveMiter( Gia_Man_t * pOne, Gia_Man_t * pTwo, int Type { int pLitsF[2] = { (int)Gia_ManCo(pOne, i)->Value, (int)Gia_ManCo(pOne, i+1)->Value }; int pLitsS[2] = { (int)Gia_ManCo(pTwo, i)->Value, (int)Gia_ManCo(pTwo, i+1)->Value }; - Gia_ManAppendCo( pNew, Gia_ManDualCompare( pNew, pLitsF, pLitsS ) ); + Gia_ManAppendCo( pNew, Gia_ManDualCompare( pNew, (unsigned int *)pLitsF, (unsigned int *)pLitsS ) ); } } Gia_ManHashStop( pNew ); @@ -458,7 +458,7 @@ Gia_Man_t * Acb_NtkGiaDeriveMiter( Gia_Man_t * pOne, Gia_Man_t * pTwo, int Type Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -475,7 +475,7 @@ void Acb_OutputFile( char * pFileName, Acb_Ntk_t * pNtkF, int * pModel ) } if ( pModel == NULL ) fprintf( pFile, "EQ\n" ); - else + else { /* NEQ @@ -521,7 +521,7 @@ int * Acb_NtkSolve( Gia_Man_t * p ) Synopsis [Various statistics.] Description [] - + SideEffects [] SeeAlso [] @@ -549,7 +549,7 @@ void Acb_NtkPrintCecStats( Acb_Ntk_t * pNtk ) Synopsis [Changing the PI order.] Description [] - + SideEffects [] SeeAlso [] @@ -601,7 +601,7 @@ int Acb_NtkCheckPiOrder( Acb_Ntk_t * pNtkF, Acb_Ntk_t * pNtkG ) Synopsis [] Description [] - + SideEffects [] SeeAlso [] @@ -621,7 +621,7 @@ void Acb_NtkRunTest( char * pFileNames[4], int fFancy, int fVerbose ) Acb_Ntk_t * pNtkG = Acb_VerilogSimpleRead( pFileNames[1], NULL ); if ( !pNtkF || !pNtkG ) return; - + assert( Acb_NtkCiNum(pNtkF) == Acb_NtkCiNum(pNtkG) ); assert( Acb_NtkCoNum(pNtkF) == Acb_NtkCoNum(pNtkG) ); diff --git a/src/base/main/abcapis.h b/src/base/main/abcapis.h index 5c6bc66bac..3b759dee6c 100644 --- a/src/base/main/abcapis.h +++ b/src/base/main/abcapis.h @@ -9,7 +9,7 @@ Synopsis [External declarations.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - September 29, 2012.] @@ -17,7 +17,7 @@ Revision [$Id: abcapis.h,v 1.00 2012/09/29 00:00:00 alanmi Exp $] ***********************************************************************/ - + #ifndef MINI_AIG__abc_apis_h #define MINI_AIG__abc_apis_h @@ -51,72 +51,75 @@ typedef struct Abc_Frame_t_ Abc_Frame_t; #endif #else /* defined(WIN32) */ #define ABC_DLLIMPORT +#define ABC_DLLEXPORT __attribute__((visibility("default"))) #endif /* defined(WIN32) */ #ifndef ABC_DLL -#define ABC_DLL ABC_DLLIMPORT + #ifdef ABC_NAMESPACE + #define ABC_DLL ABC_DLLEXPORT + #else + #define ABC_DLL ABC_DLLIMPORT + #endif #endif -#pragma GCC visibility push(default) //////////////////////////////////////////////////////////////////////// /// FUNCTION DECLARATIONS /// //////////////////////////////////////////////////////////////////////// // procedures to start and stop the ABC framework -extern ABC_DLL void Abc_Start(); -extern ABC_DLL void Abc_Stop(); +ABC_DLL extern void Abc_Start(); +ABC_DLL extern void Abc_Stop(); // procedures to get the ABC framework (pAbc) and execute commands in it -extern ABC_DLL Abc_Frame_t * Abc_FrameGetGlobalFrame(); -extern ABC_DLL int Cmd_CommandExecute( Abc_Frame_t * pAbc, const char * pCommandLine ); +ABC_DLL extern Abc_Frame_t * Abc_FrameGetGlobalFrame(); +ABC_DLL extern int Cmd_CommandExecute( Abc_Frame_t * pAbc, const char * pCommandLine ); // procedures to input/output 'mini AIG' -extern ABC_DLL void Abc_NtkInputMiniAig( Abc_Frame_t * pAbc, void * pMiniAig ); -extern ABC_DLL void * Abc_NtkOutputMiniAig( Abc_Frame_t * pAbc ); -extern ABC_DLL void Abc_FrameGiaInputMiniAig( Abc_Frame_t * pAbc, void * p ); -extern ABC_DLL void * Abc_FrameGiaOutputMiniAig( Abc_Frame_t * pAbc ); -extern ABC_DLL void Abc_NtkSetFlopNum( Abc_Frame_t * pAbc, int nFlops ); +ABC_DLL extern void Abc_NtkInputMiniAig( Abc_Frame_t * pAbc, void * pMiniAig ); +ABC_DLL extern void * Abc_NtkOutputMiniAig( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_FrameGiaInputMiniAig( Abc_Frame_t * pAbc, void * p ); +ABC_DLL extern void * Abc_FrameGiaOutputMiniAig( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_NtkSetFlopNum( Abc_Frame_t * pAbc, int nFlops ); // procedures to input/output 'mini LUT' -extern ABC_DLL void Abc_FrameGiaInputMiniLut( Abc_Frame_t * pAbc, void * pMiniLut ); -extern ABC_DLL void Abc_FrameGiaInputMiniLut2( Abc_Frame_t * pAbc, void * pMiniLut ); -extern ABC_DLL void * Abc_FrameGiaOutputMiniLut( Abc_Frame_t * pAbc ); -extern ABC_DLL char * Abc_FrameGiaOutputMiniLutAttr( Abc_Frame_t * pAbc, void * pMiniLut ); -extern ABC_DLL int * Abc_FrameGiaOutputMiniLutObj( Abc_Frame_t * pAbc ); -extern ABC_DLL void Abc_FrameSetObjDelays( Abc_Frame_t * pAbc, int * pDelays, int nDelays ); -extern ABC_DLL int * Abc_FrameReadMiniLutSwitching( Abc_Frame_t * pAbc ); -extern ABC_DLL int * Abc_FrameReadMiniLutSwitching2( Abc_Frame_t * pAbc, int nRandPiFactor ); -extern ABC_DLL int * Abc_FrameReadMiniLutSwitchingPo( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_FrameGiaInputMiniLut( Abc_Frame_t * pAbc, void * pMiniLut ); +ABC_DLL extern void Abc_FrameGiaInputMiniLut2( Abc_Frame_t * pAbc, void * pMiniLut ); +ABC_DLL extern void * Abc_FrameGiaOutputMiniLut( Abc_Frame_t * pAbc ); +ABC_DLL extern char * Abc_FrameGiaOutputMiniLutAttr( Abc_Frame_t * pAbc, void * pMiniLut ); +ABC_DLL extern int * Abc_FrameGiaOutputMiniLutObj( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_FrameSetObjDelays( Abc_Frame_t * pAbc, int * pDelays, int nDelays ); +ABC_DLL extern int * Abc_FrameReadMiniLutSwitching( Abc_Frame_t * pAbc ); +ABC_DLL extern int * Abc_FrameReadMiniLutSwitching2( Abc_Frame_t * pAbc, int nRandPiFactor ); +ABC_DLL extern int * Abc_FrameReadMiniLutSwitchingPo( Abc_Frame_t * pAbc ); // procedures to input/output NDR data-structure -extern ABC_DLL void Abc_FrameInputNdr( Abc_Frame_t * pAbc, void * pData ); -extern ABC_DLL void * Abc_FrameOutputNdr( Abc_Frame_t * pAbc ); -extern ABC_DLL int * Abc_FrameOutputNdrArray( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_FrameInputNdr( Abc_Frame_t * pAbc, void * pData ); +ABC_DLL extern void * Abc_FrameOutputNdr( Abc_Frame_t * pAbc ); +ABC_DLL extern int * Abc_FrameOutputNdrArray( Abc_Frame_t * pAbc ); // procedures to set CI/CO arrival/required times -extern ABC_DLL void Abc_NtkSetCiArrivalTime( Abc_Frame_t * pAbc, int iCi, float Rise, float Fall ); -extern ABC_DLL void Abc_NtkSetCoRequiredTime( Abc_Frame_t * pAbc, int iCo, float Rise, float Fall ); +ABC_DLL extern void Abc_NtkSetCiArrivalTime( Abc_Frame_t * pAbc, int iCi, float Rise, float Fall ); +ABC_DLL extern void Abc_NtkSetCoRequiredTime( Abc_Frame_t * pAbc, int iCo, float Rise, float Fall ); // procedure to set AND-gate delay to tech-independent synthesis and mapping -extern ABC_DLL void Abc_NtkSetAndGateDelay( Abc_Frame_t * pAbc, float Delay ); +ABC_DLL extern void Abc_NtkSetAndGateDelay( Abc_Frame_t * pAbc, float Delay ); // procedures to return the mapped network -extern ABC_DLL int * Abc_NtkOutputMiniMapping( Abc_Frame_t * pAbc ); -extern ABC_DLL void Abc_NtkPrintMiniMapping( int * pArray ); -extern ABC_DLL int * Abc_FrameReadArrayMapping( Abc_Frame_t * pAbc ); -extern ABC_DLL int * Abc_FrameReadBoxes( Abc_Frame_t * pAbc ); +ABC_DLL extern int * Abc_NtkOutputMiniMapping( Abc_Frame_t * pAbc ); +ABC_DLL extern void Abc_NtkPrintMiniMapping( int * pArray ); +ABC_DLL extern int * Abc_FrameReadArrayMapping( Abc_Frame_t * pAbc ); +ABC_DLL extern int * Abc_FrameReadBoxes( Abc_Frame_t * pAbc ); // procedures to access verifization status and a counter-example -extern ABC_DLL int Abc_FrameReadProbStatus( Abc_Frame_t * pAbc ); -extern ABC_DLL void * Abc_FrameReadCex( Abc_Frame_t * pAbc ); +ABC_DLL extern int Abc_FrameReadProbStatus( Abc_Frame_t * pAbc ); +ABC_DLL extern void * Abc_FrameReadCex( Abc_Frame_t * pAbc ); // procedure to set retiming data -extern ABC_DLL void Abc_FrameSetRetimingData( Abc_Frame_t * pAbc, int * pRst, int * pSet, int * pEna, int nRegs ); +ABC_DLL extern void Abc_FrameSetRetimingData( Abc_Frame_t * pAbc, int * pRst, int * pSet, int * pEna, int nRegs ); // procedure to return sequential equivalences -extern ABC_DLL int * Abc_FrameReadMiniAigEquivClasses( Abc_Frame_t * pAbc ); +ABC_DLL extern int * Abc_FrameReadMiniAigEquivClasses( Abc_Frame_t * pAbc ); -#pragma GCC visibility pop ABC_NAMESPACE_HEADER_END #endif diff --git a/src/base/main/main.c b/src/base/main/main.c index f440aa33be..6cec4aba3e 100644 --- a/src/base/main/main.c +++ b/src/base/main/main.c @@ -2,7 +2,7 @@ ABC_NAMESPACE_IMPL_START -extern ABC_DLL int Abc_RealMain(int argc, char *argv[]); +extern int Abc_RealMain(int argc, char *argv[]); ABC_NAMESPACE_IMPL_END diff --git a/src/base/main/main.h b/src/base/main/main.h index f3457e27f6..f95a475fcf 100644 --- a/src/base/main/main.h +++ b/src/base/main/main.h @@ -9,7 +9,7 @@ Synopsis [External declarations of the main package.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -67,106 +67,106 @@ ABC_NAMESPACE_HEADER_START //////////////////////////////////////////////////////////////////////// /*=== main.c ===========================================================*/ -extern ABC_DLL void Abc_Start(); -extern ABC_DLL void Abc_Stop(); +ABC_DLL extern void Abc_Start(); +ABC_DLL extern void Abc_Stop(); /*=== mainFrame.c ===========================================================*/ -extern ABC_DLL Abc_Ntk_t * Abc_FrameReadNtk( Abc_Frame_t * p ); -extern ABC_DLL Gia_Man_t * Abc_FrameReadGia( Abc_Frame_t * p ); -extern ABC_DLL FILE * Abc_FrameReadOut( Abc_Frame_t * p ); -extern ABC_DLL FILE * Abc_FrameReadErr( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameReadMode( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameSetMode( Abc_Frame_t * p, int fNameMode ); -extern ABC_DLL void Abc_FrameRestart( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameShowProgress( Abc_Frame_t * p ); -extern ABC_DLL void Abc_FrameClearVerifStatus( Abc_Frame_t * p ); -extern ABC_DLL void Abc_FrameUpdateGia( Abc_Frame_t * p, Gia_Man_t * pNew ); -extern ABC_DLL Gia_Man_t * Abc_FrameGetGia( Abc_Frame_t * p ); - -extern ABC_DLL void Abc_FrameSetCurrentNetwork( Abc_Frame_t * p, Abc_Ntk_t * pNet ); -extern ABC_DLL void Abc_FrameSwapCurrentAndBackup( Abc_Frame_t * p ); -extern ABC_DLL void Abc_FrameReplaceCurrentNetwork( Abc_Frame_t * p, Abc_Ntk_t * pNet ); -extern ABC_DLL void Abc_FrameUnmapAllNetworks( Abc_Frame_t * p ); -extern ABC_DLL void Abc_FrameDeleteAllNetworks( Abc_Frame_t * p ); - -extern ABC_DLL void Abc_FrameSetGlobalFrame( Abc_Frame_t * p ); -extern ABC_DLL Abc_Frame_t * Abc_FrameGetGlobalFrame(); -extern ABC_DLL Abc_Frame_t * Abc_FrameReadGlobalFrame(); - -extern ABC_DLL Vec_Ptr_t * Abc_FrameReadStore(); -extern ABC_DLL int Abc_FrameReadStoreSize(); -extern ABC_DLL void * Abc_FrameReadLibLut(); -extern ABC_DLL void * Abc_FrameReadLibBox(); -extern ABC_DLL void * Abc_FrameReadLibGen(); -extern ABC_DLL void * Abc_FrameReadLibGen2(); -extern ABC_DLL void * Abc_FrameReadLibSuper(); -extern ABC_DLL void * Abc_FrameReadLibScl(); -extern ABC_DLL void * Abc_FrameReadManDd(); -extern ABC_DLL void * Abc_FrameReadManDec(); -extern ABC_DLL void * Abc_FrameReadManDsd(); -extern ABC_DLL void * Abc_FrameReadManDsd2(); -extern ABC_DLL Vec_Ptr_t * Abc_FrameReadSignalNames(); -extern ABC_DLL char * Abc_FrameReadSpecName(); - -extern ABC_DLL char * Abc_FrameReadFlag( char * pFlag ); -extern ABC_DLL int Abc_FrameIsFlagEnabled( char * pFlag ); -extern ABC_DLL int Abc_FrameIsBatchMode(); -extern ABC_DLL void Abc_FrameSetBatchMode( int Mode ); -extern ABC_DLL int Abc_FrameIsBridgeMode(); -extern ABC_DLL void Abc_FrameSetBridgeMode(); - -extern ABC_DLL int Abc_FrameReadBmcFrames( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameReadProbStatus( Abc_Frame_t * p ); -extern ABC_DLL void * Abc_FrameReadCex( Abc_Frame_t * p ); -extern ABC_DLL Vec_Ptr_t * Abc_FrameReadCexVec( Abc_Frame_t * p ); -extern ABC_DLL Vec_Int_t * Abc_FrameReadStatusVec( Abc_Frame_t * p ); -extern ABC_DLL Vec_Ptr_t * Abc_FrameReadPoEquivs( Abc_Frame_t * p ); -extern ABC_DLL Vec_Int_t * Abc_FrameReadPoStatuses( Abc_Frame_t * p ); -extern ABC_DLL Vec_Int_t * Abc_FrameReadObjIds( Abc_Frame_t * p ); -extern ABC_DLL Abc_Nam_t * Abc_FrameReadJsonStrs( Abc_Frame_t * p ); -extern ABC_DLL Vec_Wec_t * Abc_FrameReadJsonObjs( Abc_Frame_t * p ); - -extern ABC_DLL int Abc_FrameReadCexPiNum( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameReadCexRegNum( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameReadCexPo( Abc_Frame_t * p ); -extern ABC_DLL int Abc_FrameReadCexFrame( Abc_Frame_t * p ); - -extern ABC_DLL void Abc_FrameSetNtkStore( Abc_Ntk_t * pNtk ); -extern ABC_DLL void Abc_FrameSetNtkStoreSize( int nStored ); -extern ABC_DLL void Abc_FrameSetLibLut( void * pLib ); -extern ABC_DLL void Abc_FrameSetLibBox( void * pLib ); -extern ABC_DLL void Abc_FrameSetLibGen( void * pLib ); -extern ABC_DLL void Abc_FrameSetLibGen2( void * pLib ); -extern ABC_DLL void Abc_FrameSetLibSuper( void * pLib ); -extern ABC_DLL void Abc_FrameSetLibVer( void * pLib ); -extern ABC_DLL void Abc_FrameSetFlag( char * pFlag, char * pValue ); -extern ABC_DLL void Abc_FrameSetCex( Abc_Cex_t * pCex ); -extern ABC_DLL void Abc_FrameSetNFrames( int nFrames ); -extern ABC_DLL void Abc_FrameSetStatus( int Status ); -extern ABC_DLL void Abc_FrameSetManDsd( void * pMan ); -extern ABC_DLL void Abc_FrameSetManDsd2( void * pMan ); -extern ABC_DLL void Abc_FrameSetInv( Vec_Int_t * vInv ); -extern ABC_DLL void Abc_FrameSetCnf( Vec_Int_t * vInv ); -extern ABC_DLL void Abc_FrameSetStr( Vec_Str_t * vInv ); -extern ABC_DLL void Abc_FrameSetJsonStrs( Abc_Nam_t * pStrs ); -extern ABC_DLL void Abc_FrameSetJsonObjs( Vec_Wec_t * vObjs ); -extern ABC_DLL void Abc_FrameSetSignalNames( Vec_Ptr_t * vNames ); -extern ABC_DLL void Abc_FrameSetSpecName( char * pFileName ); - -extern ABC_DLL int Abc_FrameCheckPoConst( Abc_Frame_t * p, int iPoNum ); - -extern ABC_DLL void Abc_FrameReplaceCex( Abc_Frame_t * pAbc, Abc_Cex_t ** ppCex ); -extern ABC_DLL void Abc_FrameReplaceCexVec( Abc_Frame_t * pAbc, Vec_Ptr_t ** pvCexVec ); -extern ABC_DLL void Abc_FrameReplacePoEquivs( Abc_Frame_t * pAbc, Vec_Ptr_t ** pvPoEquivs ); -extern ABC_DLL void Abc_FrameReplacePoStatuses( Abc_Frame_t * pAbc, Vec_Int_t ** pvStatuses ); - -extern ABC_DLL char * Abc_FrameReadDrivingCell(); -extern ABC_DLL float Abc_FrameReadMaxLoad(); -extern ABC_DLL void Abc_FrameSetDrivingCell( char * pName ); -extern ABC_DLL void Abc_FrameSetMaxLoad( float Load ); - -extern ABC_DLL void Abc_FrameSetArrayMapping( int * p ); -extern ABC_DLL void Abc_FrameSetBoxes( int * p ); +ABC_DLL extern Abc_Ntk_t * Abc_FrameReadNtk( Abc_Frame_t * p ); +ABC_DLL extern Gia_Man_t * Abc_FrameReadGia( Abc_Frame_t * p ); +ABC_DLL extern FILE * Abc_FrameReadOut( Abc_Frame_t * p ); +ABC_DLL extern FILE * Abc_FrameReadErr( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameReadMode( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameSetMode( Abc_Frame_t * p, int fNameMode ); +ABC_DLL extern void Abc_FrameRestart( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameShowProgress( Abc_Frame_t * p ); +ABC_DLL extern void Abc_FrameClearVerifStatus( Abc_Frame_t * p ); +ABC_DLL extern void Abc_FrameUpdateGia( Abc_Frame_t * p, Gia_Man_t * pNew ); +ABC_DLL extern Gia_Man_t * Abc_FrameGetGia( Abc_Frame_t * p ); + +ABC_DLL extern void Abc_FrameSetCurrentNetwork( Abc_Frame_t * p, Abc_Ntk_t * pNet ); +ABC_DLL extern void Abc_FrameSwapCurrentAndBackup( Abc_Frame_t * p ); +ABC_DLL extern void Abc_FrameReplaceCurrentNetwork( Abc_Frame_t * p, Abc_Ntk_t * pNet ); +ABC_DLL extern void Abc_FrameUnmapAllNetworks( Abc_Frame_t * p ); +ABC_DLL extern void Abc_FrameDeleteAllNetworks( Abc_Frame_t * p ); + +ABC_DLL extern void Abc_FrameSetGlobalFrame( Abc_Frame_t * p ); +ABC_DLL extern Abc_Frame_t * Abc_FrameGetGlobalFrame(); +ABC_DLL extern Abc_Frame_t * Abc_FrameReadGlobalFrame(); + +ABC_DLL extern Vec_Ptr_t * Abc_FrameReadStore(); +ABC_DLL extern int Abc_FrameReadStoreSize(); +ABC_DLL extern void * Abc_FrameReadLibLut(); +ABC_DLL extern void * Abc_FrameReadLibBox(); +ABC_DLL extern void * Abc_FrameReadLibGen(); +ABC_DLL extern void * Abc_FrameReadLibGen2(); +ABC_DLL extern void * Abc_FrameReadLibSuper(); +ABC_DLL extern void * Abc_FrameReadLibScl(); +ABC_DLL extern void * Abc_FrameReadManDd(); +ABC_DLL extern void * Abc_FrameReadManDec(); +ABC_DLL extern void * Abc_FrameReadManDsd(); +ABC_DLL extern void * Abc_FrameReadManDsd2(); +ABC_DLL extern Vec_Ptr_t * Abc_FrameReadSignalNames(); +ABC_DLL extern char * Abc_FrameReadSpecName(); + +ABC_DLL extern char * Abc_FrameReadFlag( char * pFlag ); +ABC_DLL extern int Abc_FrameIsFlagEnabled( char * pFlag ); +ABC_DLL extern int Abc_FrameIsBatchMode(); +ABC_DLL extern void Abc_FrameSetBatchMode( int Mode ); +ABC_DLL extern int Abc_FrameIsBridgeMode(); +ABC_DLL extern void Abc_FrameSetBridgeMode(); + +ABC_DLL extern int Abc_FrameReadBmcFrames( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameReadProbStatus( Abc_Frame_t * p ); +ABC_DLL extern void * Abc_FrameReadCex( Abc_Frame_t * p ); +ABC_DLL extern Vec_Ptr_t * Abc_FrameReadCexVec( Abc_Frame_t * p ); +ABC_DLL extern Vec_Int_t * Abc_FrameReadStatusVec( Abc_Frame_t * p ); +ABC_DLL extern Vec_Ptr_t * Abc_FrameReadPoEquivs( Abc_Frame_t * p ); +ABC_DLL extern Vec_Int_t * Abc_FrameReadPoStatuses( Abc_Frame_t * p ); +ABC_DLL extern Vec_Int_t * Abc_FrameReadObjIds( Abc_Frame_t * p ); +ABC_DLL extern Abc_Nam_t * Abc_FrameReadJsonStrs( Abc_Frame_t * p ); +ABC_DLL extern Vec_Wec_t * Abc_FrameReadJsonObjs( Abc_Frame_t * p ); + +ABC_DLL extern int Abc_FrameReadCexPiNum( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameReadCexRegNum( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameReadCexPo( Abc_Frame_t * p ); +ABC_DLL extern int Abc_FrameReadCexFrame( Abc_Frame_t * p ); + +ABC_DLL extern void Abc_FrameSetNtkStore( Abc_Ntk_t * pNtk ); +ABC_DLL extern void Abc_FrameSetNtkStoreSize( int nStored ); +ABC_DLL extern void Abc_FrameSetLibLut( void * pLib ); +ABC_DLL extern void Abc_FrameSetLibBox( void * pLib ); +ABC_DLL extern void Abc_FrameSetLibGen( void * pLib ); +ABC_DLL extern void Abc_FrameSetLibGen2( void * pLib ); +ABC_DLL extern void Abc_FrameSetLibSuper( void * pLib ); +ABC_DLL extern void Abc_FrameSetLibVer( void * pLib ); +ABC_DLL extern void Abc_FrameSetFlag( char * pFlag, char * pValue ); +ABC_DLL extern void Abc_FrameSetCex( Abc_Cex_t * pCex ); +ABC_DLL extern void Abc_FrameSetNFrames( int nFrames ); +ABC_DLL extern void Abc_FrameSetStatus( int Status ); +ABC_DLL extern void Abc_FrameSetManDsd( void * pMan ); +ABC_DLL extern void Abc_FrameSetManDsd2( void * pMan ); +ABC_DLL extern void Abc_FrameSetInv( Vec_Int_t * vInv ); +ABC_DLL extern void Abc_FrameSetCnf( Vec_Int_t * vInv ); +ABC_DLL extern void Abc_FrameSetStr( Vec_Str_t * vInv ); +ABC_DLL extern void Abc_FrameSetJsonStrs( Abc_Nam_t * pStrs ); +ABC_DLL extern void Abc_FrameSetJsonObjs( Vec_Wec_t * vObjs ); +ABC_DLL extern void Abc_FrameSetSignalNames( Vec_Ptr_t * vNames ); +ABC_DLL extern void Abc_FrameSetSpecName( char * pFileName ); + +ABC_DLL extern int Abc_FrameCheckPoConst( Abc_Frame_t * p, int iPoNum ); + +ABC_DLL extern void Abc_FrameReplaceCex( Abc_Frame_t * pAbc, Abc_Cex_t ** ppCex ); +ABC_DLL extern void Abc_FrameReplaceCexVec( Abc_Frame_t * pAbc, Vec_Ptr_t ** pvCexVec ); +ABC_DLL extern void Abc_FrameReplacePoEquivs( Abc_Frame_t * pAbc, Vec_Ptr_t ** pvPoEquivs ); +ABC_DLL extern void Abc_FrameReplacePoStatuses( Abc_Frame_t * pAbc, Vec_Int_t ** pvStatuses ); + +ABC_DLL extern char * Abc_FrameReadDrivingCell(); +ABC_DLL extern float Abc_FrameReadMaxLoad(); +ABC_DLL extern void Abc_FrameSetDrivingCell( char * pName ); +ABC_DLL extern void Abc_FrameSetMaxLoad( float Load ); + +ABC_DLL extern void Abc_FrameSetArrayMapping( int * p ); +ABC_DLL extern void Abc_FrameSetBoxes( int * p ); ABC_NAMESPACE_HEADER_END diff --git a/src/base/main/mainLib.c b/src/base/main/mainLib.c index 5af63d79db..79c9abbc1b 100644 --- a/src/base/main/mainLib.c +++ b/src/base/main/mainLib.c @@ -9,7 +9,7 @@ Synopsis [Here everything starts.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -27,7 +27,7 @@ ABC_NAMESPACE_IMPL_START //////////////////////////////////////////////////////////////////////// /// DECLARATIONS /// //////////////////////////////////////////////////////////////////////// - + //////////////////////////////////////////////////////////////////////// /// FUNCTION DEFINITIONS /// //////////////////////////////////////////////////////////////////////// @@ -37,23 +37,23 @@ ABC_NAMESPACE_IMPL_START Synopsis [Initialization procedure for the library project.] Description [Note that when Abc_Start() is run in a static library - project, it does not load the resource file by default. As a result, - ABC is not set up the same way, as when it is run on a command line. - For example, some error messages while parsing files will not be - produced, and intermediate networks will not be checked for consistancy. + project, it does not load the resource file by default. As a result, + ABC is not set up the same way, as when it is run on a command line. + For example, some error messages while parsing files will not be + produced, and intermediate networks will not be checked for consistancy. One possibility is to load the resource file after Abc_Start() as follows: Abc_UtilsSource( Abc_FrameGetGlobalFrame() );] - + SideEffects [] SeeAlso [] ***********************************************************************/ -void Abc_Start() +ABC_DLL void Abc_Start() { Abc_Frame_t * pAbc; // added to detect memory leaks: -#if defined(_DEBUG) && defined(_MSC_VER) +#if defined(_DEBUG) && defined(_MSC_VER) _CrtSetDbgFlag( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF ); #endif // start the glocal frame @@ -67,13 +67,13 @@ void Abc_Start() Synopsis [Deallocation procedure for the library project.] Description [] - + SideEffects [] SeeAlso [] ***********************************************************************/ -void Abc_Stop() +ABC_DLL void Abc_Stop() { Abc_Frame_t * pAbc; pAbc = Abc_FrameGetGlobalFrame(); diff --git a/src/base/main/mainReal.c b/src/base/main/mainReal.c index 51c82ffe0d..0e9e46e676 100644 --- a/src/base/main/mainReal.c +++ b/src/base/main/mainReal.c @@ -35,7 +35,7 @@ SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. Synopsis [Here everything starts.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -45,12 +45,12 @@ SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. ***********************************************************************/ #ifndef WIN32 -#include -#include +#include +#include #include -#include +#include #if !defined(__wasm) -#include +#include #endif #include #endif @@ -59,7 +59,6 @@ SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. #include "mainInt.h" #include "base/wlc/wlc.h" -#pragma GCC visibility push(default) ABC_NAMESPACE_IMPL_START //////////////////////////////////////////////////////////////////////// @@ -67,25 +66,26 @@ ABC_NAMESPACE_IMPL_START //////////////////////////////////////////////////////////////////////// static int TypeCheck( Abc_Frame_t * pAbc, const char * s); +ABC_DLL extern int Abc_RealMain(int argc, char *argv[]); //////////////////////////////////////////////////////////////////////// /// FUNCTION DEFINITIONS /// //////////////////////////////////////////////////////////////////////// -unsigned enable_dbg_outs = 1; +unsigned enable_dbg_outs = 1; /**Function************************************************************* Synopsis [The main() procedure.] Description [] - + SideEffects [] SeeAlso [] ***********************************************************************/ -ABC_DLL int Abc_RealMain( int argc, char * argv[] ) +extern int Abc_RealMain( int argc, char * argv[] ) { Abc_Frame_t * pAbc; Vec_Str_t* sCommandUsr = Vec_StrAlloc(1000); @@ -129,34 +129,34 @@ ABC_DLL int Abc_RealMain( int argc, char * argv[] ) while ((c = Extra_UtilGetopt(argc, argv, "dm:l:c:q:C:Q:S:hf:F:o:st:T:xb")) != EOF) { switch(c) { - case 'd': - enable_dbg_outs ^= 1; - break; + case 'd': + enable_dbg_outs ^= 1; + break; case 'm': { #if !defined(WIN32) && !defined(ABC_NO_RLIMIT) - int maxMb = atoi(globalUtilOptarg); + int maxMb = atoi(globalUtilOptarg); printf("Limiting memory use to %d MB\n", maxMb); - struct rlimit limit = { - maxMb * (1llu << 20), /* soft limit */ - maxMb * (1llu << 20) /* hard limit */ - }; - setrlimit(RLIMIT_AS, &limit); + struct rlimit limit = { + maxMb * (1llu << 20), /* soft limit */ + maxMb * (1llu << 20) /* hard limit */ + }; + setrlimit(RLIMIT_AS, &limit); #endif - break; - } + break; + } case 'l': { #if !defined(WIN32) && !defined(ABC_NO_RLIMIT) - rlim_t maxTime = atoi(globalUtilOptarg); + rlim_t maxTime = atoi(globalUtilOptarg); printf("Limiting time to %d seconds\n", (int)maxTime); - struct rlimit limit = { - maxTime, /* soft limit */ - maxTime /* hard limit */ - }; - setrlimit(RLIMIT_CPU, &limit); + struct rlimit limit = { + maxTime, /* soft limit */ + maxTime /* hard limit */ + }; + setrlimit(RLIMIT_CPU, &limit); #endif - break; - } + break; + } case 'c': if( Vec_StrSize(sCommandUsr) > 0 ) { @@ -377,7 +377,7 @@ ABC_DLL int Abc_RealMain( int argc, char * argv[] ) } // if the memory should be freed, quit packages -// if ( fStatus < 0 ) +// if ( fStatus < 0 ) { Abc_Stop(); } @@ -393,7 +393,7 @@ ABC_DLL int Abc_RealMain( int argc, char * argv[] ) Synopsis [Returns 1 if s is a file type recognized, else returns 0.] - Description [Returns 1 if s is a file type recognized by ABC, else returns 0. + Description [Returns 1 if s is a file type recognized by ABC, else returns 0. Recognized types are "blif", "bench", "pla", and "none".] SideEffects [] @@ -422,5 +422,5 @@ static int TypeCheck( Abc_Frame_t * pAbc, const char * s ) /// END OF FILE /// //////////////////////////////////////////////////////////////////////// + ABC_NAMESPACE_IMPL_END -#pragma GCC visibility pop diff --git a/src/demo.c b/src/demo.c index e6616d4b71..c6284f764f 100644 --- a/src/demo.c +++ b/src/demo.c @@ -9,7 +9,7 @@ Synopsis [A demo program illustrating the use of ABC as a static library.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -59,12 +59,12 @@ using namespace ABC_NAMESPACE; Synopsis [The main() procedure.] - Description [This procedure compiles into a stand-alone program for + Description [This procedure compiles into a stand-alone program for DAG-aware rewriting of the AIGs. A BLIF or PLA file to be considered - for rewriting should be given as a command-line argument. Implementation - of the rewriting is inspired by the paper: Per Bjesse, Arne Boralv, + for rewriting should be given as a command-line argument. Implementation + of the rewriting is inspired by the paper: Per Bjesse, Arne Boralv, "DAG-aware circuit compression for formal verification", Proc. ICCAD 2004.] - + SideEffects [] SeeAlso [] diff --git a/src/misc/util/abc_global.h b/src/misc/util/abc_global.h index b666fca01e..81982e685d 100644 --- a/src/misc/util/abc_global.h +++ b/src/misc/util/abc_global.h @@ -9,7 +9,7 @@ Synopsis [Global declarations.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - Jan 30, 2009.] @@ -51,10 +51,15 @@ #endif #else /* defined(WIN32) */ #define ABC_DLLIMPORT +#define ABC_DLLEXPORT __attribute__((visibility("default"))) #endif /* defined(WIN32) */ #ifndef ABC_DLL -#define ABC_DLL ABC_DLLIMPORT + #ifdef ABC_NAMESPACE + #define ABC_DLL ABC_DLLEXPORT + #else + #define ABC_DLL ABC_DLLIMPORT + #endif #endif #if !defined(___unused) @@ -235,7 +240,7 @@ typedef unsigned __int64 ABC_UINT64_T; #endif /* defined(PLATFORM) */ #ifdef LIN - #define ABC_CONST(number) number ## ULL + #define ABC_CONST(number) number ## ULL #else // LIN64 and windows #define ABC_CONST(number) number #endif @@ -340,7 +345,7 @@ static inline abctime Abc_Clock() #endif #if (defined(LIN) || defined(LIN64)) && !APPLE_MACH && !defined(__MINGW32__) && !defined(__wasm) struct timespec ts; - if ( clock_gettime(CLOCK_MONOTONIC, &ts) < 0 ) + if ( clock_gettime(CLOCK_MONOTONIC, &ts) < 0 ) return (abctime)-1; abctime res = ((abctime) ts.tv_sec) * CLOCKS_PER_SEC; res += (((abctime) ts.tv_nsec) * CLOCKS_PER_SEC) / 1000000000; @@ -359,7 +364,7 @@ static inline abctime Abc_ThreadClock() #endif #if (defined(LIN) || defined(LIN64)) && !APPLE_MACH && !defined(__MINGW32__) && !defined(__wasm) struct timespec ts; - if ( clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts) < 0 ) + if ( clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts) < 0 ) return (abctime)-1; abctime res = ((abctime) ts.tv_sec) * CLOCKS_PER_SEC; res += (((abctime) ts.tv_nsec) * CLOCKS_PER_SEC) / 1000000000; @@ -396,7 +401,7 @@ static inline void Abc_Print( int level, const char * format, ... ) { extern ABC_DLL int Abc_FrameIsBridgeMode(); va_list args; - extern unsigned enable_dbg_outs; + extern unsigned enable_dbg_outs; if ( !enable_dbg_outs ) return; @@ -507,7 +512,7 @@ static inline int Abc_PrimeCudd( unsigned int p ) } while (!pn); return (int)(p); -} // end of Cudd_Prime +} // end of Cudd_Prime // the returned buffer has 32 unused bytes at the end, filled with zeros static inline void * Abc_FileReadContents( char * pFileName, int * pnFileSize ) diff --git a/tox.ini b/tox.ini index 1fb6dea74c..02203e8898 100644 --- a/tox.ini +++ b/tox.ini @@ -66,9 +66,9 @@ commands_pre = {base,libs,clang}: cmake -E make_directory {toxinidir}/build commands = - abc: make -j{env:CPUS} ABC_USE_PIC=1 {posargs} abc - abc: make -j{env:CPUS} {posargs} libabc.a - soname: make -j{env:CPUS} ABC_USE_PIC=1 ABC_USE_SONAME=1 {posargs} lib + abc: make ABC_USE_PIC=1 {posargs} abc + abc: make {posargs} libabc.a + soname: make ABC_USE_PIC=1 ABC_USE_SONAME=1 {posargs} lib tests: make test # demo requires CC, CXX set in environment or on cmd line # eg: CC=gcc CXX=g++ tox -e demo From ee5ce1460e95f5c5b0008ad11de9ce66ae4b23d5 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 24 Feb 2025 09:58:35 -0800 Subject: [PATCH 29/35] chg: dev: use static libs and local gtest in windows conda env gia_test cmd fails with exit code and no useful traceback:: FAILED: test/gia/gia_test.exe test/gia/gia_test[1]_tests.cmake D:/a/abc-fork/abc-fork/build/test/gia/gia_test[1]_tests.cmake C:\Windows\system32\cmd.exe /C "cd . && C:\mingw64\bin\c++.exe -g test/gia/CMakeFiles/gia_test.dir/gia_test.cc.obj -o test\gia\gia_test.exe -Wl,--out-implib,test\gia\libgia_test.dll.a -Wl,--major-image-version,0,--minor-image-version,0 libabc.dll.a lib/libgtest_main.dll.a -lm -lshlwapi lib/libgtest.dll.a -lkernel32 -luser32 -lgdi32 -lwinspool -lshell32 -lole32 -loleaut32 -luuid -lcomdlg32 -ladvapi32 && C:\Windows\system32\cmd.exe /C "cd /D D:\a\abc-fork\abc-fork\build\test\gia && C:\Miniconda\envs\abc-test\Library\bin\cmake.exe -D TEST_TARGET=gia_test -D TEST_EXECUTABLE=D:/a/abc-fork/abc-fork/build/test/gia/gia_test.exe -D TEST_EXECUTOR= -D TEST_WORKING_DIR=D:/a/abc-fork/abc-fork/build/test/gia -D TEST_EXTRA_ARGS= -D TEST_PROPERTIES= -D TEST_PREFIX= -D TEST_SUFFIX= -D TEST_FILTER= -D NO_PRETTY_TYPES=FALSE -D NO_PRETTY_VALUES=FALSE -D TEST_LIST=gia_test_TESTS -D CTEST_FILE=D:/a/abc-fork/abc-fork/build/test/gia/gia_test[1]_tests.cmake -D TEST_DISCOVERY_TIMEOUT=5 -D TEST_DISCOVERY_EXTRA_ARGS= -D TEST_XML_OUTPUT_DIR= -P C:/Miniconda/envs/abc-test/Library/share/cmake-3.31/Modules/GoogleTestAddTests.cmake"" CMake Error at C:/Miniconda/envs/abc-test/Library/share/cmake-3.31/Modules/GoogleTestAddTests.cmake:132 (message): Error running test executable. Path: 'D:/a/abc-fork/abc-fork/build/test/gia/gia_test.exe' Working directory: 'D:/a/abc-fork/abc-fork/build/test/gia' Result: Exit code 0xc0000135 Output: Call Stack (most recent call first): C:/Miniconda/envs/abc-test/Library/share/cmake-3.31/Modules/GoogleTestAddTests.cmake:275 (gtest_discover_tests_impl) ninja: build stopped: subcommand failed. --- .github/workflows/conda-dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 61be008329..92600166fb 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -34,7 +34,7 @@ jobs: - os: 'windows-2019' generator: 'Ninja' build_type: 'Debug' - extra_args: '-DBUILD_SHARED_LIBS=ON -DABC_USE_SONAME=ON -DABC_USE_NO_READLINE=ON -DVENDOR_GTEST=ON' + extra_args: '-DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_READLINE=ON -DVENDOR_GTEST=ON' env: OS: ${{ matrix.os }} PY_VER: ${{ matrix.python-version }} From fe0f64437ca4a76e3d3cae40427e294a01e6f4d4 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 24 Feb 2025 20:06:20 -0800 Subject: [PATCH 30/35] chg: dev: use C++ namespace for msys2 builds, workflow and tox cleanup * generate and add CMake for latest upstream module bits * cleanup platform includes Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 1 - .github/workflows/win.yml | 5 +- CMakeLists.txt | 5 +- src/opt/rar/CMakeLists.txt | 8 +++ src/sat/kissat/CMakeLists.txt | 95 +++++++++++++++++++++++++++++++++++ src/sat/kissat/colors.c | 2 +- tox.ini | 2 +- 7 files changed, 112 insertions(+), 6 deletions(-) create mode 100644 src/opt/rar/CMakeLists.txt create mode 100644 src/sat/kissat/CMakeLists.txt diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index af380c1918..09bbb6e75a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -134,7 +134,6 @@ jobs: brew install gcc@${{ matrix.version }} echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV - brew install googletest fi - name: Build and test MacOS diff --git a/.github/workflows/win.yml b/.github/workflows/win.yml index 51f847866c..ebb48746a7 100644 --- a/.github/workflows/win.yml +++ b/.github/workflows/win.yml @@ -44,8 +44,11 @@ jobs: cmake -Wdev -B build + -DABC_USE_NAMESPACE=xxxx -DBUILD_SHARED_LIBS=OFF - -DCMAKE_BUILD_TYPE=Debug + -DABC_USE_NO_READLINE=ON + -DVENDOR_GTEST=ON + -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_INSTALL_PREFIX=$PWD/_dist - name: CMake build diff --git a/CMakeLists.txt b/CMakeLists.txt index ef38be16cb..d656557fc5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -119,9 +119,10 @@ set(ABC_MODULES src/misc/vec src/misc/hash src/misc/tim src/misc/bzlib src/misc/zlib src/misc/mem src/misc/bar src/misc/bbl src/misc/parse src/opt/cut src/opt/fxu src/opt/fxch src/opt/rwr src/opt/mfs src/opt/sim - src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt + src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt src/opt/rar src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd - src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 + src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat + src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/sat/kissat src/bool/bdc src/bool/deco src/bool/dec src/bool/kit src/bool/lucky src/bool/rsb src/bool/rpo src/proof/pdr src/proof/abs src/proof/live src/proof/ssc src/proof/int diff --git a/src/opt/rar/CMakeLists.txt b/src/opt/rar/CMakeLists.txt new file mode 100644 index 0000000000..cd7a1f52a5 --- /dev/null +++ b/src/opt/rar/CMakeLists.txt @@ -0,0 +1,8 @@ +abc_libabc_add_sources( + NAME opt_rar + SOURCES + rewire_map.c + rewire_rar.c + rewire_rng.c + rewire_miaig.cpp +) diff --git a/src/sat/kissat/CMakeLists.txt b/src/sat/kissat/CMakeLists.txt new file mode 100644 index 0000000000..949bdcb105 --- /dev/null +++ b/src/sat/kissat/CMakeLists.txt @@ -0,0 +1,95 @@ +abc_libabc_add_sources( + NAME sat_kissat + SOURCES + gates.c + propinitially.c + format.c + flags.c + analyze.c + build.c + heap.c + learn.c + restart.c + backbone.c + warmup.c + report.c + forward.c + file.c + proprobe.c + error.c + transitive.c + minimize.c + walk.c + colors.c + strengthen.c + preprocess.c + eliminate.c + kitten.c + arena.c + backtrack.c + stack.c + definition.c + resolve.c + factor.c + extend.c + kimits.c + deduce.c + substitute.c + clause.c + kptions.c + allocate.c + import.c + dense.c + tiers.c + terminate.c + kissatTest.c + logging.c + reluctant.c + reduce.c + watch.c + probe.c + vector.c + vivify.c + print.c + proof.c + resize.c + propdense.c + fastel.c + kucky.c + bump.c + collect.c + assign.c + sweep.c + queue.c + weaken.c + reorder.c + propbeyond.c + decide.c + equivalences.c + kissatSolver.c + averages.c + rephase.c + profile.c + statistics.c + trail.c + dump.c + mode.c + internal.c + classify.c + search.c + shrink.c + phases.c + check.c + config.c + utilities.c + promote.c + sort.c + ifthenelse.c + krite.c + congruence.c + propsearch.c + resources.c + smooth.c + compact.c + ands.c +) diff --git a/src/sat/kissat/colors.c b/src/sat/kissat/colors.c index f45260b297..c6141b7491 100644 --- a/src/sat/kissat/colors.c +++ b/src/sat/kissat/colors.c @@ -1,6 +1,6 @@ #include "colors.h" -#ifdef WIN32 +#if defined(WIN32) && !defined(__MINGW32__) #define isatty _isatty #else #include diff --git a/tox.ini b/tox.ini index 02203e8898..7eef12b478 100644 --- a/tox.ini +++ b/tox.ini @@ -86,7 +86,7 @@ commands = clang: lcov_cobertura {toxinidir}/build/coverage/lcov.info --base-dir {toxinidir}/src --output coverage.xml {base,libs}: cmake --build . --target install {base,libs}: bash -c 'find $PREFIX/ -type f -name \*abc\* -o -name demo | xargs ls -lh' - ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V + ctest: ctest -j {env:CPUS} --build-generator {posargs:"Ninja"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DABC_USE_NAMESPACE={env:ABC_USE_NAMESPACE} -DABC_SKIP_EXE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V ctestwin: ctest --build-generator {posargs:"Visual Studio 16 2019"} --build-and-test . build --build-options -DVENDOR_GTEST=ON -DBUILD_SHARED_LIBS=ON -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DCMAKE_BUILD_TYPE={env:BUILD_TYPE} --test-command ctest -C {env:BUILD_TYPE} --rerun-failed --output-on-failure -V ctest: bash -c 'ls -lh build/*abc* || true' lint: bash -c 'cpplint --output=gsed {toxinidir}/src/base/main/* {toxinidir}/lib/*' From 7d532c74eb5812c65ca719c9764cc47b44a747d3 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Thu, 6 Mar 2025 19:15:53 -0800 Subject: [PATCH 31/35] fix: dev: cleanup llvm coverage in smoke workflow, sort out version path * give find_package a hint for finding the correct versioned LLVM dir * use LLVM_VER_DIR to set major llvm version path (mainly for CI) * set default in tox (github workflows get /usr/lib/ prepended) Signed-off-by: Stephen L Arnold --- .github/workflows/ci.yml | 12 ++++++----- cmake/coverage.cmake | 43 +++++++++++++++++++++------------------- tox.ini | 1 + 3 files changed, 31 insertions(+), 25 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 09bbb6e75a..2cce8f4eac 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: windows-2019-cl, ubuntu-22.04-gcc-10, ubuntu-24.04-gcc-13, - ubuntu-22.04-clang-14, + ubuntu-22.04-clang-15, macOS-13-gcc, macOS-13-clang, ] @@ -51,10 +51,10 @@ jobs: version: "13" toxcmd: libs - - name: ubuntu-22.04-clang-14 + - name: ubuntu-22.04-clang-15 os: ubuntu-22.04 compiler: clang - version: "14" + version: "15" toxcmd: clang - name: macOS-13-gcc @@ -100,9 +100,10 @@ jobs: echo "CC=gcc-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=g++-${{ matrix.version }}" >> $GITHUB_ENV else - sudo apt-get install -y clang-${{ matrix.version }} llvm-${{ matrix.version }} lld-${{ matrix.version }} g++-multilib + sudo apt-get install -y clang-${{ matrix.version }} clang++-${{ matrix.version }} llvm-${{ matrix.version }}-tools lld-${{ matrix.version }} echo "CC=clang-${{ matrix.version }}" >> $GITHUB_ENV echo "CXX=clang++-${{ matrix.version }}" >> $GITHUB_ENV + echo "LLVM_VER_DIR=/usr/lib/llvm-${{ matrix.version }}" >> $GITHUB_ENV fi - name: Build and test Linux @@ -110,12 +111,13 @@ jobs: env: CC: ${{ env.CC }} CXX: ${{ env.CXX }} + LLVM_VER_DIR: ${{ env.LLVM_VER_DIR }} PREFIX: ../staging run: | tox -e ${{ matrix.toxcmd }} - uses: actions/upload-artifact@v4 - if: matrix.name == 'ubuntu-22.04-clang-14' + if: matrix.name == 'ubuntu-22.04-clang-15' with: name: src_coverage_data path: | diff --git a/cmake/coverage.cmake b/cmake/coverage.cmake index eb2c5e42eb..7d433bbe08 100644 --- a/cmake/coverage.cmake +++ b/cmake/coverage.cmake @@ -1,9 +1,10 @@ -option(COVERAGE_TEXT "Show text summary of the coverage" OFF) +option(COVERAGE_TEXT "Show text summary of the coverage" ON) option(COVERAGE_LCOV "Export coverage data in lcov trace file" ON) -option(COVERAGE_HTML "Detailed html report of the coverage" ON) +option(COVERAGE_HTML "Detailed html report of the coverage" OFF) -set(COVERAGE_EXCLUDE_REGEX "(lib/)") +set(COVERAGE_EXCLUDE_REGEX "(test/|lib/)") set(COVERAGE_PATH ${PROJECT_BINARY_DIR}/coverage) +set(LLVM_DIRECTORY "$ENV{LLVM_VER_DIR}") if(COVERAGE_BUILD) message( @@ -11,20 +12,22 @@ if(COVERAGE_BUILD) "Source coverage is enabled. TEXT=${COVERAGE_TEXT}, LCOV=${COVERAGE_LCOV}, HTML=${COVERAGE_HTML}" ) - find_package(LLVM REQUIRED CONFIG) - get_filename_component(LLVM_PREFIX "${LLVM_DIR}" DIRECTORY) - message(STATUS "Found llvm directory: ${LLVM_PREFIX}") + find_package( + LLVM REQUIRED CONFIG + HINTS ${LLVM_DIRECTORY} + ) + message(STATUS "Using llvm directory: ${LLVM_DIRECTORY}") find_program( LLVM_COV_PATH NAMES llvm-cov - HINTS ${LLVM_PREFIX} + HINTS ${LLVM_DIRECTORY} PATH_SUFFIXES bin ) find_program( LLVM_PROFDATA_PATH NAMES llvm-profdata - HINTS ${LLVM_PREFIX} + HINTS ${LLVM_DIRECTORY} PATH_SUFFIXES bin ) @@ -74,6 +77,18 @@ function(add_coverage TARGET) add_custom_target(coverage) + if(COVERAGE_TEXT) + add_custom_target( + coverage-text + COMMAND + ${LLVM_COV_PATH} report `cat ${COVERAGE_TARGETS}` + -instr-profile=${COVERAGE_PROFDATA} + -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" + DEPENDS coverage-profdata + ) + add_dependencies(coverage coverage-text) + endif() + if(COVERAGE_HTML) add_custom_target( coverage-html @@ -100,18 +115,6 @@ function(add_coverage TARGET) ) add_dependencies(coverage coverage-lcov) endif() - - if(COVERAGE_TEXT) - add_custom_target( - coverage-text - COMMAND - ${LLVM_COV_PATH} report `cat ${COVERAGE_TARGETS}` - -instr-profile=${COVERAGE_PROFDATA} - -ignore-filename-regex="${COVERAGE_EXCLUDE_REGEX}" - DEPENDS coverage-profdata - ) - add_dependencies(coverage coverage-text) - endif() endif() add_custom_target( diff --git a/tox.ini b/tox.ini index 7eef12b478..a26f31b7de 100644 --- a/tox.ini +++ b/tox.ini @@ -13,6 +13,7 @@ setenv = {base,libs,clang,ctest}: ABC_USE_SONAME={env:ABC_USE_SONAME:ON} {base,libs,clang,ctest}: ABC_USE_PIC={env:ABC_USE_PIC:ON} {base,libs,clang,ctest}: VENDOR_GTEST={env:VENDOR_GTEST:OFF} + {base,libs,clang,ctest}: LLVM_VER_DIR = {env:LLVM_VER_DIR:llvm-15} {base,libs,clang}: BUILD_TYPE={env:BUILD_TYPE:Release} {ctest,ctestwin}: BUILD_TYPE={env:BUILD_TYPE:Debug} base: PREFIX={env:PREFIX:staging} From 3f3c3d2be52ed9c0afb137350c7b9f3c3a835375 Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Fri, 7 Mar 2025 17:16:57 -0800 Subject: [PATCH 32/35] fix: dev: prep msvc cl and github environment for conda on windows * disable pthreads when using msvc compiler * fix build errors on windows, including the following: missing symbols, non-const, designated initializers, and non-standard explicit type conversions * uncork sys/stat.h and add missing win32 define for S_ISDIR * add clang++ flag to get errors on c++20 initializers and set C99 std Signed-off-by: Stephen L Arnold --- .github/workflows/conda-dev.yml | 31 ++++++- CMakeLists.txt | 7 ++ Makefile | 1 + src/base/abc/abcHieNew.c | 152 ++++++++++++++++---------------- src/base/abci/abcNpn.c | 2 +- src/sat/kissat/bump.c | 2 +- src/sat/kissat/colors.c | 1 + src/sat/kissat/congruence.c | 18 ++-- src/sat/kissat/dense.c | 2 +- src/sat/kissat/file.c | 7 +- src/sat/kissat/kitten.c | 6 +- src/sat/kissat/proplit.h | 2 +- src/sat/kissat/sweep.c | 8 +- src/sat/kissat/walk.c | 2 +- src/sat/kissat/watch.c | 4 +- 15 files changed, 143 insertions(+), 102 deletions(-) diff --git a/.github/workflows/conda-dev.yml b/.github/workflows/conda-dev.yml index 92600166fb..f7523a1a59 100644 --- a/.github/workflows/conda-dev.yml +++ b/.github/workflows/conda-dev.yml @@ -34,7 +34,7 @@ jobs: - os: 'windows-2019' generator: 'Ninja' build_type: 'Debug' - extra_args: '-DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_READLINE=ON -DVENDOR_GTEST=ON' + extra_args: '-DBUILD_SHARED_LIBS=OFF -DABC_USE_NO_PTHREADS=ON -DABC_USE_NO_READLINE=ON -DVENDOR_GTEST=ON' env: OS: ${{ matrix.os }} PY_VER: ${{ matrix.python-version }} @@ -42,6 +42,21 @@ jobs: CMAKE_ARGS: ${{ matrix.use_namespace && '-DABC_USE_NAMESPACE=xxx' || '' }} steps: + #- if: matrix.os == 'windows-2019' + #name: Install newer windows compiler + #id: install_cc + #uses: rlalik/setup-cpp-compiler@master + #with: + #compiler: g++-11.2.0 + + #- if: matrix.os == 'windows-2019' + #name: Use compiler + #shell: bash -l {0} + #env: + #CC: ${{ steps.install_cc.outputs.cc }} + #CXX: ${{ steps.install_cc.outputs.cxx }} + #run: | + - uses: actions/checkout@v4 - name: Setup base python @@ -49,12 +64,24 @@ jobs: with: python-version: ${{ matrix.python-version }} + - name: Prepare build environment for windows + if: runner.os == 'Windows' + uses: ilammy/msvc-dev-cmd@v1 + with: + arch: x64 + + - name: Env (Windows) + if: runner.os == 'Windows' + run: | + echo "CXX=cl.exe" >> $GITHUB_ENV + echo "CC=cl.exe" >> $GITHUB_ENV + - name: Cache conda id: cache uses: actions/cache@v4 env: # Increase this value to reset cache if environment.devenv.yml has not changed - CACHE_NUMBER: 1 + CACHE_NUMBER: 2 with: path: ~/conda_pkgs_dir key: ${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{ hashFiles('environment.devenv.yml') }} diff --git a/CMakeLists.txt b/CMakeLists.txt index d656557fc5..46c16a9933 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -28,6 +28,8 @@ set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_EXTENSIONS OFF) +set(CMAKE_C_STANDARD 99) + # MSVC has symbols hidden by default. On GCC and Clang we need to explicitly # set the visibility to hidden to achieve the same result and then manually # expose what we need. This results in smaller abc dynamic library and thus @@ -167,6 +169,10 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" AND NOT (CMAKE_CXX_COMPILER_VERSION VERS target_compile_options(abc_interface INTERFACE -fno-aggressive-loop-optimizations -Wno-unused-but-set-variable ) +elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") + target_compile_options(abc_interface + INTERFACE -Werror=c99-designator + ) endif() if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") @@ -189,6 +195,7 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") "_MBCS" "_SCL_SECURE_NO_WARNINGS" "_CRT_SECURE_NO_WARNINGS" + "_CRT_INTERNAL_NONSTDC_NAMES" "_XKEYCHECK_H" "_ALLOW_KEYWORD_MACROS=1" ) diff --git a/Makefile b/Makefile index f75dc60a5c..7e090b7458 100644 --- a/Makefile +++ b/Makefile @@ -71,6 +71,7 @@ ifdef ABC_USE_NAMESPACE DLIBS := -lstdc++ $(info $(MSG_PREFIX)Compiling in namespace $(ABC_NAMESPACE)) else + CFLAGS += -std=gnu99 CXXFLAGS := $(CFLAGS) ABC_USE_LIBSTDCXX := 1 endif diff --git a/src/base/abc/abcHieNew.c b/src/base/abc/abcHieNew.c index 54a61609f8..87efef2b66 100644 --- a/src/base/abc/abcHieNew.c +++ b/src/base/abc/abcHieNew.c @@ -9,7 +9,7 @@ Synopsis [New hierarchy manager.] Author [Alan Mishchenko] - + Affiliation [UC Berkeley] Date [Ver. 1.0. Started - June 20, 2005.] @@ -34,8 +34,8 @@ ABC_NAMESPACE_IMPL_START //////////////////////////////////////////////////////////////////////// #define AU_MAX_FANINS 0x1FFFFFFF - -typedef enum { + +typedef enum { AU_OBJ_NONE, // 0: non-existent object AU_OBJ_CONST0, // 1: constant node AU_OBJ_PI, // 2: primary input @@ -61,7 +61,7 @@ struct Au_Obj_t_ // 16 bytes int Fanins[2]; // fanin literals }; -struct Au_Ntk_t_ +struct Au_Ntk_t_ { char * pName; // model name Au_Man_t * pMan; // model manager @@ -95,7 +95,7 @@ struct Au_Ntk_t_ double nNodeMuxs; }; -struct Au_Man_t_ +struct Au_Man_t_ { char * pName; // the name of the library Vec_Ptr_t vNtks; // the array of modules @@ -120,7 +120,7 @@ static inline Au_Obj_t * Au_Regular( Au_Obj_t * p ) { retur static inline Au_Obj_t * Au_Not( Au_Obj_t * p ) { return (Au_Obj_t *)((ABC_PTRUINT_T)(p) ^ 01); } static inline Au_Obj_t * Au_NotCond( Au_Obj_t * p, int c ) { return (Au_Obj_t *)((ABC_PTRUINT_T)(p) ^ (c)); } static inline int Au_IsComplement( Au_Obj_t * p ) { return (int)((ABC_PTRUINT_T)(p) & 01); } - + static inline char * Au_UtilStrsav( char * s ) { return s ? strcpy(ABC_ALLOC(char, strlen(s)+1), s) : NULL; } static inline char * Au_ManName( Au_Man_t * p ) { return p->pName; } @@ -130,32 +130,32 @@ static inline Au_Ntk_t * Au_ManNtkRoot( Au_Man_t * p ) { retur static inline char * Au_NtkName( Au_Ntk_t * p ) { return p->pName; } static inline Au_Man_t * Au_NtkMan( Au_Ntk_t * p ) { return p->pMan; } -static inline int Au_NtkPiNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_PI]; } -static inline int Au_NtkPoNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_PO]; } -static inline int Au_NtkFanNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_FAN]; } -static inline int Au_NtkFlopNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_FLOP]; } -static inline int Au_NtkBoxNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_BOX]; } -static inline int Au_NtkNodeNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_NODE]; } -static inline int Au_NtkObjNumMax( Au_Ntk_t * p ) { return (Vec_PtrSize(&p->vPages) - 1) * (1 << 12) + p->iHandle; } -static inline int Au_NtkObjNum( Au_Ntk_t * p ) { return Vec_IntSize(&p->vObjs); } +static inline int Au_NtkPiNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_PI]; } +static inline int Au_NtkPoNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_PO]; } +static inline int Au_NtkFanNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_FAN]; } +static inline int Au_NtkFlopNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_FLOP]; } +static inline int Au_NtkBoxNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_BOX]; } +static inline int Au_NtkNodeNum( Au_Ntk_t * p ) { return p->nObjs[AU_OBJ_NODE]; } +static inline int Au_NtkObjNumMax( Au_Ntk_t * p ) { return (Vec_PtrSize(&p->vPages) - 1) * (1 << 12) + p->iHandle; } +static inline int Au_NtkObjNum( Au_Ntk_t * p ) { return Vec_IntSize(&p->vObjs); } static inline Au_Obj_t * Au_NtkObj( Au_Ntk_t * p, int h ) { return (Au_Obj_t *)p->vPages.pArray[h >> 12] + (h & 0xFFF); } static inline Au_Obj_t * Au_NtkPi( Au_Ntk_t * p, int i ) { return Au_NtkObj(p, Vec_IntEntry(&p->vPis, i)); } static inline Au_Obj_t * Au_NtkPo( Au_Ntk_t * p, int i ) { return Au_NtkObj(p, Vec_IntEntry(&p->vPos, i)); } static inline Au_Obj_t * Au_NtkObjI( Au_Ntk_t * p, int i ) { return Au_NtkObj(p, Vec_IntEntry(&p->vObjs, i)); } -static inline int Au_ObjIsNone( Au_Obj_t * p ) { return p->Type == AU_OBJ_NONE; } -static inline int Au_ObjIsConst0( Au_Obj_t * p ) { return p->Type == AU_OBJ_CONST0; } -static inline int Au_ObjIsPi( Au_Obj_t * p ) { return p->Type == AU_OBJ_PI; } -static inline int Au_ObjIsPo( Au_Obj_t * p ) { return p->Type == AU_OBJ_PO; } -static inline int Au_ObjIsFan( Au_Obj_t * p ) { return p->Type == AU_OBJ_FAN; } -static inline int Au_ObjIsFlop( Au_Obj_t * p ) { return p->Type == AU_OBJ_FLOP; } -static inline int Au_ObjIsBox( Au_Obj_t * p ) { return p->Type == AU_OBJ_BOX; } +static inline int Au_ObjIsNone( Au_Obj_t * p ) { return p->Type == AU_OBJ_NONE; } +static inline int Au_ObjIsConst0( Au_Obj_t * p ) { return p->Type == AU_OBJ_CONST0; } +static inline int Au_ObjIsPi( Au_Obj_t * p ) { return p->Type == AU_OBJ_PI; } +static inline int Au_ObjIsPo( Au_Obj_t * p ) { return p->Type == AU_OBJ_PO; } +static inline int Au_ObjIsFan( Au_Obj_t * p ) { return p->Type == AU_OBJ_FAN; } +static inline int Au_ObjIsFlop( Au_Obj_t * p ) { return p->Type == AU_OBJ_FLOP; } +static inline int Au_ObjIsBox( Au_Obj_t * p ) { return p->Type == AU_OBJ_BOX; } static inline int Au_ObjIsNode( Au_Obj_t * p ) { return p->Type == AU_OBJ_NODE; } -static inline int Au_ObjIsTerm( Au_Obj_t * p ) { return p->Type >= AU_OBJ_PI && p->Type <= AU_OBJ_FLOP; } +static inline int Au_ObjIsTerm( Au_Obj_t * p ) { return p->Type >= AU_OBJ_PI && p->Type <= AU_OBJ_FLOP; } -static inline char * Au_ObjBase( Au_Obj_t * p ) { return (char *)p - ((ABC_PTRINT_T)p & 0x3FF); } -static inline Au_Ntk_t * Au_ObjNtk( Au_Obj_t * p ) { return ((Au_Ntk_t **)Au_ObjBase(p))[0]; } +static inline char * Au_ObjBase( Au_Obj_t * p ) { return (char *)p - ((ABC_PTRINT_T)p & 0x3FF); } +static inline Au_Ntk_t * Au_ObjNtk( Au_Obj_t * p ) { return ((Au_Ntk_t **)Au_ObjBase(p))[0]; } static inline int Au_ObjId( Au_Obj_t * p ) { return ((int *)Au_ObjBase(p))[2] | (((ABC_PTRINT_T)p & 0x3FF) >> 4); } static inline int Au_ObjPioNum( Au_Obj_t * p ) { assert(Au_ObjIsTerm(p)); return p->Fanins[p->nFanins]; } static inline int Au_ObjFunc( Au_Obj_t * p ) { return p->Func; } @@ -197,17 +197,17 @@ static inline void Au_ObjSetTravIdCurrentId( Au_Ntk_t * p, int Id ) { Ve static inline int Au_ObjIsTravIdCurrentId( Au_Ntk_t * p, int Id ) { return (Vec_IntGetEntry(&p->vTravIds, Id) == p->nTravIds); } #define Au_ManForEachNtk( p, pNtk, i ) \ - for ( i = 1; (i < Vec_PtrSize(&p->vNtks)) && (((pNtk) = Au_ManNtk(p, i)), 1); i++ ) + for ( i = 1; (i < Vec_PtrSize(&p->vNtks)) && (((pNtk) = Au_ManNtk(p, i)), 1); i++ ) #define Au_ManForEachNtkReverse( p, pNtk, i ) \ - for ( i = Vec_PtrSize(&p->vNtks) - 1;(i>=1) && (((pNtk) = Au_ManNtk(p, i)), 1); i-- ) + for ( i = Vec_PtrSize(&p->vNtks) - 1;(i>=1) && (((pNtk) = Au_ManNtk(p, i)), 1); i-- ) #define Au_ObjForEachFaninId( pObj, hFanin, i ) \ - for ( i = 0; (i < Au_ObjFaninNum(pObj)) && (((hFanin) = Au_ObjFaninId(pObj, i)), 1); i++ ) + for ( i = 0; (i < Au_ObjFaninNum(pObj)) && (((hFanin) = Au_ObjFaninId(pObj, i)), 1); i++ ) #define Au_BoxForEachFanoutId( pObj, hFanout, i) \ for ( i = 0; (i < Au_BoxFanoutNum(pObj)) && (((hFanout) = Au_BoxFanoutId(pObj, i)), 1); i++ ) #define Au_ObjForEachFanin( pObj, pFanin, i ) \ - for ( i = 0; (i < Au_ObjFaninNum(pObj)) && (((pFanin) = Au_ObjFanin(pObj, i)), 1); i++ ) + for ( i = 0; (i < Au_ObjFaninNum(pObj)) && (((pFanin) = Au_ObjFanin(pObj, i)), 1); i++ ) #define Au_BoxForEachFanout( pObj, pFanout, i) \ for ( i = 0; (i < Au_BoxFanoutNum(pObj)) && (((pFanout) = Au_BoxFanout(pObj, i)), 1); i++ ) @@ -236,7 +236,7 @@ extern void Au_ManFree( Au_Man_t * p ); Synopsis [Working with models.] Description [] - + SideEffects [] SeeAlso [] @@ -318,7 +318,7 @@ int Au_NtkNodeNumFunc( Au_Ntk_t * p, int Func ) Synopsis [Working with manager.] Description [] - + SideEffects [] SeeAlso [] @@ -351,7 +351,7 @@ void Au_ManDelete( Au_Man_t * p ) Au_ManForEachNtk( p, pNtk, i ) Au_NtkFree( pNtk ); } -int Au_ManFindNtk( Au_Man_t * p, char * pName ) +int Au_ManFindNtk( Au_Man_t * p, const char * pName ) { Au_Ntk_t * pNtk; int i; @@ -360,7 +360,7 @@ int Au_ManFindNtk( Au_Man_t * p, char * pName ) return i; return -1; } -Au_Ntk_t * Au_ManFindNtkP( Au_Man_t * p, char * pName ) +Au_Ntk_t * Au_ManFindNtkP( Au_Man_t * p, const char * pName ) { int iNtk = Au_ManFindNtk( p, pName ); if ( iNtk == -1 ) @@ -447,7 +447,7 @@ void Au_ManReorderModels( Au_Man_t * p, Au_Ntk_t * pRoot ) // reverse order vOrder->nSize--; vOrder->pArray++; - Vec_IntReverseOrder( vOrder ); + Vec_IntReverseOrder( vOrder ); vOrder->pArray--; vOrder->nSize++; // compute new order @@ -524,11 +524,11 @@ void Au_ManCountThings( Au_Man_t * p ) // printf( "total %.0f nodes in model %s\n", pNtk->nNodes, Au_NtkName(pNtk) ); } pNtk = Au_ManNtkRoot(p); - printf( "Total nodes = %15.0f. Total instances = %15.0f. Total ports = %15.0f.\n", -// printf( "Total nodes = %.2e. Total instances = %.2e. Total ports = %.2e.\n", + printf( "Total nodes = %15.0f. Total instances = %15.0f. Total ports = %15.0f.\n", +// printf( "Total nodes = %.2e. Total instances = %.2e. Total ports = %.2e.\n", pNtk->nNodes, pNtk->nBoxes, pNtk->nPorts ); -// printf( "Total ANDs = %15.0f. Total XORs = %15.0f. Total MUXes = %15.0f.\n", -// printf( "Total ANDs = %.2e. Total XORs = %.2e. Total MUXes = %.2e. ", +// printf( "Total ANDs = %15.0f. Total XORs = %15.0f. Total MUXes = %15.0f.\n", +// printf( "Total ANDs = %.2e. Total XORs = %.2e. Total MUXes = %.2e. ", // pNtk->nNodeAnds, pNtk->nNodeXors, pNtk->nNodeMuxs ); printf( "Total ANDs = %15.0f.\n", pNtk->nNodeAnds ); printf( "Total XORs = %15.0f.\n", pNtk->nNodeXors ); @@ -744,7 +744,7 @@ int Au_NtkSuppSizeTest( Au_Ntk_t * p ) Synopsis [Returns memory for the next object.] Description [] - + SideEffects [] SeeAlso [] @@ -779,7 +779,7 @@ int Au_NtkAllocObj( Au_Ntk_t * p, int nFanins, int Type ) if ( p->iHandle ) { pMem += 64 - (p->iHandle & 63); - p->iHandle = 0; + p->iHandle = 0; } Vec_PtrPush( &p->vPages, pMem ); Au_NtkInsertHeader( p ); @@ -790,7 +790,7 @@ int Au_NtkAllocObj( Au_Ntk_t * p, int nFanins, int Type ) if ( (p->iHandle & 63) == 0 || nObjInt > (64 - (p->iHandle & 63)) ) { if ( p->iHandle & 63 ) - p->iHandle += 64 - (p->iHandle & 63); + p->iHandle += 64 - (p->iHandle & 63); Au_NtkInsertHeader( p ); } if ( p->iHandle + nObjInt > (1 << 12) ) @@ -899,7 +899,7 @@ Here is a small example: Synopsis [Reads one entry.] Description [] - + SideEffects [] SeeAlso [] @@ -914,7 +914,7 @@ static inline int Au_NtkRemapNum( Vec_Int_t * vNum2Obj, int Num ) Synopsis [Reads one entry.] Description [] - + SideEffects [] SeeAlso [] @@ -950,7 +950,7 @@ static inline void Au_NtkParseCBlifNum( Vec_Int_t * vFanins, char * pToken, Vec_ Synopsis [Parses CBLIF file.] Description [] - + SideEffects [] SeeAlso [] @@ -1077,7 +1077,7 @@ Au_Ntk_t * Au_NtkParseCBlif( char * pFileName ) { pCur = strtok( NULL, " \t\r" ); if ( pCur == NULL || *pCur == '#' ) - break; + break; Au_NtkParseCBlifNum( vFanins, pCur, vNum2Obj ); } assert( Vec_IntSize(vFanins) == nOutputs ); @@ -1122,14 +1122,14 @@ extern int Abc_NtkCheckRecursive( Abc_Ntk_t * pNtk ); Synopsis [Flattens the logic hierarchy of the netlist.] Description [] - + SideEffects [] SeeAlso [] ***********************************************************************/ void Au_NtkDeriveFlatGia_rec( Gia_Man_t * pGia, Au_Ntk_t * p ) -{ +{ Au_Obj_t * pObj, * pTerm; int i, k, Lit = 0; Au_NtkForEachPi( p, pTerm, i ) @@ -1173,8 +1173,8 @@ void Au_NtkDeriveFlatGia_rec( Gia_Man_t * pGia, Au_Ntk_t * p ) Lit2 = Abc_LitNotCond( Au_ObjCopy(Au_ObjFanin2(pObj)), Au_ObjFaninC2(pObj) ); Lit = Gia_ManHashMux( pGia, Lit0, Lit1, Lit2 ); } - else assert( 0 ); - } + else assert( 0 ); + } assert( Lit >= 0 ); Au_ObjSetCopy( pObj, Lit ); } @@ -1196,7 +1196,7 @@ void Au_NtkDeriveFlatGia_rec( Gia_Man_t * pGia, Au_Ntk_t * p ) } else if ( Au_ObjIsConst0(pObj) ) Au_ObjSetCopy( pObj, 0 ); - + } Au_NtkForEachPo( p, pTerm, i ) { @@ -1213,7 +1213,7 @@ void Au_NtkDeriveFlatGia_rec( Gia_Man_t * pGia, Au_Ntk_t * p ) Synopsis [Flattens the logic hierarchy of the netlist.] Description [] - + SideEffects [] SeeAlso [] @@ -1257,17 +1257,17 @@ Gia_Man_t * Au_NtkDeriveFlatGia( Au_Ntk_t * p ) static inline void Au_ObjSetXsim( Au_Obj_t * pObj, int Value ) { pObj->Value = Value; } static inline int Au_ObjGetXsim( Au_Obj_t * pObj ) { return pObj->Value; } -static inline int Au_XsimInv( int Value ) -{ +static inline int Au_XsimInv( int Value ) +{ if ( Value == AU_VAL0 ) return AU_VAL1; if ( Value == AU_VAL1 ) return AU_VAL0; - assert( Value == AU_VALX ); + assert( Value == AU_VALX ); return AU_VALX; } -static inline int Au_XsimAnd( int Value0, int Value1 ) -{ +static inline int Au_XsimAnd( int Value0, int Value1 ) +{ if ( Value0 == AU_VAL0 || Value1 == AU_VAL0 ) return AU_VAL0; if ( Value0 == AU_VALX || Value1 == AU_VALX ) @@ -1275,16 +1275,16 @@ static inline int Au_XsimAnd( int Value0, int Value1 ) assert( Value0 == AU_VAL1 && Value1 == AU_VAL1 ); return AU_VAL1; } -static inline int Au_XsimXor( int Value0, int Value1 ) -{ +static inline int Au_XsimXor( int Value0, int Value1 ) +{ if ( Value0 == AU_VALX || Value1 == AU_VALX ) return AU_VALX; if ( (Value0 == AU_VAL0) == (Value1 == AU_VAL0) ) return AU_VAL0; return AU_VAL1; } -static inline int Au_XsimMux( int ValueC, int Value1, int Value0 ) -{ +static inline int Au_XsimMux( int ValueC, int Value1, int Value0 ) +{ if ( ValueC == AU_VAL0 ) return Value0; if ( ValueC == AU_VAL1 ) @@ -1295,18 +1295,18 @@ static inline int Au_XsimMux( int ValueC, int Value1, int Value0 ) return AU_VAL1; return AU_VALX; } -static inline int Au_ObjGetXsimFan0( Au_Obj_t * pObj ) -{ +static inline int Au_ObjGetXsimFan0( Au_Obj_t * pObj ) +{ int Value = Au_ObjGetXsim( Au_ObjFanin0(pObj) ); return Au_ObjFaninC0(pObj) ? Au_XsimInv(Value) : Value; } -static inline int Au_ObjGetXsimFan1( Au_Obj_t * pObj ) -{ +static inline int Au_ObjGetXsimFan1( Au_Obj_t * pObj ) +{ int Value = Au_ObjGetXsim( Au_ObjFanin1(pObj) ); return Au_ObjFaninC1(pObj) ? Au_XsimInv(Value) : Value; } -static inline int Au_ObjGetXsimFan2( Au_Obj_t * pObj ) -{ +static inline int Au_ObjGetXsimFan2( Au_Obj_t * pObj ) +{ int Value = Au_ObjGetXsim( Au_ObjFanin2(pObj) ); return Au_ObjFaninC2(pObj) ? Au_XsimInv(Value) : Value; } @@ -1316,14 +1316,14 @@ static inline int Au_ObjGetXsimFan2( Au_Obj_t * pObj ) Synopsis [Flattens the logic hierarchy of the netlist.] Description [] - + SideEffects [] SeeAlso [] ***********************************************************************/ void Au_NtkTerSimulate_rec( Au_Ntk_t * p ) -{ +{ Au_Obj_t * pObj = NULL, * pTerm; int i, k; Au_NtkForEachPi( p, pTerm, i ) @@ -1372,7 +1372,7 @@ void Au_NtkTerSimulate_rec( Au_Ntk_t * p ) } else if ( Au_ObjIsConst0(pObj) ) Au_ObjSetXsim( pObj, AU_VAL0 ); - + } Au_NtkForEachPo( p, pTerm, i ) Au_ObjSetXsim( pTerm, Au_ObjGetXsimFan0(pObj) ); @@ -1393,7 +1393,7 @@ void Au_NtkTerSimulate_rec( Au_Ntk_t * p ) Synopsis [Flattens the logic hierarchy of the netlist.] Description [] - + SideEffects [] SeeAlso [] @@ -1420,9 +1420,9 @@ void Au_NtkTerSimulate( Au_Ntk_t * p ) else if ( Au_ObjGetXsim(pTerm) == AU_VAL1 ) Counter[1]++; // print results - printf( "Const0 outputs =%15d. Const1 outputs =%15d. Total outputs =%15d.\n", + printf( "Const0 outputs =%15d. Const1 outputs =%15d. Total outputs =%15d.\n", Counter[0], Counter[1], Au_NtkPoNum(p) ); - printf( "Const0 ports = %.0f. Const1 ports = %.0f. Non-const ports= %.0f. Total ports = %.0f.\n", + printf( "Const0 ports = %.0f. Const1 ports = %.0f. Non-const ports= %.0f. Total ports = %.0f.\n", p->pMan->nPortsC0, p->pMan->nPortsC1, p->pMan->nPortsNC, p->pMan->nPortsC0 + p->pMan->nPortsC1 + p->pMan->nPortsNC ); } @@ -1432,7 +1432,7 @@ void Au_NtkTerSimulate( Au_Ntk_t * p ) Synopsis [Duplicates ABC network.] Description [] - + SideEffects [] SeeAlso [] @@ -1488,7 +1488,7 @@ Gia_Man_t * Au_ManDeriveTest( Abc_Ntk_t * pRoot ) extern Vec_Ptr_t * Abc_NtkCollectHie( Abc_Ntk_t * pNtk ); // char * pModelName = NULL; - char * pModelName = "path_0_r_x_lhs"; + const char * pModelName = "path_0_r_x_lhs"; Gia_Man_t * pGia = NULL; Vec_Ptr_t * vOrder, * vModels; Abc_Ntk_t * pMod; @@ -1533,7 +1533,7 @@ Gia_Man_t * Au_ManDeriveTest( Abc_Ntk_t * pRoot ) if ( pNtk == NULL ) pNtk = (Au_Ntk_t *)pRoot->pData; - + // if ( !Abc_NtkCheckRecursive(pRoot) ) { clk1 = Abc_Clock(); @@ -1549,7 +1549,7 @@ Gia_Man_t * Au_ManDeriveTest( Abc_Ntk_t * pRoot ) clk1 = Abc_Clock(); Au_ManDelete( pMan ); clk2 += Abc_Clock() - clk1; - + Abc_PrintTime( 1, "Time all ", Abc_Clock() - clk ); Abc_PrintTime( 1, "Time new ", clk2 ); Abc_PrintTime( 1, "Time GIA ", clk3 ); @@ -1562,7 +1562,7 @@ Gia_Man_t * Au_ManDeriveTest( Abc_Ntk_t * pRoot ) Synopsis [Performs hierarchical equivalence checking.] Description [] - + SideEffects [] SeeAlso [] diff --git a/src/base/abci/abcNpn.c b/src/base/abci/abcNpn.c index 92b47c177a..dcf9854a20 100644 --- a/src/base/abci/abcNpn.c +++ b/src/base/abci/abcNpn.c @@ -340,7 +340,7 @@ void Abc_TruthNpnPerform( Abc_TtStore_t * p, int NpnType, int fVerbose ) // typedef unsigned(*TtCanonicizeFunc)(Abc_TtHieMan_t * p, word * pTruth, int nVars, char * pCanonPerm, int flag); unsigned Abc_TtCanonicizeWrap(TtCanonicizeFunc func, Abc_TtHieMan_t * p, word * pTruth, int nVars, char * pCanonPerm, int flag); unsigned Abc_TtCanonicizeAda(Abc_TtHieMan_t * p, word * pTruth, int nVars, char * pCanonPerm, int iThres); - unsigned Abc_TtCanonicizeCA(Abc_TtHieMan_t * p, word * pTruth, int nVars, char * pCanonPerm, int iThres); + extern unsigned Abc_TtCanonicizeCA(Abc_TtHieMan_t * p, word * pTruth, int nVars, char * pCanonPerm, int iThres); Abc_TtHieMan_t * pMan = Abc_TtHieManStart(p->nVars, 5); for ( i = 0; i < p->nFuncs; i++ ) diff --git a/src/sat/kissat/bump.c b/src/sat/kissat/bump.c index 5dc365f51b..efe3fa46b2 100644 --- a/src/sat/kissat/bump.c +++ b/src/sat/kissat/bump.c @@ -85,7 +85,7 @@ static void move_analyzed_variables_to_front_of_queue (kissat *solver) { const links *const links = solver->links; for (all_stack (unsigned, idx, solver->analyzed)) { // clang-format off - const datarank rank = { .data = idx, .rank = links[idx].stamp }; + const datarank rank = { /*.data = */idx, /*.rank = */links[idx].stamp }; // c++20 only // clang-format on PUSH_STACK (solver->ranks, rank); } diff --git a/src/sat/kissat/colors.c b/src/sat/kissat/colors.c index c6141b7491..7c41fba617 100644 --- a/src/sat/kissat/colors.c +++ b/src/sat/kissat/colors.c @@ -1,6 +1,7 @@ #include "colors.h" #if defined(WIN32) && !defined(__MINGW32__) +#include #define isatty _isatty #else #include diff --git a/src/sat/kissat/congruence.c b/src/sat/kissat/congruence.c index 221f6a13a0..364e35d44f 100644 --- a/src/sat/kissat/congruence.c +++ b/src/sat/kissat/congruence.c @@ -846,7 +846,7 @@ static void add_binary_clause (closure *closure, unsigned a, unsigned b) { kissat_new_binary_clause (solver, a, b); else { kissat_new_unwatched_binary_clause (solver, a, b); - litpair litpair = {.lits = {a < b ? a : b, a < b ? b : a}}; + litpair litpair = {/*.lits = */{a < b ? a : b, a < b ? b : a}}; // c++20 only PUSH_STACK (closure->binaries, litpair); } } @@ -2500,7 +2500,7 @@ static bool indexed_binary (closure *closure, unsigned lit, SWAP (unsigned, lit, other); if (lit > other) SWAP (unsigned, lit, other); - binary_clause binary = {.lits = {lit, other}}; + binary_clause binary = {/*.lits = */{lit, other}}; // c++20 only const unsigned hash = hash_binary (closure, &binary); const size_t size = bintab->size; const size_t size2 = bintab->size2; @@ -2986,7 +2986,7 @@ static void index_binary (closure *closure, unsigned lit, unsigned other) { KISSAT_assert (lit < other); binary_hash_table *bintab = &closure->bintab; KISSAT_assert (!binaries_hash_table_is_full (bintab)); - binary_clause binary = {.lits = {lit, other}}; + binary_clause binary = {/*.lits = */{lit, other}}; // c++20 only const unsigned hash = hash_binary (closure, &binary); const size_t size = bintab->size; const size_t size2 = bintab->size2; @@ -3416,10 +3416,10 @@ static void copy_conditional_equivalences (kissat *solver, unsigned lit, KISSAT_assert (second != INVALID_LIT); litpair pair; if (first < second) - pair = (litpair){.lits = {first, second}}; + pair.lits[0] = first, pair.lits[1] = second; else { KISSAT_assert (second < first); - pair = (litpair){.lits = {second, first}}; + pair.lits[0] = second, pair.lits[1] = first; } LOG ("literal %s conditional binary clause %s %s", LOGLIT (lit), LOGLIT (first), LOGLIT (second)); @@ -3491,13 +3491,13 @@ static void search_condeq (closure *closure, unsigned lit, unsigned pos_lit, KISSAT_assert (first < second); check_ternary (closure, lit, first, NOT (second)); check_ternary (closure, lit, NOT (first), second); - litpair equivalence = {.lits = {first, second}}; + litpair equivalence = {/*.lits = */{first, second}}; // c++20 only PUSH_STACK (*condeq, equivalence); if (NEGATED (second)) { - litpair inverse_equivalence = {.lits = {NOT (second), NOT (first)}}; + litpair inverse_equivalence = {/*.lits = */{NOT (second), NOT (first)}}; // c++20 only PUSH_STACK (*condeq, inverse_equivalence); } else { - litpair inverse_equivalence = {.lits = {second, first}}; + litpair inverse_equivalence = {/*.lits = */{second, first}}; // c++20 only PUSH_STACK (*condeq, inverse_equivalence); } } @@ -4549,7 +4549,7 @@ static void forward_subsume_matching_clauses (closure *closure) { } const reference ref = kissat_reference_clause (solver, c); KISSAT_assert (size <= UINT_MAX); - refsize refsize = {.ref = ref, .size = (unsigned)size}; + refsize refsize = {/*.ref = */ref, /*.size = */(unsigned)size}; // c++20 only PUSH_STACK (candidates, refsize); } DEALLOC (matchable, VARS); diff --git a/src/sat/kissat/dense.c b/src/sat/kissat/dense.c index 65c668cbcc..c5273e4807 100644 --- a/src/sat/kissat/dense.c +++ b/src/sat/kissat/dense.c @@ -60,7 +60,7 @@ static void flush_large_watches (kissat *solver, litpairs *irredundant) { if (irredundant) { const unsigned other = watch.binary.lit; if (lit < other) { - const litpair litpair = {.lits = {lit, other}}; + const litpair litpair = {/*.lits = */{lit, other}}; // c++20 only PUSH_STACK (*irredundant, litpair); } } else diff --git a/src/sat/kissat/file.c b/src/sat/kissat/file.c index e4486783d2..d9564e696e 100644 --- a/src/sat/kissat/file.c +++ b/src/sat/kissat/file.c @@ -5,14 +5,19 @@ #include #include #include -#include + #include +#include #ifdef WIN32 +#include #define unlink _unlink #define access _access #define R_OK 4 #define W_OK 2 +#ifndef S_ISDIR +# define S_ISDIR(mode) (((mode) & _S_IFMT) == _S_IFDIR) +#endif #else #include #endif diff --git a/src/sat/kissat/kitten.c b/src/sat/kissat/kitten.c index ea2e7f3607..9c08d73c6d 100644 --- a/src/sat/kissat/kitten.c +++ b/src/sat/kissat/kitten.c @@ -1892,7 +1892,7 @@ unsigned kitten_compute_clausal_core (kitten *kitten, if (reason_ref == INVALID) { LOG ("assumptions mutually inconsistent"); - + // goto DONE; if (learned_ptr) *learned_ptr = learned; @@ -1907,7 +1907,7 @@ unsigned kitten_compute_clausal_core (kitten *kitten, return original; - + } } @@ -2412,7 +2412,7 @@ static inline void print_lit (line *line, int lit) { static void print_witness (kitten *kitten, int max_var) { KISSAT_assert (max_var >= 0); - line line = {.size = 0}; + line line = {/*.size = */0}; // c++20 only const size_t parsed_lits = 2 * (size_t) max_var; for (size_t ulit = 0; ulit < parsed_lits; ulit += 2) { const value sign = kitten_value (kitten, ulit); diff --git a/src/sat/kissat/proplit.h b/src/sat/kissat/proplit.h index be0632d0cb..203c1eb398 100644 --- a/src/sat/kissat/proplit.h +++ b/src/sat/kissat/proplit.h @@ -8,7 +8,7 @@ static inline void kissat_watch_large_delayed (kissat *solver, while (d != end_delayed) { const unsigned lit = *d++; KISSAT_assert (d != end_delayed); - const watch watch = {.raw = *d++}; + const watch watch = {/*.raw =*/ *d++}; // c++20 only KISSAT_assert (!watch.type.binary); KISSAT_assert (lit < LITS); watches *const lit_watches = all_watches + lit; diff --git a/src/sat/kissat/sweep.c b/src/sat/kissat/sweep.c index 42420cc541..0e56669e5f 100644 --- a/src/sat/kissat/sweep.c +++ b/src/sat/kissat/sweep.c @@ -877,8 +877,8 @@ static void substitute_connected_clauses (sweeper *sweeper, unsigned lit, REMOVE_CHECKER_BINARY (lit, other); DELETE_BINARY_FROM_PROOF (lit, other); PUSH_STACK (*delayed, head.raw); - watch src = {.raw = head.raw}; - watch dst = {.raw = head.raw}; + watch src = {/*.raw = */head.raw}; // c++20 only + watch dst = {/*.raw = */head.raw}; // c++20 only src.binary.lit = lit; dst.binary.lit = repr; watches *other_watches = &WATCHES (other); @@ -970,7 +970,7 @@ static void substitute_connected_clauses (sweeper *sweeper, unsigned lit, LOGLIT (second)); KISSAT_assert (first == repr || second == repr); const unsigned other = first ^ second ^ repr; - const watch src = {.raw = head.raw}; + const watch src = {/*.raw = */head.raw}; // c++20 only watch dst = kissat_binary_watch (repr); watches *other_watches = &WATCHES (other); kissat_substitute_large_watch (solver, other_watches, src, dst); @@ -1029,7 +1029,7 @@ static void substitute_connected_clauses (sweeper *sweeper, unsigned lit, const unsigned *const begin_delayed = BEGIN_STACK (*delayed); const unsigned *const end_delayed = END_STACK (*delayed); for (const unsigned *p = begin_delayed; p != end_delayed; p++) { - const watch head = {.raw = *p}; + const watch head = {/*.raw = */*p}; // c++20 only watches *repr_watches = &WATCHES (repr); PUSH_WATCHES (*repr_watches, head); } diff --git a/src/sat/kissat/walk.c b/src/sat/kissat/walk.c index 72ce38a6c3..18ebdd6792 100644 --- a/src/sat/kissat/walk.c +++ b/src/sat/kissat/walk.c @@ -28,7 +28,7 @@ struct tagged { static inline tagged make_tagged (bool binary, unsigned ref) { KISSAT_assert (ref <= MAX_WALK_REF); - tagged res = {.ref = ref, .binary = binary}; + tagged res = {/*.ref = */ref, /*.binary = */binary}; // c++20 only return res; } diff --git a/src/sat/kissat/watch.c b/src/sat/kissat/watch.c index 78f9a69ce7..d444f18c26 100644 --- a/src/sat/kissat/watch.c +++ b/src/sat/kissat/watch.c @@ -36,7 +36,7 @@ void kissat_remove_binary_watch (kissat *solver, watches *watches, KISSAT_assert (begin + 1 <= end); watches->end -= 1; #endif - const watch empty = {.raw = INVALID_VECTOR_ELEMENT}; + const watch empty = {/*.raw = */INVALID_VECTOR_ELEMENT}; // c++20 only end[-1] = empty; KISSAT_assert (solver->vectors.usable < MAX_SECTOR - 1); solver->vectors.usable += 1; @@ -73,7 +73,7 @@ void kissat_remove_blocking_watch (kissat *solver, watches *watches, KISSAT_assert (begin + 2 <= end); watches->end -= 2; #endif - const watch empty = {.raw = INVALID_VECTOR_ELEMENT}; + const watch empty = {/*.raw = */INVALID_VECTOR_ELEMENT}; // c++20 only end[-2] = end[-1] = empty; KISSAT_assert (solver->vectors.usable < MAX_SECTOR - 2); solver->vectors.usable += 2; From 1a2a9e08a7140abb7e964b3d29b3c5c9e12133af Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Sat, 8 Mar 2025 20:46:28 -0800 Subject: [PATCH 33/35] fix: dev: add latest modules to cmake build modules * correct the cadical usage of __USE_MINGW_ANSI_STDIO * cleanup more win32/mingw32 defines in cadical * add tox cmd descriptions, run tox list to see them Signed-off-by: Stephen L Arnold --- CMakeLists.txt | 4 +- Makefile | 4 +- src/opt/eslim/CMakeLists.txt | 6 ++ src/sat/cadical/CMakeLists.txt | 95 ++++++++++++++++++++++++++ src/sat/cadical/cadical.hpp | 5 +- src/sat/cadical/cadical_congruence.cpp | 34 ++++----- src/sat/cadical/cadical_decompose.cpp | 4 +- src/sat/cadical/cadical_external.cpp | 2 +- src/sat/cadical/cadical_file.cpp | 4 +- src/sat/cadical/cadical_vivify.cpp | 4 +- src/sat/cadical/inttypes.hpp | 1 + src/sat/cadical/util.hpp | 4 +- tox.ini | 17 ++++- 13 files changed, 151 insertions(+), 33 deletions(-) create mode 100644 src/opt/eslim/CMakeLists.txt create mode 100644 src/sat/cadical/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index 46c16a9933..3385c173c4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -122,9 +122,9 @@ set(ABC_MODULES src/misc/mem src/misc/bar src/misc/bbl src/misc/parse src/opt/cut src/opt/fxu src/opt/fxch src/opt/rwr src/opt/mfs src/opt/sim src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt src/opt/rar - src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd + src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd src/opt/eslim src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat - src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/sat/kissat + src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/sat/kissat src/sat/cadical src/bool/bdc src/bool/deco src/bool/dec src/bool/kit src/bool/lucky src/bool/rsb src/bool/rpo src/proof/pdr src/proof/abs src/proof/live src/proof/ssc src/proof/int diff --git a/Makefile b/Makefile index 7e090b7458..eb7b027628 100644 --- a/Makefile +++ b/Makefile @@ -29,7 +29,8 @@ MODULES := \ src/opt/cut src/opt/fxu src/opt/fxch src/opt/rwr src/opt/mfs src/opt/sim \ src/opt/ret src/opt/fret src/opt/res src/opt/lpk src/opt/nwk src/opt/rwt src/opt/rar \ src/opt/cgt src/opt/csw src/opt/dar src/opt/dau src/opt/dsc src/opt/sfm src/opt/sbd src/opt/eslim \ - src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/sat/kissat src/sat/cadical \ + src/sat/bsat src/sat/xsat src/sat/satoko src/sat/csat src/sat/msat src/sat/psat \ + src/sat/cnf src/sat/bmc src/sat/glucose src/sat/glucose2 src/sat/kissat src/sat/cadical \ src/bool/bdc src/bool/deco src/bool/dec src/bool/kit src/bool/lucky \ src/bool/rsb src/bool/rpo \ src/proof/pdr src/proof/abs src/proof/live src/proof/ssc src/proof/int \ @@ -71,7 +72,6 @@ ifdef ABC_USE_NAMESPACE DLIBS := -lstdc++ $(info $(MSG_PREFIX)Compiling in namespace $(ABC_NAMESPACE)) else - CFLAGS += -std=gnu99 CXXFLAGS := $(CFLAGS) ABC_USE_LIBSTDCXX := 1 endif diff --git a/src/opt/eslim/CMakeLists.txt b/src/opt/eslim/CMakeLists.txt new file mode 100644 index 0000000000..4e3df8832c --- /dev/null +++ b/src/opt/eslim/CMakeLists.txt @@ -0,0 +1,6 @@ +abc_libabc_add_sources( + NAME opt_eslim + SOURCES + relationGeneration.cpp + eSLIM.cpp +) diff --git a/src/sat/cadical/CMakeLists.txt b/src/sat/cadical/CMakeLists.txt new file mode 100644 index 0000000000..f00811a268 --- /dev/null +++ b/src/sat/cadical/CMakeLists.txt @@ -0,0 +1,95 @@ +abc_libabc_add_sources( + NAME sat_cadical + SOURCES + cadical_drattracer.cpp + cadical_restart.cpp + cadical_lidruptracer.cpp + cadical_ternary.cpp + cadical_options.cpp + cadical_constrain.cpp + cadical_minimize.cpp + cadical_logging.cpp + cadical_restore.cpp + cadical_lratchecker.cpp + cadical_backward.cpp + cadical_contract.cpp + cadical_watch.cpp + cadical_flags.cpp + cadical_propagate.cpp + cadical_veripbtracer.cpp + cadical_config.cpp + cadical_compact.cpp + cadical_score.cpp + cadical_factor.cpp + cadical_transred.cpp + cadical_report.cpp + cadical_signal.cpp + cadical_ema.cpp + cadical_file.cpp + cadical_occs.cpp + cadical_averages.cpp + cadical_rephase.cpp + cadical_idruptracer.cpp + cadical_lrattracer.cpp + cadical_walk.cpp + cadical_version.cpp + cadical_lucky.cpp + cadical_proof.cpp + cadical_terminal.cpp + cadical_external_propagate.cpp + cadical_definition.cpp + cadical_condition.cpp + cadical_tier.cpp + cadical_decompose.cpp + cadical_phases.cpp + cadical_ccadical.cpp + cadical_instantiate.cpp + cadical_shrink.cpp + cadical_block.cpp + cadical_analyze.cpp + cadical_elimfast.cpp + cadical_parse.cpp + cadical_queue.cpp + cadical_vivify.cpp + cadical_external.cpp + cadical_checker.cpp + cadical_clause.cpp + cadical_cover.cpp + cadical_resources.cpp + cadical_gates.cpp + cadical_sweep.cpp + cadical_arena.cpp + cadical_lookahead.cpp + cadical_backtrack.cpp + cadical_solution.cpp + cadical_subsume.cpp + cadicalTest.c + cadical_limit.cpp + cadical_collect.cpp + cadical_congruence.cpp + cadical_ipasir.cpp + cadical_stats.cpp + cadical_profile.cpp + cadical_extend.cpp + cadical_reduce.cpp + cadical_var.cpp + cadical_assume.cpp + cadical_unstable.cpp + cadical_internal.cpp + cadical_decide.cpp + cadical_deduplicate.cpp + cadical_format.cpp + cadical_util.cpp + cadical_frattracer.cpp + cadical_kitten.c + cadicalSolver.c + cadical_bins.cpp + cadical_probe.cpp + cadical_flip.cpp + cadical_solver.cpp + cadical_stable.cpp + cadical_elim.cpp + cadical_random.cpp + cadical_reap.cpp + cadical_message.cpp +) diff --git a/src/sat/cadical/cadical.hpp b/src/sat/cadical/cadical.hpp index c9ed413328..cba7aca0c3 100644 --- a/src/sat/cadical/cadical.hpp +++ b/src/sat/cadical/cadical.hpp @@ -486,8 +486,8 @@ class Solver { // Returns // - // 0 = UNKNOWN (unit propagation did not lead to a conflict nor to a - // complete assignment, or limit reached or interrupted + // 0 = UNKNOWN (unit propagation did not lead to a conflict nor to a + // complete assignment, or limit reached or interrupted // through 'terminate') // 10 = SATISFIABLE // 20 = UNSATISFIABLE @@ -1083,6 +1083,7 @@ class Solver { #ifndef PRINTF_FORMAT #ifdef __MINGW32__ +#undef __USE_MINGW_ANSI_STDIO #define __USE_MINGW_ANSI_STDIO 1 #define PRINTF_FORMAT __MINGW_PRINTF_FORMAT #else diff --git a/src/sat/cadical/cadical_congruence.cpp b/src/sat/cadical/cadical_congruence.cpp index 8fbceee24e..14a64e6636 100644 --- a/src/sat/cadical/cadical_congruence.cpp +++ b/src/sat/cadical/cadical_congruence.cpp @@ -1215,7 +1215,7 @@ void Closure::learn_congruence_unit_falsifies_lrat_chain ( LOG (proof_chain, "produced lrat chain so far"); } } - CADICAL_assert (!proof_chain.empty ()); + CADICAL_assert (!proof_chain.empty ()); } else { LOG ("degenerated AND gate with conflict without LHS"); for (const auto &litId : g->pos_lhs_ids) { @@ -1735,9 +1735,9 @@ bool Closure::merge_literals_lrat ( internal->lrat_chain.push_back ( internal->unit_id (val_smaller < 0 ? -smaller : smaller)); internal->lrat_chain.push_back ( - internal->unit_id (val_larger < 0 ? -larger : larger)); + internal->unit_id (val_larger < 0 ? -larger : larger)); for (auto id : (val_smaller < 0 ? *smaller_chain : *larger_chain)) { - internal->lrat_chain.push_back(id); + internal->lrat_chain.push_back(id); } } internal->learn_empty_clause (); @@ -2443,7 +2443,7 @@ void Closure::update_and_gate_build_lrat_chain ( for (auto &litId : h->pos_lhs_ids) { if (litId.current_lit == g->lhs) { CADICAL_assert (extra_reasons_ulit.empty ()); - CADICAL_assert (litId.clause); + CADICAL_assert (litId.clause); LOG (litId.clause, "binary clause to push into the reason"); litId.clause = produce_rewritten_clause_lrat (litId.clause, h->lhs, remove_units); @@ -2473,7 +2473,7 @@ void Closure::update_and_gate_build_lrat_chain ( // one direction: the binary clause already exists for (auto &litId : other->pos_lhs_ids) { if (litId.current_lit == tauto->lhs) { - CADICAL_assert (litId.clause); + CADICAL_assert (litId.clause); CADICAL_assert (extra_reasons_tauto.empty ()); LOG (litId.clause, "binary clause to push into the reason"); litId.clause = produce_rewritten_clause_lrat ( @@ -2493,12 +2493,12 @@ void Closure::update_and_gate_build_lrat_chain ( litId.current_lit, tauto->lhs); if (litId.current_lit != tauto->lhs) { LOG (litId.clause, "binary clause to push into the reason"); - CADICAL_assert (litId.clause); + CADICAL_assert (litId.clause); litId.clause = produce_rewritten_clause_lrat ( litId.clause, tauto->lhs, remove_units); if (!litId.clause) // degenerated but does not know yet - continue; - CADICAL_assert (litId.clause); + continue; + CADICAL_assert (litId.clause); extra_reasons_other.push_back (litId.clause->id); } tauto->pos_lhs_ids.erase (std::remove_if (begin (tauto->pos_lhs_ids), @@ -4880,10 +4880,10 @@ void Closure::reset_extraction () { const size_t size = watchers.size (); size_t j = 0; for (size_t i = 0; i != size; ++i) { - const auto w = watchers[i]; - watchers[j] = watchers[i]; - if (!w.clause->garbage) - ++j; + const auto w = watchers[i]; + watchers[j] = watchers[i]; + if (!w.clause->garbage) + ++j; } watchers.resize(j); } @@ -5730,7 +5730,7 @@ void Closure::rewrite_ite_gate (Gate *g, int dst, int src) { lrat_chain = reasons_unit; learn_congruence_unit (cond, true); if (then_lit != lhs) { - LOG ("special case, learning %d",cond == -lhs ? -then_lit : then_lit); + LOG ("special case, learning %d",cond == -lhs ? -then_lit : then_lit); if (internal->lrat) lrat_chain = reasons_implication; learn_congruence_unit (cond == -lhs ? -then_lit : then_lit, false, true); @@ -5981,7 +5981,7 @@ void Closure::rewrite_ite_gate (Gate *g, int dst, int src) { #endif } else { CADICAL_assert (false); -#ifdef WIN32 +#if defined(WIN32) && !defined(__MINGW32__) __assume(false); #else __builtin_unreachable (); @@ -6036,7 +6036,7 @@ void Closure::rewrite_ite_gate (Gate *g, int dst, int src) { } else { LOG (g, "rewritten"); if (internal->lrat) - update_ite_flags (g), check_correct_ite_flags(g); + update_ite_flags (g), check_correct_ite_flags(g); CADICAL_assert (rhs[0] != rhs[1]); CADICAL_assert (rhs[0] != rhs[2]); CADICAL_assert (rhs[1] != rhs[2]); @@ -6053,7 +6053,7 @@ void Closure::rewrite_ite_gate (Gate *g, int dst, int src) { g->lhs = -lhs; check_ite_lrat_reasons (g); if (internal->lrat) - check_correct_ite_flags (g); + check_correct_ite_flags (g); if (h) { garbage = true; check_ite_gate_implied (g); @@ -6695,7 +6695,7 @@ void Closure::add_ite_matching_proof_chain ( unsimplified.clear (); return; } - + LOG ("normal path"); CADICAL_assert (!internal->lrat || degenerated_g_then || (g_then_id && g_neg_then_id)); diff --git a/src/sat/cadical/cadical_decompose.cpp b/src/sat/cadical/cadical_decompose.cpp index 9081321b4b..133cc0e811 100644 --- a/src/sat/cadical/cadical_decompose.cpp +++ b/src/sat/cadical/cadical_decompose.cpp @@ -712,8 +712,8 @@ bool Internal::decompose_round () { mark_substituted (idx); } - reprs_delete.free (); - dfs_delete.free (); + reprs_delete._free (); + dfs_delete._free (); erase_vector (dfs_chains); if (substituted) diff --git a/src/sat/cadical/cadical_external.cpp b/src/sat/cadical/cadical_external.cpp index 67d1f918d8..b9f225bab3 100644 --- a/src/sat/cadical/cadical_external.cpp +++ b/src/sat/cadical/cadical_external.cpp @@ -858,7 +858,7 @@ void External::check_failing () { int res = checker->solve (); if (res != 20) FATAL ("failed assumptions do not form a core"); - delete_checker.free (); + delete_checker._free (); VERBOSE (1, "checked that %zd failing assumptions form a core", assumptions.size ()); } diff --git a/src/sat/cadical/cadical_file.cpp b/src/sat/cadical/cadical_file.cpp index 98f19f752d..e96ea64a31 100644 --- a/src/sat/cadical/cadical_file.cpp +++ b/src/sat/cadical/cadical_file.cpp @@ -27,8 +27,8 @@ extern "C" { #define R_OK 4 #define W_OK 2 #define S_IFIFO _S_IFIFO -#define S_ISFIFO(mode) (((mode) & S_IFMT) == S_IFIFO) -#define S_ISDIR(mode) (((mode) & S_IFMT) == S_IFDIR) +#define S_ISFIFO(mode) (((mode) & S_IFMT) == S_IFIFO) +#define S_ISDIR(mode) (((mode) & S_IFMT) == S_IFDIR) #else diff --git a/src/sat/cadical/cadical_vivify.cpp b/src/sat/cadical/cadical_vivify.cpp index 8d99c29323..5ec6401cff 100644 --- a/src/sat/cadical/cadical_vivify.cpp +++ b/src/sat/cadical/cadical_vivify.cpp @@ -1501,7 +1501,7 @@ inline std::vector ¤t_refs_schedule (Vivifier &vivifier) { return vivifier.refs_schedule_irred; break; } -#ifdef WIN32 +#if defined(WIN32) && !defined(__MINGW32__) __assume(false); #else __builtin_unreachable (); @@ -1523,7 +1523,7 @@ inline std::vector ¤t_schedule (Vivifier &vivifier) { return vivifier.schedule_irred; break; } -#ifdef WIN32 +#if defined(WIN32) && !defined(__MINGW32__) __assume(false); #else __builtin_unreachable (); diff --git a/src/sat/cadical/inttypes.hpp b/src/sat/cadical/inttypes.hpp index 2f7cb74a4d..ff4d722785 100644 --- a/src/sat/cadical/inttypes.hpp +++ b/src/sat/cadical/inttypes.hpp @@ -18,6 +18,7 @@ #ifndef PRINTF_FORMAT #ifdef __MINGW32__ +#undef __USE_MINGW_ANSI_STDIO #define __USE_MINGW_ANSI_STDIO 1 #define PRINTF_FORMAT __MINGW_PRINTF_FORMAT #else diff --git a/src/sat/cadical/util.hpp b/src/sat/cadical/util.hpp index 3882c6ede8..4533461ac5 100644 --- a/src/sat/cadical/util.hpp +++ b/src/sat/cadical/util.hpp @@ -127,7 +127,7 @@ template struct DeferDeleteArray { DeferDeleteArray (T *t) : data (t) {} ~DeferDeleteArray () { delete[] data; } void release () { data = nullptr; } - void free () { + void _free () { delete[] data; data = nullptr; } @@ -138,7 +138,7 @@ template struct DeferDeletePtr { DeferDeletePtr (T *t) : data (t) {} ~DeferDeletePtr () { delete data; } void release () { data = nullptr; } - void free () { + void _free () { delete data; data = nullptr; } diff --git a/tox.ini b/tox.ini index a26f31b7de..fe931bfa77 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,ctestwin,cclean +envlist = abc,demo,soname,tests,lint,base,libs,clang,ctest,grind,ctestwin,cclean,clean skip_missing_interpreters = true skipsdist = true @@ -40,6 +40,21 @@ passenv = envdir = {toxinidir}/.env skip_install = true +description = + abc: Makefile build of abc binary and static library + demo: Makeflie build of demo app (requires CC, CXX set in environment or on cmd line) + soname: Makefile build with lib .so name and version + tests: Makefile test target + lint: Run cpplint on base/main and lib/ dirs + base: CMake shared libs with LTO and external/system googletest + libs: CMake shared libs with LTO and vendored googletest + clang: CMake with clang source-based coverage + ctest: CMake Ninja default with namespace=xxxx and vendored googletest + grind: Run valgrind memory checks after CMake Debug build + ctestwin: Ctest with Windows default generator and related options + cclean: Clean cmake build cruft + clean: Clean Makefile build cruft + setenv = {abc,tests}: {[base]setenv} {base,libs,clang,ctest,ctestwin}: {[base]setenv} From fd49ebaf6462b45275f35ebb9bad24d7e9093ccd Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 24 Mar 2025 22:10:48 -0700 Subject: [PATCH 34/35] chg: dev: post-rebase (re)generate cmake files Signed-off-by: Stephen L Arnold --- src/aig/aig/CMakeLists.txt | 44 +++---- src/aig/gia/CMakeLists.txt | 196 +++++++++++++++---------------- src/aig/hop/CMakeLists.txt | 14 +-- src/aig/ioa/CMakeLists.txt | 2 +- src/aig/ivy/CMakeLists.txt | 30 ++--- src/aig/saig/CMakeLists.txt | 40 +++---- src/base/abc/CMakeLists.txt | 32 ++--- src/base/abci/CMakeLists.txt | 124 +++++++++---------- src/base/acb/CMakeLists.txt | 10 +- src/base/bac/CMakeLists.txt | 18 +-- src/base/cba/CMakeLists.txt | 10 +- src/base/cmd/CMakeLists.txt | 10 +- src/base/exor/CMakeLists.txt | 6 +- src/base/io/CMakeLists.txt | 46 ++++---- src/base/pla/CMakeLists.txt | 8 +- src/base/ver/CMakeLists.txt | 4 +- src/base/wlc/CMakeLists.txt | 24 ++-- src/base/wln/CMakeLists.txt | 14 +-- src/bdd/bbr/CMakeLists.txt | 2 +- src/bdd/cudd/CMakeLists.txt | 92 +++++++-------- src/bdd/dsd/CMakeLists.txt | 8 +- src/bdd/extrab/CMakeLists.txt | 10 +- src/bdd/llb/CMakeLists.txt | 26 ++-- src/bdd/mtr/CMakeLists.txt | 2 +- src/bdd/reo/CMakeLists.txt | 10 +- src/bool/bdc/CMakeLists.txt | 2 +- src/bool/dec/CMakeLists.txt | 4 +- src/bool/kit/CMakeLists.txt | 12 +- src/bool/lucky/CMakeLists.txt | 6 +- src/bool/rsb/CMakeLists.txt | 2 +- src/map/amap/CMakeLists.txt | 18 +-- src/map/cov/CMakeLists.txt | 8 +- src/map/fpga/CMakeLists.txt | 16 +-- src/map/if/CMakeLists.txt | 38 +++--- src/map/mapper/CMakeLists.txt | 20 ++-- src/map/mio/CMakeLists.txt | 6 +- src/map/mpm/CMakeLists.txt | 16 +-- src/map/scl/CMakeLists.txt | 14 +-- src/map/super/CMakeLists.txt | 2 +- src/misc/bzlib/CMakeLists.txt | 8 +- src/misc/espresso/CMakeLists.txt | 60 +++++----- src/misc/extra/CMakeLists.txt | 28 ++--- src/misc/mvc/CMakeLists.txt | 22 ++-- src/misc/tim/CMakeLists.txt | 4 +- src/misc/util/CMakeLists.txt | 14 +-- src/misc/zlib/CMakeLists.txt | 18 +-- src/opt/cgt/CMakeLists.txt | 6 +- src/opt/csw/CMakeLists.txt | 4 +- src/opt/cut/CMakeLists.txt | 12 +- src/opt/dar/CMakeLists.txt | 10 +- src/opt/dau/CMakeLists.txt | 12 +- src/opt/eslim/CMakeLists.txt | 2 +- src/opt/fret/CMakeLists.txt | 4 +- src/opt/fsim/CMakeLists.txt | 8 +- src/opt/fxch/CMakeLists.txt | 6 +- src/opt/fxu/CMakeLists.txt | 14 +-- src/opt/lpk/CMakeLists.txt | 16 +-- src/opt/mfs/CMakeLists.txt | 6 +- src/opt/nwk/CMakeLists.txt | 18 +-- src/opt/rar/CMakeLists.txt | 2 +- src/opt/res/CMakeLists.txt | 8 +- src/opt/ret/CMakeLists.txt | 4 +- src/opt/rwr/CMakeLists.txt | 8 +- src/opt/rwt/CMakeLists.txt | 4 +- src/opt/sbd/CMakeLists.txt | 10 +- src/opt/sfm/CMakeLists.txt | 8 +- src/opt/sim/CMakeLists.txt | 8 +- src/phys/place/CMakeLists.txt | 12 +- src/proof/abs/CMakeLists.txt | 20 ++-- src/proof/acec/CMakeLists.txt | 28 ++--- src/proof/cec/CMakeLists.txt | 28 ++--- src/proof/dch/CMakeLists.txt | 10 +- src/proof/fra/CMakeLists.txt | 22 ++-- src/proof/fraig/CMakeLists.txt | 14 +-- src/proof/int/CMakeLists.txt | 12 +- src/proof/int2/CMakeLists.txt | 6 +- src/proof/live/CMakeLists.txt | 8 +- src/proof/pdr/CMakeLists.txt | 12 +- src/proof/ssc/CMakeLists.txt | 4 +- src/proof/ssw/CMakeLists.txt | 28 ++--- src/sat/bmc/CMakeLists.txt | 48 ++++---- src/sat/bsat/CMakeLists.txt | 18 +-- src/sat/bsat2/CMakeLists.txt | 4 +- src/sat/cadical/CMakeLists.txt | 146 +++++++++++------------ src/sat/cnf/CMakeLists.txt | 10 +- src/sat/glucose/CMakeLists.txt | 4 +- src/sat/glucose2/CMakeLists.txt | 6 +- src/sat/kissat/CMakeLists.txt | 154 ++++++++++++------------ src/sat/msat/CMakeLists.txt | 16 +-- src/sat/satoko/CMakeLists.txt | 4 +- 90 files changed, 942 insertions(+), 942 deletions(-) diff --git a/src/aig/aig/CMakeLists.txt b/src/aig/aig/CMakeLists.txt index 902a762954..78ace8c34d 100644 --- a/src/aig/aig/CMakeLists.txt +++ b/src/aig/aig/CMakeLists.txt @@ -1,35 +1,35 @@ abc_libabc_add_sources( NAME aig_aig SOURCES - aigTable.c + aigInter.c aigJust.c - aigOper.c - aigScl.c - aigDfs.c - aigPart.c - aigShow.c - aigFanout.c - aigPartReg.c - aigWin.c + aigUtil.c + aigRet.c aigObj.c - aigCanon.c - aigTiming.c - aigOrder.c aigRepr.c - aigMem.c + aigOrder.c + aigPartReg.c aigPack.c - aigCheck.c - aigCuts.c + aigFanout.c + aigTiming.c + aigCanon.c aigTruth.c aigMan.c - aigInter.c - aigSplit.c + aigCheck.c + aigTsim.c + aigOper.c aigFrames.c - aigUtil.c - aigRetF.c - aigPartSat.c + aigTable.c + aigMem.c + aigShow.c + aigPart.c + aigScl.c aigDup.c - aigTsim.c + aigPartSat.c + aigWin.c + aigDfs.c + aigSplit.c aigMffc.c - aigRet.c + aigCuts.c + aigRetF.c ) diff --git a/src/aig/gia/CMakeLists.txt b/src/aig/gia/CMakeLists.txt index 4b56918def..ed09325059 100644 --- a/src/aig/gia/CMakeLists.txt +++ b/src/aig/gia/CMakeLists.txt @@ -1,120 +1,120 @@ abc_libabc_add_sources( NAME aig_gia SOURCES - giaSupp.c - giaCSat.c - giaIso3.c - giaIff.c - giaCTas.c - giaSatLut.c - giaExist.c - giaEra.c - giaStr.c - giaResub.c - giaBalMap.c - giaTruth.c + giaMem.c + giaMini.c + giaMinLut2.c + giaReshape2.c + giaOf.c + giaSat3.c + giaRex.c + giaIiff.c giaPat2.c - giaMinLut.c - giaBalAig.c - giaTransduction.cpp - giaSif.c - giaRetime.c - giaCex.c - giaTsim.c - giaSweeper.c - giaCSatOld.c - giaFrames.c + giaResub3.c + giaStoch.c + giaSatLE.c + giaExist.c giaDfs.c - giaGig.c - giaSatoko.c - giaAiger.c - giaBalLut.c - giaResub6.c - giaAig.c - giaUnate.c - giaEdge.c - giaSimBase.c - giaMuxes.c + giaClp.c giaResub2.c - giaShrink7.c - giaEmbed.c - giaScl.c - giaSatMap.c - giaHash.c giaShrink.c - giaSplit.c - giaTim.c - giaCone.c - giaUtil.c - giaCut.c + giaCCof.c + giaPat.c + giaSim.c + giaSwitch.c + giaShrink6.c + giaSupMin.c + giaCSat.c giaSweep.c - giaTranStoch.c - giaPack.c + giaStg.c + giaCSatOld.c + giaSort.c + giaCex.c + giaCSatP.c + giaIso.c + giaCof.c + giaReshape1.c + giaSatEdge.c + giaSatMap.c + giaTtopt.cpp giaMulFind.c - giaLf.c - giaGlitch.c + giaIff.c + giaBalMap.c + giaResub.c + giaSif.c + giaBalAig.c + giaFanout.c giaMfs.c - giaNf.c - giaForce.c - giaClp.c - giaAgi.c - giaMf.c - giaCof.c - giaPf.c - giaMini.c - giaSatLE.c - giaRex.c - giaFx.c + giaUtil.c + giaTranStoch.c + giaGlitch.c + giaTruth.c + giaEra.c + giaLf.c giaMan.c - giaCSat3.c - giaFront.c + giaCSat2.c + giaTransduction.cpp + giaScript.c + giaQbf.c giaShow.c + giaAig.c + gia.c + giaEsop.c + giaEnable.c + giaBound.c + giaPack.c + giaBidec.c + giaBalLut.c + giaSimBase.c giaDup.c - giaTis.c - giaResub3.c - giaReshape1.c - giaIso.c + giaEmbed.c + giaNf.c + giaIso3.c + giaTim.c giaEra2.c + giaEdge.c + giaCSat3.c + giaPf.c + giaFalse.c + giaAiger.c + giaSupps.c giaIso2.c - giaCCof.c - giaSim2.c + giaUnate.c giaSatSyn.c - giaDeep.c - giaSim.c - giaSat3.c - giaBound.c - giaSwitch.c - giaFanout.c - giaQbf.c + giaFx.c + giaSupp.c + giaTsim.c + giaStr.c + giaIf.c + giaCut.c + giaCone.c + giaCTas.c + giaMinLut.c + giaMuxes.c + giaMf.c giaEquiv.c + giaSplit.c + giaSweeper.c + giaRrr.cpp + giaShrink7.c + giaDecs.c + giaAgi.c + giaFront.c + giaDeep.c + giaSatoko.c + giaJf.c + giaForce.c + giaFrames.c + giaGig.c + giaHash.c giaSpeedup.c - giaShrink6.c - gia.c - giaMem.c - giaBidec.c - giaMinLut2.c - giaPat.c - giaStg.c - giaReshape2.c - giaSupps.c giaGen.c - giaRrr.cpp - giaOf.c - giaSupMin.c + giaSatLut.c + giaRetime.c + giaSim2.c giaKf.c - giaDecs.c - giaEsop.c + giaTis.c giaAigerExt.c - giaSort.c - giaFalse.c - giaCSatP.c - giaIiff.c - giaTtopt.cpp - giaStoch.c - giaCSat2.c - giaScript.c - giaSatEdge.c - giaEnable.c - giaIf.c - giaJf.c + giaResub6.c + giaScl.c ) diff --git a/src/aig/hop/CMakeLists.txt b/src/aig/hop/CMakeLists.txt index ae6aaa0d22..47917ada77 100644 --- a/src/aig/hop/CMakeLists.txt +++ b/src/aig/hop/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME aig_hop SOURCES - hopBalance.c - hopMan.c - hopUtil.c - hopMem.c - hopOper.c hopDfs.c - hopCheck.c - hopObj.c hopTable.c hopTruth.c + hopMem.c + hopCheck.c + hopBalance.c + hopMan.c + hopObj.c + hopOper.c + hopUtil.c ) diff --git a/src/aig/ioa/CMakeLists.txt b/src/aig/ioa/CMakeLists.txt index 3cb61395d2..3f210b2498 100644 --- a/src/aig/ioa/CMakeLists.txt +++ b/src/aig/ioa/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME aig_ioa SOURCES + ioaReadAig.c ioaWriteAig.c ioaUtil.c - ioaReadAig.c ) diff --git a/src/aig/ivy/CMakeLists.txt b/src/aig/ivy/CMakeLists.txt index 890e10cb42..e32fc42273 100644 --- a/src/aig/ivy/CMakeLists.txt +++ b/src/aig/ivy/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME aig_ivy SOURCES + ivyShow.c + ivyCut.c + ivyResyn.c + ivyCheck.c + ivyBalance.c + ivyFraig.c ivyUtil.c - ivyMan.c - ivyDfs.c - ivyMem.c - ivySeq.c - ivyCutTrav.c ivyObj.c + ivySeq.c ivyCanon.c - ivyBalance.c + ivyMan.c + ivyOper.c ivyHaig.c - ivyShow.c + ivyTable.c ivyDsd.c - ivyRwr.c - ivyCut.c + ivyFanout.c ivyMulti.c - ivyFraig.c - ivyResyn.c ivyFastMap.c - ivyFanout.c - ivyTable.c - ivyCheck.c - ivyOper.c + ivyCutTrav.c + ivyRwr.c + ivyDfs.c + ivyMem.c ) diff --git a/src/aig/saig/CMakeLists.txt b/src/aig/saig/CMakeLists.txt index 1a6d6825b5..06c0bfc8db 100644 --- a/src/aig/saig/CMakeLists.txt +++ b/src/aig/saig/CMakeLists.txt @@ -1,30 +1,30 @@ abc_libabc_add_sources( NAME aig_saig SOURCES - saigTempor.c + saigCone.c + saigIsoFast.c + saigOutDec.c + saigInd.c + saigSimFast.c saigConstr.c - saigStrSim.c - saigIoa.c - saigIsoSlow.c - saigIso.c + saigPhase.c saigRetMin.c saigTrans.c - saigDual.c - saigMiter.c - saigPhase.c + saigIoa.c + saigSimMv.c + saigStrSim.c + saigTempor.c + saigDup.c + saigSimSeq.c saigRetStep.c - saigOutDec.c - saigScl.c - saigSwitch.c - saigConstr2.c - saigCone.c - saigInd.c - saigWnd.c - saigSimFast.c + saigMiter.c saigSynch.c + saigDual.c + saigSwitch.c saigRetFwd.c - saigIsoFast.c - saigDup.c - saigSimMv.c - saigSimSeq.c + saigIsoSlow.c + saigWnd.c + saigScl.c + saigIso.c + saigConstr2.c ) diff --git a/src/base/abc/CMakeLists.txt b/src/base/abc/CMakeLists.txt index 844d997de2..eb01c56f74 100644 --- a/src/base/abc/CMakeLists.txt +++ b/src/base/abc/CMakeLists.txt @@ -1,27 +1,27 @@ abc_libabc_add_sources( NAME base_abc SOURCES - abcMinBase.c abcHieNew.c - abcAig.c - abcLib.c - abcFunc.c - abcNames.c - abcHieGia.c - abcNtk.c - abcNetlist.c - abcShow.c - abcBarBuf.c abcDfs.c + abcNtk.c + abcFanio.c + abcHieGia.c + abcMinBase.c abcCheck.c - abcBlifMv.c - abcFanOrder.c - abcObj.c abcLatch.c - abcSop.c abcHieCec.c + abcShow.c + abcAig.c + abcNames.c abcRefs.c - abcHie.c - abcFanio.c + abcNetlist.c + abcFunc.c abcUtil.c + abcLib.c + abcSop.c + abcObj.c + abcBlifMv.c + abcFanOrder.c + abcHie.c + abcBarBuf.c ) diff --git a/src/base/abci/CMakeLists.txt b/src/base/abci/CMakeLists.txt index 420cb182e0..0910dc2d88 100644 --- a/src/base/abci/CMakeLists.txt +++ b/src/base/abci/CMakeLists.txt @@ -1,81 +1,81 @@ abc_libabc_add_sources( NAME base_abci SOURCES - abcExtract.c - abcAttach.c - abcOdc.c - abcCollapse.c - abcNtbdd.c - abcDsd.c - abcUnreach.c - abcXsim.c - abcDar.c - abcDress.c - abcExact.c + abcCascade.c + abcCut.c abcReach.c - abcIfif.c - abc.c + abcIvy.c abcQbf.c - abcDec.c - abcDress3.c - abcScorr.c - abcBidec.c - abcCas.c + abc.c + abcExtract.c + abcGen.c + abcAuto.c abcBmc.c + abcHaig.c + abcFraig.c + abcDress3.c + abcTim.c + abcRec3.c + abcLut.c + abcMfs.c + abcVerify.c + abcNpnSave.c abcReconv.c - abcLog.c - abcMerge.c - abcEco.c - abcDetect.c - abcDress2.c - abcGen.c - abcResub.c - abcSense.c - abcBm.c + abcLutmin.c + abcSpeedup.c + abcUnate.c abcRr.c - abcQuant.c - abcHaig.c - abcBalance.c - abcPrint.c + abcSaucy.c + abcSat.c + abcIfMux.c + abcNpn.c + abcRpo.c + abcDebug.c + abcRenode.c + abcXsim.c + abcReorder.c + abcExact.c + abcOdc.c + abcDar.c + abcCas.c abcRewrite.c - abcAuto.c - abcSweep.c - abcMulti.c abcIf.c - abcLut.c + abcSweep.c + abcBidec.c + abcAttach.c abcRestruct.c - abcSymm.c + abcDsd.c + abcRefactor.c + abcFx.c abcPart.c - abcMini.c + abcDetect.c + abcDress2.c + abcRunGen.c + abcScorr.c + abcNtbdd.c + abcPrint.c abcProve.c - abcRenode.c - abcCascade.c - abcSaucy.c + abcBm.c + abcSymm.c + abcMulti.c + abcQuant.c + abcLog.c abcStrash.c - abcIvy.c - abcDebug.c - abcNpnSave.c - abcRunGen.c + abcMerge.c + abcEco.c + abcFxu.c + abcOrchestration.c + abcBalance.c + abcSense.c abcMap.c - abcCut.c - abcUnate.c + abcDress.c + abcIfif.c + abcCollapse.c + abcUnreach.c + abcMini.c abcMiter.c - abcLutmin.c + abcDec.c abcOrder.c - abcOrchestration.c - abcFxu.c - abcMfs.c - abcFraig.c - abcTim.c - abcIfMux.c - abcReorder.c - abcSpeedup.c - abcRpo.c - abcRec3.c - abcVerify.c - abcFx.c + abcResub.c abcTiming.c - abcRefactor.c - abcNpn.c - abcSat.c ) diff --git a/src/base/acb/CMakeLists.txt b/src/base/acb/CMakeLists.txt index 5dd0429f93..d12669d56a 100644 --- a/src/base/acb/CMakeLists.txt +++ b/src/base/acb/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME base_acb SOURCES - acbPush.c + acbCom.c acbFunc.c + acbMfs.c + acbSets.c + acbPush.c acbTest.c - acbCom.c - acbAbc.c acbAig.c acbUtil.c - acbMfs.c - acbSets.c + acbAbc.c ) diff --git a/src/base/bac/CMakeLists.txt b/src/base/bac/CMakeLists.txt index 8494cc7e99..3073db56c4 100644 --- a/src/base/bac/CMakeLists.txt +++ b/src/base/bac/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME base_bac SOURCES - bacReadBlif.c - bacPrsBuild.c - bacWriteSmt.c - bacWriteBlif.c + bacLib.c + bacPrsTrans.c bacPtr.c - bacBac.c - bacPtrAbc.c bacReadSmt.c bacNtk.c + bacBlast.c bacWriteVer.c + bacPrsBuild.c + bacWriteSmt.c bacReadVer.c - bacLib.c - bacPrsTrans.c - bacBlast.c bacCom.c + bacBac.c + bacPtrAbc.c + bacReadBlif.c + bacWriteBlif.c ) diff --git a/src/base/cba/CMakeLists.txt b/src/base/cba/CMakeLists.txt index 694f1a20b2..2d5aa506c2 100644 --- a/src/base/cba/CMakeLists.txt +++ b/src/base/cba/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME base_cba SOURCES - cbaNtk.c - cbaReadVer.c - cbaReadBlif.c - cbaCba.c + cbaBlast.c cbaWriteBlif.c + cbaCba.c cbaCom.c - cbaBlast.c + cbaReadVer.c + cbaNtk.c cbaWriteVer.c + cbaReadBlif.c ) diff --git a/src/base/cmd/CMakeLists.txt b/src/base/cmd/CMakeLists.txt index b423e48e0a..cf36a88fb6 100644 --- a/src/base/cmd/CMakeLists.txt +++ b/src/base/cmd/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME base_cmd SOURCES - cmd.c cmdHist.c - cmdLoad.c - cmdUtils.c - cmdStarter.c cmdAuto.c - cmdPlugin.c cmdAlias.c + cmdStarter.c cmdFlag.c + cmd.c + cmdLoad.c + cmdUtils.c + cmdPlugin.c cmdApi.c ) diff --git a/src/base/exor/CMakeLists.txt b/src/base/exor/CMakeLists.txt index cb02c515d6..151d021db6 100644 --- a/src/base/exor/CMakeLists.txt +++ b/src/base/exor/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME base_exor SOURCES + exor.c exorCubes.c + exorBits.c + exorUtil.c exorLink.c exorList.c - exor.c - exorUtil.c - exorBits.c ) diff --git a/src/base/io/CMakeLists.txt b/src/base/io/CMakeLists.txt index 80f16182ef..9c4219178e 100644 --- a/src/base/io/CMakeLists.txt +++ b/src/base/io/CMakeLists.txt @@ -1,37 +1,37 @@ abc_libabc_add_sources( NAME base_io SOURCES - ioWriteHMetis.c - ioReadBlifMv.c - ioWriteBblif.c ioReadBblif.c - io.c - ioWriteBook.c - ioUtil.c - ioJson.c + ioWriteList.c + ioReadBaf.c ioWriteBlifMv.c - ioWriteVerilog.c + ioReadDsd.c + ioWriteAiger.c + ioReadBlifMv.c + io.c ioWriteBlif.c + ioWriteBench.c + ioReadEqn.c ioReadBlif.c - ioReadDsd.c + ioWriteDot.c + ioWriteVerilog.c + ioWriteHMetis.c ioWriteEqn.c - ioWriteList.c - ioWriteBaf.c - ioReadEqn.c + ioWriteBook.c + ioWriteEdgelist.c ioReadVerilog.c - ioReadPla.c + ioWriteSmv.c + ioJson.c ioReadBench.c - ioReadAiger.c - ioReadBlifAig.c - ioReadEdif.c - ioWriteBench.c - ioWriteDot.c + ioUtil.c ioWritePla.c - ioWriteEdgelist.c - ioWriteSmv.c - ioWriteCnf.c - ioWriteAiger.c + ioReadBlifAig.c + ioWriteBblif.c ioReadPlaMo.c + ioReadAiger.c ioWriteGml.c - ioReadBaf.c + ioWriteCnf.c + ioReadEdif.c + ioReadPla.c + ioWriteBaf.c ) diff --git a/src/base/pla/CMakeLists.txt b/src/base/pla/CMakeLists.txt index 867a19c6a9..57fc27f528 100644 --- a/src/base/pla/CMakeLists.txt +++ b/src/base/pla/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME base_pla SOURCES + plaMan.c plaSimple.c - plaRead.c - plaMerge.c plaHash.c - plaWrite.c + plaMerge.c plaCom.c - plaMan.c + plaRead.c + plaWrite.c ) diff --git a/src/base/ver/CMakeLists.txt b/src/base/ver/CMakeLists.txt index 00a5a9df31..a1ccc153bc 100644 --- a/src/base/ver/CMakeLists.txt +++ b/src/base/ver/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME base_ver SOURCES - verFormula.c - verStream.c verParse.c verCore.c + verStream.c + verFormula.c ) diff --git a/src/base/wlc/CMakeLists.txt b/src/base/wlc/CMakeLists.txt index 6fcd44e0e7..6b674193b9 100644 --- a/src/base/wlc/CMakeLists.txt +++ b/src/base/wlc/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME base_wlc SOURCES + wlcAbc.c + wlcWriteVer.c + wlcNtk.c wlcCom.c + wlcNdr.c + wlcStdin.c wlcPth.c - wlcJson.c - wlcWriteVer.c - wlcWin.c wlcUif.c wlcSim.c - wlcAbc.c - wlcAbs2.c - wlcNtk.c - wlcReadSmt.c wlcBlast.c - wlcReadVer.c - wlcShow.c - wlcGraft.c + wlcReadSmt.c wlcAbs.c - wlcStdin.c - wlcNdr.c + wlcShow.c + wlcReadVer.c wlcMem.c + wlcGraft.c + wlcWin.c + wlcJson.c + wlcAbs2.c ) diff --git a/src/base/wln/CMakeLists.txt b/src/base/wln/CMakeLists.txt index fe8d18d8ea..c746c36a7e 100644 --- a/src/base/wln/CMakeLists.txt +++ b/src/base/wln/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME base_wln SOURCES + wlnBlast.c + wlnNdr.c + wlnMem.c wlnWriteVer.c + wlnRtl.c wln.c - wlnNtk.c - wlnNdr.c wlnObj.c - wlnCom.c - wlnGuide.c wlnRead.c + wlnCom.c wlnWlc.c - wlnMem.c - wlnBlast.c - wlnRtl.c + wlnNtk.c wlnRetime.c + wlnGuide.c ) diff --git a/src/bdd/bbr/CMakeLists.txt b/src/bdd/bbr/CMakeLists.txt index b1863602c2..95c8128eb1 100644 --- a/src/bdd/bbr/CMakeLists.txt +++ b/src/bdd/bbr/CMakeLists.txt @@ -3,6 +3,6 @@ abc_libabc_add_sources( SOURCES bbrImage.c bbrCex.c - bbrNtbdd.c bbrReach.c + bbrNtbdd.c ) diff --git a/src/bdd/cudd/CMakeLists.txt b/src/bdd/cudd/CMakeLists.txt index 4f7f18eecb..ba90876eec 100644 --- a/src/bdd/cudd/CMakeLists.txt +++ b/src/bdd/cudd/CMakeLists.txt @@ -1,65 +1,65 @@ abc_libabc_add_sources( NAME bdd_cudd SOURCES - cuddBddIte.c - cuddZddMisc.c - cuddSubsetSP.c - cuddExport.c - cuddLCache.c - cuddCache.c + cuddZddIsop.c cuddGroup.c - cuddInit.c - cuddZddReord.c + cuddAndAbs.c + cuddSubsetSP.c cuddAddAbs.c - cuddTable.c - cuddAddInv.c - cuddSubsetHB.c + cuddLinear.c + cuddZddLin.c + cuddAddNeg.c + cuddWindow.c + cuddBddIte.c + cuddAddWalsh.c + cuddGenetic.c cuddRef.c - cuddAddFind.c - cuddZddIsop.c - cuddZddSetop.c - cuddLiteral.c - cuddApprox.c cuddUtil.c - cuddReorder.c - cuddWindow.c - cuddAddApply.c - cuddGenCof.c - cuddSolve.c - cuddZddFuncs.c + cuddSubsetHB.c + cuddLCache.c cuddMatMult.c + cuddZddPort.c + cuddZddReord.c + cuddInteract.c + cuddZddSetop.c + cuddExact.c cuddCheck.c + cuddAddInv.c + cuddInit.c + cuddPriority.c cuddApa.c - cuddZddPort.c - cuddHarwell.c + cuddAPI.c + cuddBddCorr.c + cuddAddFind.c + cuddEssent.c + cuddSat.c + cuddLiteral.c + cuddBridge.c + cuddRead.c cuddSymmetry.c - cuddAnneal.c + cuddApprox.c + cuddSolve.c cuddZddGroup.c - cuddZddLin.c - cuddInteract.c cuddBddAbs.c - cuddBridge.c - cuddCof.c + cuddTable.c + cuddReorder.c cuddZddCount.c - cuddSplit.c - cuddEssent.c - cuddRead.c - cuddBddCorr.c - cuddLinear.c - cuddExact.c - cuddAddNeg.c + cuddCompose.c + cuddSign.c cuddLevelQ.c - cuddGenetic.c - cuddAddIte.c - cuddPriority.c - cuddSat.c - cuddZddSymm.c cuddDecomp.c - cuddAddWalsh.c - cuddCompose.c + cuddZddMisc.c + cuddHarwell.c + cuddZddSymm.c + cuddSplit.c + cuddCof.c + cuddAddApply.c + cuddCache.c + cuddAddIte.c + cuddZddFuncs.c cuddZddUtil.c - cuddAndAbs.c - cuddSign.c - cuddAPI.c cuddClip.c + cuddExport.c + cuddAnneal.c + cuddGenCof.c ) diff --git a/src/bdd/dsd/CMakeLists.txt b/src/bdd/dsd/CMakeLists.txt index 2ab912109f..1954d2f4ca 100644 --- a/src/bdd/dsd/CMakeLists.txt +++ b/src/bdd/dsd/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME bdd_dsd SOURCES - dsdMan.c - dsdTree.c - dsdLocal.c dsdCheck.c - dsdProc.c dsdApi.c + dsdTree.c + dsdMan.c + dsdProc.c + dsdLocal.c ) diff --git a/src/bdd/extrab/CMakeLists.txt b/src/bdd/extrab/CMakeLists.txt index 0aaa0f32c2..e9425d920a 100644 --- a/src/bdd/extrab/CMakeLists.txt +++ b/src/bdd/extrab/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME bdd_extrab SOURCES - extraBddUnate.c extraBddMaxMin.c - extraBddAuto.c + extraBddMisc.c + extraBddTime.c extraBddSymm.c - extraBddImage.c extraBddThresh.c + extraBddUnate.c extraBddKmap.c - extraBddMisc.c extraBddCas.c - extraBddTime.c extraBddSet.c + extraBddAuto.c + extraBddImage.c ) diff --git a/src/bdd/llb/CMakeLists.txt b/src/bdd/llb/CMakeLists.txt index 8d0ed0fe0d..ce4a37cad1 100644 --- a/src/bdd/llb/CMakeLists.txt +++ b/src/bdd/llb/CMakeLists.txt @@ -1,26 +1,26 @@ abc_libabc_add_sources( NAME bdd_llb SOURCES - llb2Image.c llb1Reach.c - llb3Nonlin.c - llb4Sweep.c - llb2Bad.c - llb4Image.c + llb2Dump.c llb3Image.c + llb2Driver.c llb4Cex.c - llb1Hint.c + llb1Cluster.c llb1Group.c llb2Core.c - llb1Cluster.c - llb1Constr.c - llb1Pivot.c - llb1Man.c + llb4Sweep.c + llb3Nonlin.c + llb2Image.c llb4Nonlin.c + llb1Man.c + llb1Core.c + llb1Pivot.c llb2Flow.c llb1Sched.c - llb2Driver.c - llb1Core.c + llb4Image.c llb1Matrix.c - llb2Dump.c + llb1Hint.c + llb2Bad.c + llb1Constr.c ) diff --git a/src/bdd/mtr/CMakeLists.txt b/src/bdd/mtr/CMakeLists.txt index cf84703ef8..634875995a 100644 --- a/src/bdd/mtr/CMakeLists.txt +++ b/src/bdd/mtr/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bdd_mtr SOURCES - mtrGroup.c mtrBasic.c + mtrGroup.c ) diff --git a/src/bdd/reo/CMakeLists.txt b/src/bdd/reo/CMakeLists.txt index 8cc6d12660..d1ce74ce63 100644 --- a/src/bdd/reo/CMakeLists.txt +++ b/src/bdd/reo/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME bdd_reo SOURCES - reoProfile.c reoTransfer.c - reoUnits.c - reoApi.c - reoShuffle.c - reoCore.c reoSwap.c + reoShuffle.c reoSift.c + reoApi.c + reoProfile.c + reoUnits.c + reoCore.c ) diff --git a/src/bool/bdc/CMakeLists.txt b/src/bool/bdc/CMakeLists.txt index 32dd14d87c..77b3c7d009 100644 --- a/src/bool/bdc/CMakeLists.txt +++ b/src/bool/bdc/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME bool_bdc SOURCES + bdcSpfd.c bdcCore.c bdcDec.c bdcTable.c - bdcSpfd.c ) diff --git a/src/bool/dec/CMakeLists.txt b/src/bool/dec/CMakeLists.txt index 563637f8f8..31b6142968 100644 --- a/src/bool/dec/CMakeLists.txt +++ b/src/bool/dec/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME bool_dec SOURCES - decMan.c + decPrint.c decUtil.c decFactor.c decAbc.c - decPrint.c + decMan.c ) diff --git a/src/bool/kit/CMakeLists.txt b/src/bool/kit/CMakeLists.txt index cb6d75e4be..46783c3a90 100644 --- a/src/bool/kit/CMakeLists.txt +++ b/src/bool/kit/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME bool_kit SOURCES - kitTruth.c - kitAig.c - kitPla.c kitSop.c cloud.c + kitHop.c + kitAig.c kitBdd.c + kitIsop.c kitGraph.c kitDsd.c - kitHop.c - kitFactor.c - kitIsop.c kitCloud.c + kitTruth.c + kitFactor.c + kitPla.c ) diff --git a/src/bool/lucky/CMakeLists.txt b/src/bool/lucky/CMakeLists.txt index 8c6e3e913b..f579c8cb70 100644 --- a/src/bool/lucky/CMakeLists.txt +++ b/src/bool/lucky/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME bool_lucky SOURCES - luckyRead.c luckySwapIJ.c + luckyRead.c + luckyFast16.c lucky.c - luckyFast6.c luckySwap.c + luckyFast6.c luckySimple.c - luckyFast16.c ) diff --git a/src/bool/rsb/CMakeLists.txt b/src/bool/rsb/CMakeLists.txt index 7c3157ada7..57bf6b8fa0 100644 --- a/src/bool/rsb/CMakeLists.txt +++ b/src/bool/rsb/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME bool_rsb SOURCES - rsbDec6.c rsbMan.c + rsbDec6.c ) diff --git a/src/map/amap/CMakeLists.txt b/src/map/amap/CMakeLists.txt index 0d3b8a1564..853c9ec00a 100644 --- a/src/map/amap/CMakeLists.txt +++ b/src/map/amap/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_amap SOURCES - amapLib.c - amapGraph.c - amapParse.c - amapPerm.c - amapMerge.c - amapMan.c amapLiberty.c - amapRead.c - amapCore.c - amapRule.c amapOutput.c + amapRule.c + amapCore.c + amapRead.c + amapGraph.c + amapParse.c + amapLib.c amapUniq.c + amapPerm.c amapMatch.c + amapMan.c + amapMerge.c ) diff --git a/src/map/cov/CMakeLists.txt b/src/map/cov/CMakeLists.txt index aad831cdab..323f897e9e 100644 --- a/src/map/cov/CMakeLists.txt +++ b/src/map/cov/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME map_cov SOURCES - covMinMan.c - covCore.c + covMinEsop.c covMinUtil.c covMinSop.c - covBuild.c - covMinEsop.c + covMinMan.c + covCore.c covMan.c + covBuild.c ) diff --git a/src/map/fpga/CMakeLists.txt b/src/map/fpga/CMakeLists.txt index 1699fa799e..939645a323 100644 --- a/src/map/fpga/CMakeLists.txt +++ b/src/map/fpga/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME map_fpga SOURCES - fpgaCutUtils.c fpgaCreate.c + fpgaMatch.c fpgaUtils.c - fpgaLib.c - fpgaVec.c - fpgaTruth.c - fpgaTime.c - fpgaSwitch.c + fpgaFanout.c fpgaCut.c - fpgaMatch.c + fpgaSwitch.c + fpgaTruth.c + fpgaLib.c fpga.c - fpgaFanout.c + fpgaCutUtils.c fpgaCore.c + fpgaVec.c + fpgaTime.c ) diff --git a/src/map/if/CMakeLists.txt b/src/map/if/CMakeLists.txt index 442376309f..62ef5b6ba1 100644 --- a/src/map/if/CMakeLists.txt +++ b/src/map/if/CMakeLists.txt @@ -1,31 +1,31 @@ abc_libabc_add_sources( NAME map_if SOURCES - ifSat.c - ifDelay.c - ifReduce.c - ifCom.c - ifLibLut.c - ifDec07.c - ifCut.c ifMatch2.c - ifTest.c - ifDec16.c - ifDec66.c - ifMan.c + ifCom.c + ifSelect.c ifLibBox.c ifDsd.c - ifDec10.c + ifReduce.c + ifDec16.c ifTruth.c + ifSat.c + ifSeq.c + ifTest.c + ifUtil.c + ifDelay.c ifData2.c + ifTune.c + ifDec10.c + ifLibLut.c + ifCore.c + ifDec66.c ifCache.c - ifSeq.c - ifDec08.c - ifSelect.c - ifTime.c ifMap.c - ifCore.c ifDec75.c - ifTune.c - ifUtil.c + ifCut.c + ifTime.c + ifMan.c + ifDec07.c + ifDec08.c ) diff --git a/src/map/mapper/CMakeLists.txt b/src/map/mapper/CMakeLists.txt index 18ceff8628..fcec6bb23a 100644 --- a/src/map/mapper/CMakeLists.txt +++ b/src/map/mapper/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME map_mapper SOURCES - mapperSwitch.c - mapperCanon.c - mapperCore.c + mapperTime.c + mapperTruth.c mapperCut.c mapperSuper.c mapperTree.c + mapperUtils.c + mapperLib.c + mapperCanon.c + mapperTable.c mapperVec.c + mapperMatch.c mapperRefs.c - mapperLib.c - mapperTruth.c - mapper.c mapperCutUtils.c - mapperTime.c - mapperMatch.c - mapperTable.c - mapperUtils.c + mapperCore.c + mapperSwitch.c + mapper.c mapperCreate.c ) diff --git a/src/map/mio/CMakeLists.txt b/src/map/mio/CMakeLists.txt index c0a5156c79..95274db790 100644 --- a/src/map/mio/CMakeLists.txt +++ b/src/map/mio/CMakeLists.txt @@ -3,9 +3,9 @@ abc_libabc_add_sources( SOURCES mioApi.c mioParse.c - mioRead.c + mio.c + mioFunc.c mioSop.c mioUtils.c - mioFunc.c - mio.c + mioRead.c ) diff --git a/src/map/mpm/CMakeLists.txt b/src/map/mpm/CMakeLists.txt index b6bc6001d6..ebaaf9a602 100644 --- a/src/map/mpm/CMakeLists.txt +++ b/src/map/mpm/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_mpm SOURCES - mpmPre.c - mpmMap.c - mpmGates.c - mpmTruth.c - mpmMig.c + mpmLib.c mpmAbc.c - mpmDsd.c - mpmMan.c + mpmMig.c mpmUtil.c mpmCore.c - mpmLib.c + mpmDsd.c + mpmTruth.c + mpmMap.c + mpmPre.c + mpmGates.c + mpmMan.c ) diff --git a/src/map/scl/CMakeLists.txt b/src/map/scl/CMakeLists.txt index c52a750465..07b4e9d8f5 100644 --- a/src/map/scl/CMakeLists.txt +++ b/src/map/scl/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME map_scl SOURCES + sclBufSize.c + sclLoad.c + sclLibScl.c + sclUpsize.c + scl.c sclBuffer.c - sclDnsize.c - sclSize.c sclLibUtil.c sclUtil.c - sclLoad.c - sclBufSize.c sclLiberty.c - sclUpsize.c - sclLibScl.c - scl.c + sclSize.c + sclDnsize.c ) diff --git a/src/map/super/CMakeLists.txt b/src/map/super/CMakeLists.txt index f7192746fc..83d6098c20 100644 --- a/src/map/super/CMakeLists.txt +++ b/src/map/super/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME map_super SOURCES - superGate.c super.c + superGate.c superAnd.c ) diff --git a/src/misc/bzlib/CMakeLists.txt b/src/misc/bzlib/CMakeLists.txt index 06182a305a..314b892607 100644 --- a/src/misc/bzlib/CMakeLists.txt +++ b/src/misc/bzlib/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME misc_bzlib SOURCES - huffman.c decompress.c - compress.c - randtable.c + blocksort.c bzlib.c crctable.c - blocksort.c + compress.c + huffman.c + randtable.c ) diff --git a/src/misc/espresso/CMakeLists.txt b/src/misc/espresso/CMakeLists.txt index a107d8b092..668c400426 100644 --- a/src/misc/espresso/CMakeLists.txt +++ b/src/misc/espresso/CMakeLists.txt @@ -1,43 +1,43 @@ abc_libabc_add_sources( NAME misc_espresso SOURCES - hack.c - cvrout.c - cvrin.c - setc.c - primes.c - set.c + cols.c + reduce.c irred.c - sminterf.c - contain.c - globals.c - cvrmisc.c - mincov.c - sparse.c - espresso.c - cubehack.c - gasp.c + hack.c matrix.c + gasp.c + cubehack.c solution.c - cubestr.c - cvrm.c + setc.c + compl.c essen.c + exact.c + sparse.c part.c - verify.c - pair.c - reduce.c + mincov.c unate.c - compl.c - sharp.c - cofactor.c - cols.c + equiv.c + globals.c + gimpel.c + set.c + opo.c + sminterf.c + cvrout.c expand.c + primes.c + cvrin.c + map.c + verify.c indep.c - rows.c - gimpel.c - equiv.c dominate.c - exact.c - map.c - opo.c + cvrmisc.c + cvrm.c + rows.c + cubestr.c + pair.c + cofactor.c + espresso.c + contain.c + sharp.c ) diff --git a/src/misc/extra/CMakeLists.txt b/src/misc/extra/CMakeLists.txt index 67196e5991..61b8d99d4d 100644 --- a/src/misc/extra/CMakeLists.txt +++ b/src/misc/extra/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME misc_extra SOURCES - extraUtilPerm.c - extraUtilBitMatrix.c - extraUtilReader.c - extraUtilMemory.c extraUtilCfs.c - extraUtilFile.c - extraUtilSupp.c - extraUtilMacc.c - extraUtilTruth.c - extraUtilMult.c - extraUtilProgress.c - extraUtilEnum.c - extraUtilCanon.c extraUtilPath.c - extraUtilMisc.c - extraUtilGen.c extraUtilDsd.c + extraUtilMemory.c + extraUtilMacc.c extraUtilMaj.c + extraUtilMult.c + extraUtilTruth.c + extraUtilSupp.c + extraUtilBitMatrix.c + extraUtilCanon.c extraUtilCube.c + extraUtilPerm.c + extraUtilReader.c + extraUtilMisc.c + extraUtilProgress.c extraUtilUtil.c + extraUtilEnum.c + extraUtilGen.c + extraUtilFile.c ) diff --git a/src/misc/mvc/CMakeLists.txt b/src/misc/mvc/CMakeLists.txt index 76e54e031c..95e404c1b8 100644 --- a/src/misc/mvc/CMakeLists.txt +++ b/src/misc/mvc/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_mvc SOURCES - mvcApi.c - mvcDivide.c - mvcList.c - mvcCompare.c - mvcPrint.c - mvcOpBool.c - mvcSort.c - mvcOpAlg.c + mvcContain.c mvcCube.c - mvcMan.c + mvcUtils.c mvcCover.c mvcDivisor.c + mvcList.c + mvcApi.c mvcLits.c - mvcUtils.c - mvcContain.c + mvcMan.c + mvcCompare.c + mvcDivide.c + mvcPrint.c + mvcOpAlg.c + mvcSort.c + mvcOpBool.c ) diff --git a/src/misc/tim/CMakeLists.txt b/src/misc/tim/CMakeLists.txt index 1538b50007..ff1190ca70 100644 --- a/src/misc/tim/CMakeLists.txt +++ b/src/misc/tim/CMakeLists.txt @@ -2,8 +2,8 @@ abc_libabc_add_sources( NAME misc_tim SOURCES timTime.c - timDump.c - timTrav.c timBox.c + timTrav.c timMan.c + timDump.c ) diff --git a/src/misc/util/CMakeLists.txt b/src/misc/util/CMakeLists.txt index ab6ca1da2a..fac455db78 100644 --- a/src/misc/util/CMakeLists.txt +++ b/src/misc/util/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME misc_util SOURCES - utilIsop.c - utilFile.c - utilBSet.c - utilCex.c - utilSignal.c - utilPth.c utilSort.c - utilColor.c + utilBSet.c utilNam.c utilBridge.c + utilColor.c + utilCex.c + utilFile.c + utilIsop.c + utilPth.c + utilSignal.c ) diff --git a/src/misc/zlib/CMakeLists.txt b/src/misc/zlib/CMakeLists.txt index ae20c86b28..3d85c00f16 100644 --- a/src/misc/zlib/CMakeLists.txt +++ b/src/misc/zlib/CMakeLists.txt @@ -1,19 +1,19 @@ abc_libabc_add_sources( NAME misc_zlib SOURCES - inftrees.c + gzread.c uncompr.c trees.c - inflate.c - crc32.c - infback.c + gzwrite.c + gzclose.c inffast.c + inftrees.c + infback.c gzlib.c - gzclose.c + adler32.c + crc32.c + inflate.c + zutil.c compress_.c - gzwrite.c - gzread.c deflate.c - zutil.c - adler32.c ) diff --git a/src/opt/cgt/CMakeLists.txt b/src/opt/cgt/CMakeLists.txt index 4128222199..6890c1b9d7 100644 --- a/src/opt/cgt/CMakeLists.txt +++ b/src/opt/cgt/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME opt_cgt SOURCES - cgtCore.c + cgtAig.c cgtSat.c - cgtMan.c + cgtCore.c cgtDecide.c - cgtAig.c + cgtMan.c ) diff --git a/src/opt/csw/CMakeLists.txt b/src/opt/csw/CMakeLists.txt index 256338a893..882d8b5473 100644 --- a/src/opt/csw/CMakeLists.txt +++ b/src/opt/csw/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_csw SOURCES - cswMan.c - cswCut.c cswTable.c + cswMan.c cswCore.c + cswCut.c ) diff --git a/src/opt/cut/CMakeLists.txt b/src/opt/cut/CMakeLists.txt index 2535cc9e7c..fba1c938a4 100644 --- a/src/opt/cut/CMakeLists.txt +++ b/src/opt/cut/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_cut SOURCES - cutApi.c - cutOracle.c - cutMerge.c cutCut.c - cutNode.c + cutPre22.c cutMan.c - cutTruth.c cutSeq.c - cutPre22.c + cutNode.c + cutOracle.c + cutMerge.c + cutTruth.c + cutApi.c ) diff --git a/src/opt/dar/CMakeLists.txt b/src/opt/dar/CMakeLists.txt index 92b00f044f..dae978c6ac 100644 --- a/src/opt/dar/CMakeLists.txt +++ b/src/opt/dar/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_dar SOURCES - darData.c - darScript.c darBalance.c - darLib.c - darMan.c darPrec.c + darData.c + darMan.c darCut.c - darRefact.c + darLib.c + darScript.c darCore.c + darRefact.c ) diff --git a/src/opt/dau/CMakeLists.txt b/src/opt/dau/CMakeLists.txt index c043c4369f..a2fa3d97cd 100644 --- a/src/opt/dau/CMakeLists.txt +++ b/src/opt/dau/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_dau SOURCES - dauNpn.c + dauEnum.c + dauTree.c dauNonDsd.c - dauNpn2.c - dauCore.c dauMerge.c + dauDsd.c dauDivs.c - dauTree.c dauCount.c dauCanon.c + dauNpn2.c dauGia.c - dauEnum.c - dauDsd.c + dauNpn.c + dauCore.c ) diff --git a/src/opt/eslim/CMakeLists.txt b/src/opt/eslim/CMakeLists.txt index 4e3df8832c..5781fc7240 100644 --- a/src/opt/eslim/CMakeLists.txt +++ b/src/opt/eslim/CMakeLists.txt @@ -1,6 +1,6 @@ abc_libabc_add_sources( NAME opt_eslim SOURCES - relationGeneration.cpp eSLIM.cpp + relationGeneration.cpp ) diff --git a/src/opt/fret/CMakeLists.txt b/src/opt/fret/CMakeLists.txt index d01604ac6d..6a269c7897 100644 --- a/src/opt/fret/CMakeLists.txt +++ b/src/opt/fret/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fret SOURCES - fretMain.c - fretInit.c fretFlow.c + fretInit.c + fretMain.c fretTime.c ) diff --git a/src/opt/fsim/CMakeLists.txt b/src/opt/fsim/CMakeLists.txt index dd744e6588..052b8d31b8 100644 --- a/src/opt/fsim/CMakeLists.txt +++ b/src/opt/fsim/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME opt_fsim SOURCES - fsimFront.c - fsimSwitch.c - fsimTsim.c - fsimCore.c fsimMan.c + fsimFront.c fsimSim.c + fsimCore.c + fsimTsim.c + fsimSwitch.c ) diff --git a/src/opt/fxch/CMakeLists.txt b/src/opt/fxch/CMakeLists.txt index 1ba0e72e8c..ad4a264c69 100644 --- a/src/opt/fxch/CMakeLists.txt +++ b/src/opt/fxch/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_fxch SOURCES - Fxch.c - FxchDiv.c - FxchSCHashTable.c FxchMan.c + FxchSCHashTable.c + FxchDiv.c + Fxch.c ) diff --git a/src/opt/fxu/CMakeLists.txt b/src/opt/fxu/CMakeLists.txt index d95fdbc203..7071c4a2be 100644 --- a/src/opt/fxu/CMakeLists.txt +++ b/src/opt/fxu/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME opt_fxu SOURCES + fxu.c fxuMatrix.c - fxuHeapD.c - fxuHeapS.c - fxuPair.c + fxuCreate.c + fxuPrint.c + fxuSingle.c fxuSelect.c fxuUpdate.c - fxu.c - fxuCreate.c fxuList.c - fxuSingle.c - fxuPrint.c + fxuPair.c + fxuHeapS.c fxuReduce.c + fxuHeapD.c ) diff --git a/src/opt/lpk/CMakeLists.txt b/src/opt/lpk/CMakeLists.txt index f00e5169a8..a30f70802b 100644 --- a/src/opt/lpk/CMakeLists.txt +++ b/src/opt/lpk/CMakeLists.txt @@ -1,15 +1,15 @@ abc_libabc_add_sources( NAME opt_lpk SOURCES - lpkMap.c - lpkMulti.c - lpkMux.c + lpkAbcMux.c + lpkAbcDsd.c + lpkSets.c lpkCut.c - lpkAbcDec.c lpkMan.c - lpkAbcDsd.c - lpkAbcUtil.c + lpkAbcDec.c + lpkMux.c + lpkMap.c lpkCore.c - lpkAbcMux.c - lpkSets.c + lpkAbcUtil.c + lpkMulti.c ) diff --git a/src/opt/mfs/CMakeLists.txt b/src/opt/mfs/CMakeLists.txt index a2a325b5e9..ea77845b7c 100644 --- a/src/opt/mfs/CMakeLists.txt +++ b/src/opt/mfs/CMakeLists.txt @@ -1,12 +1,12 @@ abc_libabc_add_sources( NAME opt_mfs SOURCES - mfsSat.c mfsInter.c mfsWin.c + mfsSat.c + mfsResub.c + mfsStrash.c mfsMan.c mfsDiv.c - mfsStrash.c - mfsResub.c mfsCore.c ) diff --git a/src/opt/nwk/CMakeLists.txt b/src/opt/nwk/CMakeLists.txt index 0931631504..c0979cc550 100644 --- a/src/opt/nwk/CMakeLists.txt +++ b/src/opt/nwk/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME opt_nwk SOURCES - nwkCheck.c - nwkSpeedup.c - nwkAig.c - nwkBidec.c + nwkDfs.c nwkFlow.c - nwkFanio.c + nwkBidec.c nwkMap.c + nwkFanio.c + nwkAig.c + nwkSpeedup.c nwkStrash.c - nwkDfs.c - nwkObj.c - nwkMerge.c - nwkMan.c + nwkCheck.c nwkTiming.c + nwkMerge.c + nwkObj.c nwkUtil.c + nwkMan.c ) diff --git a/src/opt/rar/CMakeLists.txt b/src/opt/rar/CMakeLists.txt index cd7a1f52a5..01af6db8f5 100644 --- a/src/opt/rar/CMakeLists.txt +++ b/src/opt/rar/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME opt_rar SOURCES + rewire_miaig.cpp rewire_map.c rewire_rar.c rewire_rng.c - rewire_miaig.cpp ) diff --git a/src/opt/res/CMakeLists.txt b/src/opt/res/CMakeLists.txt index d3d8467806..fcb01910e3 100644 --- a/src/opt/res/CMakeLists.txt +++ b/src/opt/res/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_res SOURCES - resFilter.c resDivs.c - resSim.c - resCore.c - resWin.c resSat.c + resFilter.c + resCore.c resStrash.c + resWin.c + resSim.c ) diff --git a/src/opt/ret/CMakeLists.txt b/src/opt/ret/CMakeLists.txt index a651c876f9..29e3c13ae7 100644 --- a/src/opt/ret/CMakeLists.txt +++ b/src/opt/ret/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_ret SOURCES - retFlow.c retCore.c + retIncrem.c + retFlow.c retLvalue.c retDelay.c retInit.c - retIncrem.c retArea.c ) diff --git a/src/opt/rwr/CMakeLists.txt b/src/opt/rwr/CMakeLists.txt index 7a741a47e1..c32588fc7c 100644 --- a/src/opt/rwr/CMakeLists.txt +++ b/src/opt/rwr/CMakeLists.txt @@ -1,11 +1,11 @@ abc_libabc_add_sources( NAME opt_rwr SOURCES + rwrExp.c rwrUtil.c - rwrDec.c rwrEva.c - rwrPrint.c - rwrLib.c - rwrExp.c + rwrDec.c rwrMan.c + rwrLib.c + rwrPrint.c ) diff --git a/src/opt/rwt/CMakeLists.txt b/src/opt/rwt/CMakeLists.txt index 1a9d6fb7ec..29f1e55cf4 100644 --- a/src/opt/rwt/CMakeLists.txt +++ b/src/opt/rwt/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME opt_rwt SOURCES - rwtUtil.c - rwtDec.c rwtMan.c + rwtDec.c + rwtUtil.c ) diff --git a/src/opt/sbd/CMakeLists.txt b/src/opt/sbd/CMakeLists.txt index a7e8f9a52d..ac79cb96c2 100644 --- a/src/opt/sbd/CMakeLists.txt +++ b/src/opt/sbd/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sbd SOURCES - sbdCnf.c - sbdCut.c - sbdPath.c - sbdCut2.c sbdSat.c + sbd.c sbdWin.c + sbdCut.c sbdLut.c sbdCore.c - sbd.c + sbdCut2.c + sbdCnf.c + sbdPath.c ) diff --git a/src/opt/sfm/CMakeLists.txt b/src/opt/sfm/CMakeLists.txt index 5e85451418..39c4ec84af 100644 --- a/src/opt/sfm/CMakeLists.txt +++ b/src/opt/sfm/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME opt_sfm SOURCES - sfmSat.c + sfmArea.c + sfmNtk.c + sfmDec.c sfmTim.c sfmCnf.c - sfmArea.c sfmMit.c sfmWin.c - sfmNtk.c sfmCore.c + sfmSat.c sfmLib.c - sfmDec.c ) diff --git a/src/opt/sim/CMakeLists.txt b/src/opt/sim/CMakeLists.txt index 3470c727b7..961f509577 100644 --- a/src/opt/sim/CMakeLists.txt +++ b/src/opt/sim/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME opt_sim SOURCES - simSwitch.c - simSym.c simSymSim.c simSymSat.c + simSupp.c simUtils.c - simSymStr.c simMan.c + simSym.c + simSymStr.c + simSwitch.c simSeq.c - simSupp.c ) diff --git a/src/phys/place/CMakeLists.txt b/src/phys/place/CMakeLists.txt index 60cdf9f1b7..81bcc66cd7 100644 --- a/src/phys/place/CMakeLists.txt +++ b/src/phys/place/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME phys_place SOURCES - place_pads.c + place_base.c place_qpsolver.c - place_partition.c place_legalize.c place_bin.c - place_genqp.c - place_base.c - place_gordian.c - place_io.c place_inc.c + place_pads.c + place_io.c + place_gordian.c + place_partition.c + place_genqp.c ) diff --git a/src/proof/abs/CMakeLists.txt b/src/proof/abs/CMakeLists.txt index d46922ea17..7fb17e6a8b 100644 --- a/src/proof/abs/CMakeLists.txt +++ b/src/proof/abs/CMakeLists.txt @@ -2,19 +2,19 @@ abc_libabc_add_sources( NAME proof_abs SOURCES absOldRef.c + absGla.c + absGlaOld.c + absRpmOld.c absUtil.c - absOldSat.c - absRpm.c + absDup.c + absVta.c + absRef.c absPth.c - absRpmOld.c - absGlaOld.c + absOldCex.c + absOldSat.c absOut.c - absIter.c - absRef.c - absDup.c - absGla.c absOldSim.c - absOldCex.c - absVta.c + absRpm.c absRefSelect.c + absIter.c ) diff --git a/src/proof/acec/CMakeLists.txt b/src/proof/acec/CMakeLists.txt index a1c0cc134c..748a8ffb1a 100644 --- a/src/proof/acec/CMakeLists.txt +++ b/src/proof/acec/CMakeLists.txt @@ -1,23 +1,23 @@ abc_libabc_add_sources( NAME proof_acec SOURCES + acecPolyn.c + acecSt.c + acecNorm.c + acecTree.c acecMult.c - acecCore.c - acecRe.c - acecFadds.c - acecPool.c + acecXor.c acecBo.c - acecTree.c - acecUtil.c - acecNorm.c - acecPolyn.c - acecCover.c - acecPa.c - acecCo.c + acecCl.c acecOrder.c - acecXor.c - acecSt.c acecPo.c acec2Mult.c - acecCl.c + acecFadds.c + acecCo.c + acecCover.c + acecRe.c + acecPa.c + acecUtil.c + acecCore.c + acecPool.c ) diff --git a/src/proof/cec/CMakeLists.txt b/src/proof/cec/CMakeLists.txt index ff321b7e90..d04ab9f383 100644 --- a/src/proof/cec/CMakeLists.txt +++ b/src/proof/cec/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_cec SOURCES - cecProve.c - cecSatG.c - cecSat.c - cecCorr.c - cecIso.c + cecSynth.c + cecSatG2.c cecCec.c - cecCore.c - cecSweep.c cecPat.c - cecSolveG.c - cecSim.c - cecSatG3.c cecMan.c - cecSynth.c + cecCore.c + cecIso.c + cecCorr.c + cecSplit.c cecClass.c - cecSolve.c + cecSim.c + cecProve.c + cecSat.c cecChoice.c - cecSplit.c + cecSolveG.c cecSeq.c - cecSatG2.c + cecSolve.c + cecSatG.c + cecSatG3.c + cecSweep.c ) diff --git a/src/proof/dch/CMakeLists.txt b/src/proof/dch/CMakeLists.txt index 4730025863..4d0278534b 100644 --- a/src/proof/dch/CMakeLists.txt +++ b/src/proof/dch/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_dch SOURCES - dchSweep.c - dchAig.c dchClass.c - dchSat.c - dchSimSat.c dchSim.c dchCore.c dchMan.c - dchChoice.c dchCnf.c + dchSweep.c + dchChoice.c + dchSimSat.c + dchSat.c + dchAig.c ) diff --git a/src/proof/fra/CMakeLists.txt b/src/proof/fra/CMakeLists.txt index 23d673330d..189ceca7ff 100644 --- a/src/proof/fra/CMakeLists.txt +++ b/src/proof/fra/CMakeLists.txt @@ -1,21 +1,21 @@ abc_libabc_add_sources( NAME proof_fra SOURCES - fraHot.c - fraClau.c - fraMan.c fraSim.c - fraImp.c fraCore.c - fraPart.c fraCnf.c - fraInd.c + fraCec.c + fraClass.c fraLcr.c - fraBmc.c - fraSat.c - fraSec.c + fraPart.c fraClaus.c - fraCec.c fraIndVer.c - fraClass.c + fraSat.c + fraMan.c + fraSec.c + fraInd.c + fraClau.c + fraBmc.c + fraImp.c + fraHot.c ) diff --git a/src/proof/fraig/CMakeLists.txt b/src/proof/fraig/CMakeLists.txt index d84ee401f9..e8179b22bf 100644 --- a/src/proof/fraig/CMakeLists.txt +++ b/src/proof/fraig/CMakeLists.txt @@ -1,16 +1,16 @@ abc_libabc_add_sources( NAME proof_fraig SOURCES + fraigNode.c + fraigFanout.c + fraigMem.c + fraigTable.c fraigPrime.c fraigUtil.c - fraigMan.c - fraigFeed.c - fraigFanout.c + fraigSat.c fraigVec.c - fraigTable.c + fraigMan.c fraigCanon.c fraigApi.c - fraigMem.c - fraigNode.c - fraigSat.c + fraigFeed.c ) diff --git a/src/proof/int/CMakeLists.txt b/src/proof/int/CMakeLists.txt index b7d7b54158..4176fa5f03 100644 --- a/src/proof/int/CMakeLists.txt +++ b/src/proof/int/CMakeLists.txt @@ -1,14 +1,14 @@ abc_libabc_add_sources( NAME proof_int SOURCES - intDup.c - intCheck.c - intUtil.c + intCtrex.c intInter.c - intFrames.c - intMan.c intM114.c intCore.c + intDup.c + intFrames.c intContain.c - intCtrex.c + intCheck.c + intUtil.c + intMan.c ) diff --git a/src/proof/int2/CMakeLists.txt b/src/proof/int2/CMakeLists.txt index 2c2392b230..8a4972b542 100644 --- a/src/proof/int2/CMakeLists.txt +++ b/src/proof/int2/CMakeLists.txt @@ -1,8 +1,8 @@ abc_libabc_add_sources( NAME proof_int2 SOURCES - int2Bmc.c - int2Refine.c - int2Core.c int2Util.c + int2Core.c + int2Refine.c + int2Bmc.c ) diff --git a/src/proof/live/CMakeLists.txt b/src/proof/live/CMakeLists.txt index 6e942ebbd5..bbe53de2bf 100644 --- a/src/proof/live/CMakeLists.txt +++ b/src/proof/live/CMakeLists.txt @@ -3,11 +3,11 @@ abc_libabc_add_sources( SOURCES disjunctiveMonotone.c liveness_sim.c - arenaViolation.c + kliveness.c + kLiveConstraints.c + liveness.c monotone.c + arenaViolation.c combination.c - kLiveConstraints.c ltl_parser.c - liveness.c - kliveness.c ) diff --git a/src/proof/pdr/CMakeLists.txt b/src/proof/pdr/CMakeLists.txt index 403198dd1a..88af4b2cab 100644 --- a/src/proof/pdr/CMakeLists.txt +++ b/src/proof/pdr/CMakeLists.txt @@ -2,13 +2,13 @@ abc_libabc_add_sources( NAME proof_pdr SOURCES pdrCore.c - pdrTsim.c - pdrSat.c - pdrCnf.c - pdrIncr.c + pdrInv.c pdrUtil.c + pdrTsim3.c + pdrCnf.c pdrTsim2.c + pdrSat.c + pdrTsim.c + pdrIncr.c pdrMan.c - pdrTsim3.c - pdrInv.c ) diff --git a/src/proof/ssc/CMakeLists.txt b/src/proof/ssc/CMakeLists.txt index f809a60d98..2fedf0a57d 100644 --- a/src/proof/ssc/CMakeLists.txt +++ b/src/proof/ssc/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME proof_ssc SOURCES - sscUtil.c - sscSim.c sscClass.c sscCore.c sscSat.c + sscUtil.c + sscSim.c ) diff --git a/src/proof/ssw/CMakeLists.txt b/src/proof/ssw/CMakeLists.txt index b6d7892aa0..21a01f5e04 100644 --- a/src/proof/ssw/CMakeLists.txt +++ b/src/proof/ssw/CMakeLists.txt @@ -1,24 +1,24 @@ abc_libabc_add_sources( NAME proof_ssw SOURCES - sswSemi.c - sswClass.c sswCore.c - sswSim.c - sswSimSat.c - sswSweep.c - sswDyn.c - sswCnf.c + sswClass.c + sswSat.c + sswRarity.c + sswAig.c sswMan.c + sswSimSat.c + sswUnique.c + sswLcorr.c sswConstr.c + sswBmc.c + sswCnf.c sswPart.c - sswFilter.c - sswUnique.c - sswSat.c sswIslands.c - sswAig.c - sswLcorr.c + sswDyn.c sswPairs.c - sswBmc.c - sswRarity.c + sswSweep.c + sswSemi.c + sswSim.c + sswFilter.c ) diff --git a/src/sat/bmc/CMakeLists.txt b/src/sat/bmc/CMakeLists.txt index d041be1476..186d19fe9b 100644 --- a/src/sat/bmc/CMakeLists.txt +++ b/src/sat/bmc/CMakeLists.txt @@ -1,36 +1,36 @@ abc_libabc_add_sources( NAME sat_bmc SOURCES - bmcMesh2.c - bmcCexCut.c - bmcCexCare.c - bmcEco.c - bmcBmcAnd.c - bmcGen.c - bmcICheck.c bmcCexTools.c - bmcBmcS.c - bmcClp.c - bmcInse.c - bmcFault.c - bmcCexMin1.c bmcBmc.c - bmcMaj3.c - bmcMulti.c - bmcMaj.c - bmcMaj2.c + bmcCexMin2.c + bmcFault.c bmcBmci.c - bmcUnroll.c + bmcGen.c + bmcBmcS.c + bmcMesh.c + bmcCexCut.c + bmcBmcG.c + bmcChain.c + bmcMulti.c + bmcICheck.c bmcBmc2.c + bmcMaj3.c + bmcBmc3.c bmcMaxi.c bmcBCore.c - bmcChain.c + bmcUnroll.c bmcCexDepth.c - bmcBmc3.c - bmcLoad.c - bmcBmcG.c - bmcCexMin2.c - bmcMesh.c - bmcExpand.c + bmcBmcAnd.c + bmcCexMin1.c bmcFx.c + bmcExpand.c + bmcMaj2.c + bmcCexCare.c + bmcClp.c + bmcEco.c + bmcMaj.c + bmcLoad.c + bmcMesh2.c + bmcInse.c ) diff --git a/src/sat/bsat/CMakeLists.txt b/src/sat/bsat/CMakeLists.txt index 8e1ad8338a..4644cd669b 100644 --- a/src/sat/bsat/CMakeLists.txt +++ b/src/sat/bsat/CMakeLists.txt @@ -1,18 +1,18 @@ abc_libabc_add_sources( NAME sat_bsat SOURCES + satInterB.c + satTruth.c + satInter.c + satSolver3.c + satStore.c satProof.c - satInterP.c satSolver2i.c - satInterB.c + satTrace.c + satSolver.c satMem.c - satInterA.c + satInterP.c satSolver2.c - satStore.c - satTrace.c - satSolver3.c - satTruth.c + satInterA.c satUtil.c - satSolver.c - satInter.c ) diff --git a/src/sat/bsat2/CMakeLists.txt b/src/sat/bsat2/CMakeLists.txt index eb85f78270..02b87e93dd 100644 --- a/src/sat/bsat2/CMakeLists.txt +++ b/src/sat/bsat2/CMakeLists.txt @@ -1,9 +1,9 @@ abc_libabc_add_sources( NAME sat_bsat2 SOURCES - Solver.cpp - SimpSolver.cpp System.cpp Options.cpp AbcApi.cpp + Solver.cpp + SimpSolver.cpp ) diff --git a/src/sat/cadical/CMakeLists.txt b/src/sat/cadical/CMakeLists.txt index f00811a268..d32a7280d2 100644 --- a/src/sat/cadical/CMakeLists.txt +++ b/src/sat/cadical/CMakeLists.txt @@ -1,95 +1,95 @@ abc_libabc_add_sources( NAME sat_cadical SOURCES - cadical_drattracer.cpp + cadical_kitten.c + cadical_random.cpp cadical_restart.cpp - cadical_lidruptracer.cpp + cadicalSolver.c + cadical_ccadical.cpp + cadical_extend.cpp + cadical_resources.cpp + cadical_solver.cpp cadical_ternary.cpp - cadical_options.cpp - cadical_constrain.cpp - cadical_minimize.cpp - cadical_logging.cpp - cadical_restore.cpp - cadical_lratchecker.cpp - cadical_backward.cpp - cadical_contract.cpp - cadical_watch.cpp - cadical_flags.cpp - cadical_propagate.cpp - cadical_veripbtracer.cpp - cadical_config.cpp - cadical_compact.cpp - cadical_score.cpp - cadical_factor.cpp + cadical_assume.cpp cadical_transred.cpp - cadical_report.cpp - cadical_signal.cpp - cadical_ema.cpp - cadical_file.cpp - cadical_occs.cpp - cadical_averages.cpp - cadical_rephase.cpp - cadical_idruptracer.cpp + cadical_internal.cpp cadical_lrattracer.cpp + cadical_vivify.cpp + cadical_minimize.cpp + cadical_compact.cpp + cadical_arena.cpp + cadical_terminal.cpp cadical_walk.cpp + cadical_backward.cpp + cadical_lratchecker.cpp + cadical_averages.cpp + cadical_reap.cpp cadical_version.cpp - cadical_lucky.cpp - cadical_proof.cpp - cadical_terminal.cpp - cadical_external_propagate.cpp - cadical_definition.cpp - cadical_condition.cpp - cadical_tier.cpp - cadical_decompose.cpp + cadical_occs.cpp + cadical_stable.cpp + cadical_lookahead.cpp + cadical_backtrack.cpp cadical_phases.cpp - cadical_ccadical.cpp - cadical_instantiate.cpp - cadical_shrink.cpp - cadical_block.cpp + cadical_elim.cpp + cadical_propagate.cpp cadical_analyze.cpp - cadical_elimfast.cpp - cadical_parse.cpp - cadical_queue.cpp - cadical_vivify.cpp - cadical_external.cpp - cadical_checker.cpp + cadical_instantiate.cpp + cadical_lidruptracer.cpp + cadical_probe.cpp cadical_clause.cpp - cadical_cover.cpp - cadical_resources.cpp - cadical_gates.cpp - cadical_sweep.cpp - cadical_arena.cpp - cadical_lookahead.cpp - cadical_backtrack.cpp - cadical_solution.cpp + cadical_checker.cpp + cadical_score.cpp + cadical_restore.cpp + cadical_file.cpp cadical_subsume.cpp - cadicalTest.c + cadical_external.cpp + cadical_tier.cpp + cadical_message.cpp + cadical_shrink.cpp + cadical_ipasir.cpp cadical_limit.cpp cadical_collect.cpp + cadical_elimfast.cpp + cadical_condition.cpp + cadical_decide.cpp + cadical_watch.cpp + cadical_drattracer.cpp + cadical_format.cpp + cadical_gates.cpp + cadical_definition.cpp cadical_congruence.cpp - cadical_ipasir.cpp + cadical_flags.cpp + cadical_constrain.cpp cadical_stats.cpp - cadical_profile.cpp - cadical_extend.cpp cadical_reduce.cpp - cadical_var.cpp - cadical_assume.cpp + cadical_sweep.cpp + cadicalTest.c + cadical_bins.cpp + cadical_parse.cpp + cadical_frattracer.cpp + cadical_external_propagate.cpp cadical_unstable.cpp - cadical_internal.cpp - cadical_decide.cpp - cadical_deduplicate.cpp - cadical_format.cpp + cadical_block.cpp cadical_util.cpp - cadical_frattracer.cpp - cadical_kitten.c - cadicalSolver.c - cadical_bins.cpp - cadical_probe.cpp + cadical_veripbtracer.cpp + cadical_profile.cpp + cadical_rephase.cpp + cadical_queue.cpp + cadical_deduplicate.cpp + cadical_ema.cpp + cadical_signal.cpp + cadical_contract.cpp + cadical_lucky.cpp + cadical_decompose.cpp + cadical_report.cpp + cadical_proof.cpp + cadical_idruptracer.cpp + cadical_solution.cpp + cadical_cover.cpp cadical_flip.cpp - cadical_solver.cpp - cadical_stable.cpp - cadical_elim.cpp - cadical_random.cpp - cadical_reap.cpp - cadical_message.cpp + cadical_logging.cpp + cadical_options.cpp + cadical_config.cpp + cadical_factor.cpp + cadical_var.cpp ) diff --git a/src/sat/cnf/CMakeLists.txt b/src/sat/cnf/CMakeLists.txt index a831dd32c6..040d2d3458 100644 --- a/src/sat/cnf/CMakeLists.txt +++ b/src/sat/cnf/CMakeLists.txt @@ -1,13 +1,13 @@ abc_libabc_add_sources( NAME sat_cnf SOURCES + cnfCore.c + cnfData.c + cnfWrite.c cnfUtil.c - cnfMan.c cnfMap.c cnfFast.c - cnfPost.c - cnfData.c cnfCut.c - cnfCore.c - cnfWrite.c + cnfMan.c + cnfPost.c ) diff --git a/src/sat/glucose/CMakeLists.txt b/src/sat/glucose/CMakeLists.txt index 6777e98a3a..22dd086649 100644 --- a/src/sat/glucose/CMakeLists.txt +++ b/src/sat/glucose/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose SOURCES - SimpSolver.cpp - AbcGlucoseCmd.cpp System.cpp Options.cpp AbcGlucose.cpp Glucose.cpp + SimpSolver.cpp + AbcGlucoseCmd.cpp ) diff --git a/src/sat/glucose2/CMakeLists.txt b/src/sat/glucose2/CMakeLists.txt index 7654e71529..a6930eb706 100644 --- a/src/sat/glucose2/CMakeLists.txt +++ b/src/sat/glucose2/CMakeLists.txt @@ -1,10 +1,10 @@ abc_libabc_add_sources( NAME sat_glucose2 SOURCES + System2.cpp + AbcGlucoseCmd2.cpp Glucose2.cpp + SimpSolver2.cpp Options2.cpp - System2.cpp AbcGlucose2.cpp - SimpSolver2.cpp - AbcGlucoseCmd2.cpp ) diff --git a/src/sat/kissat/CMakeLists.txt b/src/sat/kissat/CMakeLists.txt index 949bdcb105..5dcffa3fb1 100644 --- a/src/sat/kissat/CMakeLists.txt +++ b/src/sat/kissat/CMakeLists.txt @@ -1,95 +1,95 @@ abc_libabc_add_sources( NAME sat_kissat SOURCES - gates.c - propinitially.c - format.c - flags.c - analyze.c - build.c - heap.c - learn.c - restart.c - backbone.c - warmup.c - report.c - forward.c - file.c - proprobe.c - error.c - transitive.c - minimize.c + tiers.c walk.c - colors.c - strengthen.c - preprocess.c - eliminate.c - kitten.c - arena.c - backtrack.c - stack.c - definition.c resolve.c - factor.c - extend.c - kimits.c - deduce.c - substitute.c - clause.c - kptions.c - allocate.c - import.c - dense.c - tiers.c - terminate.c - kissatTest.c - logging.c - reluctant.c - reduce.c - watch.c - probe.c - vector.c - vivify.c - print.c - proof.c - resize.c - propdense.c - fastel.c - kucky.c - bump.c + propbeyond.c collect.c - assign.c - sweep.c + resize.c + vivify.c + promote.c queue.c - weaken.c + kitten.c + reduce.c + assign.c + analyze.c + minimize.c + kissatTest.c + allocate.c + internal.c reorder.c - propbeyond.c - decide.c - equivalences.c - kissatSolver.c averages.c - rephase.c - profile.c - statistics.c - trail.c + file.c dump.c - mode.c - internal.c + stack.c + learn.c + propsearch.c + preprocess.c + ifthenelse.c + kissatSolver.c + forward.c classify.c - search.c + backtrack.c + congruence.c + eliminate.c + sweep.c + config.c + warmup.c + utilities.c + transitive.c + propdense.c + resources.c + profile.c + krite.c + arena.c + clause.c + colors.c shrink.c + gates.c + definition.c + equivalences.c phases.c + terminate.c + bump.c + proprobe.c + heap.c + restart.c + statistics.c + decide.c + print.c + proof.c + propinitially.c + rephase.c check.c - config.c - utilities.c - promote.c + dense.c + substitute.c + search.c + extend.c sort.c - ifthenelse.c - krite.c - congruence.c - propsearch.c - resources.c + kucky.c + import.c + fastel.c + vector.c + strengthen.c + probe.c + weaken.c + ands.c + deduce.c + reluctant.c + flags.c smooth.c + trail.c + error.c + watch.c + report.c + kimits.c + backbone.c + kptions.c + logging.c + format.c + build.c + mode.c + factor.c compact.c - ands.c ) diff --git a/src/sat/msat/CMakeLists.txt b/src/sat/msat/CMakeLists.txt index cc80678afa..79fe7a0aef 100644 --- a/src/sat/msat/CMakeLists.txt +++ b/src/sat/msat/CMakeLists.txt @@ -1,17 +1,17 @@ abc_libabc_add_sources( NAME sat_msat SOURCES - msatSort.c - msatRead.c + msatSolverIo.c msatClauseVec.c - msatSolverSearch.c - msatVec.c + msatActivity.c + msatMem.c + msatClause.c + msatSort.c msatSolverApi.c + msatSolverSearch.c msatSolverCore.c msatOrderH.c - msatMem.c - msatActivity.c - msatClause.c + msatVec.c + msatRead.c msatQueue.c - msatSolverIo.c ) diff --git a/src/sat/satoko/CMakeLists.txt b/src/sat/satoko/CMakeLists.txt index 77cbf21698..3341a6f9c1 100644 --- a/src/sat/satoko/CMakeLists.txt +++ b/src/sat/satoko/CMakeLists.txt @@ -1,7 +1,7 @@ abc_libabc_add_sources( NAME sat_satoko SOURCES - cnf_reader.c - solver.c solver_api.c + solver.c + cnf_reader.c ) From 37501cea3b5de406a5f66566b1b1b2ce7951997d Mon Sep 17 00:00:00 2001 From: Stephen L Arnold Date: Mon, 24 Mar 2025 22:36:04 -0700 Subject: [PATCH 35/35] fix: dev: rename conflicting Win32 symbol, cleanup whitespace Signed-off-by: Stephen L Arnold --- src/opt/eslim/eSLIMMan.tpp | 28 ++++++++++++------------ src/opt/eslim/selectionStrategy.tpp | 18 +++++++-------- src/opt/eslim/utils.hpp | 34 ++++++++++++++--------------- 3 files changed, 40 insertions(+), 40 deletions(-) diff --git a/src/opt/eslim/eSLIMMan.tpp b/src/opt/eslim/eSLIMMan.tpp index 8eb46db5ca..0054cc9d9e 100644 --- a/src/opt/eslim/eSLIMMan.tpp +++ b/src/opt/eslim/eSLIMMan.tpp @@ -9,7 +9,7 @@ Synopsis [eSLIM manager.] Author [Franz-Xaver Reichl] - + Affiliation [University of Freiburg] Date [Ver. 1.0. Started - March 2025.] @@ -52,8 +52,8 @@ namespace eSLIM { template - eSLIM_Man::eSLIM_Man(Gia_Man_t * pGia, const eSLIMConfig& cfg, eSLIMLog& log) - : gia_man(pGia), cfg(cfg), log(log), + eSLIM_Man::eSLIM_Man(Gia_Man_t * pGia, const eSLIMConfig& cfg, eSLIMLog& log) + : gia_man(pGia), cfg(cfg), log(log), subcircuit_selection(gia_man, cfg, log) { if (cfg.fix_seed) { subcircuit_selection.setSeed(cfg.seed); @@ -61,7 +61,7 @@ namespace eSLIM { relation_generation_time = log.relation_generation_time; synthesis_time = log.synthesis_time; } - + template void eSLIM_Man::minimize() { abctime clkStart = Abc_Clock(); @@ -117,7 +117,7 @@ namespace eSLIM { } return vSimsDiv; } - + template Vec_Wrd_t* eSLIM_Man::getSimsOut(Abc_RData_t* relation) { Vec_Wrd_t* vSimsOut = Vec_WrdStart(relation->nPats); @@ -145,7 +145,7 @@ namespace eSLIM { insertReplacement(replacement, subcir); Mini_AigStop(replacement); } - subcir.free(); + subcir._free(); } // Based on Exa_ManExactSynthesis6Int and Exa_ManExactSynthesis6 @@ -191,11 +191,11 @@ namespace eSLIM { log.nof_reduced_circuits_per_size.resize(original_size + 1, 0); } log.nof_analyzed_circuits_per_size[original_size]++; - + abctime synthesis_start = Abc_Clock(); std::tie(size, pMini) = reduce(vSimsDiv2, vSimsOut2, subcir.forbidden_pairs, nVars, nDivs, nOuts, size); log.synthesis_time += (double)1.0*(Abc_Clock() - synthesis_start)/CLOCKS_PER_SEC; - + if (size > original_size) { // Could not find a replacement. This can be caused by a timeout. Abc_RDataStop(relation); @@ -232,7 +232,7 @@ namespace eSLIM { if (pMini != nullptr) { Mini_Aig_t* pTemp = pMini; pMini = Mini_AigDupCompl(pTemp, DivCompl, OutCompl); - Mini_AigStop(pTemp); + Mini_AigStop(pTemp); log.nof_replaced_circuits_per_size[original_size]++; if (size < original_size) { @@ -272,7 +272,7 @@ namespace eSLIM { } else { valuefanin0 = false; } - valuefanin0 = valuefanin0 != pObj->fCompl0; + valuefanin0 = valuefanin0 != pObj->fCompl0; if (Gia_ObjIsTravIdCurrent(gia_man, Gia_ObjFanin1(pObj))) { valuefanin1 = getAllFalseBehaviourRec(Gia_ObjFanin1(pObj)); } else { @@ -288,7 +288,7 @@ namespace eSLIM { bool fanin_negated = Abc_LitIsCompl(fanin_lit); int fanin_value; if (fanin_idx == 0) { // constant fanin - fanin_value = 0; + fanin_value = 0; } else if (fanin_idx <= subcir.nof_inputs) { Gia_Obj_t* pObj = Gia_ManObj(gia_man, Vec_IntEntry(subcir.io, fanin_idx - 1)); if (Gia_ObjIsTravIdCurrent(gia_man, pObj)) { //the node has already been added @@ -432,7 +432,7 @@ namespace eSLIM { } po_idx++; } - + Gia_ManForEachPo( gia_man, pObj, i ) { assert(Gia_ObjIsTravIdCurrent(gia_man, Gia_ObjFanin0(pObj))); bool fanin_negated = Gia_ObjFaninC0(pObj) ^ Gia_ObjFanin0(pObj)->fMark0; @@ -444,7 +444,7 @@ namespace eSLIM { } template - std::pair eSLIM_Man::reduce(Vec_Wrd_t* vSimsDiv, Vec_Wrd_t* vSimsOut, const std::unordered_map>& forbidden_pairs, + std::pair eSLIM_Man::reduce(Vec_Wrd_t* vSimsDiv, Vec_Wrd_t* vSimsOut, const std::unordered_map>& forbidden_pairs, int nVars, int nDivs, int nOuts, int size) { Y synth_man(vSimsDiv,vSimsOut,nVars,1+nVars+nDivs,nOuts,size, forbidden_pairs, log, cfg); Mini_Aig_t* result = nullptr; @@ -479,4 +479,4 @@ namespace eSLIM { } -ABC_NAMESPACE_CXX_HEADER_END \ No newline at end of file +ABC_NAMESPACE_CXX_HEADER_END diff --git a/src/opt/eslim/selectionStrategy.tpp b/src/opt/eslim/selectionStrategy.tpp index 94f656a5b3..909b3a4b86 100644 --- a/src/opt/eslim/selectionStrategy.tpp +++ b/src/opt/eslim/selectionStrategy.tpp @@ -9,7 +9,7 @@ Synopsis [Procedures for selecting subcircuits.] Author [Franz-Xaver Reichl] - + Affiliation [University of Freiburg] Date [Ver. 1.0. Started - March 2025.] @@ -35,7 +35,7 @@ namespace eSLIM { if (filterSubcircuit(subcir)) { return subcir; } else { - subcir.free(); + subcir._free(); } } status = false; @@ -76,12 +76,12 @@ namespace eSLIM { if (!Gia_ObjIsTravIdPrevious(gia_man, Gia_ObjFanin0(pObj)) && !Gia_ObjIsTravIdCurrent(gia_man, Gia_ObjFanin0(pObj))) { Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin0(pObj)); Vec_IntPush(io, Gia_ObjId(gia_man, Gia_ObjFanin0(pObj))); - } + } // fanin1 is not in the subcircuit and was not considered yet if (!Gia_ObjIsTravIdPrevious(gia_man, Gia_ObjFanin1(pObj)) && !Gia_ObjIsTravIdCurrent(gia_man, Gia_ObjFanin1(pObj))) { Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin1(pObj)); Vec_IntPush(io, Gia_ObjId(gia_man, Gia_ObjFanin1(pObj))); - } + } } int nof_inputs = Vec_IntSize(io); @@ -90,11 +90,11 @@ namespace eSLIM { // If there is an object that is not contained in the subcircuit that has a fanin in the subcircuit then this fanin is an output if (!Gia_ObjIsTravIdPrevious(gia_man, pObj)) { if (Gia_ObjIsTravIdPrevious(gia_man, Gia_ObjFanin0(pObj))) { - Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin0(pObj)); + Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin0(pObj)); Vec_IntPush(io, Gia_ObjId(gia_man, Gia_ObjFanin0(pObj))); } if (Gia_ObjIsTravIdPrevious(gia_man, Gia_ObjFanin1(pObj))) { - Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin1(pObj)); + Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin1(pObj)); Vec_IntPush(io, Gia_ObjId(gia_man, Gia_ObjFanin1(pObj))); } } @@ -102,7 +102,7 @@ namespace eSLIM { Gia_ManForEachPo( gia_man, pObj, i ) { if (Gia_ObjIsTravIdPrevious(gia_man, Gia_ObjFanin0(pObj))) { - Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin0(pObj)); + Gia_ObjSetTravIdCurrent(gia_man, Gia_ObjFanin0(pObj)); Vec_IntPush(io, Gia_ObjId(gia_man, Gia_ObjFanin0(pObj))); } } @@ -131,7 +131,7 @@ namespace eSLIM { template void SelectionStrategy::forbiddenPairsRec(Gia_Obj_t * pObj, int input, int min_level, std::unordered_map>& pairs, const std::unordered_map& out_id) { - if (Gia_ObjIsTravIdCurrent(gia_man, pObj)) { + if (Gia_ObjIsTravIdCurrent(gia_man, pObj)) { auto id = Gia_ObjId(gia_man, pObj); pairs[out_id.at(id)].insert(input); return; @@ -230,4 +230,4 @@ namespace eSLIM { } } -ABC_NAMESPACE_CXX_HEADER_END \ No newline at end of file +ABC_NAMESPACE_CXX_HEADER_END diff --git a/src/opt/eslim/utils.hpp b/src/opt/eslim/utils.hpp index fb942c417b..37b048e848 100644 --- a/src/opt/eslim/utils.hpp +++ b/src/opt/eslim/utils.hpp @@ -9,7 +9,7 @@ Synopsis [Utilities for the eSLIM package.] Author [Franz-Xaver Reichl] - + Affiliation [University of Freiburg] Date [Ver. 1.0. Started - March 2025.] @@ -33,21 +33,21 @@ ABC_NAMESPACE_CXX_HEADER_START namespace eSLIM { - struct eSLIMConfig { - bool extended_normality_processing = false; - bool apply_strash = true; - bool fix_seed = false; - bool fill_subcircuits = false; + struct eSLIMConfig { + bool extended_normality_processing = false; + bool apply_strash = true; + bool fix_seed = false; + bool fill_subcircuits = false; bool trial_limit_active = true; - bool allow_xors = false; + bool allow_xors = false; - unsigned int timeout = 3600; - unsigned int iterations = 0; - unsigned int subcircuit_size_bound = 6; - unsigned int strash_intervall = 100; + unsigned int timeout = 3600; + unsigned int iterations = 0; + unsigned int subcircuit_size_bound = 6; + unsigned int strash_intervall = 100; int seed = 0; unsigned int nselection_trials = 100; - double expansion_probability = 0.6; + double expansion_probability = 0.6; // times given in sec int minimum_sat_timeout = 1; @@ -81,18 +81,18 @@ namespace eSLIM { Vec_Int_t* io; unsigned int nof_inputs; std::unordered_map> forbidden_pairs; - void free(); + void _free(); }; - inline void Subcircuit::free() { + inline void Subcircuit::_free() { Vec_IntFree(nodes); Vec_IntFree(io); } - inline eSLIMLog::eSLIMLog(int size) + inline eSLIMLog::eSLIMLog(int size) : nof_analyzed_circuits_per_size(size + 1, 0), nof_replaced_circuits_per_size(size + 1, 0), nof_reduced_circuits_per_size(size + 1, 0), cummulative_sat_runtimes_per_size(size + 1, 0), - nof_sat_calls_per_size(size + 1, 0), cummulative_unsat_runtimes_per_size(size + 1, 0), + nof_sat_calls_per_size(size + 1, 0), cummulative_unsat_runtimes_per_size(size + 1, 0), nof_unsat_calls_per_size(size + 1, 0) { } @@ -100,4 +100,4 @@ namespace eSLIM { ABC_NAMESPACE_CXX_HEADER_END -#endif \ No newline at end of file +#endif