https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91220

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |ASSIGNED
   Last reconfirmed|                            |2020-01-21
           Assignee|unassigned at gcc dot gnu.org      |marxin at gcc dot 
gnu.org
     Ever confirmed|0                           |1

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Confirmed. Let me work on that.
One can see the full list with the following patch:

diff --git a/gcc/opt-functions.awk b/gcc/opt-functions.awk
index 2f0442dc563..494bc94b315 100644
--- a/gcc/opt-functions.awk
+++ b/gcc/opt-functions.awk
@@ -86,7 +86,7 @@ function nth_arg(n, s)
 }

 # Return a bitmask of CL_* values for option flags FLAGS.
-function switch_flags (flags)
+function switch_flags (flags, name)
 {
        result = "0"
        for (j = 0; j < n_langs; j++) {
@@ -94,6 +94,8 @@ function switch_flags (flags)
                gsub ( "\\+", "\\+", regex )
                result = result test_flag(regex, flags, " | " macros[j])
        }
+       if (result ~ "CL_" && flags ~ "Common")
+         print "#error -" name " combines CL_COMMON and some FE flags: " flags
        result = result \
          test_flag("Common", flags, " | CL_COMMON") \
          test_flag("Target", flags, " | CL_TARGET") \
diff --git a/gcc/optc-gen.awk b/gcc/optc-gen.awk
index 73a96bac9e7..751be2471e3 100644
--- a/gcc/optc-gen.awk
+++ b/gcc/optc-gen.awk
@@ -401,7 +401,7 @@ for (i = 0; i < n_opts; i++) {
               alias_data, back_chain[i], len)
        printf(" /* .neg_idx = */ %d,\n", idx)
        condition = opt_args("Condition", flags[i])
-       cl_flags = switch_flags(flags[i])
+       cl_flags = switch_flags(flags[i], opts[i])
        cl_bit_fields = switch_bit_fields(flags[i])
        cl_zero_bit_fields = switch_bit_fields("")
        if (condition != "")

List:

options.c:2776:2: error: #error --dump combines CL_COMMON and some FE flags:
BRIG Separate Alias(d) C ObjC C++ ObjC++ Separate Alias(d) Common Separate
Alias(d) Fortran Separate Alias(d)
 2776 | #error --dump combines CL_COMMON and some FE flags: BRIG Separate
Alias(d) C ObjC C++ ObjC++ Separate Alias(d) Common Separate Alias(d) Fortran
Separate Alias(d)
      |  ^~~~~
options.c:2786:2: error: #error --dump= combines CL_COMMON and some FE flags:
BRIG Joined Alias(d) C ObjC C++ ObjC++ Joined Alias(d) Common Joined Alias(d)
Fortran Joined Alias(d)
 2786 | #error --dump= combines CL_COMMON and some FE flags: BRIG Joined
Alias(d) C ObjC C++ ObjC++ Joined Alias(d) Common Joined Alias(d) Fortran
Joined Alias(d)
      |  ^~~~~
options.c:3156:2: error: #error --no-warnings combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ Alias(w) Common Alias(w)
 3156 | #error --no-warnings combines CL_COMMON and some FE flags: C ObjC C++
ObjC++ Alias(w) Common Alias(w)
      |  ^~~~~
options.c:3175:2: error: #error --output combines CL_COMMON and some FE flags:
C ObjC C++ ObjC++ Separate Alias(o) Common Driver Separate Alias(o)
MissingArgError(missing filename after %qs) Fortran Separate Alias(o)
 3175 | #error --output combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Separate Alias(o) Common Driver Separate Alias(o) MissingArgError(missing
filename after %qs) Fortran Separate Alias(o)
      |  ^~~~~
options.c:3194:2: error: #error --output= combines CL_COMMON and some FE flags:
BRIG Driver Joined Alias(o) MissingArgError(missing filename after %qs) C ObjC
C++ ObjC++ Joined Alias(o) Common Driver Joined Alias(o)
MissingArgError(missing filename after %qs) Fortran Joined Alias(o)
 3194 | #error --output= combines CL_COMMON and some FE flags: BRIG Driver
Joined Alias(o) MissingArgError(missing filename after %qs) C ObjC C++ ObjC++
Joined Alias(o) Common Driver Joined Alias(o) MissingArgError(missing filename
after %qs) Fortran Joined Alias(o)
      |  ^~~~~
options.c:5310:2: error: #error --pedantic combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ Alias(pedantic) Common Alias(Wpedantic)
 5310 | #error --pedantic combines CL_COMMON and some FE flags: C ObjC C++
ObjC++ Alias(pedantic) Common Alias(Wpedantic)
      |  ^~~~~
options.c:5662:2: error: #error --verbose combines CL_COMMON and some FE flags:
Common C ObjC C++ ObjC++ Alias(v) D Alias(v) Driver Alias(v) Fortran Alias(v)
 5662 | #error --verbose combines CL_COMMON and some FE flags: Common C ObjC
C++ ObjC++ Alias(v) D Alias(v) Driver Alias(v) Fortran Alias(v)
      |  ^~~~~
options.c:6842:2: error: #error -Wcpp combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ CppReason(CPP_W_WARNING_DIRECTIVE) Common Var(warn_cpp) Init(1)
Warning
 6842 | #error -Wcpp combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
CppReason(CPP_W_WARNING_DIRECTIVE) Common Var(warn_cpp) Init(1) Warning
      |  ^~~~~
options.c:6906:2: error: #error -Wdeprecated combines CL_COMMON and some FE
flags: C C++ ObjC ObjC++ CPP(cpp_warn_deprecated) CppReason(CPP_W_DEPRECATED)
Common Var(warn_deprecated) Init(1) Warning D
 6906 | #error -Wdeprecated combines CL_COMMON and some FE flags: C C++ ObjC
ObjC++ CPP(cpp_warn_deprecated) CppReason(CPP_W_DEPRECATED) Common
Var(warn_deprecated) Init(1) Warning D
      |  ^~~~~
options.c:7078:2: error: #error -Werror combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ Common Var(warnings_are_errors) D
 7078 | #error -Werror combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Common Var(warnings_are_errors) D
      |  ^~~~~
options.c:7115:2: error: #error -Wextra combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ Warning Common Var(extra_warnings) Warning Fortran Warning
 7115 | #error -Wextra combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Warning Common Var(extra_warnings) Warning Fortran Warning
      |  ^~~~~
options.c:7674:2: error: #error -Wmaybe-uninitialized combines CL_COMMON and
some FE flags: C ObjC C++ ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall)
Common Var(warn_maybe_uninitialized) Warning EnabledBy(Wuninitialized) Fortran
LangEnabledBy(Fortran,Wall)
 7674 | #error -Wmaybe-uninitialized combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall) Common
Var(warn_maybe_uninitialized) Warning EnabledBy(Wuninitialized) Fortran
LangEnabledBy(Fortran,Wall)
      |  ^~~~~
options.c:7702:2: error: #error -Wmisleading-indentation combines CL_COMMON and
some FE flags: C C++ Common Var(warn_misleading_indentation) Warning
LangEnabledBy(C C++,Wall)
 7702 | #error -Wmisleading-indentation combines CL_COMMON and some FE flags: C
C++ Common Var(warn_misleading_indentation) Warning LangEnabledBy(C C++,Wall)
      |  ^~~~~
options.c:8135:2: error: #error -Wpedantic combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ CPP(cpp_pedantic) CppReason(CPP_W_PEDANTIC) Warning
Common Var(pedantic) Init(0) Warning Fortran
 8135 | #error -Wpedantic combines CL_COMMON and some FE flags: C ObjC C++
ObjC++ CPP(cpp_pedantic) CppReason(CPP_W_PEDANTIC) Warning Common Var(pedantic)
Init(0) Warning Fortran
      |  ^~~~~
options.c:8595:2: error: #error -Wstrict-aliasing= combines CL_COMMON and some
FE flags: C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 3, 0)
IntegerRange(0, 3) Common Joined RejectNegative UInteger
Var(warn_strict_aliasing) Warning
 8595 | #error -Wstrict-aliasing= combines CL_COMMON and some FE flags: C ObjC
C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 3, 0) IntegerRange(0, 3)
Common Joined RejectNegative UInteger Var(warn_strict_aliasing) Warning
      |  ^~~~~
options.c:8623:2: error: #error -Wstrict-overflow= combines CL_COMMON and some
FE flags: C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0)
IntegerRange(0, 5) Common Joined RejectNegative UInteger
Var(warn_strict_overflow) Warning
 8623 | #error -Wstrict-overflow= combines CL_COMMON and some FE flags: C ObjC
C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall, 1, 0) IntegerRange(0, 5)
Common Joined RejectNegative UInteger Var(warn_strict_overflow) Warning
      |  ^~~~~
options.c:8858:2: error: #error -Wsystem-headers combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ Warning Common Var(warn_system_headers) Warning
 8858 | #error -Wsystem-headers combines CL_COMMON and some FE flags: C ObjC
C++ ObjC++ Warning Common Var(warn_system_headers) Warning
      |  ^~~~~
options.c:8994:2: error: #error -Wuninitialized combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall) Common
Var(warn_uninitialized) Warning EnabledBy(Wextra) Fortran
LangEnabledBy(Fortran,Wall)
 8994 | #error -Wuninitialized combines CL_COMMON and some FE flags: C ObjC C++
ObjC++ LTO LangEnabledBy(C ObjC C++ ObjC++ LTO,Wall) Common
Var(warn_uninitialized) Warning EnabledBy(Wextra) Fortran
LangEnabledBy(Fortran,Wall)
      |  ^~~~~
options.c:9040:2: error: #error -Wunused combines CL_COMMON and some FE flags:
C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wall) Common Var(warn_unused)
Init(0) Warning LangEnabledBy(Fortran,Wall)
 9040 | #error -Wunused combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
LangEnabledBy(C ObjC C++ ObjC++,Wall) Common Var(warn_unused) Init(0) Warning
LangEnabledBy(Fortran,Wall)
      |  ^~~~~
options.c:9158:2: error: #error -Wunused-variable combines CL_COMMON and some
FE flags: C ObjC C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wunused) Common
Var(warn_unused_variable) Warning EnabledBy(Wunused)
 9158 | #error -Wunused-variable combines CL_COMMON and some FE flags: C ObjC
C++ ObjC++ LangEnabledBy(C ObjC C++ ObjC++,Wunused) Common
Var(warn_unused_variable) Warning EnabledBy(Wunused)
      |  ^~~~~
options.c:9447:2: error: #error -d combines CL_COMMON and some FE flags: C ObjC
C++ ObjC++ Joined Common Joined Fortran Joined
 9447 | #error -d combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Joined Common Joined Fortran Joined
      |  ^~~~~
options.c:10105:2: error: #error -fbounds-check combines CL_COMMON and some FE
flags: Common Report Var(flag_bounds_check) D
10105 | #error -fbounds-check combines CL_COMMON and some FE flags: Common
Report Var(flag_bounds_check) D
      |  ^~~~~
options.c:15250:2: error: #error -fstrong-eval-order combines CL_COMMON and
some FE flags: C++ ObjC++ Common Alias(fstrong-eval-order=, all, none)
15250 | #error -fstrong-eval-order combines CL_COMMON and some FE flags: C++
ObjC++ Common Alias(fstrong-eval-order=, all, none)
      |  ^~~~~
options.c:15260:2: error: #error -fstrong-eval-order= combines CL_COMMON and
some FE flags: C++ ObjC++ Common Var(flag_strong_eval_order) Joined
Enum(strong_eval_order) RejectNegative Init(-1)
15260 | #error -fstrong-eval-order= combines CL_COMMON and some FE flags: C++
ObjC++ Common Var(flag_strong_eval_order) Joined Enum(strong_eval_order)
RejectNegative Init(-1)
      |  ^~~~~
options.c:18753:2: error: #error -o combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ Joined Separate Common Driver Joined Separate
Var(asm_file_name) MissingArgError(missing filename after %qs) Fortran Joined
Separate Go Joined Separate
18753 | #error -o combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Joined Separate Common Driver Joined Separate Var(asm_file_name)
MissingArgError(missing filename after %qs) Fortran Joined Separate Go Joined
Separate
      |  ^~~~~
options.c:18790:2: error: #error -pedantic combines CL_COMMON and some FE
flags: C ObjC C++ ObjC++ Alias(Wpedantic) Common Alias(Wpedantic)
18790 | #error -pedantic combines CL_COMMON and some FE flags: C ObjC C++
ObjC++ Alias(Wpedantic) Common Alias(Wpedantic)
      |  ^~~~~
options.c:19790:2: error: #error -v combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ Common Driver Var(verbose_flag) D Fortran
19790 | #error -v combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Common Driver Var(verbose_flag) D Fortran
      |  ^~~~~
options.c:19809:2: error: #error -w combines CL_COMMON and some FE flags: C
ObjC C++ ObjC++ Common Var(inhibit_warnings)
19809 | #error -w combines CL_COMMON and some FE flags: C ObjC C++ ObjC++
Common Var(inhibit_warnings)
      |  ^~~~~

Reply via email to