blob: e675dfde41cef2db0a9e4cdc6118469c5b5a05b1 [file]
// Copyright 2020 The IREE Authors
//
// Licensed under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
// This file defines a helper to add passes to the global registry.
#ifndef IREE_TOOLS_INIT_PASSES_H_
#define IREE_TOOLS_INIT_PASSES_H_
#include <cstdlib>
#include "iree/compiler/Codegen/Passes.h"
#include "iree/compiler/Dialect/HAL/Conversion/Passes.h"
#include "iree/tools/init_iree_passes.h"
#include "iree/tools/init_mlir_passes.h"
namespace mlir {
namespace iree_compiler {
// Registers IREE core passes and other important passes to the global registry.
inline void registerAllPasses() {
registerAllIreePasses();
registerCodegenPasses();
registerMlirPasses();
registerHALConversionPasses();
}
} // namespace iree_compiler
} // namespace mlir
#endif // IREE_TOOLS_INIT_PASSES_H_