DynamicCodeGenerator shouldn't iterate many times the same data array