-/* Copyright (c) 2019-2020. The SimGrid Team. All rights reserved. */
+/* Copyright (c) 2019-2021. 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. */
IoPtr Disk::io_init(sg_size_t size, Io::OpType type)
{
- return IoPtr(new Io(this, size, type));
+ return Io::init()->set_disk(this)->set_size(size)->set_op_type(type);
}
IoPtr Disk::read_async(sg_size_t size)