When we start the Prolog environment through RulesCache, we create a
bare machine (=interpreter) that will later be used by
PrologEnvironment, a subclass of BufferingPrologControl.
The reduction limit is applied through PrologEnvironment when terms are
evaluated. The problem with that is that even the bare machine creation
might run into the reduction limit by interpreting the provided facts.
Before this commit, the reduction limit in the bare machine was always
1M. This commit makes it so that we apply the same limit that we have
configured in Gerrit to the bare machine.
This commit is obviously lacking a test, but we see this bug occuring in
production right now and don't want to block the fix on providing a
test. The effect was validated in a local Gerrit test site.
Change-Id: I688f4abd8c02b635edb1c0cab9c921448ce6ac0a