This is an archive of the discontinued LLVM Phabricator instance.

[NativeProcessLinux] Pass around threads by reference
ClosedPublic

Authored by labath on Aug 21 2015, 6:40 AM.

Details

Summary

Most NPL private functions took (shared) pointers to threads as arguments. This meant that the
callee could not be sure if the pointer was valid and so most functions were peppered with
null-checks. Now, I move the check closer to the source, and pass around the threads as
references (which are then assumed to be valid).

Diff Detail

Event Timeline

labath updated this revision to Diff 32824.Aug 21 2015, 6:40 AM
labath retitled this revision from to [NativeProcessLinux] Pass around threads by reference.
labath updated this object.
labath added a reviewer: tberghammer.
labath added a subscriber: lldb-commits.
tberghammer accepted this revision.Aug 21 2015, 8:27 AM
tberghammer edited edge metadata.

Looks good (I assume when you dropped const from the argument it was intentional)

This revision is now accepted and ready to land.Aug 21 2015, 8:27 AM
This revision was automatically updated to reflect the committed changes.