Details
Details
- Reviewers
kcc samsonov - Commits
- rGd02ce13bd97c: SanitizerCoverage: Use `createSanitizerCtor` to create ctor and call init
rG5bc0feb3deaf: SanitizerCoverage: Use `createSanitizerCtor` to create ctor and call init
rL236951: SanitizerCoverage: Use `createSanitizerCtor` to create ctor and call init
rL236780: SanitizerCoverage: Use `createSanitizerCtor` to create ctor and call init
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Transforms/Instrumentation/SanitizerCoverage.cpp | ||
---|---|---|
163 ↗ | (On Diff #23072) | Isn't this function supposed to be created in createSanitizerCtor? |
lib/Transforms/Instrumentation/SanitizerCoverage.cpp | ||
---|---|---|
163 ↗ | (On Diff #23072) | Good catch, thanks! I will include it in the next revision. It needs a test to check init function is called from module ctor, as well as renaming createSanitizerCtor below. |
Comment Actions
- createSanitizerCtor renamed to createSanitizerCtorAndInitFunctions to match with changes in D8777
- SanCovModuleInit was initialized with checkInterfaceFunction by mistake; this is already done by createSanitizerCtorAndInitFunctions
Turns out, there is already a test checking module ctor, and call to init function, in test/Instrumentation/SanitizerCoverage/coverage.ll.
Comment Actions
LGTM
lib/Transforms/Instrumentation/SanitizerCoverage.cpp | ||
---|---|---|
271 ↗ | (On Diff #25227) | No need to initialize this variable, as it should be initialized by subsequent call. |
272 ↗ | (On Diff #25227) | Note that SanCovModuleInit is not used anywhere, maybe you can also turn it into a local variable, and delete the class member? |
lib/Transforms/Instrumentation/SanitizerCoverage.cpp | ||
---|---|---|
272 ↗ | (On Diff #25227) | (or just use std::ignore) |