Construct optimizer chain only once
Construct compiler chain only once