Rewrite runFnX calls to trigger optimisation