#pragma once

#include "llvm/Support/CommandLine.h"

#define INSTRUMENTSTAGE_ENUM_PIM

#define INSTRUMENTSTAGE_CL_ENUM_PIM

#define PROFILEIR_CL_ENUM_PIM

#define OPTREPORT_ENUM_PIM

#define OPTREPORT_CL_ENUM_PIM

namespace onnx_mlir {
typedef enum {
  EmitSpatial = 0,
  EmitPim = 1,
  EmitPimBufferized = 2,
  EmitPimCodegen = 3
} PimEmissionTargetType;

extern llvm::cl::OptionCategory OnnxMlirOptions;
extern llvm::cl::opt<PimEmissionTargetType> pimEmissionTarget;

extern llvm::cl::opt<bool> pimOnlyCodegen;
extern llvm::cl::opt<bool> useExperimentalConvImpl;

extern llvm::cl::opt<size_t> crossbarSize;
extern llvm::cl::opt<size_t> crossbarCountInCore;
extern llvm::cl::opt<long> coresCount;

// This option, by default set to false, will ignore an error when resolving a
// specific tiles of the operands of a concat. This specific case is when the
// wanted tile is generated by two separate operands of the concat. If this is
// set to false, this corner case will assert an error. If this is set to true,
// a simplification is performed and only the tile from the first operand is
// taken.
extern llvm::cl::opt<bool> ignoreConcatError;

} // namespace onnx_mlir
