[Mlir-commits] [mlir] [MLIR][Presburger] Generating functions and quasi-polynomials for Barvinok's algorithm (PR #75702)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Wed Dec 20 04:20:50 PST 2023
================
@@ -0,0 +1,65 @@
+//===- QuasiPolynomial.cpp - Quasipolynomial Class --------------*- C++ -*-===//
+//
+// Part of the LLVM Project, 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
+//
+//===----------------------------------------------------------------------===//
+
+#include "mlir/Analysis/Presburger/QuasiPolynomial.h"
+#include "mlir/Analysis/Presburger/Fraction.h"
+#include "mlir/Analysis/Presburger/IntegerRelation.h"
+#include "mlir/Analysis/Presburger/Matrix.h"
+#include "mlir/Analysis/Presburger/PresburgerSpace.h"
+#include "mlir/Analysis/Presburger/Utils.h"
+#include "mlir/Support/LogicalResult.h"
+#include <optional>
+
+using namespace mlir;
+using namespace presburger;
+
+QuasiPolynomial::QuasiPolynomial(
+ unsigned numParam, SmallVector<Fraction> coeffs,
+ std::vector<std::vector<SmallVector<Fraction>>> aff)
+ : numParam(numParam), coefficients(coeffs), affine(aff) {
+ // Find the first term which involves some affine function.
----------------
Abhinav271828 wrote:
No I intended it as part of the explanation for the assert; it's meant to be read along with the following lines
https://github.com/llvm/llvm-project/pull/75702
More information about the Mlir-commits
mailing list