================
@@ -2592,13 +2633,24 @@ bool ThreadSafetyAnalyzer::join(const FactEntry &A,
const FactEntry &B,
/// \param JoinLoc The location of the join point for error reporting
/// \param EntryLEK The warning if a mutex is missing from \p EntrySet.
/// \param ExitLEK The warning if a mutex is missing from \p ExitSet.
-void ThreadSafetyAnalyzer::intersectAndWarn(FactSet &EntrySet,
- const FactSet &ExitSet,
- SourceLocation JoinLoc,
- LockErrorKind EntryLEK,
- LockErrorKind ExitLEK) {
+/// \param TrylockRebranchCaps Capabilities acquired by a try-lock whose result
+/// the joining block's terminator branches on; differences in these are not
+/// diagnosed because the paths re-diverge at the terminator (but they are
+/// still removed from the intersection, and conditionally re-added on the
+/// outgoing edges by getEdgeLockset()).
+void ThreadSafetyAnalyzer::intersectAndWarn(
+ FactSet &EntrySet, const FactSet &ExitSet, SourceLocation JoinLoc,
+ LockErrorKind EntryLEK, LockErrorKind ExitLEK,
+ const CapExprSet *TrylockRebranchCaps) {
----------------
aaronpuchert wrote:
The function used to look only at lock sets at the current point, but now we're
looking into the future of the control flow graph. This seems like a layering
violation to me.
https://github.com/llvm/llvm-project/pull/209796
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits