We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mull supports mutations for negate operator. (see https://mull.readthedocs.io/en/latest/SupportedMutations.html)
$ cat example.c
int main() { int a = 2; if (!a) a = 4; return 0; }
$ clang -fembed-bitcode -g example.c -o example $ mull-cxx ./example [info] Extracting bitcode from executable (threads: 1) [################################] 1/1. Finished in 0ms [info] Loading bitcode files (threads: 1) [################################] 1/1. Finished in 10ms [info] Sanity check run (threads: 1) [################################] 1/1. Finished in 4ms [info] Gathering functions under test (threads: 1) [################################] 1/1. Finished in 0ms [info] Applying function filter: no debug info (threads: 2) [################################] 2/2. Finished in 1ms [info] Applying function filter: file path (threads: 1) [################################] 1/1. Finished in 10ms [info] Instruction selection (threads: 1) [################################] 1/1. Finished in 1ms [info] Searching mutants across functions (threads: 1) [################################] 1/1. Finished in 10ms [info] Applying filter: no debug info (threads: 1) [################################] 1/1. Finished in 0ms [info] Applying filter: file path (threads: 1) [################################] 1/1. Finished in 0ms [info] Applying filter: junk (threads: 1) [################################] 1/1. Finished in 11ms [info] Deduplicate mutants (threads: 1) [################################] 1/1. Finished in 0ms [info] No mutants found. Mutation score: infinitely high [info] Total execution time: 50ms $
sergeyb@pony:~/sources/mull_testing$ mull-cxx --version Mull: LLVM-based mutation testing https://github.com/mull-project/mull Version: 0.10.0-trunk1 Commit: 296ee8e Date: 10 Mar 2021 LLVM: 11.0.0
The text was updated successfully, but these errors were encountered:
Well this seems like there is no not happening here. Clang just reverses the order of the branches in its bitcode:
not
if(!a)
becomes
br i1 %4, label %6, label %5, !dbg !18
See https://godbolt.org/z/1rT8Wrqrz
and
if(a)
br i1 %4, label %5, label %6, !dbg !18
It may be possible to add a "switch branch mutator".
Sorry, something went wrong.
No branches or pull requests
Description
Mull supports mutations for negate operator. (see https://mull.readthedocs.io/en/latest/SupportedMutations.html)
$ cat example.c
$ clang -fembed-bitcode -g example.c -o example
$ mull-cxx ./example
[info] Extracting bitcode from executable (threads: 1)
[################################] 1/1. Finished in 0ms
[info] Loading bitcode files (threads: 1)
[################################] 1/1. Finished in 10ms
[info] Sanity check run (threads: 1)
[################################] 1/1. Finished in 4ms
[info] Gathering functions under test (threads: 1)
[################################] 1/1. Finished in 0ms
[info] Applying function filter: no debug info (threads: 2)
[################################] 2/2. Finished in 1ms
[info] Applying function filter: file path (threads: 1)
[################################] 1/1. Finished in 10ms
[info] Instruction selection (threads: 1)
[################################] 1/1. Finished in 1ms
[info] Searching mutants across functions (threads: 1)
[################################] 1/1. Finished in 10ms
[info] Applying filter: no debug info (threads: 1)
[################################] 1/1. Finished in 0ms
[info] Applying filter: file path (threads: 1)
[################################] 1/1. Finished in 0ms
[info] Applying filter: junk (threads: 1)
[################################] 1/1. Finished in 11ms
[info] Deduplicate mutants (threads: 1)
[################################] 1/1. Finished in 0ms
[info] No mutants found. Mutation score: infinitely high
[info] Total execution time: 50ms
$
Version
sergeyb@pony:~/sources/mull_testing$ mull-cxx --version
Mull: LLVM-based mutation testing
https://github.com/mull-project/mull
Version: 0.10.0-trunk1
Commit: 296ee8e
Date: 10 Mar 2021
LLVM: 11.0.0
The text was updated successfully, but these errors were encountered: