Some libraries used by VTR are developed in other repositories and integrated using git subtrees.
Currently these includes:
- libsdcparse
- libblifparse
As an example consider libsdcparse:
-
To begin add the sub-project as a remote:
git remote add -f github-libsdcparse [email protected]:kmurray/libsdcparse.git
-
To initially add the library (first time the library is added only):
git subtree add --prefix libsdcparse github-libsdcparse master --squash
Note the '--squash' option which prevents the whole up-stream history from being merged into the current repository.
-
To update a library (subsequently):
git subtree pull --prefix libsdcparse github-libsdcparse master --squash
Note the '--squash' option which prevents the whole up-stream history from being merged into the current repository.
For more details see here for a good overview.
Coverity Scan is a static code analysis service which can be used to detect bugs.
To view defects detected do the following:
-
Get a coverity scan account
Contact a project maintainer for an invitation.
-
Browse the existing defects through the coverity web interface
To submit a build to coverity do the following:
-
Download the coverity build tool
-
Configure VTR to perform a debug build. This ensures that all assertions are enabled, without assertions coverity may report bugs that are gaurded against by assertions.
#From the VTR root mkdir -p build cd build CC=gcc CXX=g++ cmake .. -DCMAKE_BUILD_TYPE=debug
Note that we explicitly asked for gcc and g++, the coverity build tool defaults to these compilers, and may not like the default 'cc' or 'c++' (even if they are linked to gcc/g++).
-
Run the coverity build tool
#From the build directory where we ran cmake cov-build --dir cov-int make -j8
-
Archive the output directory
tar -czvf cov-int vtr_coverity.tar.gz
-
Submit the archive through the coverity web interface
Once the build has been analyzed you can browse the latest results throught the coverity web interface