To check if a ModelAction is for a C/C++ atomic variable (vs. a Thread
action, a fake ModelChecker action, a mutex, a condition variable, etc.)
return (type == ATOMIC_TRYLOCK && value == VALUE_TRYFAILED);
}
+/** @return True if this operation is performed on a C/C++ atomic variable */
+bool ModelAction::is_atomic_var() const
+{
+ return is_read() || could_be_write();
+}
+
bool ModelAction::is_uninitialized() const
{
return type == ATOMIC_UNINIT;
bool is_notify_one() const;
bool is_success_lock() const;
bool is_failed_trylock() const;
+ bool is_atomic_var() const;
bool is_uninitialized() const;
bool is_read() const;
bool is_write() const;