-/* Copyright (c) 2019-2021. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2019-2022. The SimGrid Team. All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* under the terms of the license (GNU LGPL) which comes with this package. */
#include "src/kernel/activity/SemaphoreImpl.hpp"
-#include "src/kernel/activity/SynchroRaw.hpp"
+#include "src/kernel/activity/Synchro.hpp"
#include "src/kernel/actor/SimcallObserver.hpp"
#include <cmath> // std::isfinite
xbt_assert(std::isfinite(timeout), "timeout is not finite!");
if (value_ <= 0) {
- RawImplPtr synchro(new RawImpl([this, issuer]() {
+ SynchroImplPtr synchro(new SynchroImpl([this, issuer]() {
this->remove_sleeping_actor(*issuer);
auto* observer = dynamic_cast<kernel::actor::SemAcquireSimcall*>(issuer->simcall_.observer_);
xbt_assert(observer != nullptr);
}
}
-/** Increase the refcount for this semaphore */
-SemaphoreImpl* SemaphoreImpl::ref()
-{
- intrusive_ptr_add_ref(this);
- return this;
-}
-
-/** Decrease the refcount for this mutex */
-void SemaphoreImpl::unref()
-{
- intrusive_ptr_release(this);
-}
-
} // namespace activity
} // namespace kernel
} // namespace simgrid