On Mon, Mar 31, 2014 at 8:05 PM, Quentin Colombet <[email protected]> wrote:

> ================
> Comment at: lib/CodeGen/CodeGenAction.cpp:419
> @@ -394,1 +418,3 @@
> +      OptimizationReportHandler(cast<DiagnosticInfoOptimizationReport>(DI));
> +    return;
>    default:
> ----------------
> This does not follow the same pattern as the previous handler, i.e., with the 
> fall through setting the DiagID to use the default handler (the ComputeDiagID 
> part etc.).
>
> My guess is we want to push the check of 
> CodeGenOpts.OptimizationReportPattern into OptimizationReportHandler and 
> check the return of that.
>
> If we do not want to follow the same pattern, we should comment on that. 
> Indeed, I think it is important to explain why we are not reporting anything 
> when CodeGenOpts.OptimizationReportPattern is not set.

These messages should only show up when the diagnostic identifier
matches the pattern provided by the user. So, even if -Rpass is used,
we still need to make sure that the pass name matches the regular
expression in -Rpass.

I'll re-arrange the logic and add documentation.


Thanks.  Diego.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to