[PATCH] D130513: [Flang] Add -fconvert option to swap endianness for unformatted files

Jonathon Penix via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 25 22:58:39 PDT 2022


jpenix-quic added inline comments.


================
Comment at: clang/include/clang/Driver/Options.td:4897
 def ffixed_line_length_VALUE : Joined<["-"], "ffixed-line-length-">, Group<f_Group>, Alias<ffixed_line_length_EQ>;
+def fconvert_EQ : Joined<["-"], "fconvert=">, Group<f_Group>,
+  HelpText<"Set endian conversion of data for unformatted files">;
----------------
peixin wrote:
> Why do you move it here? Maybe it is not implemented now, clang may need this option eventually. @MaskRay 
I was using the fixed line length options as a reference for how to handle this--based on the discussion in the review here (https://reviews.llvm.org/D95460) about forwarding options to gfortran, I was thinking that it would also be safe to handle fconvert similarly, but I'm not 100% sure and definitely might be misunderstanding something!


================
Comment at: clang/lib/Driver/ToolChains/Flang.cpp:52
+                            options::OPT_fno_automatic,
+                            options::OPT_fconvert_EQ});
 }
----------------
Reading through https://reviews.llvm.org/D95460 again, I'm not sure this is the appropriate place to add . I am marking this as a TODO that I will revisit with the other feedback!


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D130513



More information about the cfe-commits mailing list