Skip to content

Commit e814013

Browse files
committed
[Wasm][LTO][NPM] Use NPM for LTO with ENABLE_EXPERIMENTAL_NEW_PASS_MANAGER
Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D92867
1 parent 1fd1f63 commit e814013

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lld/wasm/Driver.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
#include "lld/Common/Strings.h"
2222
#include "lld/Common/Version.h"
2323
#include "llvm/ADT/Twine.h"
24+
#include "llvm/Config/llvm-config.h"
2425
#include "llvm/Object/Wasm.h"
2526
#include "llvm/Option/Arg.h"
2627
#include "llvm/Option/ArgList.h"
@@ -379,8 +380,9 @@ static void readConfigs(opt::InputArgList &args) {
379380
config->importTable = args.hasArg(OPT_import_table);
380381
config->ltoo = args::getInteger(args, OPT_lto_O, 2);
381382
config->ltoPartitions = args::getInteger(args, OPT_lto_partitions, 1);
382-
config->ltoNewPassManager = args.hasFlag(OPT_lto_new_pass_manager,
383-
OPT_no_lto_new_pass_manager, false);
383+
config->ltoNewPassManager =
384+
args.hasFlag(OPT_lto_new_pass_manager, OPT_no_lto_new_pass_manager,
385+
LLVM_ENABLE_NEW_PASS_MANAGER);
384386
config->ltoDebugPassManager = args.hasArg(OPT_lto_debug_pass_manager);
385387
config->mapFile = args.getLastArgValue(OPT_Map);
386388
config->optimize = args::getInteger(args, OPT_O, 0);

0 commit comments

Comments
 (0)