This revision was automatically updated to reflect the committed changes.
Closed by commit rC321090: [clang] -foptimization-record-file= should imply
-fsave-optimization-record (authored by JDevlieghere, committed by ).
Repository:
rC Clang
https://reviews.llvm.org/D39834
Files:
Quolyk added a comment.
In https://reviews.llvm.org/D39834#959500, @JDevlieghere wrote:
> Thanks Dmitry, this LGTM!
>
> PS: Let me know if you don't have commit access and want me to commit it for
> you.
I don't have commit access, please commit. Thanks for code review.
JDevlieghere accepted this revision.
JDevlieghere added a comment.
This revision is now accepted and ready to land.
Thanks Dmitry, this LGTM!
PS: Let me know if you don't have commit access and want me to commit it for
you.
https://reviews.llvm.org/D39834
Quolyk updated this revision to Diff 123914.
https://reviews.llvm.org/D39834
Files:
lib/Driver/ToolChains/Clang.cpp
test/Driver/opt-record.c
Index: test/Driver/opt-record.c
===
--- test/Driver/opt-record.c
+++
JDevlieghere added a comment.
I think you can achieve the same result with less code by checking for the
flag's presence higher up, where currently `OPT_fsave_optimization_record` is
handled (Clang.cpp:4329). Something like:
if (Args.hasFlag(options::OPT_fsave_optimization_record,
JDevlieghere added a comment.
This also ensures that if `fno_save_optimization_record` is specified, you
don't overwrite it by setting the file. This is definitely something you'd want
to add to your test case.
https://reviews.llvm.org/D39834
___