This is an archive of the discontinued LLVM Phabricator instance.

[AddressSanitizer] Refactor ClDebug{Min,Max} handling
ClosedPublic

Authored by thejh on Apr 6 2020, 6:00 PM.

Details

Summary

A following commit will split the loop over ToInstrument into two.
To avoid having to duplicate the condition for suppressing instrumentation
sites based on ClDebug{Min,Max}, refactor it out into a new function.

While we're at it, we can also avoid the indirection through
NumInstrumented for setting FunctionModified.

This is patch 1/4 of a patch series:
https://reviews.llvm.org/D77616 [PATCH 1/4] [AddressSanitizer] Refactor ClDebug{Min,Max} handling
https://reviews.llvm.org/D77617 [PATCH 2/4] [AddressSanitizer] Split out memory intrinsic handling
https://reviews.llvm.org/D77618 [PATCH 3/4] [AddressSanitizer] Refactor: Permit >1 interesting operands per instruction
https://reviews.llvm.org/D77619 [PATCH 4/4] [AddressSanitizer] Instrument byval call arguments

Diff Detail

Event Timeline

thejh created this revision.Apr 6 2020, 6:00 PM
thejh edited the summary of this revision. (Show Details)Apr 6 2020, 6:13 PM
thejh added reviewers: kcc, glider.

I've skimmed through the four patches and they look good. Can you please fix the lint checks?

thejh updated this revision to Diff 257385.Apr 14 2020, 9:47 AM

fix clang-format warnings

thejh updated this revision to Diff 257435.Apr 14 2020, 12:01 PM

fix clang-tidy complaint

thejh added a comment.Apr 14 2020, 3:34 PM

@glider Alright, I've fixed the clang-format stuff (and fixed a mistake where I put a variable declaration in the wrong patch, and another clang-tidy warning about coding conventions on variable naming). The build status is "passed" on all four patches now.

glider accepted this revision.Apr 15 2020, 8:06 AM
This revision is now accepted and ready to land.Apr 15 2020, 8:06 AM
thejh updated this revision to Diff 259924.Apr 24 2020, 10:35 AM

rebase to make harbormaster happy

thejh added a comment.Apr 24 2020, 3:52 PM

I don't understand those latest build failures at all. I've run the regression tests, with mlir enabled. I see no failures, even when building off the exact commit in the build log. Manually running mlir/test/Dialect/Vector/vector-transforms.mlir doesn't show any errors either.

Is this just some random flake in the build system? Can I just ignore that? Should I resubmit? Should I do something else?

thejh updated this revision to Diff 260018.Apr 24 2020, 3:55 PM

let's see whether the build system is more happy if I just resend this...

thejh updated this revision to Diff 261149.Apr 30 2020, 2:00 AM
glider closed this revision.Apr 30 2020, 6:45 AM

I've landed this revision. There are some difficulties with the rest, sorting that out.

glider reopened this revision.Apr 30 2020, 7:35 AM
This revision is now accepted and ready to land.Apr 30 2020, 7:35 AM
glider updated this revision to Diff 261223.Apr 30 2020, 7:35 AM

Trying to fix the state of the things

Harbormaster completed remote builds in B55301: Diff 261224.
This revision was automatically updated to reflect the committed changes.