mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
We already computed this information so this is just storing information we were already computing. One thing to note is that in code with canonicalized loops, we will always only have one backedge. But we would like loop region to be correct even in the case of non-canonicalized code so we support having multiple back edges. But since the common case is 1 backedge, we optimize for that case. This commit contains updated tests and also updates to the loop region graph viewer so that it draws backedges as green arrows from the loop to its backedge subregions. The test updates were done by examining each test case by hand.
42 KiB
42 KiB