Age | Commit message (Collapse) | Author |
|
Do not instrument divisions which do have a constant non-zero value.
|
|
Use llvm::Builder instead of raw `*Inst::create()` functions.
Builder automatically manages metadata (e.g. debug, TBAA, ..) such that
we don't have to take care of this automatically.
Updated code to C++11 and clang-formated it.
|
|
Simplify the handling of metadata attached to LLVM IR that is specific
to KLEE.
|
|
|
|
and introduce klee_open_compressed_output_file with similar behavior
along some other minor improvements
|
|
|
|
|
|
|
|
|
|
* use `using` instead of typdef
* use `collection.empty()` instead of size
* use `auto` if clear
* use `emplace_back` where useful
* use `nullptr` instead of NULL
* use `override` if applicable
* use `explicit` for constructor to avoid implicit conversion
|
|
Don't pollute the project include directory with optimization specific
headers.
|
|
Remove unneeded headers from include files
|
|
Conditions are checked inside of `optimizeExpr()`
anyway. This simplifies the code a lot.
|
|
|
|
simplifies code a lot.
|
|
avoid ambiguity of valueOnly parameter
|
|
|
|
|
|
|
|
|
|
to have only solver options.
|
|
Currently KLEE only handles the first segfault in external calls
as it doesn't unblock SIGSEGV afterwards. This patch unblocks the
signal and enables handling of multiple failing calls.
|
|
|
|
|
|
|
|
AddressSpace::checkPointerInObject() that is called in both the forward and the backward searches. This makes the code more modular and removes a large part of duplicated code and should also address the non-deterministic coverage in the resolve() function which affects Codecov reports.
|
|
|
|
change)
|
|
Starting with LLVM 4, we have getStructTypeOrNull(), so use it.
operator* in post-4 will have a different semantics.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
So handle the type specially whenever needed.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
LLVM 4 removes the old time interface and starts using the C++11's
chrono. So switch to that in klee for LLVM 4 too.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
LLVM 4 renamed and splitted some headers. Take this into account in
includes.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
|
|
Validate if the user-selected entry function exists. Do not assume it is
`main`.
|
|
|
|
Replace the remaining occurrences of `Inst::Create()` with
`llvm::Builder` to manage metadata automatically and to fold
instructions.
C++11 it and clang-format
|
|
|
|
|
|
* handle BlockAddress (which is not a valid function pointer)
* there is no instruction with opcode 0
* add test for functionality
|
|
With version 3.5, LLVM introduced a subtle semantic change in the API of
`Value`. With that change, `use_begin()` is renamed to `user_begin()`.
Additionally, a new method `use_begin()` with a different meaning was
introduced. Now, `use_begin()` actually iterates over `Use`s, whereas
before, dereferencing it would give a `User *`. For further details,
please refer to https://reviews.llvm.org/rL203364.
Due to the reintroduction of `use_begin()`, existing code may still
compile, although the semantics have changed. In the code changed with
this patch, all `dyn_cast`s for `Use` fail and the else branch is
always taken.
|
|
addresses comment made by @adrianherrera in #385
|
|
LLVM commit eac309550f25 removed implicit iterator conversions. So we
have to get the iterators explicitly now.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
After LLVM commit 25569fdcdab0, archive iterator returns
object::Archive::Child instead of child_iterator, adapt to that.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
LLVM commit d912be98f8eb changed the prototype of linkModules to accept
std::unique_ptr. Adapt to that.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
createFunctionAttrsPass was split to createPostOrderFunctionAttrsPass
and createReversePostOrderFunctionAttrsPass in LLVM commit e96fb9ab15d4.
createGlobalsModRefPass was changed to createGlobalsAAWrapperPass in
LLVM commit 9146833fa313.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
The rounding was removed because it was never needed:
llvm-mirror/llvm@ff278be
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
|
|
clang-format on patch)
|