Imported Upstream version 5.18.0.205

Former-commit-id: 7f59f7e792705db773f1caecdaa823092f4e2927
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2018-11-16 08:20:38 +00:00
parent 5cd5df71cc
commit 8e12397d70
28486 changed files with 3867013 additions and 66 deletions

View File

@@ -0,0 +1,5 @@
#include <stdio.h>
#include <string>
__attribute__((noinline))
void foo() { printf("foo\n"); }

View File

@@ -0,0 +1 @@
fun:bar*

View File

@@ -0,0 +1,3 @@
# this path looks like sancov/Inputs/../Inputs/ in the binary.
# Make sure it is filtered out correctly.
src:*/sancov/Inputs/test.cpp

Binary file not shown.

View File

@@ -0,0 +1 @@
854459d69fea1d05f668bfe766c77b9955f7d3f2

Binary file not shown.

View File

@@ -0,0 +1,25 @@
{
"covered-points" : ["4e132b", "4e1472", "4e1520", "4e1553", "4e1586"],
"binary-hash" : "BB3CDD5045AED83906F6ADCC1C4DAF7E2596A6B5",
"point-symbol-info" : {
"test/tools/sancov/Inputs/foo.cpp" : {
"foo()" : {
"4e178c" : "5:0"
}
},
"test/tools/sancov/Inputs/test.cpp" : {
"bar(std::string)" : {
"4e132b" : "12:0"
},
"main" : {
"4e1472" : "14:0",
"4e14c2" : "16:9",
"4e1520" : "17:5",
"4e1553" : "17:5",
"4e1586" : "17:5",
"4e1635" : "19:1",
"4e1690" : "17:5"
}
}
}
}

Binary file not shown.

View File

@@ -0,0 +1,25 @@
{
"covered-points" : ["4e132b", "4e1472", "4e14c2", "4e1520", "4e1553", "4e1586", "4e178c"],
"binary-hash" : "BB3CDD5045AED83906F6ADCC1C4DAF7E2596A6B5",
"point-symbol-info" : {
"test/tools/sancov/Inputs/foo.cpp" : {
"foo()" : {
"4e178c" : "5:0"
}
},
"test/tools/sancov/Inputs/test.cpp" : {
"bar(std::string)" : {
"4e132b" : "12:0"
},
"main" : {
"4e1472" : "14:0",
"4e14c2" : "16:9",
"4e1520" : "17:5",
"4e1553" : "17:5",
"4e1586" : "17:5",
"4e1635" : "19:1",
"4e1690" : "17:5"
}
}
}
}

View File

@@ -0,0 +1 @@
9ffac6f81b9d935988b2462b1edc86a94b5cbfc0

View File

@@ -0,0 +1 @@
3eaab93b4cfd7f52ed76c2a4f3585884be9031d8

View File

@@ -0,0 +1,19 @@
// compile & generate coverage data using:
// clang++ -g -o test-linux_x86_64 -fsanitize=address -fsanitize-coverage=bb test.cpp ../Inputs/foo.cpp
// ASAN_OPTIONS="coverage=1" ./test-linux_x86_64 && mv test-linux_x86_64.??*.sancov test-linux_x86_64.0.sancov
// ASAN_OPTIONS="coverage=1" ./test-linux_x86_64 1 && mv test-linux_x86_64.??*.sancov test-linux_x86_64.1.sancov
#include <stdio.h>
#include <string>
void foo();
__attribute__((noinline))
std::string bar(std::string str) { printf("bar\n"); return str; }
int main(int argc, char **argv) {
if (argc == 2)
foo();
bar("str");
printf("main\n");
}