mirror of
https://github.com/revng/revng
synced 2026-06-21 14:07:57 +00:00
d91ca93b5b4e2b709d0d42b88ef98df199dde877
Before this commit, `MakeEnvNullPass` was substituting uses of `env` with uses of `nullptr`. This operation was introducing undefined behavior, and subsequent optimizations were allowed to mark BasicBlocks where it occured as unreachable, eventually leading to their wrong removal. This commit fixes the substitution, properly replacing loads from `env` with `nullptr`. This should never cause undefined behavior anymore, because the results from load from `env` is never referenced in isolated functions.
Description
Languages
C++
77.1%
Python
12.6%
MLIR
4.4%
CMake
1.9%
LLVM
1.4%
Other
2.5%