In the paper referred to above, there is an order R with
Unknown <= .Le <= Lt
This is generalized to Unknown <= 'Decr k' where
Decr 1 replaces Lt and Decr 0 replaces Le.
A negative decrease means an increase. The generalization
allows the termination checker to record an increase by 1 which
can be compensated by a following decrease by 2 which results in
an overall decrease.
However, the termination checker of the paper itself terminates because
there are only finitely many different call-matrices. To maintain
termination of the terminator we set a cutoff point which determines
how high the termination checker can count. This value should be
set by a global or file-wise option.
See Call for more information.
TODO: document orders which are call-matrices themselves.
Constructors
Decr !Bool !IntDecrease of callee argument wrt. caller parameter.
The
Boolindicates whether the decrease (if any) is usable. In any chain, there needs to be one usable decrease. Unusable decreases come from SIZELT constraints which are not in inductive pattern match or a coinductive copattern match. See issue #2331.UPDATE: Andreas, 2017-07-26: Feature #2331 is unsound due to size quantification in terms. While the infrastructure for usable/unusable decrease remains in place, no unusable decreases are generated by TermCheck.
UnknownNo relation, infinite increase, or increase beyond termination depth.
Mat !(Matrix Int Order)Matrix-shaped order, currently UNUSED.
Instances11Eq, Ord, Show, Pretty, PartialOrd, CallComb, …
Eq OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderOrd OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderShow OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderPretty CallMatrixDefined in Agda-2.7.0.1 · Agda.Termination.CallMatrixPretty OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderPartialOrd OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderInformation order: Unknown is least information. The more we decrease, the more information we have.
When having comparable call-matrices, we keep the lesser one. Call graph completion works toward losing the good calls, tending towards Unknown (the least information).
CallComb CallMatrixDefined in Agda-2.7.0.1 · Agda.Termination.CallMatrixCall matrix multiplication.
f --(m1)--> g --(m2)--> his combined tof --(m2 mul m1)--> hNote the reversed order of multiplication: The matrix
c1of the second callg-->hin the sequencef-->g-->his multiplied with the matrixc2of the first call.Preconditions:
m1has dimensionsar(g) × ar(f).m2has dimensionsar(h) × ar(g).Postcondition:
m1 >*< m2has dimensionsar(h) × ar(f).HasZero OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderNotWorse CallMatrixDefined in Agda-2.7.0.1 · Agda.Termination.CallMatrixNotWorse OrderDefined in Agda-2.7.0.1 · Agda.Termination.OrderIt does not get worse then `
increase'. If we are still decreasing, it can get worse: less decreasing.Diagonal (CallMatrixAug cinfo) OrderDefined in Agda-2.7.0.1 · Agda.Termination.CallMatrix