llvm-project icon indicating copy to clipboard operation
llvm-project copied to clipboard

flang-new -fc1 --version hangs

Open psteinfeld opened this issue 5 years ago • 2 comments

Bugzilla Link 52096
Version unspecified
OS Windows NT
CC @banach-space,@jeanPerier,@kiranktp,@sscalpone

Extended Description

The following invocation of flang-new hangs the compiler --

flang-new -fc1 --version

psteinfeld avatar Oct 06 '21 18:10 psteinfeld

Options.td enables --version for both flang-new and flang-new -fc1. However, flang-new -fc1 checks for the presence of -version instead. Hence flang-new -fc1 --version is accepted but triggers no action. Instead, the frontend driver waits for fortran source from standard input.

In https://reviews.llvm.org/D122542 I propose a fix, which makes flang-new -fc1 accept -version instead of --version. This behaviour is (since https://reviews.llvm.org/D122344) consistent with clang -cc1 and clang -cc1as.

ekieri avatar Mar 27 '22 07:03 ekieri

Legend, thanks for looking into this!

This makes sense to me and we can close it once D122542 is merged.

-Andrzej

banach-space avatar Mar 28 '22 08:03 banach-space