I would cache the conv.getState() to a variable outside of the loop (unless the state can be changed during the loop), but I would imagine it would still be cacheable so that it's not called multiple times per single iteration.