diff options
| author | Axel Cohen <axel.cohen@eshard.com> | 2021-11-24 11:43:40 +0100 |
|---|---|---|
| committer | Axel Cohen <axel.cohen@eshard.com> | 2021-12-13 10:41:43 +0100 |
| commit | c4f29fa0ed738b52e7d8ef372c2d09300755dfef (patch) | |
| tree | 70209b622c152b56c44064255abe29d85a46c2cd /compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp | |
| parent | 97cf461b8f4c0ed0de8fdc1c441b904ddb8b3194 (diff) | |
| download | rust-c4f29fa0ed738b52e7d8ef372c2d09300755dfef.tar.gz rust-c4f29fa0ed738b52e7d8ef372c2d09300755dfef.zip | |
Use the existing llvm-plugins option for both legacy and new pm registration
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp')
| -rw-r--r-- | compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp index 32a2ffcef00..f06fc3edf58 100644 --- a/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp +++ b/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp @@ -755,7 +755,7 @@ LLVMRustOptimizeWithNewPassManager( LLVMRustSelfProfileBeforePassCallback BeforePassCallback, LLVMRustSelfProfileAfterPassCallback AfterPassCallback, const char *ExtraPasses, size_t ExtraPassesLen, - const char *PassPlugins, size_t PassPluginsLen) { + const char *LLVMPlugins, size_t LLVMPluginsLen) { Module *TheModule = unwrap(ModuleRef); TargetMachine *TM = unwrap(TMRef); OptimizationLevel OptLevel = fromRust(OptLevelRust); @@ -926,10 +926,10 @@ LLVMRustOptimizeWithNewPassManager( } } - if (PassPluginsLen) { - auto PluginsStr = StringRef(PassPlugins, PassPluginsLen); + if (LLVMPluginsLen) { + auto PluginsStr = StringRef(LLVMPlugins, LLVMPluginsLen); SmallVector<StringRef> Plugins; - PluginsStr.split(Plugins, ' ', -1, false); + PluginsStr.split(Plugins, ',', -1, false); for (auto PluginPath: Plugins) { auto Plugin = PassPlugin::Load(PluginPath.str()); if (!Plugin) { |
