This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: -Wunused-macros
Kaveh R. Ghazi wrote:-
> After all of your cleanups, how many of these warnings remain in the
> gcc bootstrap?
The code is now in CVS. This is what I got for adding it to BOOT_CFLAGS
for stage2, for a C/ObjC/C++ build. About 80% is YACC/LEX related,
the rest are not necessarily removable but fixable in some other way.
I'd not run it on cp/ or obj/ until now.
../../gcc/gengtype-lex.c:127:1: warning: macro "yyless" is not used
../../gcc/gengtype-lex.c:291:1: warning: macro "YY_NUM_RULES" is not used
../../gcc/gengtype-lex.c:1389:1: warning: macro "REJECT" is not used
../../gcc/gengtype-lex.c:9:1: warning: macro "YY_FLEX_MAJOR_VERSION" is not used
../../gcc/gengtype-lex.c:249:1: warning: macro "yy_new_buffer" is not used
../../gcc/gengtype-lex.c:2949:1: warning: macro "yyless" is not used
../../gcc/gengtype-lex.c:258:1: warning: macro "yy_set_bol" is not used
../../gcc/gengtype-lex.c:1390:1: warning: macro "yymore" is not used
../../gcc/gengtype-lex.c:210:1: warning: macro "YY_CURRENT_BUFFER" is not used
../../gcc/gengtype-lex.c:138:1: warning: macro "unput" is not used
../../gcc/gengtype-lex.c:251:1: warning: macro "yy_set_interactive" is not used
../../gcc/gengtype-lex.c:89:1: warning: macro "YYSTATE" is not used
../../gcc/gengtype-lex.c:1527:1: warning: macro "ECHO" is not used
../../gcc/gengtype-lex.c:10:1: warning: macro "YY_FLEX_MINOR_VERSION" is not used
../../gcc/gengtype-lex.c:239:1: warning: macro "YY_FLUSH_BUFFER" is not used
../../gcc/gengtype-lex.c:1573:1: warning: macro "YY_START_STACK_INCR" is not used
../../gcc/gengtype-yacc.c:20:1: warning: macro "STRING" is not used
../../gcc/gengtype-yacc.c:15:1: warning: macro "PARAM_IS" is not used
../../gcc/gengtype-yacc.c:23:1: warning: macro "CHAR" is not used
../../gcc/gengtype-yacc.c:14:1: warning: macro "ALIAS" is not used
/usr/share/bison/bison.simple:421:1: warning: macro "YYPOPSTACK" is not used
../../gcc/gengtype-yacc.c:8:1: warning: macro "ENT_EXTERNSTATIC" is not used
../../gcc/gengtype-yacc.c:12:1: warning: macro "STRUCT" is not used
../../gcc/gengtype-yacc.c:16:1: warning: macro "NUM" is not used
../../gcc/gengtype-yacc.c:6:1: warning: macro "ENT_TYPEDEF_STRUCT" is not used
/usr/share/bison/bison.simple:167:1: warning: macro "YYBACKUP" is not used
/usr/share/bison/bison.simple:161:1: warning: macro "YYERROR" is not used
../../gcc/gengtype-yacc.c:11:1: warning: macro "UNION" is not used
/usr/share/bison/bison.simple:155:1: warning: macro "yyerrok" is not used
../../gcc/gengtype-yacc.c:13:1: warning: macro "ENUM" is not used
/usr/share/bison/bison.simple:166:1: warning: macro "YYRECOVERING" is not used
/usr/share/bison/bison.simple:185:1: warning: macro "YYERRCODE" is not used
../../gcc/gengtype-yacc.c:9:1: warning: macro "ENT_YACCUNION" is not used
../../gcc/gengtype-yacc.c:21:1: warning: macro "ARRAY" is not used
/usr/share/bison/bison.simple:165:1: warning: macro "YYFAIL" is not used
../../gcc/gengtype-yacc.c:22:1: warning: macro "PERCENT_ID" is not used
../../gcc/gengtype-yacc.c:7:1: warning: macro "ENT_STRUCT" is not used
../../gcc/gengtype-yacc.c:19:1: warning: macro "ID" is not used
../../gcc/gengtype-yacc.c:17:1: warning: macro "PERCENTPERCENT" is not used
../../gcc/gengtype-yacc.c:10:1: warning: macro "GTY_TOKEN" is not used
/usr/share/bison/bison.simple:196:1: warning: macro "YYLLOC_DEFAULT" is not used
/usr/share/bison/bison.simple:156:1: warning: macro "yyclearin" is not used
../../gcc/gengtype-yacc.c:18:1: warning: macro "SCALAR" is not used
/usr/share/bison/bison.simple:185:1: warning: macro "YYERRCODE" is not used
/usr/share/bison/bison.simple:155:1: warning: macro "yyerrok" is not used
/usr/share/bison/bison.simple:421:1: warning: macro "YYPOPSTACK" is not used
../../gcc/c-parse.c:54:1: warning: macro "UNARY" is not used
/usr/share/bison/bison.simple:166:1: warning: macro "YYRECOVERING" is not used
../../gcc/c-parse.c:65:1: warning: macro "CLASSNAME" is not used
/usr/share/bison/bison.simple:260:1: warning: macro "YYMAXDEPTH" is not used
../../gcc/c-parse.c:57:1: warning: macro "HYPERUNARY" is not used
/usr/share/bison/bison.simple:165:1: warning: macro "YYFAIL" is not used
/usr/share/bison/bison.simple:167:1: warning: macro "YYBACKUP" is not used
/usr/share/bison/bison.simple:156:1: warning: macro "yyclearin" is not used
/usr/share/bison/bison.simple:196:1: warning: macro "YYLLOC_DEFAULT" is not used
../../gcc/c-common.c:4390:1: warning: macro "preprocessing_asm_p" is not used
../../gcc/combine.c:8000:1: warning: macro "num_sign_bit_copies" is not used
../../gcc/combine.c:96:1: warning: macro "gen_lowpart" is not used
../../gcc/dwarf2out.c:335:1: warning: macro "CIE_LENGTH_LABEL" is not used
../../gcc/dwarf2out.c:3769:1: warning: macro "BODY_BEGIN_LABEL" is not used
../../gcc/dwarf2out.c:339:1: warning: macro "FDE_LENGTH_LABEL" is not used
../../gcc/dwarf2out.c:3772:1: warning: macro "BODY_END_LABEL" is not used
../../gcc/dwarf2out.c:3253:1: warning: macro "DWARF_LINE_PROLOG_HEADER_SIZE" is not used
../../gcc/dwarf2out.c:3760:1: warning: macro "BSS_END_LABEL" is not used
../../gcc/dwarf2out.c:3757:1: warning: macro "DATA_END_LABEL" is not used
../../gcc/dwarfout.c:997:1: warning: macro "DATA1_SECTION_NAME" is not used
../../gcc/dwarfout.c:1148:1: warning: macro "DERIV_END_LABEL_FMT" is not used
../../gcc/dwarfout.c:1056:1: warning: macro "RODATA1_BEGIN_LABEL" is not used
../../gcc/dwarfout.c:1145:1: warning: macro "DERIV_BEGIN_LABEL_FMT" is not used
../../gcc/dwarfout.c:1151:1: warning: macro "SL_BEGIN_LABEL_FMT" is not used
../../gcc/dwarfout.c:936:1: warning: macro "FILE_ASM_OP" is not used
../../gcc/dwarfout.c:1045:1: warning: macro "DATA1_END_LABEL" is not used
../../gcc/dwarfout.c:1059:1: warning: macro "RODATA1_END_LABEL" is not used
../../gcc/dwarfout.c:939:1: warning: macro "VERSION_ASM_OP" is not used
../../gcc/dwarfout.c:1154:1: warning: macro "SL_END_LABEL_FMT" is not used
../../gcc/dwarfout.c:1003:1: warning: macro "RODATA1_SECTION_NAME" is not used
../../gcc/dwarfout.c:1042:1: warning: macro "DATA1_BEGIN_LABEL" is not used
../../gcc/function.c:77:1: warning: macro "NAME__MAIN" is not used
../../gcc/gcse.c:171:1: warning: macro "obstack_chunk_alloc" is not used
../../gcc/varasm.c:57:1: warning: macro "TRAMPOLINE_ALIGNMENT" is not used
../../gcc/cp/error.c:48:1: warning: macro "print_whitespace" is not used
../../gcc/cp/parse.c:63:1: warning: macro "NSNAME" is not used
../../gcc/cp/parse.c:7:1: warning: macro "tTYPENAME" is not used
../../gcc/cp/parse.c:88:1: warning: macro "TYPENAME_DEFN" is not used
../../gcc/cp/parse.c:20:1: warning: macro "ELSE" is not used
../../gcc/cp/parse.c:23:1: warning: macro "FOR" is not used
../../gcc/cp/parse.c:81:1: warning: macro "CATCH" is not used
../../gcc/cp/parse.c:47:1: warning: macro "CXX_TRUE" is not used
../../gcc/cp/parse.c:33:1: warning: macro "ALIGNOF" is not used
../../gcc/cp/parse.c:27:1: warning: macro "BREAK" is not used
../../gcc/cp/parse.c:21:1: warning: macro "WHILE" is not used
../../gcc/cp/parse.c:42:1: warning: macro "VISSPEC" is not used
../../gcc/cp/parse.c:31:1: warning: macro "ASM_KEYWORD" is not used
../../gcc/cp/parse.c:40:1: warning: macro "VA_ARG" is not used
../../gcc/cp/parse.c:53:1: warning: macro "TEMPLATE" is not used
../../gcc/cp/parse.c:44:1: warning: macro "NEW" is not used
../../gcc/cp/parse.c:74:1: warning: macro "DOT_STAR" is not used
../../gcc/cp/parse.c:51:1: warning: macro "USING" is not used
../../gcc/cp/parse.c:45:1: warning: macro "THIS" is not used
../../gcc/cp/parse.c:34:1: warning: macro "SIGOF" is not used
../../gcc/cp/parse.c:75:1: warning: macro "UNARY" is not used
../../gcc/cp/parse.c:89:1: warning: macro "IDENTIFIER_DEFN" is not used
../../gcc/cp/parse.c:25:1: warning: macro "CASE" is not used
../../gcc/cp/parse.c:60:1: warning: macro "EXPORT" is not used
../../gcc/cp/parse.c:76:1: warning: macro "PLUSPLUS" is not used
../../gcc/cp/parse.c:87:1: warning: macro "PRE_PARSED_FUNCTION_DECL" is not used
../../gcc/cp/parse.c:72:1: warning: macro "RSHIFT" is not used
../../gcc/cp/parse.c:58:1: warning: macro "CONST_CAST" is not used
../../gcc/cp/parse.c:43:1: warning: macro "DELETE" is not used
../../gcc/cp/parse.c:37:1: warning: macro "LABEL" is not used
../../gcc/cp/parse.c:56:1: warning: macro "STATIC_CAST" is not used
../../gcc/cp/parse.c:67:1: warning: macro "ANDAND" is not used
../../gcc/cp/parse.c:24:1: warning: macro "SWITCH" is not used
../../gcc/cp/parse.c:18:1: warning: macro "ENUM" is not used
../../gcc/cp/parse.c:52:1: warning: macro "LEFT_RIGHT" is not used
../../gcc/cp/parse.c:83:1: warning: macro "ALL" is not used
../../gcc/cp/parse.c:8:1: warning: macro "SELFNAME" is not used
/usr/share/bison/bison.simple:165:1: warning: macro "YYFAIL" is not used
../../gcc/cp/parse.c:73:1: warning: macro "POINTSAT_STAR" is not used
../../gcc/cp/parse.c:49:1: warning: macro "NAMESPACE" is not used
../../gcc/cp/parse.c:84:1: warning: macro "PRE_PARSED_CLASS_DECL" is not used
../../gcc/cp/parse.c:92:1: warning: macro "END_OF_SAVED_INPUT" is not used
../../gcc/cp/parse.c:17:1: warning: macro "SIZEOF" is not used
../../gcc/cp/parse.c:28:1: warning: macro "CONTINUE" is not used
../../gcc/cp/parse.c:15:1: warning: macro "STRING" is not used
../../gcc/cp/parse.c:39:1: warning: macro "IMAGPART" is not used
../../gcc/cp/parse.c:35:1: warning: macro "ATTRIBUTE" is not used
../../gcc/cp/parse.c:48:1: warning: macro "CXX_FALSE" is not used
../../gcc/cp/parse.c:16:1: warning: macro "ELLIPSIS" is not used
../../gcc/cp/parse.c:36:1: warning: macro "EXTENSION" is not used
../../gcc/cp/parse.c:38:1: warning: macro "REALPART" is not used
/usr/share/bison/bison.simple:421:1: warning: macro "YYPOPSTACK" is not used
../../gcc/cp/parse.c:41:1: warning: macro "AGGR" is not used
../../gcc/cp/parse.c:61:1: warning: macro "EMPTY" is not used
../../gcc/cp/parse.c:62:1: warning: macro "PTYPENAME" is not used
../../gcc/cp/parse.c:66:1: warning: macro "OROR" is not used
../../gcc/cp/parse.c:85:1: warning: macro "DEFARG" is not used
../../gcc/cp/parse.c:64:1: warning: macro "THROW" is not used
../../gcc/cp/parse.c:70:1: warning: macro "ARITHCOMPARE" is not used
../../gcc/cp/parse.c:79:1: warning: macro "POINTSAT" is not used
../../gcc/cp/parse.c:69:1: warning: macro "EQCOMPARE" is not used
../../gcc/cp/parse.c:55:1: warning: macro "DYNAMIC_CAST" is not used
../../gcc/cp/parse.c:10:1: warning: macro "SCSPEC" is not used
../../gcc/cp/parse.c:80:1: warning: macro "TRY" is not used
../../gcc/cp/parse.c:90:1: warning: macro "PTYPENAME_DEFN" is not used
../../gcc/cp/parse.c:11:1: warning: macro "TYPESPEC" is not used
/usr/share/bison/bison.simple:155:1: warning: macro "yyerrok" is not used
../../gcc/cp/parse.c:30:1: warning: macro "GOTO" is not used
../../gcc/cp/parse.c:78:1: warning: macro "HYPERUNARY" is not used
../../gcc/cp/parse.c:6:1: warning: macro "IDENTIFIER" is not used
/usr/share/bison/bison.simple:260:1: warning: macro "YYMAXDEPTH" is not used
/usr/share/bison/bison.simple:167:1: warning: macro "YYBACKUP" is not used
../../gcc/cp/parse.c:77:1: warning: macro "MINUSMINUS" is not used
/usr/share/bison/bison.simple:185:1: warning: macro "YYERRCODE" is not used
../../gcc/cp/parse.c:14:1: warning: macro "VAR_FUNC_NAME" is not used
../../gcc/cp/parse.c:65:1: warning: macro "ASSIGN" is not used
../../gcc/cp/parse.c:29:1: warning: macro "RETURN_KEYWORD" is not used
../../gcc/cp/parse.c:12:1: warning: macro "CV_QUALIFIER" is not used
../../gcc/cp/parse.c:91:1: warning: macro "END_OF_LINE" is not used
../../gcc/cp/parse.c:68:1: warning: macro "MIN_MAX" is not used
../../gcc/cp/parse.c:9:1: warning: macro "PFUNCNAME" is not used
/usr/share/bison/bison.simple:166:1: warning: macro "YYRECOVERING" is not used
../../gcc/cp/parse.c:26:1: warning: macro "DEFAULT" is not used
../../gcc/cp/parse.c:50:1: warning: macro "TYPENAME_KEYWORD" is not used
../../gcc/cp/parse.c:22:1: warning: macro "DO" is not used
../../gcc/cp/parse.c:71:1: warning: macro "LSHIFT" is not used
../../gcc/cp/parse.c:19:1: warning: macro "IF" is not used
../../gcc/cp/parse.c:46:1: warning: macro "OPERATOR" is not used
../../gcc/cp/parse.c:13:1: warning: macro "CONSTANT" is not used
../../gcc/cp/parse.c:86:1: warning: macro "DEFARG_MARKER" is not used
../../gcc/cp/parse.c:54:1: warning: macro "TYPEID" is not used
../../gcc/cp/parse.c:82:1: warning: macro "EXTERN_LANG_STRING" is not used
../../gcc/cp/parse.c:32:1: warning: macro "TYPEOF" is not used
/usr/share/bison/bison.simple:196:1: warning: macro "YYLLOC_DEFAULT" is not used
../../gcc/cp/parse.c:57:1: warning: macro "REINTERPRET_CAST" is not used
/usr/share/bison/bison.simple:156:1: warning: macro "yyclearin" is not used
../../gcc/cp/mangle.c:235:1: warning: macro "write_signed_number" is not used
../../gcc/cp/mangle.c:219:1: warning: macro "mangled_position" is not used
/usr/share/bison/bison.simple:185:1: warning: macro "YYERRCODE" is not used
/usr/share/bison/bison.simple:155:1: warning: macro "yyerrok" is not used
/usr/share/bison/bison.simple:421:1: warning: macro "YYPOPSTACK" is not used
../../gcc/objc/objc-parse.c:54:1: warning: macro "UNARY" is not used
/usr/share/bison/bison.simple:166:1: warning: macro "YYRECOVERING" is not used
/usr/share/bison/bison.simple:260:1: warning: macro "YYMAXDEPTH" is not used
../../gcc/objc/objc-parse.c:57:1: warning: macro "HYPERUNARY" is not used
/usr/share/bison/bison.simple:165:1: warning: macro "YYFAIL" is not used
/usr/share/bison/bison.simple:167:1: warning: macro "YYBACKUP" is not used
/usr/share/bison/bison.simple:156:1: warning: macro "yyclearin" is not used
/usr/share/bison/bison.simple:196:1: warning: macro "YYLLOC_DEFAULT" is not used
../../gcc/objc/objc-act.c:319:1: warning: macro "UTAG_PROTOCOL_LIST" is not used
../../gcc/objc/objc-act.c:313:1: warning: macro "UTAG_STATICS" is not used
../../gcc/objc/objc-act.c:3432:1: warning: macro "USERTYPE" is not used
../../gcc/collect2.c:53:1: warning: macro "COLLECT" is not used
../../gcc/collect2.c:147:1: warning: macro "SYMBOL__MAIN" is not used
../../gcc/gcc.c:98:1: warning: macro "TARGET_EXECUTABLE_SUFFIX" is not used
../../gcc/cp/g++spec.c:47:1: warning: macro "LIBUNWIND" is not used
cxxmain.c:308:1: warning: macro "PREPEND_BLANK" is not used
I wasn't sure whether the dwarf ones were informative, so I left them.
If they are informative, they should be commented out, otherwise they
should go.
I'll chase up some of the above with new patches.
Neil.