Replace void* with std::byte* in AsyncRuntime to make it clear that these pointers point to a memory region.
Reviewed By: ezhulenev
Differential Revision: https://reviews.llvm.org/D140428
#ifndef MLIR_EXECUTIONENGINE_ASYNCRUNTIME_H_
#define MLIR_EXECUTIONENGINE_ASYNCRUNTIME_H_
+#include <cstddef>
#include <stdint.h>
#ifdef mlir_async_runtime_EXPORTS
using AsyncValue = struct AsyncValue;
// Async value payload stored in a memory owned by the async.value.
-using ValueStorage = void *;
+using ValueStorage = std::byte *;
// Async runtime uses LLVM coroutines to represent asynchronous tasks. Task
// function is a coroutine handle and a resume function that continue coroutine
std::atomic<State::StateEnum> state;
// Use vector of bytes to store async value payload.
- std::vector<int8_t> storage;
+ std::vector<std::byte> storage;
// Pending awaiters are guarded by a mutex.
std::mutex mu;