[PATCH] D99645: [flang][driver] Add debug options not requiring semantic checks

Andrzej Warzynski via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 7 08:39:32 PDT 2021


awarzynski added inline comments.


================
Comment at: clang/include/clang/Driver/Options.td:4378
   HelpText<"Run the InputOuputTest action. Use for development and testing only.">;
+def fdebug_unparse_no_sema : Flag<["-"], "fdebug-unparse-no-sema">, Group<Action_Group>,
+  HelpText<"Unparse and stop (skips the semantic checks)">;
----------------
awarzynski wrote:
> kiranchandramohan wrote:
> > Does this flag actually mean, parse and construct the parse-tree and unparse and stop?
> > 
> > While the current name is OK now, when the rest of the pipeline (codegen, linking etc) is there will it be an issue?
> > Does this flag actually mean, parse and construct the parse-tree and unparse and stop?
> 
> Yes
> 
> > While the current name is OK now, when the rest of the pipeline (codegen, linking etc) is there will it be an issue?
> IIUC, there shouldn't be any. Currently, the `-fdebug-unparse` options have dedicated frontend actions 
> * `-fdebug-unparse` runs [[ https://github.com/llvm/llvm-project/blob/main/flang/lib/Frontend/FrontendActions.cpp#L194-L208 | DebugUnparseAction ]]
> * `-fdebug-unparse-no-sema` will run `DebugUnparseNoSemaAction` (introduced here)
> I don't see why we'd change these actions once codegen or linking are available. That's something that will be implemented separately.
> 
> Does this help?
> 
> 
I added `DocBrief` descriptions to clarify the purpose of these options. Please note that currently these are not used anywhere. In Clang `DocBrief` descriptions are used to generate https://clang.llvm.org/docs/ClangCommandLineReference.html. We could set-up something similar for Flang.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99645/new/

https://reviews.llvm.org/D99645



More information about the cfe-commits mailing list