Fix #541: Make incremental optimizer honor clean