[PATCH] D14572: sanitizer: add support for trace coverage

Kostya Serebryany via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 12 15:33:35 PST 2015


kcc added a comment.

I see you have not submitted this yet... 
And I have an afterthought....

The tracing that we have now (https://github.com/google/sanitizers/wiki/AddressSanitizerBasicBlockTracing) 
is more complex but it actually provides more functionality at almost same cost.

1. It uses consecutive BB ids instead of PCs. This will buy us cheaper analysis because with consecutive ids we can use a bit set.

2. It will allow us to implement coverage frontier:

at compile time, we create a static table that stores the Control Flow Graph of the function using the pairs of IDs. 
at run-time, we load this table and we can find the edges that belong to the frontier (i.e. the edges that were never executed but that have one preceding edge that was executed)
(I have a patch for that lying somewhere).
This will be much harder to achieve with raw PCs.


http://reviews.llvm.org/D14572





More information about the llvm-commits mailing list