[MLIR] Simplex: split some basic functionality out into a SimplexBase class
authorArjun P <arjunpitchanathan@gmail.com>
Thu, 16 Dec 2021 12:41:31 +0000 (18:11 +0530)
committerArjun P <arjunpitchanathan@gmail.com>
Sun, 19 Dec 2021 16:54:40 +0000 (22:24 +0530)
commit4fa96b7eca73b6b235e22f18371dba8c20ed715a
tree1939a62d52036f8e928e9180be55bbc3c4451846
parentec0e4545caa18e0b55e4f25db913a10a4782fdc3
[MLIR] Simplex: split some basic functionality out into a SimplexBase class

This is a purely mechanical patch moving some functionality out from the
`Simplex` class out into a `SimplexBase` class. This pavees the way for
a future patch adding support for lexicographic optimization with a class
`LexSimplex`, which will inherit from `SimplexBase`. Inheriting directly
from `Simplex` would bring many additional functions that would not work in
`LexSimplex` because it operates slighty differently from `Simplex`. So We
split out only the basic functionality it needs to inherit into `SimplexBase`.

Reviewed By: Groverkss

Differential Revision: https://reviews.llvm.org/D115831
mlir/include/mlir/Analysis/Presburger/Simplex.h
mlir/lib/Analysis/Presburger/Simplex.cpp