Loading [MathJax]/jax/output/HTML-CSS/config.js
CIRCT 21.0.0git
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
InferIntRangeInterfaceImpls.cpp
Go to the documentation of this file.
1//===- InferIntRangeInterfaceImpls.cpp - Integer range impls for HW -------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
10
11#include "mlir/Interfaces/InferIntRangeInterface.h"
12#include "mlir/Interfaces/Utils/InferIntRangeCommon.h"
13
14using namespace mlir;
15using namespace mlir::intrange;
16using namespace circt;
17
18//===----------------------------------------------------------------------===//
19// ConstantOp
20//===----------------------------------------------------------------------===//
21
22void hw::ConstantOp::inferResultRanges(ArrayRef<ConstantIntRanges> argRanges,
23 SetIntRangeFn setResultRange) {
24 setResultRange(getResult(), ConstantIntRanges::constant(getValue()));
25}
The InstanceGraph op interface, see InstanceGraphInterface.td for more details.