CommPtr Comm::set_rate(double rate)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
rate_ = rate;
return this;
}
CommPtr Comm::set_mailbox(Mailbox* mailbox)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
mailbox_ = mailbox;
return this;
}
CommPtr Comm::set_src_data(void* buff)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
xbt_assert(dst_buff_ == nullptr, "Cannot set the src and dst buffers at the same time");
src_buff_ = buff;
return this;
CommPtr Comm::set_src_data_size(size_t size)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
src_buff_size_ = size;
return this;
}
CommPtr Comm::set_src_data(void* buff, size_t size)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
xbt_assert(dst_buff_ == nullptr, "Cannot set the src and dst buffers at the same time");
src_buff_ = buff;
CommPtr Comm::set_dst_data(void** buff)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
xbt_assert(src_buff_ == nullptr, "Cannot set the src and dst buffers at the same time");
dst_buff_ = buff;
return this;
CommPtr Comm::set_dst_data(void** buff, size_t size)
{
xbt_assert(state_ == State::INITED, "You cannot use %s() once your communication started (not implemented)",
- __FUNCTION__);
+ __func__);
xbt_assert(src_buff_ == nullptr, "Cannot set the src and dst buffers at the same time");
dst_buff_ = buff;
Comm* Comm::do_start()
{
xbt_assert(get_state() == State::INITED || get_state() == State::STARTING,
- "You cannot use %s() once your communication started (not implemented)", __FUNCTION__);
+ "You cannot use %s() once your communication started (not implemented)", __func__);
auto myself = kernel::actor::ActorImpl::self();
Comm* Comm::detach()
{
xbt_assert(state_ == State::INITED || state_ == State::STARTING,
- "You cannot use %s() once your communication is %s (not implemented)", __FUNCTION__, get_state_str());
+ "You cannot use %s() once your communication is %s (not implemented)", __func__, get_state_str());
xbt_assert(dst_buff_ == nullptr && dst_buff_size_ == 0, "You can only detach sends, not recvs");
detached_ = true;
start();