[clang] [Clang] Add "extend lifetime" flags and release note (PR #110000)
Stephen Tozer via cfe-commits
cfe-commits at lists.llvm.org
Wed Nov 27 09:01:21 PST 2024
================
@@ -2217,6 +2217,11 @@ bool CompilerInvocation::ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args,
Args.getAllArgValues(OPT_fsanitize_trap_EQ), Diags,
Opts.SanitizeTrap);
+ Opts.ExtendThisPtr =
+ Opts.OptimizationLevel > 0 && Args.hasArg(OPT_fextend_this_ptr);
----------------
SLTozer wrote:
I'm currently looking into this to see if there would be any notable negative consequences, but for now I'm at least happy to move this to the [next patch along](https://github.com/llvm/llvm-project/pull/110102): in that patch, we emit fake uses for functions when `OptimizationLevel != 0` and _or_ we've passed `-disable-O0-optnone` - that at least gives the ability to pass `-O0 -fextend-lifetimes` together if desired.
https://github.com/llvm/llvm-project/pull/110000
More information about the cfe-commits
mailing list