<div dir="ltr"><div>The ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER CMake flag currently only affects Clang. It should probably also change all other uses of pass managers where possible.  <br></div><div></div><div><br></div><div>There are a couple of uses inside LLD for LTO which already have new/legacy PM flags and should probably look at 

ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER to determine the default. <a href="https://github.com/llvm/llvm-project/blob/1314a4938fba865412598b7227cb4657d59cd8bc/lld/wasm/Driver.cpp#L382">Some</a> <a href="https://github.com/llvm/llvm-project/blob/1314a4938fba865412598b7227cb4657d59cd8bc/llvm/include/llvm/LTO/Config.h#L53">examples</a>.</div><div><br></div><div>Also at some point in the future when check-llvm has been fixed to work with opt's -enable-new-pm flag by default, that should also be dependent upon ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER.</div><div><br></div><div>Any objections?</div></div>