diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..5768c44 --- /dev/null +++ b/.gitignore @@ -0,0 +1,10 @@ +.sconf_temp +.scons-cache +.scons-config +.sconsign.dblite +Release +config.log +csi-*.*.* +csi-*.*.*.tar.gz + +**/*.pyc diff --git a/COPYING b/COPYING index ce88b2b..c3477be 100644 --- a/COPYING +++ b/COPYING @@ -3,7 +3,7 @@ CSI Release License ------------------- Apache License, Version 2.0 -Copyright (c) 2013 Peter J. Ohmann and Benjamin R. Liblit +Copyright (c) 2016 Peter J. Ohmann and Benjamin R. Liblit Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/NEWS b/NEWS index 85627c4..8604395 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,7 @@ +* csi-1.1.0 + +** Build used for 2016 ASE journal paper. + * csi-1.0.0 ** Initial build used in ASE 2013 paper. diff --git a/README.md b/README.md index 6ea2ebe..a1c84cc 100644 --- a/README.md +++ b/README.md @@ -3,15 +3,15 @@ An instrumenting compiler for lightweight program tracing. The mechanisms were originally proposed in > P. Ohmann and B. Liblit. -“[Lightweight control-flow instrumentation and postmortem analysis in support of debugging](http://pages.cs.wisc.edu/~liblit/ase-2013/).” -28th International Conference on Automated Software Engineering (ASE -2013), Nov. 2013. IEEE and ACM. +“[Lightweight control-flow instrumentation and postmortem analysis in support of debugging](http://pages.cs.wisc.edu/~liblit/ase-2016/).” +Automated Software Engineering Journal, 2016. Springer. +DOI: 10.1007/s10515-016-0190-1 -Preprint: http://pages.cs.wisc.edu/~liblit/ase-2013/ase-2013.pdf +Preprint: http://pages.cs.wisc.edu/~liblit/ase-2016/ase-2016.pdf ## Current Release -[`csi-cc` v1.0.0](../../releases/tag/v1.0.0) +[`csi-cc` v1.1.0](../../releases/tag/v1.1.0) ## Documentation @@ -20,6 +20,15 @@ Documentation is included in the source download, or you can view the ## Changelog +###[v. 1.1.0](../../releases/tag/v1.1.0) + +Release associated with the article from the Automated Software Engineering +journal (2016). Major changes include: + +- Support for function, call-site, and statement coverage instrumentation +- Support for more customizable tracing (see the +[online documentation](https://rawgit.com/liblit/csi-cc/master/doc/running_schemes.html)) + ###[v. 1.0.0](../../releases/tag/v1.0.0) Initial release. diff --git a/SConstruct b/SConstruct index e76f03b..3150dd6 100644 --- a/SConstruct +++ b/SConstruct @@ -3,18 +3,38 @@ # configurable options # +from os import access, environ, X_OK + +def pathIsExecutable(key, val, env): + found = env.WhereIs(val) + if found: val = found + PathVariable.PathIsFile(key, val, env) + if not access(val, X_OK): + raise SCons.Errors.UserError('Path for option %s is not executable: %s' % (key, val)) + + opts = Variables('.scons-config', ARGUMENTS) opts.AddVariables( - PathVariable(key='LLVMBIN', - help='location of bin directory of LLVM installation', - default=None, - validator=PathVariable.PathIsDir), + PathVariable(key='LLVM_CONFIG', + help='path to llvm-config executable for LLVM installation', + default=WhereIs('llvm-config'), + validator=pathIsExecutable), PathVariable(key='CXX_ALT', help='path to alternate C++ compiler', default=None, - validator=PathVariable.PathIsFile), - ) -env = Environment(options=opts) + validator=pathIsExecutable), + BoolVariable(key='DEBUG', + help='Compile with extra information for debugging', + default=False), + BoolVariable(key='MEMCHECK', + help="Run instrumentor tests under Valgrind's memcheck tool", + default=False), +) +env = Environment( + options=opts, + tools=('default', 'llvm'), + toolpath=('instrumentor',), +) opts.Save('.scons-config', env) ######################################################################## @@ -23,7 +43,7 @@ opts.Save('.scons-config', env) # CacheDir('.scons-cache') -SetOption('implicit_cache', True) +#SetOption('implicit_cache', True) SetOption('max_drift', 1) @@ -38,6 +58,7 @@ env = env.Clone( '-Wextra', '-Werror', '-Wformat=2', + '${("", "-g")[DEBUG]}', ), ) @@ -59,6 +80,8 @@ SConscript(dirs=[ 'tests', ]) +Default('Release') + ######################################################################## # @@ -87,4 +110,4 @@ package = env.Package( source=sources, )[0] -AddPostAction(package, [Chmod('$TARGET', 0644)]) +AddPostAction(package, Chmod('$TARGET', 0644)) diff --git a/doc/building_comments.html b/doc/building_comments.html index 02563be..aeb610d 100644 --- a/doc/building_comments.html +++ b/doc/building_comments.html @@ -28,8 +28,9 @@

Additional Comments and Suggestions

As noted, LLVM version 3.1 or newer is required. If LLVM is not installed in a standard location, you will probably have to tell scons where to find the -bin directory of your installation. You can do this by a command like
-scons LLVMBIN=/path/to/LLVMBIN-DIR

+LLVM configuration helper for your installation. You can do this by a command +like
+scons LLVM_CONFIG=/path/to/llvm-config

If you get an error like
/usr/bin/ld: cannot find -lLLVM-3.X
diff --git a/doc/index.html b/doc/index.html index c4c9bd6..595335d 100644 --- a/doc/index.html +++ b/doc/index.html @@ -16,9 +16,11 @@

CSI: Crash Scene Investigation

A guide for the instrumenting compiler


Summary

-

The CSI compiler instruments programs with two tracing strategies as described -in [1]—Path Tracing and -Callsite Coverage.

+

The CSI compiler instruments programs with two forms of customizable tracing +as described in +[1, + 2]—Path Tracing and +Program Coverage.

Contents