swift
8cb8e751 - [constant-folding] Eliminate complexity introducing pre-mature optimization.

Commit
6 years ago
[constant-folding] Eliminate complexity introducing pre-mature optimization. The code that is deleted in this PR attempted to save a bit of compile time by: 1. Checking if after constant folding we have a tuple that is immediately tuple extracted from. 2. RAUW the tuple extracts directly from the tuple's operands. This adds a bunch of complexity to the pass and also moves code that should be in a visitor into the main pass workloop function. After this PR what happens instead is that after we fold, we add the tuple to the worklist. Then during the next iteration we look at the tuple_extract users and simplify them at that point.
Author
Committer
Parents
Loading