diff options
author | Daniel Dunbar <daniel@zuster.org> | 2009-05-22 16:27:06 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2009-05-22 16:27:06 +0000 |
commit | ea6e216751979131b269ed31873edbe7e8b752a3 (patch) | |
tree | 8d4911a0bcd4c99ce3e832fce88bdad34bd61bfc /runtime/Intrinsic | |
parent | 21bbf33d53209f1bc30562b1bebb9f568c5c7360 (diff) | |
download | klee-ea6e216751979131b269ed31873edbe7e8b752a3.tar.gz |
Add "name" argument to klee_make_symbolic, and kill off klee_make_symbolic_name.
- For compatibility we still accept 2 argument form of klee_make_symbolic, but this will go away eventually. git-svn-id: https://llvm.org/svn/llvm-project/klee/trunk@72265 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'runtime/Intrinsic')
-rw-r--r-- | runtime/Intrinsic/klee_int.c | 2 | ||||
-rw-r--r-- | runtime/Intrinsic/klee_make_symbolic.c | 14 | ||||
-rw-r--r-- | runtime/Intrinsic/klee_range.c | 5 |
3 files changed, 4 insertions, 17 deletions
diff --git a/runtime/Intrinsic/klee_int.c b/runtime/Intrinsic/klee_int.c index 88ec5026..56f0f9dc 100644 --- a/runtime/Intrinsic/klee_int.c +++ b/runtime/Intrinsic/klee_int.c @@ -12,6 +12,6 @@ int klee_int(const char *name) { int x; - klee_make_symbolic_name(&x, sizeof x, name); + klee_make_symbolic(&x, sizeof x, name); return x; } diff --git a/runtime/Intrinsic/klee_make_symbolic.c b/runtime/Intrinsic/klee_make_symbolic.c deleted file mode 100644 index b9dec2a7..00000000 --- a/runtime/Intrinsic/klee_make_symbolic.c +++ /dev/null @@ -1,14 +0,0 @@ -//===-- klee_make_symbolic.c ----------------------------------------------===// -// -// The KLEE Symbolic Virtual Machine -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#include <klee/klee.h> - -void klee_make_symbolic(void *addr, unsigned nbytes) { - klee_make_symbolic_name(addr, nbytes, "unnamed"); -} diff --git a/runtime/Intrinsic/klee_range.c b/runtime/Intrinsic/klee_range.c index 59d1a05e..5da6a7a5 100644 --- a/runtime/Intrinsic/klee_range.c +++ b/runtime/Intrinsic/klee_range.c @@ -13,12 +13,13 @@ int klee_range(int start, int end, const char* name) { int x; - assert(start < end); + if (start >= end) + klee_report_error(__FILE__, __LINE__, "invalid range", "user"); if (start+1==end) { return start; } else { - klee_make_symbolic_name(&x, sizeof x, name); + klee_make_symbolic(&x, sizeof x, name); /* Make nicer constraint when simple... */ if (start==0) { |