[PATCH] D87989: [Flang][Driver] Add infrastructure for basic frontend actions and file I/O

2020-10-24 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thank you all for your input! Before merging I took the liberty to rename `NoClangOption` as `FlangOnlyOption`. The new name reflects better what the flag is introduced for. Also, based on responses to [1], it is unlikely that it will be used beyond flang-only option

[PATCH] D88381: [Flang][Driver] Add PrintPreprocessed FrontendAction

2020-10-27 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/include/flang/Frontend/CompilerInvocation.h:12 #include "flang/Frontend/FrontendOptions.h" +#include "flang/Parser/parsing.h" #include "clang/Basic/Diagnostic.h" sameeranjoshi wrote: > awarzynski wrote: > > sa

[PATCH] D88381: [Flang][Driver] Add PrintPreprocessed FrontendAction

2020-10-27 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 301066. awarzynski added a comment. Rebase on top of master + rename accessor method Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D88381/new/ https://reviews.llvm.org/D88381 Files: clang/include/clang/Dri

[PATCH] D89799: [clang][driver] Rename DriverOption as NoXarchOption (NFC)

2020-10-28 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89799/new/ https://reviews.llvm.org/D89799 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cg

[PATCH] D89799: [clang][driver] Rename DriverOption as NoXarchOption (NFC)

2020-10-28 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 301414. awarzynski added a comment. Remove the diagnostic - Deleted the `err_drv_invalid_Xarch_argument_unsupported` diagnostic - Removed `const` from &getDiags() - otherwise I couldn't use `getCustomDiagID` (which is a non-const member function). `Diagno

[PATCH] D84362: [NFC] Refactor DiagnosticBuilder and PartialDiagnostic

2020-10-29 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi All, I've just noticed this patch and realised that it takes `DiagnosticBuilder` in the direction tangential to what we proposed in [1]. I've just restarted our efforts with regard to refactoring these APIs and feel that it would be good to coordinate any future

[PATCH] D84362: [NFC] Refactor DiagnosticBuilder and PartialDiagnostic

2020-10-30 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @rjmccall , thank you for your quick reply! > It sounds like what you want is a diagnostic library that's almost completely > abstracted over the kinds of entities that can be stored in a diagnostic, > including the definition of a source location. No :) We sugge

[PATCH] D89799: [clang][driver] Rename DriverOption as NoXarchOption (NFC)

2020-10-30 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe5699b8ff1b6: [clang][driver] Rename DriverOption as NoXarchOption (NFC) (authored by awarzynski). Changed prior to commit: https://reviews.llvm.o

[PATCH] D88381: [Flang][Driver] Add PrintPreprocessed FrontendAction

2020-11-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGd28de0d7f257: [Flang][Driver] Add PrintPreprocessedInput FrontendAction (`flang-new -E`) (authored by CarolineConcatto, committed by awarzynski). C

[PATCH] D88381: [Flang][Driver] Add PrintPreprocessed FrontendAction

2020-11-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D88381#2357123 , @sameeranjoshi wrote: > I would wait for a couple of more days for someone to review from community > may be from Nvidia's side if someone would verify the initial design. As there were no new reviews, I a

[PATCH] D84362: [NFC] Refactor DiagnosticBuilder and PartialDiagnostic

2020-11-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D84362#2365153 , @rjmccall wrote: > I may not have been clear. I'm not saying SourceLocation is a meaningful > concept in the driver. Likewise, I should be more careful with respect to how I refer to `SourceLocation` (a cl

[PATCH] D102849: [flang][driver] Add support for the "-init-only" option

2021-06-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @stuartellis , Thank you for preparing this! This looks good to me, but I would appreciate a comment somewhere (e.g. in the commit message) comparing `-init-only` and `-test-io`. Essentially, both options are for testing purposes only. IMHO, we should only requir

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a reviewer: sscalpone. Herald added a subscriber: dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adds new option for the new Flang driver: `-fno-unparse-typed-exprs

[PATCH] D103613: [flang][driver] Add support for `-module-suffix`

2021-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a reviewer: sscalpone. Herald added a subscriber: dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This option is required in order to call `flang-new` from the `flang` bash scr

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-01-27 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. @arnamoy10, thank you for this patch and for working on this! I have a few high-level suggestions (+ some inline comments): **Q1** `-module-dir` and `-J` in Options.td should be aliases - otherwise we need to duplicate some code. I've not used Aliases myself, but pe

[PATCH] D95460: [flang][driver] Add forced form flags and -ffixed-line-length

2021-01-27 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thank you for working on this @FarisRehman ! I've left a few inline comments, but nothing major. Really nice to see this being added and working as expected! Comment at: clang/include/clang/Driver/Options.td:4074-4076 +def ffixed_line_length_VALUE :

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-01-28 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. @arnamoy10 , could you also add tests that show that `-J/-module-dir` is taken into account when deciding where to put module files? Thank you! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95448/new/ https://reviews.ll

[PATCH] D95460: [flang][driver] Add forced form flags and -ffixed-line-length

2021-01-29 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. @FarisRehman, thank you for addressing my comments! I've just realised that `gfortran` doesn't actually support `-fno-fixed-form` or `-fno-free-form`: $ gfortran -ffixed-form -fno-fixed-form test.f gfortran: error: unrecognized command line option ‘-fno-fixed-form

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-02-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. @arnamoy10 Thank you for addressing my comments! As for testing that `-J/-module-dir` are taken into account when specifying the output directory for modules, could try adding the following: ! RUN: mkdir -p %t/dir-f18 && %f18 -fparse-only -I tools/flang/include/fla

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-02-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/test/Flang-Driver/include-module.f90:15 +! RUN: not %flang-new -fsyntax-only -module-dir %S/Inputs %s 2>&1 | FileCheck %s --check-prefix=SINGLEINCLUDE +! RUN: not %flang-new -fsyntax-only -J %S/Inputs/module-dir -J %S/Inputs/

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-02-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. LGTM! Thank you for addressing my comments, (`DELETEME` can be fixed when pushing upstream)! From what I can see you've also addressed all of Tim's comments, but could you wait a day or two before merging this? Just in case I missed something, or Tim or somebody els

[PATCH] D95460: [flang][driver] Add forced form flags and -ffixed-line-length

2021-02-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you for working on this @FarisRehman ! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95460/new/ https://reviews.llvm.org/D95460 _

[PATCH] D94533: [clang] Add AddClang.cmake to the list of the CMake modules that are installed

2021-02-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG62e4f22e297a: [clang] Add AddClang.cmake to the list of the CMake modules that are installed (authored by awarzynski). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.ll

[PATCH] D95448: [flang][driver] Add support for `-J/-module-dir`

2021-02-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG985a42fdf8ae: [flang][driver] Add support for `-J/-module-dir` (authored by arnamoy10, committed by awarzynski). Changed prior to commit: https://reviews.llvm.org/D95448?vs=320617&id=321448#toc Reposit

[PATCH] D96032: [flang][driver] Add support for -fopenmp and -fopenacc

2021-02-08 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you for this patch @FarisRehman , it's great to see more tests being ported to the new driver! Although this patches touches many files, it mostly just generalizes the `RUN` lin

[PATCH] D96032: [flang][driver] Add support for -fopenmp and -fopenacc

2021-02-09 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added inline comments. Comment at: clang/lib/Driver/ToolChains/Flang.cpp:25-26 Args.AddAllArgs(CmdArgs, {options::OPT_ffixed_form, options::OPT_ffree_form, -options::OPT_ffixed_line_length_EQ}); +

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-10 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @arnamoy10, thank you for working on this! Overall this looks good to me, but I'm wondering whether we could simplify it a bit? More comments inline. Comment at: clang/include/clang/Driver/Options.td:4163 defm d_lines_as_comments : BooleanFFlag<

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-11 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added subscribers: dang, mgorny. Herald added a reviewer: sscalpone. Herald added a reviewer: jansvoboda11. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adds the following co

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-11 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 323054. awarzynski added a comment. Fix typo in f18.cpp Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96483/new/ https://reviews.llvm.org/D96483 Files: clang/include/clang/Driver/Options.td flang/includ

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-11 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/tools/f18/f18.cpp:541 driver.debugNoSemantics = true; -} else if (arg == "-funparse") { +} else if (arg == "-funparse" || arg == "-fdebug_unparse") { driver.dumpUnparse = true; tskeith wrot

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-12 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Btw, could you clang-format your patch? I normally use `git -lang-format HEAD~`. Thank you! Comment at: flang/lib/Frontend/CompilerInvocation.cpp:261 + diags.getCustomDiagID(clang::DiagnosticsEngine::Error, + "Use of `-fdefault

[PATCH] D96407: [flang][driver] Add extension options and -finput-charset

2021-02-12 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thank you for submitting this @FarisRehman ! Overall this looks good to me. I've left a few minor comments inline. Also, I think that it is worth adding a help message for `-finput-charset`. Lack of it in `clang` feels like an accidental omission. We can follow GCC h

[PATCH] D95737: [NFC][Docs] Fix RAVFrontendAction doc's CMakelists.txt for Shared build

2021-02-13 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @xgupta , thank you for working on this! It's quite easy to miss dependencies when building with `BUILD_SHARED_LIBS=Off` (i.e. with the default setting - static libs). IIUC, that's what happened here. This example clearly requires the following: - `ASTConsumer` i

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. LGTM, thank you for working on this @arnamoy10 ! I left a few _minor_ comments. These can be addressed in the actual commit. Comment at: clang/include/clang/Driver/Options.td:4224-4231 +def fdefault_double_8 : Flag<["-"],"fdefault-double-8">, Group,

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 323756. awarzynski added a comment. Updated lit.cfg.py Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96483/new/ https://reviews.llvm.org/D96483 Files: clang/include/clang/Driver/Options.td flang/include

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D96483#2563323 , @FarisRehman wrote: > Do you know what the use of `GetActionKindName` in `FrontendOptions.h` is, as > it is currently not being called anywhere and whilst this patch currently > does not update that method

[PATCH] D96407: [flang][driver] Add extension options and -finput-charset

2021-02-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you for addressing my comments. LGTM! Please add missing `newline` chars before merging ;-) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.ll

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: clang/include/clang/Driver/Options.td:4231 +def flarge_sizes : Flag<["-"],"flarge-sizes">, Group, + HelpText<"Set the default KIND for INTEGER to 8.">; } tskeith wrote: > That's not what -flarge-sizes does. Here is

[PATCH] D96483: [flang][driver] Add options for unparsing

2021-02-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG96d229c9abdf: [flang][driver] Add options for unparsing (authored by awarzynski). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D96777: [clang][driver] Set the input type to Fortran when reading from stdin

2021-02-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added subscribers: usaxena95, kadircet. Herald added a reviewer: sscalpone. awarzynski requested review of this revision. Herald added subscribers: cfe-commits, ilya-biryukov. Herald added a project: clang. This patch makes sure that for the following invoc

[PATCH] D96716: [flang][driver] Add debug dump options

2021-02-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. I think that this patch does a great job demonstrating the use of frontend actions and how _action_ compiler flags map to them. Given how `Fortran::semantics::Semantics` are defined and created, I think that adding _semantics_ as a member variable to `PrescanAndSemaA

[PATCH] D96864: [flang][driver] Add -Xflang and make -test-io a frontend-only flang

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a reviewer: sscalpone. Herald added subscribers: jansvoboda11, dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adds support for `-Xflang` in `flang-new`. The semanti

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski requested changes to this revision. awarzynski added a comment. This revision now requires changes to proceed. Thank you for updating this! I've left a couple of small suggestions inline. Once those are addressed I believe that this is ready to land. @tskeith, any thoughts ? ==

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/lib/Frontend/CompilerInvocation.cpp:254 + if (args.hasArg(clang::driver::options::OPT_fdefault_real_8)) +res.defaultKinds().set_defaultRealKind(8); + if (args.hasArg(clang::driver::options::OPT_fdefault_integer_8)) { -

[PATCH] D96864: [flang][driver] Add -Xflang and make -test-io a frontend-only flag

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/test/Frontend/input-output-file.f90:6 !-- +! NOTE: We need `-E` below in order to instruct the compiler driver to create a job representing a fronted compiler invocation ! TEST 1: Print to stdout (impl

[PATCH] D96716: [flang][driver] Add debug dump options

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. This patch doesn't require the tests to be updated, does it? Also: https://reviews.llvm.org/D96870. So it looks these are unrelated changes. Could you remove them before merging? Othe

[PATCH] D96716: [flang][driver] Add debug dump options

2021-02-17 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D96716#2569160 , @FarisRehman wrote: > They do require updating as `-fdebug-dump-symbol` and > `-fdebug-dump-parse-tree` are otherwise not tested by the new driver in this > patch. Apologies, I wasn't clear (realized after

[PATCH] D96884: [flang][driver] Add more -fdebug options

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you for working on this @FarisRehman ! This semantics implemented here are identical to what `f18` does. `-fdebug-instrumented-parse` from `f18` becomes `-fdebug-parsing-log` in

[PATCH] D96875: [flang][driver] Add -fdebug-module-writer option

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thank you for submitting this @arnamoy10 ! Comments inline. Comment at: clang/include/clang/Driver/Options.td:4232-4233 HelpText<"Use INTEGER(KIND=8) for the result type in size-related intrinsics.">; +def fdebug_module_writer : Flag<["-"],"fdebu

[PATCH] D96771: [OpenCL] Add distinct file extension for C++ for OpenCL

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @Anastasia , thank you for working on this! IIUC, this patch introduces: - new input types: `TY_CLCXX` and `TY_CLCXXHeader` - new language: `OpenCLCXX` Based on the attached test, this is only to remove the need for `-cl-std=clc++`. Do you expect any other benefi

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/test/Flang-Driver/fdefault.f90:1 +! Ensure argument -fdefault* works as expected. +! TODO: Add checks when actual codegen is possible for this family I think that this test is a great improvement compared to wha

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/test/Flang-Driver/fdefault.f90:10 +! RUN: not %flang-new -fsyntax-only -fdefault-double-8 %s 2>&1 | FileCheck %s --check-prefix=DOUBLE +! RUN: mkdir -p %t/dir-flang-new && %flang-new -fsyntax-only -module-dir %t/dir-flang-new

[PATCH] D96884: [flang][driver] Add more -fdebug options

2021-02-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. I've just realized that for `-fdebug-parsing-log` we need to set `Fortran::parser::instrumentedParse`. I don't see a good place for that just yet. It's probably best extracting that option into a separate patch. Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D96884: [flang][driver] Add debug measure-parse-tree and pre-fir-tree options

2021-02-19 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you for updating this @FarisRehman ! The original implementation of ``-fdebug-parsing-log` submitted here was not 100% compatible with `-fdebug-instrumented-parse` from `f18` as

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-02-19 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. I've left a few comments, but these are nice-to-haves from my perspective. @tskeith , what do you think about the suggested changes in `f18`? We could upload a separate patch for that.

[PATCH] D96771: [OpenCL] Add distinct file extension for C++ for OpenCL

2021-02-19 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D96771#2571855 , @Anastasia wrote: > This is only the initial patch and for the moment the primary goal is to > remove the need for the flag at least from the clang perspective. Shorter compiler invocation is always nice! D

[PATCH] D96777: [clang][driver] Set the input type to Fortran when reading from stdin

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a subscriber: hans. awarzynski added a comment. In D96777#2578153 , @SouraVX wrote: > Thanks! for the patch. > This code touches some of the `clang` part, Anyway changes are pretty > self-explanatory. I'll leave this one to you, if you wa

[PATCH] D96864: [flang][driver] Add -Xflang and make -test-io a frontend-only flag

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd81f633fe28f: [flang][driver] Add -Xflang and make -test-io a frontend-only flang (authored by awarzynski). Changed prior to commit: https://reviews.llvm.org/D96864?vs=324287&id=325405#toc Repository:

[PATCH] D96864: [flang][driver] Add -Xflang and make -test-io a frontend-only flag

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thanks for reviewing @SouraVX ! I did update that comment before merging. Hopefully it _will_ make sense when we come back to it at later time :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96864/new/ https://reviews.

[PATCH] D97138: [Driver] replace argc_ with argc

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski requested changes to this revision. awarzynski added a comment. This revision now requires changes to proceed. Thank you for submitting this @achieveartificialintelligence ! The aim of these changes is to improve the consistency of the code-base with respect to the coding standards do

[PATCH] D97119: [flang][driver] Add options for -std=2018

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Hi @arnamoy10 , thank for working on this! I suggest making it more explicit that the new option is about _enabling standard conformance checks_. So e.g. `enableConformanceChecks` rather than `setStandard` (or `set_EnableConformanceChecks` if the member variable is

[PATCH] D97080: [flang][driver] Add -fintrinsic-modules-path option

2021-02-22 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski requested changes to this revision. awarzynski added a comment. This revision now requires changes to proceed. Hi @arnamoy10 , thanks for the patch! Both `ieee_arithmetic.mod` and `iso_fortran_env.mod` look like copies of similar files from `/tools/flang/include/flang`. Could you eith

[PATCH] D97457: [flang][driver] Add `-fdebug-dump-parsing-log`

2021-02-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a reviewer: sscalpone. Herald added subscribers: jansvoboda11, dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Adds `-fdebug-dump-parsing-log` in the new driver. This option is

[PATCH] D96777: [clang][driver] Set the input type to Fortran when reading from stdin

2021-02-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbaebc1162f81: [clang][driver] Set the input type to Fortran when reading from stdin (authored by awarzynski). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D9

[PATCH] D97138: [clang][flang] Improve the consistency of the code-base

2021-02-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. Thank you, this is a much appreciated improvement! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97138/new/ https://reviews.llvm.org/D97138 __

[PATCH] D97457: [flang][driver] Add `-fdebug-dump-parsing-log`

2021-02-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 326372. awarzynski added a comment. Remove spurious comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97457/new/ https://reviews.llvm.org/D97457 Files: clang/include/clang/Driver/Options.td flang/i

[PATCH] D97457: [flang][driver] Add `-fdebug-dump-parsing-log`

2021-02-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski marked an inline comment as done. awarzynski added inline comments. Comment at: flang/lib/Frontend/CompilerInvocation.cpp:88-95 +// Tweak the frontend configuration based on the frontend action +static void setUpFrontendBasedOnAction(FrontendOptions &opts) { + assert(

[PATCH] D103613: [flang][driver] Add support for `-module-suffix`

2021-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 349595. awarzynski added a comment. Minor tweaks (different suffix in test, updated help text) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103613/new/ https://reviews.llvm.org/D103613 Files: clang/inclu

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 349598. awarzynski added a comment. Rebased on top of D103613 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103612/new/ https://reviews.llvm.org/D103612 Files: clang/inc

[PATCH] D103613: [flang][driver] Add support for `-module-suffix`

2021-06-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG20bd2142d465: [flang][driver] Add support for `-module-suffix` (authored by awarzynski). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103613/new/ https://r

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 349868. awarzynski added a comment. Rebase on top of main, revert one small change uploaded accidentally Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103612/new/ https://reviews.llvm.org/D103612 Files: c

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 349881. awarzynski added a comment. Fix build and test failure Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103612/new/ https://reviews.llvm.org/D103612 Files: clang/include/clang/Driver/Options.td fla

[PATCH] D102849: [flang][driver] Add support for the "-init-only" option

2021-06-07 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe1da3297d253: [flang][driver] Add support for the "-init-only" option (authored by stuartellis, committed by awarzynski). Changed prior to commit:

[PATCH] D104305: [flang][driver] Add `-fdebug-dump-all`

2021-06-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a reviewer: sscalpone. Herald added a subscriber: dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. The new option will run the semantic checks and then dump the parse tree and a

[PATCH] D104305: [flang][driver] Add `-fdebug-dump-all`

2021-06-15 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 352234. awarzynski added a comment. Add missing test (forgot to add when making the submission) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D104305/new/ https://reviews.llvm.org/D104305 Files: clang/incl

[PATCH] D104305: [flang][driver] Add `-fdebug-dump-all`

2021-06-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGa6be6e31f181: [flang][driver] Add `-fdebug-dump-all` (authored by awarzynski). Changed prior to commit: https://reviews.llvm.org/D104305?vs=352234&id=352364#toc Repository: rG LLVM Github Monorepo C

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 352403. awarzynski added a comment. Rebase on top of main Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103612/new/ https://reviews.llvm.org/D103612 Files: clang/include/clang/Driver/Options.td flang/in

[PATCH] D104305: [flang][driver] Add `-fdebug-dump-all`

2021-06-16 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Apologies, this is my fault. Should be fixed: https://github.com/llvm/llvm-project/commit/46446e398b5202303280d9e18676c07529f1d0b0. I pushed it without a review as it felt rather straightforward and I wanted to make sure that you are unblocked. If for whatever reaso

[PATCH] D103612: [flang][driver] Add `-fno-unparse-typed-exprs`

2021-06-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 353032. awarzynski added a comment. Refine the semantics after some discussion offline Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D103612/new/ https://reviews.llvm.org/D103612 Files: clang/include/clang

[PATCH] D103612: [flang][driver] Add `-funparse-typed-exprs-as-fortran`

2021-06-18 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D103612#2827444 , @klausler wrote: >> The default behaviour is to always decorate unparsed typed expression with >> e.g. their KIND. The new flag can be used to turn this off, so that the >> generated output uses valid For

[PATCH] D103612: [flang][driver] Add `-funparse-typed-exprs-as-fortran`

2021-06-21 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D103612#2827468 , @klausler wrote: > Kind suffixes are described in subclause 7.4.3 of Fortran 2018, e.g. R708 on > p. 58. Many thanks for this reference. So when calling `Unparse,` one specifes `AnalyzedObjectsAsFortran`

[PATCH] D103612: [flang][driver] Add `-funparse-typed-exprs-as-fortran`

2021-06-24 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 354294. awarzynski added a subscriber: PeteSteinfeld. awarzynski added a comment. Rename the new flag as `-fno-analyzed-objects-for-unparse` Based on the discussion, I've renamed the flag to better reflect the intention. Does it make more sense now? Note

[PATCH] D99353: [driver] Make `clang` warn rather then error on `flang` options

2021-08-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D99353#2918629 , @protze.joachim wrote: > Any chance that we get this into llvm/13? Given that Release-13 branch has already been created (https://lists.llvm.org/pipermail/llvm-dev/2021-July/151956.html), this is very unl

[PATCH] D99353: [driver] Make `clang` warn rather then error on `flang` options

2021-08-02 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a subscriber: rsmith. awarzynski added a comment. In D99353#2919774 , @tstellar wrote: > This is something we could merge, just need a code owner ack. Let me add @rsmith as a reviewer. Repository: rG LLVM Github Monorepo CHANGES SINC

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-08-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D105881#2919575 , @jansvoboda11 wrote: > The `clang` driver always accepts both the positive and negative options, and > it always only considers the argument that appeared last on the command-line > (using `ArgList::getL

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-08-04 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 364220. awarzynski added a comment. Remove `EmptyKPM`, introduce `OptOutFC1FFlag` and `OptInFC1FFlag` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D105881/new/ https://reviews.llvm.org/D105881 Files: clan

[PATCH] D105881: [flang][driver] Refactor boolean options

2021-08-05 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG55a961559954: [flang][driver] Refactor boolean options (authored by awarzynski). Changed prior to commit: https://reviews.llvm.org/D105881?vs=3642

[PATCH] D106137: [flang][driver] Add support for Frontend Plugins

2021-08-10 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. This revision is now accepted and ready to land. LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106137/new/ https://reviews.llvm.org/D106137 __

[PATCH] D106137: [flang][driver] Add support for Frontend Plugins

2021-08-12 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGf52fc591fa34: [flang][driver] Add support for Frontend Plugins (authored by stuartellis, committed by awarzynski). Repository: rG LLVM Github Mono

[PATCH] D106137: [flang][driver] Add support for Frontend Plugins

2021-08-12 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D106137#2941616 , @DavidSpickett wrote: > This has broken cmake config on the out of tree flang bot: > https://lab.llvm.org/buildbot/#/builders/175/builds/2026 > > (with perhaps the least helpful cmake error I've ever seen)

[PATCH] D103612: [flang][driver] Add `-fno-analyzed-objects-for-unparse`

2021-06-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG2a7bb8494e9c: [flang][driver] Add `-fno-analyzed-objects-for-unparse` (authored by awarzynski). Changed prior to commit: https://reviews.llvm.org/D103612?vs=354294&id=354474#toc Repository: rG LLVM G

[PATCH] D103612: [flang][driver] Add `-fno-analyzed-objects-for-unparse`

2021-06-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D103612#2840886 , @klausler wrote: > This patch may have broken the shared library buildbots. Sorry about that. A fix is on its way. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.

[PATCH] D103612: [flang][driver] Add `-fno-analyzed-objects-for-unparse`

2021-06-25 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. I pushed a fix without a review: https://reviews.llvm.org/rGc3ebb53eabb7f851687f66ada88aa16f768d76ce. Please let me know if you prefer such changes to go through a regular review in the future! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-07-13 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski created this revision. Herald added a subscriber: dang. awarzynski requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. For boolean options, e.g. `-fxor-operator/-fno-xor-operator`, we ought to be using TableGen multiclasses. This way

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-07-13 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: clang/include/clang/Driver/Options.td:246 +class EmptyKPM : KeyPathAndMacro<"", "", ""> {} class DiagnosticOpts @jansvoboda11 , is this the right approach here? I'd like use `BoolFOption` in Flang, but we don't ne

[PATCH] D105881: [flang][driver] Switch to `BoolFOption` for boolean options

2021-07-13 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: clang/include/clang/Driver/Options.td:246 +class EmptyKPM : KeyPathAndMacro<"", "", ""> {} class DiagnosticOpts jansvoboda11 wrote: > awarzynski wrote: > > @jansvoboda11 , is this the right approach here? I'd like

[PATCH] D97457: [flang][driver] Add `-fdebug-dump-parsing-log`

2021-03-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski updated this revision to Diff 327048. awarzynski marked an inline comment as done. awarzynski added a comment. Move the call to setUpFrontendBasedOnAction after all options have been set Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97457

[PATCH] D97457: [flang][driver] Add `-fdebug-dump-parsing-log`

2021-03-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: flang/lib/Frontend/CompilerInvocation.cpp:88-95 +// Tweak the frontend configuration based on the frontend action +static void setUpFrontendBasedOnAction(FrontendOptions &opts) { + assert(opts.programAction_ != Fortran::frontend::Inv

[PATCH] D96875: [flang][driver] Add -fdebug-module-writer option

2021-03-01 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added inline comments. Comment at: clang/include/clang/Driver/Options.td:4280-4281 HelpText<"Dump provenance">; +def fdebug_module_writer : Flag<["-"],"fdebug-module-writer">, + HelpText<"Enables showing debug messages while writing module files.">;

[PATCH] D96344: [flang][driver] Add options for -fdefault* and -flarge-sizes

2021-03-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski requested changes to this revision. awarzynski added a comment. This revision now requires changes to proceed. This patch won't build with `BUILD_SHARED_LIBS` set to `On`. That's because a new dependency in `CompilerInvocation` is introduced (on `IntrinsicTypeDefaultKinds`). This depe

<    1   2   3   4   5   6   7   >