about summary refs log tree commit diff homepage
path: root/test/Runtime
AgeCommit message (Collapse)Author
2019-03-15Renamed --seed-out to --seed-file and --seed-out-dir to --seed-dir, and ↵Cristian Cadar
placed them in the seeding category. Moved options and option categories in Executor.cpp to the klee namespace.
2019-03-07Renamed %llvmgcc and %llvmgxx to %clang and %clangxx respectively.Cristian Cadar
2018-12-19Added checks option category, moved --optimize to starting category, renamed ↵Cristian Cadar
original --run-in option to --running-dir
2018-11-02Replaced --no-externals and --allow-external-sym-calls with ↵Cristian Cadar
--external-calls, updated tests accordingly, and improved documentation on external calls
2018-10-29add %OOopt to recently added tests and ConcreteJulian Büning
2018-10-26Added gen-bout tool to generate ktest file (file.bout) using specified ↵Andrew Santosa
concrete arguments and files. * Sample use cases: * Using an interesting input as a seed, such as a crashing input. * Analyzing the path condition of a crashing input. * Also added the test: test/Runtime/POSIX/GenBout.c
2018-10-26llvm5: test, add -disable-O0-optnone to -O0Jiri Slaby
Otherwise optimizations done in klee won't have any effect. Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
2018-09-29Changed code to create up to 100 properly-numbered symbolic arguments, and ↵Cristian Cadar
add a corresponding check.
2018-09-29Add checks for correct usage of the POSIX model, together with an associated ↵Cristian Cadar
test.
2018-09-20Removed unused --sym-files 0 0 argument from FD_Fail test and rewrote the ↵Cristian Cadar
test to use FileCheck instead of grep
2018-09-20Updated IoCtl test to use --sym-stdin instead of --sym-files 0 x to make ↵Cristian Cadar
stdin symbolic and removed unused arguments to main.
2018-09-20Updated DirSeek test to use --sym-stdin instead of --sym-files 0 x to make ↵Cristian Cadar
stdin symbolic.
2018-09-10Add testcase to run POSIX environment and main without argumentsMartin Nowack
2018-09-06Use FileCheck and LINE instead of grep if possibleMartin Nowack
As we do not support LLVM 2.9 anymore, we can use FileCheck LINE instead of hard coding line numbers.
2018-09-06runtime: fix memory error in canonicalize_file_nameFrank Busse
Fixes #46 and reverts #47. As stated in #46, the solution works for musl, glibc etc. However, the code in stub.c is executed by uclibc and uclibc doesn't allocate the target buffer in realpath. The memory error occured while running df for 10min with DFS.
2018-07-04Reorder linking and optimizationsMartin Nowack
Link intrinsic library before executing optimizations. This makes sure that any optimization run by KLEE on the module is executed for the intrinsic library as well. Support .ll files as input for KLEE as well.
2018-05-17Add support for concretizing symbolic objects passed to external functionsTimotej Kapus
2018-05-09Fix test case to check for correct call stringMartin Nowack
2018-05-07Fixed test case to exercise modification to utimes()Cristian Cadar
2018-05-07Fixed utimes() behavior for symbolic files when the second argument is NULLyxliang01
2018-05-05Fix handling of errno if external functions are invokedMartin Nowack
If an external function in KLEE is invoked, it might update errno. Previously, the errno specific variable in a state was only updated if it was part of the executed instructions. That opened up a timeframe that increased the likelihood of errno being overwritten by another method call. This patch fixes two issues: * the errno of the KLEE process state is updated before the external function call allowing to detect changes to it later on * after the external call, the memory object of errno is directly updated with its new value, reducing the likelihood to be overwritten by another call Additional features: * Add support for `errno()` for Darwin as well. * Simplified errno handling in POSIX layer
2017-08-10Added a basic test for klee-replayCristian Cadar
2017-03-17test: POSIX, stop FD_Fail to failJiri Slaby
In our build environments, /etc/fstab is an empty file. Use /etc/mtab, which should be non-empty anywhere, hopefully. For the reference, the test fails as follows: FAIL: KLEE :: Runtime/POSIX/FD_Fail.c (188 of 212) ************ TEST 'KLEE :: Runtime/POSIX/FD_Fail.c' FAILED ************ Script: -- clang-3.8 -Iinclude test/Runtime/POSIX/FD_Fail.c -emit-llvm -O0 -c -o build/test/Runtime/POSIX/Output/FD_Fail.c.tmp1.bc rm -rf build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.klee-out build/bin/klee --output-dir=build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.klee-out --libc=uclibc --posix-runtime build/test/Runtime/POSIX/Output/FD_Fail.c.tmp1.bc --sym-files 0 0 --max-fail 1 > build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.log grep -q "fread(): ok" build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.log grep -q "fread(): fail" build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.log grep -q "fclose(): ok" build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.log grep -q "fclose(): fail" build/test/Runtime/POSIX/Output/FD_Fail.c.tmp.log -- Exit Code: 1 Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
2017-03-06test: POSIX/DirSeek, cleanupJiri Slaby
* remove unused stat variable * use %ld for long int Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
2016-05-28Fixed an incorrect read() invocation and missing includes for FD_Fail2.cCristian Cadar
2016-05-24Split creation of symbolic files and stdin in two distinct optionsAndrea Mattavelli
2015-09-25Don't use /tmp for futimesat unit testAndrew Chi
This causes problems on a shared machine where multiple users are running the KLEE unit tests.
2015-04-01[tests] Fix undefined functionMartin Nowack
Add some missing header to silence compiler warnings
2014-09-15Generate fake files for test casesMartin Nowack
2014-09-14Enable test case againMartin Nowack
2014-09-14Use not test instead of non-existing FAIL.Martin Nowack
2014-09-14Fix testcase FD_Fail2.cMartin Nowack
Major issue was that puts was used for the succeed printf calls. With newer gcc/clang versions, printf is always used. The former took different code paths leading to much more possibilities to trigger failed writes and therefore generating more test cases. This patch avoids the generation of puts. And checks for the 4 possible generated test cases for 2 possible errors.
2014-09-14[Travis] Disable Write2 on Travis with LLVM-3.4 for now, to see if this ↵Daniel Dunbar
prevents the hang we are seeing.
2014-09-12[tests] Set --output-dir on all test runs, in support of running tests in ↵Daniel Dunbar
parallel. - It would be nice if there was an easier way to do this that didn't involve editing all of the tests (like running each test in its own directory), but this approach fixes #146 and doesn't involve changing 'lit' or writing a wrapper harness. My assumption is a lot of tests start are derived from another one, so hopefully following this convention won't be burdensome, and I updated 'make check' so that it will produce an error if any test runs klee without --output-dir (by checking for the existing of klee-last files). - This also helps with #147 but I still can't fully run tests in parallel (I start hitting STP errors).
2014-01-29Fix Runtime/POSIX/Isatty.c test under LLVM3.3. The program makesDan Liew
a call fprintf(stderr,...). llvm-gcc transforms this to a call to fwrite() however clang does not so klee-uclibc's fprintf will be called instead and if klee-uclibc is compiled with KLEE_SYM_PRINTF then output will always go stdout if the FILE is stdout or stderr. The end result of this is that when we build with Clang under LLVM3.3 is that the fprintf(stderr,...) print outs go to standard output instead and so the test would fail because it expects the fprintf(stderr,...) to be on stderr. This test sort of fixes this by having the test check stdout for the fprintf(stderr,...) statements too.
2014-01-20Only run klee-uclibc tests if KLEE was configured with klee-uclibcDan Liew
support.
2014-01-20Remove the last remnants (I think) of DejaGNU. Goodbye!Dan Liew
Say hello to our new friend, llvm-lit :)
2014-01-20Only run SELinux test if support for SELinux was detected at configureDan Liew
time.
2014-01-20Added Runtime/POSIX/lit.local.cfg file that prevents the POSIXDan Liew
tests from being executed if not enabled at configure time.
2014-01-20Fixed many tests that make use of the file tool to checkDan Liew
a file created by KLEE exists. A big difference between DejaGNU and llvm-lit is that in DejaGNU the working directory is the test output directory (e.g. test/Feature/Output) but in llvm-lit the working directory is the test directory (e.g. test/Feature ) To fix this I have used the %T substitution variable for llvm-lit. I have also improved some tests by using LLVM's FileCheck tool and removing of hard coded constants for data type size in some places. This commit inevitably breaks running the tests under DejaGNU. Although it is possible to hack by introducing the %T substitution variable some tests would still be broken because the use of shell pipes in DejaGNU doesn't seem to work properly. I could work around this but it's really not worth the effort.
2013-11-14Add additional note that testcase might fail ifMartin Nowack
uclibc is compiled without symbolic printf support
2013-11-02Fix Futimesat compilation with newer gcc and clangMartin Nowack
2013-10-14Replaced --libc=klee with --libc=uclibc in two tests (as for ↵Cristian Cadar
https://github.com/ccadar/klee/issues/32) and fixed an #include in one of the tests.
2013-08-29Added some of the common *at functions to the modelPaul Marinescu
2012-09-12Restructured the command-line options for setting the searchCristian Cadar
heuristics in KLEE. The new options are documented at http://klee.llvm.org/klee-options.html. Cleaned a bit the code in UserSearcher.cpp, and fixed some test cases to use the new options. git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@163711 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-05Removed unnecessary --init-env option.Cristian Cadar
git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@154110 91177308-0d34-0410-b5e6-96231b3b80d8
2010-06-21Applied Stefan Bucur's patch that fixes a non-deterministic bug in theCristian Cadar
regression suite (see http://llvm.org/bugs/show_bug.cgi?id=7423) git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@106431 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-03Update a few things that got forgotten in the great "bout" to "ktest"Daniel Dunbar
renaming of '08. git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@72748 91177308-0d34-0410-b5e6-96231b3b80d8
2009-05-21Initial KLEE checkin.Daniel Dunbar
- Lots more tweaks, documentation, and web page content is needed, but this should compile & work on OS X & Linux. git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@72205 91177308-0d34-0410-b5e6-96231b3b80d8