[SR-7996] Assertion failure in PredictableMemOpt #50529
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
compiler
The Swift compiler in itself
crash
Bug: A crash, i.e., an abnormal termination of software
SILOptimizer
Area → compiler: SIL optimization passes
Environment
Swift 4.2-dev master branch (823ed14), macOS 10.13.5
Additional Detail from JIRA
md5: 94f6f6da4c41891b8a1f9354e15874ed
Issue Description:
... "Unknown access path instruction", line 139 in computeSubelement().
It can be triggered by compiling the following code with -O:
The SIL instruction that triggers it is the second
init_enum_data_addr
instruction (for preparing the return value).There are other assertions in the file (saying that enum projections aren't supported) testing against the error value for computeSubelement()–except for the one codepath that triggers this. That, and the fact that the generated code works (with assertions off) leads me to think that maybe this one assertion just needs to be removed to fix this. I don't know enough about SIL to know if this is a sign of something going wrong elsewhere or what. I'd be willing to look into it some more if someone could nudge me in the right direction.
The text was updated successfully, but these errors were encountered: