[llvm-dev] [RFC] Deprecating the legacy pass manager for the optimization pipeline
Chris Tetreault via llvm-dev
llvm-dev at lists.llvm.org
Tue Aug 24 15:41:10 PDT 2021
Let me clarify that when I say “it’s fine to begin removing LPM in LLVM 14”, I mean that it’s fine to begin removing LPM once LLVM 14 is released, and the version string in main is set to 15.
From: llvm-dev <llvm-dev-bounces at lists.llvm.org> On Behalf Of Chris Tetreault via llvm-dev
Sent: Tuesday, August 24, 2021 3:39 PM
To: Arthur Eubanks <aeubanks at google.com>; Fāng-ruì Sòng <maskray at google.com>
Cc: llvm-dev at lists.llvm.org
Subject: Re: [llvm-dev] [RFC] Deprecating the legacy pass manager for the optimization pipeline
WARNING: This email originated from outside of Qualcomm. Please be wary of any links or attachments, and do not enable macros.
Downstreams could be re-enabling the legacy pass manager in CMake. It’s still there, and still supported. If a downstream has made non-trivial changes to the pass pipeline for legacy pass manager, it’s going to be a ton of work to ensure performance parity when enabling new pass manager.
I think, if LLVM is built with LLVM_ENABLE_NEW_PASS_MANAGER set to OFF, then you should get a big scary warning at CMake configure time, but clang/opt should not complain. If LLVM is built with DLLVM_ENABLE_NEW_PASS_MANAGER set to ON, but the flag is passed to clang/opt to build using the legacy pass manager, you should get a warning from clang/opt.
In my opinion, if these deprecation warnings make it in for LLVM 13, then it’s fine to begin removing LPM in LLVM 14.
thanks,
Chris Tetreault
From: Arthur Eubanks <aeubanks at google.com<mailto:aeubanks at google.com>>
Sent: Tuesday, August 24, 2021 1:47 PM
To: Fāng-ruì Sòng <maskray at google.com<mailto:maskray at google.com>>
Cc: Chris Tetreault <ctetreau at quicinc.com<mailto:ctetreau at quicinc.com>>; llvm-dev at lists.llvm.org<mailto:llvm-dev at lists.llvm.org>; Tom Stellard <tstellar at redhat.com<mailto:tstellar at redhat.com>>
Subject: Re: [llvm-dev] [RFC] Deprecating the legacy pass manager for the optimization pipeline
WARNING: This email originated from outside of Qualcomm. Please be wary of any links or attachments, and do not enable macros.
If nobody is setting -DLLVM_ENABLE_NEW_PASS_MANAGER=off then I'm not sure that we need to go through the whole deprecation dance. Is there anybody doing that?
But if we do the deprecation dance, should it be a CMake warning or a clang warning? I'm not sure people will notice a CMake warning.
And would putting that in the 13.x branch be good enough to start removing after 14.x?
On Tue, Aug 24, 2021 at 12:26 PM Fāng-ruì Sòng <maskray at google.com<mailto:maskray at google.com>> wrote:
On Tue, Aug 24, 2021 at 12:21 PM Chris Tetreault <ctetreau at quicinc.com<mailto:ctetreau at quicinc.com>> wrote:
>
> Since deprecating something is giving warning that it’s going to be removed, I don’t think it’s fair to deprecate and remove in one step. If legacy pass manager isn’t currently formally deprecated (as in, loudly complains when you try to use it), then I’d personally like to see it deprecated for a release before any steps to completely remove it are taken.
I just wanted to say the same thing:)
I don't mind that we install a warning for -DLLVM_ENABLE_NEW_PASS_MANAGER=off
in the release/13.x branch so that the signal is clearer to downstream users.
> From: llvm-dev <llvm-dev-bounces at lists.llvm.org<mailto:llvm-dev-bounces at lists.llvm.org>> On Behalf Of Arthur Eubanks via llvm-dev
> Sent: Tuesday, August 24, 2021 12:10 PM
> To: Fangrui Song <maskray at google.com<mailto:maskray at google.com>>
> Cc: llvm-dev <llvm-dev at lists.llvm.org<mailto:llvm-dev at lists.llvm.org>>
> Subject: Re: [llvm-dev] [RFC] Deprecating the legacy pass manager for the optimization pipeline
>
>
>
> WARNING: This email originated from outside of Qualcomm. Please be wary of any links or attachments, and do not enable macros.
>
> I probably should have said "deprecating and removing".
>
>
>
> My intention was to remove it completely. -DLLVM_ENABLE_NEW_PASS_MANAGER wouldn't do anything and we'd remove the -flegacy-pass-manaager/-fexperimental-new-pass-manager flags, as well as the corresponding lld flags.
>
>
>
> On Tue, Aug 24, 2021 at 12:02 PM Fangrui Song <maskray at google.com<mailto:maskray at google.com>> wrote:
>
> On 2021-08-24, Arthur Eubanks via llvm-dev wrote:
> >The new pass manager has been on by default since the 13 branch. Now that
> >we've branched for 14, I'd like to start the process of deprecating and
> >removing legacy pass manager support for the optimization pipeline. This
> >includes clang, opt, and lld LTO support.
> >
> >Note that this doesn't apply to the codegen pipeline since there's no new
> >pass manager support for that yet.
> >
> >Are there any objections?
>
> "deprecating" and 'removing" are different.
>
> For 14.0.0, do you plan that -DLLVM_ENABLE_NEW_PASS_MANAGER=off will
> give a warning or will be completely unsupported?
--
宋方睿
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210824/573ac407/attachment-0001.html>
More information about the llvm-dev
mailing list