tblah updated this revision to Diff 552723. tblah added a comment. Thanks for taking a look.
Changes: add test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D158612/new/ https://reviews.llvm.org/D158612 Files: clang/include/clang/Driver/Options.td flang/test/Driver/driver-help-hidden.f90 flang/test/Driver/driver-help.f90 flang/test/Driver/fintegrated-as.f90 flang/test/Driver/fno-integrated-as.f90
Index: flang/test/Driver/fintegrated-as.f90 =================================================================== --- flang/test/Driver/fintegrated-as.f90 +++ flang/test/Driver/fintegrated-as.f90 @@ -1,4 +1,4 @@ -! Tests for the `-fno-integrated-as` flag. +! Tests for the `-f(no-)integrated-as` flag. ! UNSUPPORTED: system-windows @@ -11,10 +11,11 @@ ! CHECK-SAME: "-o" "[[assembly_file:.*]].s" ! CHECK-NEXT: "-o" "{{.*}}.o" "[[assembly_file:.*]].s" -!----------------------------- -! Without `-fno-integrated-as` -!----------------------------- +!---------------------------------------------------------------- +! Without `-fno-integrated-as` (default) / With `-fintegrated-as` +!---------------------------------------------------------------- ! Verify that there _is no_ separate line with an assembler invocation +! RUN: %flang -c -fintegrated-as %s -### 2>&1 | FileCheck %s -check-prefix=DEFAULT ! RUN: %flang -c %s -### 2>&1 | FileCheck %s -check-prefix=DEFAULT ! DEFAULT-LABEL: "-fc1" -! DEFAULT-SAME: "-o" "{{.*}}.o" "{{.*}}fno-integrated-as.f90" +! DEFAULT-SAME: "-o" "{{.*}}.o" "{{.*}}fintegrated-as.f90" Index: flang/test/Driver/driver-help.f90 =================================================================== --- flang/test/Driver/driver-help.f90 +++ flang/test/Driver/driver-help.f90 @@ -39,6 +39,7 @@ ! HELP-NEXT: -fhonor-nans Specify that floating-point optimizations are not allowed that assume arguments and results are not NANs. ! HELP-NEXT: -fimplicit-none No implicit typing allowed unless overridden by IMPLICIT statements ! HELP-NEXT: -finput-charset=<value> Specify the default character set for source files +! HELP-NEXT: -fintegrated-as Enable the integrated assembler ! HELP-NEXT: -fintrinsic-modules-path <dir> ! HELP-NEXT: Specify where to find the compiled intrinsic modules ! HELP-NEXT: -flarge-sizes Use INTEGER(KIND=8) for the result type in size-related intrinsics Index: flang/test/Driver/driver-help-hidden.f90 =================================================================== --- flang/test/Driver/driver-help-hidden.f90 +++ flang/test/Driver/driver-help-hidden.f90 @@ -43,6 +43,7 @@ ! CHECK-NEXT: -fhonor-nans Specify that floating-point optimizations are not allowed that assume arguments and results are not NANs. ! CHECK-NEXT: -fimplicit-none No implicit typing allowed unless overridden by IMPLICIT statements ! CHECK-NEXT: -finput-charset=<value> Specify the default character set for source files +! CHECK-NEXT: -fintegrated-as Enable the integrated assembler ! CHECK-NEXT: -fintrinsic-modules-path <dir> ! CHECK-NEXT: Specify where to find the compiled intrinsic modules ! CHECK-NEXT: -flang-experimental-hlfir Index: clang/include/clang/Driver/Options.td =================================================================== --- clang/include/clang/Driver/Options.td +++ clang/include/clang/Driver/Options.td @@ -2366,13 +2366,13 @@ PosFlag<SetTrue, [], [ClangOption, CC1Option, FC1Option, FlangOption], "Allow division operations to be reassociated", [funsafe_math_optimizations.KeyPath]>, - NegFlag<SetFalse>>; + NegFlag<SetFalse, [], [ClangOption, CC1Option, FC1Option, FlangOption]>>; defm approx_func : BoolFOption<"approx-func", LangOpts<"ApproxFunc">, DefaultFalse, PosFlag<SetTrue, [], [ClangOption, CC1Option, FC1Option, FlangOption], "Allow certain math function calls to be replaced " "with an approximately equivalent calculation", [funsafe_math_optimizations.KeyPath]>, - NegFlag<SetFalse>>; + NegFlag<SetFalse, [], [ClangOption, CC1Option, FC1Option, FlangOption]>>; defm finite_math_only : BoolFOption<"finite-math-only", LangOpts<"FiniteMathOnly">, DefaultFalse, PosFlag<SetTrue, [], [ClangOption, CC1Option], @@ -2386,7 +2386,7 @@ NegFlag<SetTrue, [], [ClangOption, CC1Option, FC1Option, FlangOption], "Allow optimizations that ignore the sign of floating point zeros", [cl_no_signed_zeros.KeyPath, funsafe_math_optimizations.KeyPath]>, - PosFlag<SetFalse>>; + PosFlag<SetFalse, [], [ClangOption, CC1Option, FC1Option, FlangOption]>>; def fhonor_nans : Flag<["-"], "fhonor-nans">, Group<f_Group>, Visibility<[ClangOption, FlangOption]>, HelpText<"Specify that floating-point optimizations are not allowed that " @@ -3383,12 +3383,12 @@ LangOpts<"ROPI">, DefaultFalse, PosFlag<SetTrue, [], [ClangOption, FlangOption, CC1Option], "Generate read-only position independent code (ARM only)">, - NegFlag<SetFalse>>; + NegFlag<SetFalse, [], [ClangOption, FlangOption, CC1Option]>>; defm rwpi : BoolFOption<"rwpi", LangOpts<"RWPI">, DefaultFalse, PosFlag<SetTrue, [], [ClangOption, FlangOption, CC1Option], "Generate read-write position independent code (ARM only)">, - NegFlag<SetFalse>>; + NegFlag<SetFalse, [], [ClangOption, FlangOption, CC1Option]>>; def fplugin_EQ : Joined<["-"], "fplugin=">, Group<f_Group>, Flags<[NoXarchOption]>, MetaVarName<"<dsopath>">, HelpText<"Load the named plugin (dynamic shared object)">; @@ -5311,7 +5311,7 @@ defm integrated_as : BoolFOption<"integrated-as", CodeGenOpts<"DisableIntegratedAS">, DefaultFalse, NegFlag<SetTrue, [], [ClangOption, CC1Option, FlangOption], "Disable">, - PosFlag<SetFalse, [], [ClangOption], "Enable">, + PosFlag<SetFalse, [], [ClangOption, CC1Option, FlangOption], "Enable">, BothFlags<[], [ClangOption], " the integrated assembler">>; def fintegrated_cc1 : Flag<["-"], "fintegrated-cc1">,
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits