TableGen: Refactor DAG patterns to enable parsing one pattern at a time.