[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-31 Thread Taewook Oh via cfe-commits
twoh added a comment. In https://reviews.llvm.org/D25225#584012, @hfinkel wrote: > In https://reviews.llvm.org/D25225#584010, @twoh wrote: > > > Is there a particular reason why "opt_record_file" is defined in > > CC1Options.td, not Options.td? If -opt-record-file= is provided > > by the

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-31 Thread Hal Finkel via cfe-commits
hfinkel added a comment. In https://reviews.llvm.org/D25225#584010, @twoh wrote: > Is there a particular reason why "opt_record_file" is defined in > CC1Options.td, not Options.td? If -opt-record-file= is provided by > the command line, line 829-831 in CompilerInvocation.cpp won't handle it >

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-31 Thread Taewook Oh via cfe-commits
twoh added a comment. Is there a particular reason why "opt_record_file" is defined in CC1Options.td, not Options.td? If -opt-record-file= is provided by the command line, line 829-831 in CompilerInvocation.cpp won't handle it because opt_record_file is not a CodeGenArg. Repository: rL

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-11 Thread Hal Finkel via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL283834: Add an option to save the backend-produced YAML optimization record to a file (authored by hfinkel). Changed prior to commit: https://reviews.llvm.org/D25225?vs=74001=74214#toc Repository:

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-10 Thread Hal Finkel via cfe-commits
hfinkel added a comment. In https://reviews.llvm.org/D25225#566854, @rsmith wrote: > As discussed on IRC, I have a mild concern about using > `-fsave-optimization-record` (with no argument) to enable the feature, and > `-fsave-optimization-record=X` to enable the feature and specify a

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-10 Thread Richard Smith via cfe-commits
rsmith added a comment. As discussed on IRC, I have a mild concern about using `-fsave-optimization-record` (with no argument) to enable the feature, and `-fsave-optimization-record=X` to enable the feature and specify a filename; in most (but not all) cases, `-option arg` and `-option=arg`

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-07 Thread Adam Nemet via cfe-commits
anemet added a comment. LGTM, thanks. I also like the option name but will let the the other reviewers official approve that part. https://reviews.llvm.org/D25225 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-07 Thread Hal Finkel via cfe-commits
hfinkel added inline comments. Comment at: lib/CodeGen/CodeGenAction.cpp:198 + +Ctx.setDiagnosticsOutputFile(new yaml::Output(OptRecordFile->os())); + } anemet wrote: > Sorry, one more thing: if PGO is available, I think we want to set >

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-07 Thread Adam Nemet via cfe-commits
anemet added inline comments. Comment at: lib/CodeGen/CodeGenAction.cpp:198 + +Ctx.setDiagnosticsOutputFile(new yaml::Output(OptRecordFile->os())); + } Sorry, one more thing: if PGO is available, I think we want to set

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-07 Thread Adam Nemet via cfe-commits
anemet added inline comments. Comment at: test/CodeGen/opt-record.c:17-25 +// CHECK: --- !Missed +// CHECK: Pass:inline +// CHECK: Name:NoDefinition +// CHECK: Function:foo + +// CHECK: --- !Passed +// CHECK: Pass:loop-vectorize

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-05 Thread Hal Finkel via cfe-commits
hfinkel added a comment. @rsmith @rjmccall - I chatted with @anemet about this on IRC, and he's happy with it. Please look this over, in part to make sure you're happy with the option name. On the name, two of my thoughts behind using -fsave-optimization-record were: 1) I did not want to

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-04 Thread Hal Finkel via cfe-commits
hfinkel added a dependency: D25224: Don't filter diagnostics written as YAML to the output file. hfinkel added a comment. Note: This depends on https://reviews.llvm.org/D25224. https://reviews.llvm.org/D25225 ___ cfe-commits mailing list

[PATCH] D25225: Add an option to save the backend-produced YAML optimization record to a file

2016-10-04 Thread Hal Finkel via cfe-commits
hfinkel created this revision. hfinkel added reviewers: anemet, rsmith, rjmccall. hfinkel added a subscriber: cfe-commits. Herald added a subscriber: mcrosier. The backend now has the capability to save information from optimizations, the same information that can be used to generate