#include "llvm/IR/PredIteratorCache.h"
#include "llvm/IR/ValueHandle.h"
#include "llvm/Pass.h"
+#include <optional>
namespace llvm {
void releaseMemory();
/// Return the clobber offset to dependent instruction.
- Optional<int32_t> getClobberOffset(LoadInst *DepInst) const {
+ std::optional<int32_t> getClobberOffset(LoadInst *DepInst) const {
const auto Off = ClobberOffsets.find(DepInst);
if (Off != ClobberOffsets.end())
return Off->getSecond();
/// A wrapper analysis pass for the legacy pass manager that exposes a \c
/// MemoryDepnedenceResults instance.
class MemoryDependenceWrapperPass : public FunctionPass {
- Optional<MemoryDependenceResults> MemDep;
+ std::optional<MemoryDependenceResults> MemDep;
public:
static char ID;