clingo icon indicating copy to clipboard operation
clingo copied to clipboard

Warn about assignment aggregates

Open rkaminsk opened this issue 5 years ago • 0 comments

Often assignment aggregates are used in a very inefficient way. Typical patters are

S = #sum { X : p(X) }, X > 10

or

S = #sum { X : p(X) }, T = #sum { X : q(X) }, S > T.

where p/1 and q/1 are non-domain predicates.

Both examples can easily be rewritten to drastically reduce grounding size. It would be nice to have a warning when assignment aggregates over non-domain predicates are used.

rkaminsk avatar Aug 14 '19 10:08 rkaminsk