-
-
Notifications
You must be signed in to change notification settings - Fork 14.7k
Description
The large_enums (EnumSizeOpt) MIR pass is disabled due to being unsound. It is currently the only such MIR pass apparently (at least, no other pass checks unsound_mir_opts).
We don't seem to have a very clear idea of what's wrong with the pass; it was disabled from the start in #85158 which added it (but due to a bug in the logic the pass is still enabled with opt level 3 -- which however means it is still off-by-default). What we have is:
- this comment. Apparently the MIR opt output was strange on wasm32.
- and there were test failures on ARM -- the same unexpected MIR opt output was on wasm?
So, someone needs to properly investigate this and figure out what the layout of the enums actually is on these targets and whether that explains the test output. (That can most likely be fully done with cross-compilation and no_core tests.)
It's been three years with the pass in-tree but never enabled -- when do we move towards removing it since waiting longer is unlikely to see it fixed?
Cc @rust-lang/wg-mir-opt @JulianKnodt @saethlin