RobotLocomotion / drake

Model-based design and verification for robotics.
https://drake.mit.edu
Other
3.35k stars 1.27k forks source link

Add DRAKE_ASSERT statements to ensure programs being solved in parallel are actually threadsafe. #22228

Open cohnt opened 12 hours ago

cohnt commented 12 hours ago

This change is Reviewable

cohnt commented 12 hours ago

We recently added a couple pieces of code where we solve mathematical programs in parallel, without actually asserting that they're thread-safe. This isn't a problem, since they are thread-safe, but if someone changes these programs down the line and inadvertently makes them not-thread-safe, it could lead to very confusing errors.

+@alexandreamice for feature review on this one?