Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Always prune unused 'uninstantiated' variables before codegen (chapel…
…-lang#24491) Fix nightly test failures running under `-compopts --baseline -futures-mode 3` (run with `--baseline` and only include futures with SKIPIFs). Adjust cleanup before code generation to remove symbols with type `uninstantiated` that have zero uses. This is required because currently, we do not run `--dead-code-elimination` when under `--baseline`. Note that 5 futures still fail when running a plain-old `--baseline` paratest. Fixing them is future work. In the future, perhaps we should consider always running dead code elimination, and even disabling its command-line flag altogether. This is because the current code generator expects dead code elimination to have occurred in order to function properly (as evidenced by this patch). Currently, we have a bunch of adhoc "code elimination" that occurs even under `--baseline`, but the algorithm for `--dead-code-elimination` is comprehensive and requires no additional developer effort. TESTING - [x] `linux64`, `standard` - [x] `linux64`, `--baseline -futures-mode 3` Reviewed by @benharsh. Thanks!
- Loading branch information