Uh oh!
There was an error while loading. Please reload this page.
Add more checking to GenTreeArrAddr::ParseArrayAddress() - #100327
Conversation
BruceForstall
commented
Mar 27, 2024
Extracted from #94250 |
BruceForstall
commented
Mar 27, 2024
There are a few diffs in ILGEN tests that construct array index expressions with negative indices. |
BruceForstall
commented
Mar 28, 2024
With JitOptRepeat we end up with the following situation. We hit the assert: (e.g., We start with: After optimization, this becomes: On the next iteration of JitOptRepeat, the CSE injected COMMA is not parseable by However, it might be harder for the CSE use. In that case, we start with something similar: and, after CSE, have: This would require parsing the CSE value number for Since this is VN iteration #2, I'm not sure we lose anything by assigning the |
f41383c to
c5824f8CompareBruceForstall
commented
Mar 28, 2024
@jakobbotsch PTAL |
It's interesting that there are diffs on x86, apparently because the offset of data of an array from the base of an array is 8 (it is 16 on 64-bit). This happens to be the same size as a pointer and a The result is that we give the |
If the ARR_ADDR node doesn't make sense, namely if the array offset does not appear to be in the array, then bail.
c5824f8 to
fc5333dCompareBruceForstall
commented
Mar 29, 2024
GitHub is confused; all the tests passed. |
If the ARR_ADDR node doesn't make sense, namely if the array offset does not appear to be in the array, then bail.