optimizing parsing