aboutsummaryrefslogtreecommitdiff
path: root/gcc/c
AgeCommit message (Collapse)AuthorFilesLines
2025-01-12c: UX improvements to 'too {few,many} arguments' errors (v5) [PR118112]David Malcolm1-11/+66
Consider this case of a bad call to a callback function (perhaps due to C23 changing the meaning of () in function decls): struct p { int (*bar)(); }; void baz() { struct p q; q.bar(1); } Before this patch the C frontend emits: t.c: In function 'baz': t.c:7:5: error: too many arguments to function 'q.bar' 7 | q.bar(1); | ^ which doesn't give the user much help in terms of knowing what was expected, and where the relevant declaration is. With this patch the C frontend emits: t.c: In function 'baz': t.c:7:5: error: too many arguments to function 'q.bar'; expected 0, have 1 7 | q.bar(1); | ^ ~ t.c:2:15: note: declared here 2 | int (*bar)(); | ^~~ (showing the expected vs actual counts, the pertinent field decl, and underlining the first extraneous argument at the callsite) Similarly, the patch also updates the "too few arguments" case to also show expected vs actual counts. Doing so requires a tweak to the wording to say "at least" for the case of variadic fns where previously the C FE emitted e.g.: s.c: In function 'test': s.c:5:3: error: too few arguments to function 'callee' 5 | callee (); | ^~~~~~ s.c:1:6: note: declared here 1 | void callee (const char *, ...); | ^~~~~~ with this patch it emits: s.c: In function 'test': s.c:5:3: error: too few arguments to function 'callee'; expected at least 1, have 0 5 | callee (); | ^~~~~~ s.c:1:6: note: declared here 1 | void callee (const char *, ...); | ^~~~~~ gcc/c/ChangeLog: PR c/118112 * c-typeck.cc (inform_declaration): Add "function_expr" param and use it for cases where we couldn't show the function decl to show field decls for callbacks. (build_function_call_vec): Add missing auto_diagnostic_group. Update for new param of inform_declaration. (convert_arguments): Likewise. For the "too many arguments" case add the expected vs actual counts to the message, and if we have it, add the location_t of the first surplus param as a secondary location within the diagnostic. For the "too few arguments" case, determine the minimum number of arguments required and add the expected vs actual counts to the message, tweaking it to "at least" for variadic functions. gcc/testsuite/ChangeLog: PR c/118112 * gcc.dg/too-few-arguments.c: New test. * gcc.dg/too-many-arguments.c: New test. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2025-01-11Daily bump.GCC Administrator1-0/+7
2025-01-10c: Fix up expr location for __builtin_stdc_rotate_* [PR118376]Jakub Jelinek1-0/+1
Seems I forgot to set_c_expr_source_range for the __builtin_stdc_rotate_* case (the other __builtin_stdc_* cases already have it), which means the locations in expr are uninitialized, sometimes causing ICEs in linemap code, at other times just valgrind errors about uninitialized var uses. 2025-01-10 Jakub Jelinek <jakub@redhat.com> PR c/118376 * c-parser.cc (c_parser_postfix_expression): Call set_c_expr_source_range before break in the __builtin_stdc_rotate_* case. * gcc.dg/pr118376.c: New test.
2025-01-10Daily bump.GCC Administrator1-0/+12
2025-01-09c: Restore warning for incomplete structures declared in parameter list ↵Martin Uecker1-1/+1
[PR117866] In C23 mode the warning about declaring structures and union in parameter lists was removed, because it is possible to redeclare a compatible type elsewhere. This is not the case for incomplete types, so restore the warning for those types. PR c/117866 gcc/c/ChangeLog: * c-decl.cc (get_parm_info): Change condition for warning. gcc/testsuite/ChangeLog: * gcc.dg/pr117866.c: New test. * gcc.dg/strub-pr118007.c: Adapt.
2025-01-09c, c++: preserve type name in conversion [PR116060]Jason Merrill1-0/+3
When the program requests a conversion to a typedef, let's try harder to remember the new name. Torbjörn's original patch changed the type of the original expression, but that seems not generally desirable; we might want either or both of the original type and the converted-to type to be represented. So this expresses the name change as a NOP_EXPR. Compiling stdc++.h, this adds 519 allocations out of 1870k, or 0.28%. The -Wsuggest-attribute=format change was necessary to do the check before converting to the target type, which seems like an improvement. PR c/116060 gcc/c/ChangeLog: * c-typeck.cc (convert_for_assignment): Make sure left hand side and right hand side has identical named types to aid diagnostic output. gcc/cp/ChangeLog: * call.cc (standard_conversion): Preserve type name in ck_identity. (maybe_adjust_type_name): New. (convert_like_internal): Use it. Handle -Wsuggest-attribute=format here. (convert_for_arg_passing): Not here. gcc/testsuite/ChangeLog: * c-c++-common/analyzer/out-of-bounds-diagram-8.c: Update to correct type. * c-c++-common/analyzer/out-of-bounds-diagram-11.c: Likewise. * gcc.dg/analyzer/out-of-bounds-diagram-10.c: Likewise. Co-authored-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com> Signed-off-by: Torbjörn SVENSSON <torbjorn.svensson@foss.st.com>
2025-01-04Daily bump.GCC Administrator1-0/+13
2025-01-03OpenMP: Robustify C front end handling of attribute-syntax pragmasSandra Loosemore1-14/+32
Presently, the code to handle OpenMP attribute-syntax pragmas in the C front end assumes nothing else is messing with redirecting parser->tokens, and makes no provision for restoring it from anything other than parser->tokens_buf when the buffer allocated for the pragma is exhausted. Adding support for metadirectives will change that, since it also needs to buffer tokens for the metadirective alternatives, and an attribute-syntax directive can appear inside a metadirective. This patch adds a more general save/restore mechanism attached to the parser via a pointer to a new struct omp_attribute_pragma_state. gcc/c/ChangeLog * c-parser.cc (struct c_parser): Change in_omp_attribute_pragma field to be of type struct omp_attribute_pragma_state. (struct omp_attribute_pragma_state): New. (c_parser_skip_until_found): Use the new way to restore state on EOF. (c_parser_skip_to_pragma_eol): Likewise. (c_parser_handle_statement_omp_attributes): Create an omp_attribute_pragma_state to hold the restore state. Do not store state in tok.flags. (omp_maybe_parse_omp_decl): Likewise.
2025-01-03Daily bump.GCC Administrator1-0/+12
2025-01-02c: special-case some "bool" errors with C23 (v2) [PR117629]David Malcolm4-12/+96
Changed in v2: - distinguish between "bool" and "_Bool" when determining standard version This patch attempts to provide better error messages for code compiled with C23 that hasn't been updated for "bool", "true", and "false" becoming keywords. Specifically: (1) with "typedef int bool;" previously we emitted: t1.c:7:13: error: two or more data types in declaration specifiers 7 | typedef int bool; | ^~~~ t1.c:7:1: warning: useless type name in empty declaration 7 | typedef int bool; | ^~~~~~~ whereas with this patch we emit: t1.c:7:13: error: 'bool' cannot be defined via 'typedef' 7 | typedef int bool; | ^~~~ t1.c:7:13: note: 'bool' is a keyword with '-std=c23' onwards t1.c:7:1: warning: useless type name in empty declaration 7 | typedef int bool; | ^~~~~~~ (2) with "int bool;" previously we emitted: t2.c:7:5: error: two or more data types in declaration specifiers 7 | int bool; | ^~~~ t2.c:7:1: warning: useless type name in empty declaration 7 | int bool; | ^~~ whereas with this patch we emit: t2.c:7:5: error: 'bool' cannot be used here 7 | int bool; | ^~~~ t2.c:7:5: note: 'bool' is a keyword with '-std=c23' onwards t2.c:7:1: warning: useless type name in empty declaration 7 | int bool; | ^~~ (3) with "typedef enum { false = 0, true = 1 } _Bool;" previously we emitted: t3.c:7:16: error: expected identifier before 'false' 7 | typedef enum { false = 0, true = 1 } _Bool; | ^~~~~ t3.c:7:38: error: expected ';', identifier or '(' before '_Bool' 7 | typedef enum { false = 0, true = 1 } _Bool; | ^~~~~ t3.c:7:38: warning: useless type name in empty declaration whereas with this patch we emit: t3.c:7:16: error: cannot use keyword 'false' as enumeration constant 7 | typedef enum { false = 0, true = 1 } _Bool; | ^~~~~ t3.c:7:16: note: 'false' is a keyword with '-std=c23' onwards t3.c:7:38: error: expected ';', identifier or '(' before '_Bool' 7 | typedef enum { false = 0, true = 1 } _Bool; | ^~~~~ t3.c:7:38: warning: useless type name in empty declaration gcc/c/ChangeLog: PR c/117629 * c-decl.cc (declspecs_add_type): Special-case attempts to use bool as a typedef name or declaration name. * c-errors.cc (get_std_for_keyword): New. (add_note_about_new_keyword): New. * c-parser.cc (report_bad_enum_name): New, split out from... (c_parser_enum_specifier): ...here, adding handling for RID_FALSE and RID_TRUE. * c-tree.h (add_note_about_new_keyword): New decl. gcc/testsuite/ChangeLog: PR c/117629 * gcc.dg/auto-type-2.c: Update expected output with _Bool. * gcc.dg/c23-bool-errors-1.c: New test. * gcc.dg/c23-bool-errors-2.c: New test. * gcc.dg/c23-bool-errors-3.c: New test. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2025-01-02Update copyright years.Jakub Jelinek19-19/+19
2025-01-02Update Copyright year in ChangeLog filesJakub Jelinek1-1/+1
2024 -> 2025
2024-12-19Daily bump.GCC Administrator1-0/+19
2024-12-18OpenMP: Add declare variant's 'append_args' clause in C/C++Tobias Burnus1-111/+286
Add the append_args clause of 'declare variant' to C and C++, fix/improve diagnostic for 'interop' clause and 'declare_variant' clauses on the way. Cleanup dispatch handling in gimplify_call_expr a bit and partially handle 'append_args'. (Namely, those parts that do not require libraries calls, i.e. a dispatch construct where the 'device' and 'interop' clause has been specified.) The sorry can be removed once an enum value like omp_ipr_(ompx_gnu_)omp_device_num (cf. OpenMP Spec Issue 4451) has to be added to the runtime side such that omp_get_interop_int returns the device number of an interop object (as passed to dispatch via the interop clause); and a call to GOMP_interop has to be added to create interop objects. Once available, only a very localized change in gimplify_call_expr is required to claim for full support. - And Fortran parsing support. gcc/c-family/ChangeLog: * c-omp.cc (c_omp_interop_t_p): Handle error_mark_node. gcc/c/ChangeLog: * c-parser.cc (c_parser_omp_clause_init_modifiers): New; split of from ... (c_parser_omp_clause_init): ... here; call it. (c_finish_omp_declare_variant): Parse 'append_args' clause. (c_parser_omp_clause_interop): Set tree used/read. gcc/cp/ChangeLog: * decl.cc (omp_declare_variant_finalize_one): Handle append_args. * parser.cc (cp_parser_omp_clause_init_modifiers): New; split of from ... (cp_parser_omp_clause_init): ... here; call it. (cp_parser_omp_all_clauses): Replace interop parsing by a call to ... (cp_parser_omp_clause_interop): ... this new function; set tree used/read. (cp_finish_omp_declare_variant): Parse 'append_args' clause. (cp_parser_omp_declare): Update comment. * pt.cc (tsubst_attribute, tsubst_omp_clauses): Handle template substitution also for declare variant's append_args clause, using for 'init' the same code as for interop's init clause. gcc/ChangeLog: * gimplify.cc (gimplify_call_expr): Update for OpenMP's append_args; cleanup of OpenMP's dispatch clause handling. gcc/testsuite/ChangeLog: * c-c++-common/gomp/declare-variant-2.c: Update dg-error msg. * c-c++-common/gomp/dispatch-12.c: Likewise. * c-c++-common/gomp/dispatch-11.c: Likewise and extend a bit. * c-c++-common/gomp/append-args-1.c: New test. * c-c++-common/gomp/append-args-2.c: New test. * c-c++-common/gomp/append-args-3.c: New test. * g++.dg/gomp/append-args-1.C: New test. * g++.dg/gomp/append-args-2.C: New test. * g++.dg/gomp/append-args-3.C: New test.
2024-12-18inline-asm: Add - constraint modifier support for toplevel extended asm ↵Jakub Jelinek1-0/+10
[PR41045] The following patch adds - constraint modifier support (only in toplevel asms), which one can use to allow i, s and n constraint to accept SYMBOL_REFs even with -fpic. So, the recommended way mark toplevel asm as defining some symbol would be ":" constraint (usually with cc modifier in the pattern), while to mark toplevel asm as using some symbol (again, either function or variable), one would use "-s" constraint again with address of that function or variable. 2024-12-18 Jakub Jelinek <jakub@redhat.com> PR c/41045 gcc/ * stmt.cc (parse_output_constraint, parse_input_constraint): Handle - modifier. * recog.h (raw_constraint_p): Declare. * recog.cc (raw_constraint_p): New variable. (asm_operand_ok, constrain_operands): Handle - modifier. * common.md (i, s, n): For raw_constraint_p don't require LEGITIMATE_PIC_OPERAND_P. * doc/md.texi: Document - constraint modifier. gcc/c/ * c-typeck.cc (build_asm_expr): Reject - constraint modifier inside of a function. gcc/cp/ * semantics.cc (finish_asm_stmt): Reject - constraint modifier inside of a function. gcc/testsuite/ * c-c++-common/toplevel-asm-4.c: Add missing %cc2 use in template, add bar, x, &y operands with "-i" and "-s" constraints. (x, y): New variables. (bar): Declare. * c-c++-common/toplevel-asm-7.c: New test. * c-c++-common/toplevel-asm-8.c: New test.
2024-12-18inline asm: Add new constraint for symbol definitionsJakub Jelinek1-0/+14
The following patch on top of the PR41045 toplevel extended asm patch allows marking inline asms (both toplevel and function-local, admittedly it is less useful for the latter, so if you want, I can add restrictions) as defining symbols, either functions or variables. As most remaining constraint letters are used at least on some targets, I'm using : as the new constraint. It is similar to "s" in that it wants CONSTANT_P && !CONST_SCALAR_INT_P, but 1) it specially requires an address of a function or variable declaration, so for functions the expected use is void foo (void); ... ":" (foo) or ":" (&foo) and for variables (unless they are arrays) extern int var; ... ":" (&var) 2) it makes no sense to say that either something is defined or it is used in a register or something similar, so the patch diagnoses if one attempts to mix it with other constraints; ":,:,:" is allowed just because one could be using 3 alternatives in some other operand 3) unlike "s", the constraint doesn't check LEGITIMATE_PIC_OPERAND_P for -fpic, even in -fpic one should be able to use it the same way 4) the cgraph portion needs to be really added later 5) and last but not least, I'm afraid %c0 print modifier isn't very good for printing it; it works fine without -fpic/-fpie, but 'c' modifier is handled as if (CONSTANT_ADDRESS_P (operands[opnum])) output_addr_const (asm_out_file, operands[opnum]); else output_operand (operands[opnum], 'c'); and because at least on some arches like x86 CONSTANT_ADDRESS_P is redefined to do backend specific PIC mess, it will just output_operand and likely just be rejected (on x86 with an error that the argument is not a comparison) Guess for x86 one can use %p0 instead. But I'm afraid we are mostly out of generic modifiers, and targetm.asm_out.print_operand_punct_valid_p seems to use most of the punctuation characters as well. I think ` is unused, but wonder if we want to use up the last remaining letter that way, perhaps make %`<letter>0? Or extend the existing generic modifiers, keep %c0 behave as it does right now and make %cc0 be a 2 letter modifier which is PIC friendly and prints using output_addr_const anything that can be printed that way? A follow-up patch implements the %cc0 version. 2024-12-18 Jakub Jelinek <jakub@redhat.com> gcc/ * genpreds.cc (mangle): Add ':' mangling. (add_constraint): Allow : constraint. * common.md (:): New define_constraint. * stmt.cc (parse_output_constraint): Diagnose "=:". (parse_input_constraint): Handle ":" and diagnose invalid uses. * doc/md.texi (Simple Constraints): Document ":" constraint. gcc/c/ * c-typeck.cc (build_asm_expr): Diagnose invalid ":" constraint uses. gcc/cp/ * semantics.cc (finish_asm_stmt): Diagnose invalid ":" constraint uses. gcc/testsuite/ * c-c++-common/toplevel-asm-4.c: New test. * c-c++-common/toplevel-asm-5.c: New test.
2024-12-13Daily bump.GCC Administrator1-0/+6
2024-12-12OpenMP: Enable has_device_addr clause for 'dispatch' in C/C++Tobias Burnus1-0/+4
The 'has_device_addr' of 'dispatch' has to be seen in conjunction with the 'need_device_addr' modifier to the 'adjust_args' clause of 'declare variant'. As the latter has not yet been implemented, 'has_device_addr' has no real effect. However, to prepare for 'need_device_addr' and as service to the user: For C, where 'need_device_addr' is not permitted (contrary to C++ and Fortran), a note is output when then the user tries to use it (alongside the existing error that either 'nothing' or 'need_device_ptr' was expected). And, on the ME side, is is lightly handled by diagnosing when - for the same argument - there is a mismatch between the variant's adjust_args 'need_device_ptr' modifier and dispatch having an 'has_device_addr' clause (or likewise for need_device_addr with is_device_ptr) as, according to the spec, those are completely separate. Thus, 'dispatch' will still do the host to device pointer conversion for a 'need_device_ptr' argument, even if it appeared in a 'has_device_addr' clause. gcc/c/ChangeLog: * c-parser.cc (OMP_DISPATCH_CLAUSE_MASK): Add has_device_addr clause. (c_finish_omp_declare_variant): Add an 'inform' telling the user that 'need_device_addr' is invalid for C. gcc/cp/ChangeLog: * parser.cc (OMP_DISPATCH_CLAUSE_MASK): Add has_device_addr clause. gcc/ChangeLog: * gimplify.cc (gimplify_call_expr): When handling OpenMP's dispatch, add diagnostic when there is a ptr vs. addr mismatch between need_device_{addr,ptr} and {is,has}_device_{ptr,addr}, respectively. gcc/testsuite/ChangeLog: * c-c++-common/gomp/adjust-args-3.c: New test. * gcc.dg/gomp/adjust-args-2.c: New test.
2024-12-10Daily bump.GCC Administrator1-0/+7
2024-12-09replace atoi with stroul in c_parser_gimple_parse_bb_spec [PR114541]Heiko Eißfeldt1-5/+15
The full treatment of these invalid values was considered out of scope for this patch. PR c/114541 * gimple-parser.cc (c_parser_gimple_parse_bb_spec): Use strtoul with ERANGE check instead of atoi to avoid UB and detect invalid __BB#. Signed-off-by: Heiko Eißfeldt <heiko@hexco.de>
2024-12-07Daily bump.GCC Administrator1-0/+21
2024-12-06diagnostics: UX: add doc URLs for attributes (v2)David Malcolm3-11/+29
This is v2 of the patch; v1 was here: https://gcc.gnu.org/pipermail/gcc-patches/2024-June/655541.html Changed in v2: * added a new TARGET_DOCUMENTATION_NAME hook for figuring out which documentation URL to use when there are multiple per-target docs, such as for __attribute__((interrupt)); implemented this for all targets that have target-specific attributes * moved attribute_urlifier and its support code to a new gcc-attribute-urlifier.cc since it needs to use targetm for the above; gcc-urlifier.o is used by the driver. * fixed extend.texi so that some attributes that failed to appear in attr-urls.def now do so (affected nvptx "kernel" and "shared" attrs) * regenerated attr-urls.def for the above fix, and bringing in attributes added since v1 of the patch In r14-5118-gc5db4d8ba5f3de I added a mechanism to automatically add documentation URLs to quoted strings in diagnostics. In r14-6920-g9e49746da303b8 I added a mechanism to generate URLs for mentions of command-line options in quoted strings in diagnostics. This patch does a similar thing for attributes. It adds a new Python 3 script to scrape the generated HTML looking for documentation of attributes, and uses this to (re)generate a new gcc/attr-urls.def file. Running "make regenerate-attr-urls" after rebuilding the HTML docs will regenerate gcc/attr-urls.def in the source directory. The patch uses this to optionally add doc URLs for attributes in any diagnostic emitted during the lifetime of a auto_urlify_attributes instance, and adds such instances everywhere that a diagnostic refers to a diagnostic within quotes (based on grepping the source tree for references to attributes in strings and in code). For example, given: $ ./xgcc -B. -S ../../src/gcc/testsuite/gcc.dg/attr-access-2.c ../../src/gcc/testsuite/gcc.dg/attr-access-2.c:14:16: warning: attribute ‘access(read_write, 2, 3)’ positional argument 2 conflicts with previous designation by argument 1 [-Wattributes] with this patch the quoted text `access(read_write, 2, 3)' automatically gains the URL for our docs for "access": https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-access-function-attribute in a sufficiently modern terminal. Like r14-6920-g9e49746da303b8 this avoids the Makefile target depending on the generated HTML, since a missing URL is a minor problem, whereas requiring all users to build HTML docs seems more involved. Doing so also avoids Python 3 as a build requirement for everyone, but instead just for developers addding attributes. Like the options, we could add a CI test for this. The patch gathers both general and target-specific attributes. For example, the function attribute "interrupt" has 19 URLs within our docs: one common, and 18 target-specific ones. The patch adds a new target hook used when selecting the most appropriate one. Signed-off-by: David Malcolm <dmalcolm@redhat.com> gcc/ChangeLog: * Makefile.in (OBJS): Add -attribute-urlifier.o. (ATTR_URLS_HTML_DEPS): New. (regenerate-attr-urls): New. (regenerate-attr-urls-unit-test): New. * attr-urls.def: New file. * attribs.cc: Include "gcc-urlifier.h". (decl_attributes): Use auto_urlify_attributes. * config/aarch64/aarch64.cc (TARGET_DOCUMENTATION_NAME): New. * config/arc/arc.cc (TARGET_DOCUMENTATION_NAME): New. * config/arm/arm.cc (TARGET_DOCUMENTATION_NAME): New. * config/bfin/bfin.cc (TARGET_DOCUMENTATION_NAME): New. * config/bpf/bpf.cc (TARGET_DOCUMENTATION_NAME): New. * config/epiphany/epiphany.cc (TARGET_DOCUMENTATION_NAME): New. * config/gcn/gcn.cc (TARGET_DOCUMENTATION_NAME): New. * config/h8300/h8300.cc (TARGET_DOCUMENTATION_NAME): New. * config/i386/i386.cc (TARGET_DOCUMENTATION_NAME): New. * config/ia64/ia64.cc (TARGET_DOCUMENTATION_NAME): New. * config/m32c/m32c.cc (TARGET_DOCUMENTATION_NAME): New. * config/m32r/m32r.cc (TARGET_DOCUMENTATION_NAME): New. * config/m68k/m68k.cc (TARGET_DOCUMENTATION_NAME): New. * config/mcore/mcore.cc (TARGET_DOCUMENTATION_NAME): New. * config/microblaze/microblaze.cc (TARGET_DOCUMENTATION_NAME): New. * config/mips/mips.cc (TARGET_DOCUMENTATION_NAME): New. * config/msp430/msp430.cc (TARGET_DOCUMENTATION_NAME): New. * config/nds32/nds32.cc (TARGET_DOCUMENTATION_NAME): New. * config/nvptx/nvptx.cc (TARGET_DOCUMENTATION_NAME): New. * config/riscv/riscv.cc (TARGET_DOCUMENTATION_NAME): New. * config/rl78/rl78.cc (TARGET_DOCUMENTATION_NAME): New. * config/rs6000/rs6000.cc (TARGET_DOCUMENTATION_NAME): New. * config/rx/rx.cc (TARGET_DOCUMENTATION_NAME): New. * config/s390/s390.cc (TARGET_DOCUMENTATION_NAME): New. * config/sh/sh.cc (TARGET_DOCUMENTATION_NAME): New. * config/stormy16/stormy16.cc (TARGET_DOCUMENTATION_NAME): New. * config/v850/v850.cc (TARGET_DOCUMENTATION_NAME): New. * config/visium/visium.cc (TARGET_DOCUMENTATION_NAME): New. gcc/analyzer/ChangeLog: * region-model.cc: Include "gcc-urlifier.h". (reason_attr_access::emit): Use auto_urlify_attributes. * sm-taint.cc: Include "gcc-urlifier.h". (tainted_access_attrib_size::emit): Use auto_urlify_attributes. gcc/c-family/ChangeLog: * c-attribs.cc: Include "gcc-urlifier.h". (positional_argument): Use auto_urlify_attributes. * c-common.cc: Include "gcc-urlifier.h". (parse_optimize_options): Use auto_urlify_attributes with OPT_Wattributes. (attribute_fallthrough_p): Use auto_urlify_attributes. * c-warn.cc: Include "gcc-urlifier.h". (diagnose_mismatched_attributes): Use auto_urlify_attributes. gcc/c/ChangeLog: * c-decl.cc: Include "gcc-urlifier.h". (start_decl): Use auto_urlify_attributes with OPT_Wattributes. (start_function): Likewise. * c-parser.cc: Include "gcc-urlifier.h". (c_parser_statement_after_labels): Use auto_urlify_attributes with OPT_Wattributes. * c-typeck.cc: Include "gcc-urlifier.h". (maybe_warn_nodiscard): Use auto_urlify_attributes with OPT_Wunused_result. gcc/cp/ChangeLog: * cp-gimplify.cc: Include "gcc-urlifier.h". (process_stmt_hotness_attribute): Use auto_urlify_attributes with OPT_Wattributes. * cvt.cc: Include "gcc-urlifier.h". (maybe_warn_nodiscard): Use auto_urlify_attributes with OPT_Wunused_result. * decl.cc: Include "gcc-urlifier.h". (start_decl): Use auto_urlify_attributes. (start_preparsed_function): Likewise. gcc/ChangeLog: * diagnostic.cc (diagnostic_context::override_urlifier): New. * diagnostic.h (diagnostic_context::override_urlifier): New decl. * doc/extend.texi (Nvidia PTX Function Attributes): Update @cindex to specify that "kernel" is a function attribute and "shared" is a variable attribute, so that these entries are recognized by the regex in regenerate-attr-urls.py. * doc/tm.texi: Regenerate. * doc/tm.texi.in (TARGET_DOCUMENTATION_NAME): New. * gcc-attribute-urlifier.cc: New file. * gcc-urlifier.cc: Include diagnostic.h. (gcc_urlifier::make_doc): Convert to... (make_doc_url): ...this. (auto_override_urlifier::auto_override_urlifier): New. (auto_override_urlifier::~auto_override_urlifier): New. (selftest::gcc_urlifier_cc_tests): Split out body into... (selftest::test_gcc_urlifier): ...this. * gcc-urlifier.h: Include "pretty-print-urlifier.h" and "label-text.h". (make_doc_url): New decl. (class auto_override_urlifier): New. (class attribute_urlifier): New. (class auto_urlify_attributes): New. * gimple-ssa-warn-access.cc: Include "gcc-urlifier.h". (pass_waccess::execute): Use auto_urlify_attributes. * gimplify.cc: Include "gcc-urlifier.h". (expand_FALLTHROUGH): Use auto_urlify_attributes. * internal-fn.cc: Define INCLUDE_MEMORY and include "gcc-urlifier.h. (expand_FALLTHROUGH): Use auto_urlify_attributes. * ipa-pure-const.cc: Include "gcc-urlifier.h. (suggest_attribute): Use auto_urlify_attributes. * ipa-strub.cc: Include "gcc-urlifier.h. (can_strub_p): Use auto_urlify_attributes. * regenerate-attr-urls.py: New file. * selftest-run-tests.cc (selftest::run_tests): Call gcc_attribute_urlifier_cc_tests. * selftest.h (selftest::gcc_attribute_urlifier_cc_tests): New decl. * target.def (documentation_name): New DEFHOOKPOD. * tree-cfg.cc: Include "gcc-urlifier.h. (do_warn_unused_result): Use auto_urlify_attributes. * tree-ssa-uninit.cc: Include "gcc-urlifier.h. (maybe_warn_read_write_only): Use auto_urlify_attributes. (maybe_warn_pass_by_reference): Likewise. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2024-12-06Use new RAW_DATA_{U,S}CHAR_ELT macros in the middle-end and C FEJakub Jelinek2-31/+17
During the patch review of the C++ #embed optimization, Jason asked for a macro for the common ((const unsigned char *) RAW_DATA_POINTER (value))[i] and ditto with signed char patterns which appear in a lot of places. In the just committed patch I've added +#define RAW_DATA_UCHAR_ELT(NODE, I) \ + (((const unsigned char *) RAW_DATA_POINTER (NODE))[I]) +#define RAW_DATA_SCHAR_ELT(NODE, I) \ + (((const signed char *) RAW_DATA_POINTER (NODE))[I]) macros for that in tree.h. The following patch is just a cleanup to use those macros where appropriate. 2024-12-06 Jakub Jelinek <jakub@redhat.com> gcc/ * gimplify.cc (gimplify_init_ctor_eval): Use RAW_DATA_UCHAR_ELT macro. * gimple-fold.cc (fold_array_ctor_reference): Likewise. * tree-pretty-print.cc (dump_generic_node): Use RAW_DATA_UCHAR_ELT and RAW_DATA_SCHAR_ELT macros. * fold-const.cc (fold): Use RAW_DATA_UCHAR_ELT macro. gcc/c/ * c-parser.cc (c_parser_get_builtin_args, c_parser_expression, c_parser_expr_list): Use RAW_DATA_UCHAR_ELT macro. * c-typeck.cc (digest_init): Use RAW_DATA_UCHAR_ELT and RAW_DATA_SCHAR_ELT macros. (add_pending_init, maybe_split_raw_data): Use RAW_DATA_UCHAR_ELT macro.
2024-12-06Daily bump.GCC Administrator1-0/+14
2024-12-05c: Diagnose unexpected va_start arguments in C23 [PR107980]Jakub Jelinek1-0/+95
va_start macro was changed in C23 from the C17 va_start (va_list ap, parmN) where parmN is the identifier of the last parameter into va_start (va_list ap, ...) where arguments after ap aren't evaluated. Late in the C23 development "If any additional arguments expand to include unbalanced parentheses, or a preprocessing token that does not convert to a token, the behavior is undefined." has been added, plus there is "NOTE The macro allows additional arguments to be passed for va_start for compatibility with older versions of the library only." and "Additional arguments beyond the first given to the va_start macro may be expanded and used in unspecified contexts where they are unevaluated. For example, an implementation diagnoses potentially erroneous input for an invocation of va_start such as:" ... va_start(vl, 1, 3.0, "12", xd); // diagnostic encouraged ... "Simultaneously, va_start usage consistent with older revisions of this document should not produce a diagnostic:" ... void neigh (int last_arg, ...) { va_list vl; va_start(vl, last_arg); // no diagnostic The following patch implements the recommended diagnostics. Until now in C23 mode va_start(v, ...) was defined to __builtin_va_start(v, 0) and the extra arguments were silently ignored. The following patch adds a new builtin in a form of a keyword which parses the first argument, is silent about the __builtin_c23_va_start (ap) form, for __builtin_c23_va_start (ap, identifier) looks the identifier up and is silent if it is the last named parameter (except that it diagnoses if it has register keyword), otherwise diagnoses it isn't the last one but something else, and if there is just __builtin_c23_va_start (ap, ) or if __builtin_c23_va_start (ap, is followed by tokens other than identifier followed by ), it skips over the tokens (with handling of balanced ()s) until ) and diagnoses the extra tokens. In all cases in a form of warnings. 2024-12-05 Jakub Jelinek <jakub@redhat.com> PR c/107980 gcc/ * ginclude/stdarg.h (va_start): For C23+ change parameters from v, ... to just ... and define to __builtin_c23_va_start(__VA_ARGS__) rather than __builtin_va_start(v, 0). gcc/c-family/ * c-common.h (enum rid): Add RID_C23_VA_START. * c-common.cc (c_common_reswords): Add __builtin_c23_va_start. gcc/c/ * c-parser.cc (c_parser_postfix_expression): Handle RID_C23_VA_START. gcc/testsuite/ * gcc.dg/c23-stdarg-4.c: Expect extra warning. * gcc.dg/c23-stdarg-6.c: Likewise. * gcc.dg/c23-stdarg-7.c: Likewise. * gcc.dg/c23-stdarg-8.c: Likewise. * gcc.dg/c23-stdarg-10.c: New test. * gcc.dg/c23-stdarg-11.c: New test. * gcc.dg/torture/c23-stdarg-split-1a.c: Expect extra warning. * gcc.dg/torture/c23-stdarg-split-1b.c: Likewise.
2024-12-05Allow limited extended asm at toplevel [PR41045]Jakub Jelinek2-2/+121
In the Cauldron IPA/LTO BoF we've discussed toplevel asms and it was discussed it would be nice to tell the compiler something about what the toplevel asm does. Sure, I'm aware the kernel people said they aren't willing to use something like that, but perhaps other projects do. And for kernel perhaps we should add some new option which allows some dumb parsing of the toplevel asms and gather something from that parsing. The following patch is just a small step towards that, namely, allow some subset of extended inline asm outside of functions. The patch is unfinished, LTO streaming (out/in) of the ASM_EXPRs isn't implemented (it emits a sorry diagnostics), nor any cgraph/varpool changes to find out references etc. The patch allows something like: int a[2], b; enum { E1, E2, E3, E4, E5 }; struct S { int a; char b; long long c; }; asm (".section blah; .quad %P0, %P1, %P2, %P3, %P4; .previous" : : "m" (a), "m" (b), "i" (42), "i" (E4), "i" (sizeof (struct S))); Even for non-LTO, that could be useful e.g. for getting enumerators from C/C++ as integers into the toplevel asm, or sizeof/offsetof etc. The restrictions I've implemented are: 1) asm qualifiers aren't still allowed, so asm goto or asm inline can't be specified at toplevel, asm volatile has the volatile ignored for C++ with a warning and is an error in C like before 2) I see good use for mainly input operands, output maybe to make it clear that the inline asm may write some memory, I don't see a good use for clobbers, so the patch doesn't allow those (and of course labels because asm goto can't be specified) 3) the patch allows only constraints which don't allow registers, so typically "m" or "i" or other memory or immediate constraints; for memory, it requires that the operand is addressable and its address could be used in static var initializer (so that no code actually needs to be emitted for it), for others that they are constants usable in the static var initializers 4) the patch disallows + (there is no reload of the operands, so I don't see benefits of tying some operands together), nor % (who cares if something is commutative in this case), or & (again, no code is emitted around the asm), nor the 0-9 constraints Right now there is no way to tell the compiler that the inline asm defines some symbol, that is implemented in a later patch, as : constraint. Similarly, the c modifier doesn't work in all cases and the cc modifier is implemented separately. 2024-12-05 Jakub Jelinek <jakub@redhat.com> PR c/41045 gcc/ * output.h (insn_noperands): Declare. * final.cc (insn_noperands): No longer static. * varasm.cc (assemble_asm): Handle ASM_EXPR. * lto-streamer-out.cc (lto_output_toplevel_asms): Add sorry_at for non-STRING_CST toplevel asm for now. * doc/extend.texi (Basic @code{asm}, Extended @code{asm}): Document that extended asm is now allowed outside of functions with certain restrictions. gcc/c/ * c-parser.cc (c_parser_asm_string_literal): Add forward declaration. (c_parser_asm_definition): Parse also extended asm without clobbers/labels. * c-typeck.cc (build_asm_expr): Allow extended asm outside of functions and check extra restrictions. gcc/cp/ * cp-tree.h (finish_asm_stmt): Add TOPLEV_P argument. * parser.cc (cp_parser_asm_definition): Parse also extended asm without clobbers/labels outside of functions. * semantics.cc (finish_asm_stmt): Add TOPLEV_P argument, if set, check extra restrictions for extended asm outside of functions. * pt.cc (tsubst_stmt): Adjust finish_asm_stmt caller. gcc/testsuite/ * c-c++-common/toplevel-asm-1.c: New test. * c-c++-common/toplevel-asm-2.c: New test. * c-c++-common/toplevel-asm-3.c: New test.
2024-12-04Daily bump.GCC Administrator1-0/+5
2024-12-03OpenMP: 'allocate' directive - fixes for 'alignof' and [[omp::decl]]Tobias Burnus1-4/+1
Fixed a check to permit [[omp::decl(allocate,...)]] parsing in C. Additionaly, we discussed that 'allocate align' should not affect 'alignof' to avoid issues like with: int a; _Alignas(_Alignof(a)) int b; #pragma omp allocate(a) align(128) _Alignas(_Alignof(a)) int c; Thus, the alignment is no longer set in the C and Fortran front ends, but for static variables now in varpool_node::finalize_decl. (For stack variables, the alignment is handled in gimplify_bind_expr.) NOTE: 'omp allocate' is not yet supported in C++. gcc/c/ChangeLog: * c-parser.cc (c_parser_omp_allocate): Only check scope if not in_omp_decl_attribute. Remove setting the alignment. gcc/ChangeLog: * cgraphunit.cc (varpool_node::finalize_decl): Set alignment based on OpenMP's 'omp allocate' attribute/directive. gcc/fortran/ChangeLog: * trans-decl.cc (gfc_finish_var_decl): Remove setting the alignment. libgomp/ChangeLog: * libgomp.texi (Memory allocation): Mention (non-)effect of 'align' on _Alignof. * testsuite/libgomp.c/allocate-7.c: New test. gcc/testsuite/ChangeLog: * c-c++-common/gomp/allocate-18.c: Check that alignof is unaffected by 'omp allocate'. * c-c++-common/gomp/allocate-19.c: Likewise.
2024-12-01Daily bump.GCC Administrator1-0/+11
2024-11-30c: Set attributes for fields when forming a composite type [PR117806]Martin Uecker1-0/+2
We need to call decl_attributes when creating the fields for a composite type. PR c/117806 gcc/c/ChangeLog: * c-typeck.cc (composite_type_internal): Call decl_attributes. gcc/testsuite/ChangeLog: * gcc.dg/pr117806.c: New test.
2024-11-29gimplefe: Error recovery for invalid declarations [PR117749]Andrew Pinski1-6/+6
c_parser_declarator can return null if there was an error, but c_parser_gimple_declaration was not ready for that. This fixes that oversight so we don't get an ICE after the error. Bootstrapped and tested on x86_64-linux-gnu. PR c/117749 gcc/c/ChangeLog: * gimple-parser.cc (c_parser_gimple_declaration): Check declarator to be non-null. gcc/testsuite/ChangeLog: * gcc.dg/gimplefe-55.c: New test. Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>
2024-11-30Daily bump.GCC Administrator1-0/+10
2024-11-29c: Correct type compatibility for bit-fields [PR117828]Martin Uecker1-1/+16
Add missing test for consistency of bit-fields when comparing tagged types for compatibility. PR c/117828 gcc/c/ChangeLog: * c-typeck.cc (tagged_types_tu_compatible_p): Add check. gcc/testsuite/ChangeLog: * gcc.dg/c23-tag-bitfields-1.c: New test. * gcc.dg/pr117828.c: New test.
2024-11-29c: Fix constructor bounds checking for VLA and construct VLA vector constantsTejas Belagod1-5/+11
This patch adds support for checking bounds of SVE ACLE vector initialization constructors. It also adds support to construct vector constant from init constructors. gcc/c/ChangeLog: * c-typeck.cc (process_init_element): Add check to restrict constructor length to the minimum vector length allowed. gcc/ChangeLog: * tree.cc (build_vector_from_ctor): Add support to construct VLA vector constants from init constructors. gcc/testsuite/ChangeLog: * gcc.target/aarch64/sve/acle/general-c/sizeless-1.c: Update test to test initialize error. * gcc.target/aarch64/sve/acle/general-c/sizeless-2.c: Likewise.
2024-11-29Daily bump.GCC Administrator1-0/+29
2024-11-28expr, c: Don't clear whole unions [PR116416]Jakub Jelinek2-0/+21
As discussed earlier, we currently clear padding bits even when we don't have to and that causes pessimization of emitted code, e.g. for union U { int a; long b[64]; }; void bar (union U *); void foo (void) { union U u = { 0 }; bar (&u); } we need to clear just u.a, not the whole union, but on the other side in cases where the standard requires padding bits to be zeroed, like for C23 {} initializers of aggregates with padding bits, or for C++11 zero initialization we don't do that. This patch a) moves some of the stuff into complete_ctor_at_level_p (but not all the *p_complete = 0; case, for that it would need to change so that it passes around the ctor rather than just its type) and changes the handling of unions b) introduces a new option, so that users can either get the new behavior (only what is guaranteed by the standards, the default), or previous behavior (union padding zero initialization, no such guarantees in structures) or also a guarantee in structures c) introduces a new CONSTRUCTOR flag which says that the padding bits (if any) should be zero initialized (and sets it for now in the C FE for C23 {} initializers). Am not sure the CONSTRUCTOR_ZERO_PADDING_BITS flag is really needed for C23, if there is just empty initializer, I think we already mark it as incomplete if there are any missing initializers. Maybe with some designated initializer games, say void foo () { struct S { char a; long long b; }; struct T { struct S c; } t = { .c = {}, .c.a = 1, .c.b = 2 }; ... } Is this supposed to initialize padding bits in C23 and then the .c.a = 1 and .c.b = 2 stores preserve those padding bits, so is that supposed to be different from struct T t2 = { .c = { 1, 2 } }; ? What about just struct T t3 = { .c.a = 1, .c.b = 2 }; ? And I haven't touched the C++ FE for the flag, because I'm afraid I'm lost on where exactly is zero-initialization done (vs. other types of initialization) and where is e.g. zero-initialization of a temporary then (member-wise) copied. Say struct S { char a; long long b; }; struct T { constexpr T (int a, int b) : c () { c.a = a; c.b = b; } S c; }; void bar (T *); void foo () { T t (1, 2); bar (&t); } Is the c () value-initialization of t.c followed by c.a and c.b updates which preserve the zero initialized padding bits? Or is there some copy construction involved which does member-wise copying and makes the padding bits undefined? Looking at (older) clang++ with -O2, it initializes also the padding bits when c () is used and doesn't with c {}. For GCC, note that there is that optimization from Alex to zero padding bits for optimization purposes for small aggregates, so either one needs to look at -O0 -fdump-tree-gimple dumps, or use larger structures which aren't optimized that way. 2024-11-28 Jakub Jelinek <jakub@redhat.com> PR c++/116416 gcc/ * flag-types.h (enum zero_init_padding_bits_kind): New type. * tree.h (CONSTRUCTOR_ZERO_PADDING_BITS): Define. * common.opt (fzero-init-padding-bits=): New option. * expr.cc (categorize_ctor_elements_1): Handle CONSTRUCTOR_ZERO_PADDING_BITS or flag_zero_init_padding_bits == ZERO_INIT_PADDING_BITS_ALL. Fix up *p_complete = -1; setting for unions. (complete_ctor_at_level_p): Handle unions differently for flag_zero_init_padding_bits == ZERO_INIT_PADDING_BITS_STANDARD. * gimple-fold.cc (type_has_padding_at_level_p): Fix up UNION_TYPE handling, return also true for UNION_TYPE with no FIELD_DECLs and non-zero size, handle QUAL_UNION_TYPE like UNION_TYPE. * doc/invoke.texi (-fzero-init-padding-bits=@var{value}): Document. gcc/c/ * c-parser.cc (c_parser_braced_init): Set CONSTRUCTOR_ZERO_PADDING_BITS for flag_isoc23 empty initializers. * c-typeck.cc (constructor_zero_padding_bits): New variable. (struct constructor_stack): Add zero_padding_bits member. (really_start_incremental_init): Save and clear constructor_zero_padding_bits. (push_init_level): Save constructor_zero_padding_bits. Or into it CONSTRUCTOR_ZERO_PADDING_BITS from previous value if implicit. (pop_init_level): Set CONSTRUCTOR_ZERO_PADDING_BITS if constructor_zero_padding_bits and restore constructor_zero_padding_bits. gcc/testsuite/ * gcc.dg/plugin/infoleak-1.c (test_union_2b, test_union_4b): Expect diagnostics. * gcc.dg/c23-empty-init-5.c: New test. * gcc.dg/gnu11-empty-init-1.c: New test. * gcc.dg/gnu11-empty-init-2.c: New test. * gcc.dg/gnu11-empty-init-3.c: New test. * gcc.dg/gnu11-empty-init-4.c: New test.
2024-11-27c-family: offer suggestions for missing command-line options [PR82892]David Malcolm1-0/+11
Some builtin macros are only defined when certain command-line options are provided. Update the error messages for them so that we suggest the pertinent option ('-fopenacc' for '_OPENACC', and '-fopenmp' for '_OPENMP') gcc/c-family/ChangeLog: PR c/82892 * c-common.h (get_option_for_builtin_define): New decl. * c-cppbuiltin.cc (get_option_for_builtin_define): New. * known-headers.cc: Include "opts.h". (suggest_missing_option::suggest_missing_option): New. (suggest_missing_option::~suggest_missing_option): New. * known-headers.h (class suggest_missing_option): New. gcc/c/ChangeLog: PR c/82892 * c-decl.cc (lookup_name_fuzzy): Provide hints for missing command-line options. gcc/cp/ChangeLog: PR c/82892 * name-lookup.cc (suggest_alternatives_for_1): Provide hints for missing command-line options. gcc/testsuite/ChangeLog: PR c/82892 * c-c++-common/spellcheck-missing-option.c: New test. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2024-11-27C/C++: add fix-it hints for missing '&' and '*' (v5) [PR87850]David Malcolm1-2/+16
This patch adds a note with a fix-it hint to various pointer-vs-non-pointer diagnostics, suggesting the addition of a leading '&' or '*'. For example, note the ampersand fix-it hint in the following: demo.c: In function 'int main()': demo.c:5:22: error: invalid conversion from 'pthread_key_t' {aka 'unsigned int'} to 'pthread_key_t*' {aka 'unsigned int*'} [-fpermissive] 5 | pthread_key_create(key, NULL); | ^~~ | | | pthread_key_t {aka unsigned int} demo.c:5:22: note: possible fix: take the address with '&' 5 | pthread_key_create(key, NULL); | ^~~ | & In file included from demo.c:1: /usr/include/pthread.h:1122:47: note: initializing argument 1 of 'int pthread_key_create(pthread_key_t*, void (*)(void*))' 1122 | extern int pthread_key_create (pthread_key_t *__key, | ~~~~~~~~~~~~~~~^~~~~ gcc/c-family/ChangeLog: PR c++/87850 * c-common.cc: Include "gcc-rich-location.h". (maybe_emit_indirection_note): New function. * c-common.h (maybe_emit_indirection_note): New decl. (compatible_types_for_indirection_note_p): New decl. gcc/c/ChangeLog: PR c++/87850 * c-typeck.cc (compatible_types_for_indirection_note_p): New function. (convert_for_assignment): Call maybe_emit_indirection_note for pointer vs non-pointer diagnostics. gcc/cp/ChangeLog: PR c++/87850 * call.cc (convert_like_real): Call maybe_emit_indirection_note for "invalid conversion" diagnostic. * typeck.cc (compatible_types_for_indirection_note_p): New function. gcc/testsuite/ChangeLog: PR c++/87850 * c-c++-common/indirection-fixits.c: New test. * g++.dg/template/error60.C: Add fix-it hint to expected output. * g++.dg/template/error60a.C: Likewise. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2024-11-28Daily bump.GCC Administrator1-0/+28
2024-11-27c: Fix ICE using function name in parameter type in old-style function ↵Joseph Myers1-37/+38
definition [PR91193] As reported in bug 91193, if an old-style function definition redeclares a typedef name as a function, then uses that function name at the start of the first old-style parameter definition, then the parser interprets that token as a typedef name (because lookahead occurred before processing of the function declarator completed), but when it is looked up in processing that parameter definition, what is found is the redefinition, resulting in an ICE. The function name's scope starts at the end of its declarator, so this is similar to other cases where we call c_parser_maybe_reclassify_token because lookahead might have classified a token as being a typedef or not based on information from the wrong scope; do so in this case as well, so resulting in the expected parse errors from using something that's no longer a typedef name as if it were a typedef name, and eliminating the ICE. Bootstrapped with no regressions for x86_64-pc-linux-gnu. PR c/91193 gcc/c/ * c-parser.cc (c_parser_maybe_reclassify_token): Define earlier. (c_parser_declaration_or_fndef): Call c_parser_maybe_reclassify_token before parsing old-style parameter definitions. gcc/testsuite/ * gcc.dg/pr91193-1.c, gcc.dg/pr91193-2.c: New tests.
2024-11-27c: Fix sizeof error recovery [PR117745]Jakub Jelinek1-7/+5
Compilation of the following testcase hangs forever after emitting first error. The problem is that in one place we just return error_mark_node directly rather than going through c_expr_sizeof_expr or c_expr_sizeof_type. The parsing of the expression could have called record_maybe_used_decl though, but nothing calls pop_maybe_used which needs to be called after parsing of every sizeof/typeof, successful or not. At the end of the toplevel declaration we free the parser_obstack and in another function record_maybe_used_decl is called again and due to the missing pop_maybe_unused we end up with a cycle in the chain. The following patch fixes it by just setting error and goto to the sizeof_expr: c_inhibit_evaluation_warnings--; in_sizeof--; mark_exp_read (expr.value); if (TREE_CODE (expr.value) == COMPONENT_REF && DECL_C_BIT_FIELD (TREE_OPERAND (expr.value, 1))) error_at (expr_loc, "%<sizeof%> applied to a bit-field"); result = c_expr_sizeof_expr (expr_loc, expr); where c_expr_sizeof_expr will do: struct c_expr ret; if (expr.value == error_mark_node) { ret.value = error_mark_node; ret.original_code = ERROR_MARK; ret.original_type = NULL; ret.m_decimal = 0; pop_maybe_used (false); } ... return ret; which is exactly what the old code did manually except for the missing pop_maybe_used call. mark_exp_read does nothing on error_mark_node and error_mark_node doesn't have COMPONENT_REF tree_code. 2024-11-27 Jakub Jelinek <jakub@redhat.com> PR c/117745 * c-parser.cc (c_parser_sizeof_expression): If type_name is NULL, just expr.set_error () and goto sizeof_expr instead of doing error recovery manually. * gcc.dg/pr117745.c: New test.
2024-11-27c: Do not remove _Atomic from array element type for typeof_unqual [PR117781]Joseph Myers1-3/+13
As reported in bug 117781, my fix for bug 112841 broke the case of typeof_unqual applied to an array of _Atomic elements, which should not have _Atomic removed since only the element type is atomic, not the array type. Fix with logic to ensure that atomic element types are preserved as such, while other qualifiers (i.e. those that are semantically rather than only syntactically such in C) are removed. Bootstrapped with no regressions for x86_64-pc-linux-gnu. PR c/117781 gcc/c/ * c-parser.cc (c_parser_typeof_specifier): Do not remove _Atomic from array element type for typeof_unqual. gcc/testsuite/ * gcc.dg/c23-typeof-5.c: New test.
2024-11-27c: Introduce -Wfree-labelsFlorian Weimer1-2/+3
This is another recent GCC extension whose use is apparently difficult to spot in code reviews. The name of the option is due to Jonathan Wakely. Part of it could apply to C++ as well (for labels at the end of a compound statement). gcc/c-family/ * c-opts.cc (c_common_post_options): Initialize warn_free_labels. * c.opt (Wfree-labels): New option. * c.opt.urls: Regenerate. gcc/c/ * c-parser.cc (c_parser_compound_statement_nostart): Use OPT_Wfree_labels for warning about labels on declarations. (c_parser_compound_statement_nostart): Use OPT_Wfree_labels for warning about labels at end of compound statements. gcc/ * doc/invoke.texi: Document -Wfree-labels. gcc/testsuite/ * gcc.dg/Wfree-labels-1.c: New test. * gcc.dg/Wfree-labels-2.c: New test. * gcc.dg/Wfree-labels-3.c: New test.
2024-11-27Daily bump.GCC Administrator1-0/+14
2024-11-26c: avoid double-negative in warning message [PR94370]David Malcolm1-2/+2
gcc/c/ChangeLog: PR c/94370 * c-typeck.cc (c_build_functype_attribute_variant): Reword warning message to avoid double-negative. gcc/testsuite/ChangeLog: PR c/94370 * gcc.dg/format/proto.c: Update wording of message. Signed-off-by: David Malcolm <dmalcolm@redhat.com>
2024-11-26c: Fix ICEs from invalid atomic compound assignment [PR98195, PR117755]Joseph Myers1-7/+11
As reported in bug 98195, there are ICEs from an _Atomic compound assignment with an incomplete type on the RHS, arising from an invalid temporary being created with such a type. As reported in bug 117755, there are also (different) ICEs in cases with complete types where the binary operation itself is invalid, when inside a nested function, arising from a temporary being created for the RHS, but then not used because the binary operation returns error_mark_node, resulting in the temporary not appearing in a TARGET_EXPR, never getting its DECL_CONTEXT set by the gimplifier and eventually resulting in an ICE in nested function processing (trying to find a function context for the temporary) as a result. Fix the first ICE with an earlier check for a complete type for the RHS of an assignment so the problematic temporary is never created for an incomplete type (which changes the error message three existing tests get for that case; the new message seems as good as the old one). Fix the second ICE by ensuring that once a temporary has been created, it always gets a corresponding TARGET_EXPR even on error. Bootstrapped with no regressions for x86_64-pc-linux-gnu. PR c/98195 PR c/117755 gcc/c/ * c-typeck.cc (build_atomic_assign): Always create a TARGET_EXPR for newval even in case of error from binary operation. (build_modify_expr): Check early for incomplete type of rhs. gcc/testsuite/ * gcc.dg/pr98195-1.c, gcc.dg/pr117755-1.c: New tests. * gcc.dg/noncompile/20020207-1.c, gcc.dg/pr14765-1.c, objc.dg/method-11.m: Update expected error messages.
2024-11-25Daily bump.GCC Administrator1-0/+6
2024-11-24gimplefe: Fix handling of ')'/'}' after a parse error [PR117741]Andrew Pinski1-0/+10
The problem here is c_parser_skip_until_found stops at a closing nesting delimiter without consuming it. So if we don't consume it in c_parser_gimple_compound_statement, we would go into an infinite loop. The C parser similar code in c_parser_statement_after_labels to handle this specific case too. PR c/117741 gcc/c/ChangeLog: * gimple-parser.cc (c_parser_gimple_compound_statement): Handle CPP_CLOSE_PAREN/CPP_CLOSE_SQUARE with an error and skipping the token. gcc/testsuite/ChangeLog: * gcc.dg/gimplefe-54.c: New test. Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>
2024-11-23Daily bump.GCC Administrator1-0/+40
2024-11-22build: Remove INCLUDE_MEMORY [PR117737]Andrew Pinski10-10/+0
Since diagnostic.h is included in over half of the sources, requiring to `#define INCLUDE_MEMORY` does not make sense. Instead lets unconditionally include memory in system.h. The majority of this patch is just removing `#define INCLUDE_MEMORY` from the sources which currently have it. This should also fix the mingw build issue but I have not tried it. Bootstrapped and tested on x86_64-linux-gnu. PR bootstrap/117737 gcc/ada/ChangeLog: * gcc-interface/misc.cc (INCLUDE_MEMORY): Remove. * gcc-interface/trans.cc (INCLUDE_MEMORY): Remove. * gcc-interface/utils.cc (INCLUDE_MEMORY): Remove. gcc/analyzer/ChangeLog: * access-diagram.cc (INCLUDE_MEMORY): Remove. * analysis-plan.cc (INCLUDE_MEMORY): Remove. * analyzer-language.cc (INCLUDE_MEMORY): Remove. * analyzer-logging.cc (INCLUDE_MEMORY): Remove. * analyzer-pass.cc (INCLUDE_MEMORY): Remove. * analyzer-selftests.cc (INCLUDE_MEMORY): Remove. * analyzer.cc (INCLUDE_MEMORY): Remove. * bar-chart.cc (INCLUDE_MEMORY): Remove. * bounds-checking.cc (INCLUDE_MEMORY): Remove. * call-details.cc (INCLUDE_MEMORY): Remove. * call-info.cc (INCLUDE_MEMORY): Remove. * call-string.cc (INCLUDE_MEMORY): Remove. * call-summary.cc (INCLUDE_MEMORY): Remove. * checker-event.cc (INCLUDE_MEMORY): Remove. * checker-path.cc (INCLUDE_MEMORY): Remove. * complexity.cc (INCLUDE_MEMORY): Remove. * constraint-manager.cc (INCLUDE_MEMORY): Remove. * diagnostic-manager.cc (INCLUDE_MEMORY): Remove. * engine.cc (INCLUDE_MEMORY): Remove. * feasible-graph.cc (INCLUDE_MEMORY): Remove. * infinite-loop.cc (INCLUDE_MEMORY): Remove. * infinite-recursion.cc (INCLUDE_MEMORY): Remove. * kf-analyzer.cc (INCLUDE_MEMORY): Remove. * kf-lang-cp.cc (INCLUDE_MEMORY): Remove. * kf.cc (INCLUDE_MEMORY): Remove. * known-function-manager.cc (INCLUDE_MEMORY): Remove. * pending-diagnostic.cc (INCLUDE_MEMORY): Remove. * program-point.cc (INCLUDE_MEMORY): Remove. * program-state.cc (INCLUDE_MEMORY): Remove. * ranges.cc (INCLUDE_MEMORY): Remove. * record-layout.cc (INCLUDE_MEMORY): Remove. * region-model-asm.cc (INCLUDE_MEMORY): Remove. * region-model-manager.cc (INCLUDE_MEMORY): Remove. * region-model-reachability.cc (INCLUDE_MEMORY): Remove. * region-model.cc (INCLUDE_MEMORY): Remove. * region.cc (INCLUDE_MEMORY): Remove. * sm-fd.cc (INCLUDE_MEMORY): Remove. * sm-file.cc (INCLUDE_MEMORY): Remove. * sm-malloc.cc (INCLUDE_MEMORY): Remove. * sm-pattern-test.cc (INCLUDE_MEMORY): Remove. * sm-sensitive.cc (INCLUDE_MEMORY): Remove. * sm-signal.cc (INCLUDE_MEMORY): Remove. * sm-taint.cc (INCLUDE_MEMORY): Remove. * sm.cc (INCLUDE_MEMORY): Remove. * state-purge.cc (INCLUDE_MEMORY): Remove. * store.cc (INCLUDE_MEMORY): Remove. * supergraph.cc (INCLUDE_MEMORY): Remove. * svalue.cc (INCLUDE_MEMORY): Remove. * symbol.cc (INCLUDE_MEMORY): Remove. * trimmed-graph.cc (INCLUDE_MEMORY): Remove. * varargs.cc (INCLUDE_MEMORY): Remove. gcc/ChangeLog: * asan.cc (INCLUDE_MEMORY): Remove. * attribs.cc (INCLUDE_MEMORY): Remove. * auto-profile.cc (INCLUDE_MEMORY): Remove. * calls.cc (INCLUDE_MEMORY): Remove. * cfganal.cc (INCLUDE_MEMORY): Remove. * cfgexpand.cc (INCLUDE_MEMORY): Remove. * cfghooks.cc (INCLUDE_MEMORY): Remove. * cfgloop.cc (INCLUDE_MEMORY): Remove. * cgraph.cc (INCLUDE_MEMORY): Remove. * cgraphclones.cc (INCLUDE_MEMORY): Remove. * cgraphunit.cc (INCLUDE_MEMORY): Remove. * collect-utils.cc (INCLUDE_MEMORY): Remove. * collect2.cc (INCLUDE_MEMORY): Remove. * common/config/aarch64/aarch64-common.cc (INCLUDE_MEMORY): Remove. * common/config/arm/arm-common.cc (INCLUDE_MEMORY): Remove. * common/config/avr/avr-common.cc (INCLUDE_MEMORY): Remove. * config/aarch64/aarch64-cc-fusion.cc (INCLUDE_MEMORY): Remove. * config/aarch64/aarch64-early-ra.cc (INCLUDE_MEMORY): Remove. * config/aarch64/aarch64-sve-builtins.cc (INCLUDE_MEMORY): Remove. * config/aarch64/aarch64.cc (INCLUDE_MEMORY): Remove. * config/arc/arc.cc (INCLUDE_MEMORY): Remove. * config/arm/aarch-common.cc (INCLUDE_MEMORY) Remove.: * config/arm/arm-mve-builtins.cc (INCLUDE_MEMORY): Remove. * config/arm/arm.cc (INCLUDE_MEMORY): Remove. * config/avr/avr-devices.cc (INCLUDE_MEMORY): Remove. * config/avr/driver-avr.cc (INCLUDE_MEMORY): Remove. * config/bpf/bpf.cc (INCLUDE_MEMORY): Remove. * config/bpf/btfext-out.cc (INCLUDE_MEMORY): Remove. * config/bpf/core-builtins.cc (INCLUDE_MEMORY): Remove. * config/darwin.cc (INCLUDE_MEMORY): Remove. * config/gcn/mkoffload.cc (INCLUDE_MEMORY): Remove. * config/i386/driver-i386.cc (INCLUDE_MEMORY): Remove. * config/i386/i386-builtins.cc (INCLUDE_MEMORY): Remove. * config/i386/i386-expand.cc (INCLUDE_MEMORY): Remove. * config/i386/i386-features.cc (INCLUDE_MEMORY): Remove. * config/i386/i386-options.cc (INCLUDE_MEMORY): Remove. * config/i386/i386.cc (INCLUDE_MEMORY): Remove. * config/loongarch/loongarch-builtins.cc (INCLUDE_MEMORY): Remove. * config/loongarch/loongarch.cc (INCLUDE_MEMORY): Remove. * config/mingw/winnt-cxx.cc (INCLUDE_MEMORY): Remove. * config/mingw/winnt.cc (INCLUDE_MEMORY): Remove. * config/mips/mips.cc (INCLUDE_MEMORY): Remove. * config/msp430/driver-msp430.cc (INCLUDE_MEMORY): Remove. * config/nvptx/mkoffload.cc (INCLUDE_MEMORY): Remove. * config/nvptx/nvptx.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv-avlprop.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv-target-attr.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv-vector-builtins.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv-vector-costs.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv-vsetvl.cc (INCLUDE_MEMORY): Remove. * config/riscv/riscv.cc (INCLUDE_MEMORY): Remove. * config/rs6000/driver-rs6000.cc (INCLUDE_MEMORY): Remove. * config/rs6000/host-darwin.cc (INCLUDE_MEMORY): Remove. * config/rs6000/rs6000-c.cc (INCLUDE_MEMORY): Remove. * config/rs6000/rs6000.cc (INCLUDE_MEMORY): Remove. * config/s390/s390-c.cc (INCLUDE_MEMORY): Remove. * config/s390/s390.cc (INCLUDE_MEMORY): Remove. * config/sol2-cxx.cc (INCLUDE_MEMORY): Remove. * config/vms/vms-c.cc (INCLUDE_MEMORY): Remove. * config/xtensa/xtensa-dynconfig.cc (INCLUDE_MEMORY): Remove. * coroutine-passes.cc (INCLUDE_MEMORY): Remove. * coverage.cc (INCLUDE_MEMORY): Remove. * data-streamer-in.cc (INCLUDE_MEMORY): Remove. * data-streamer-out.cc (INCLUDE_MEMORY): Remove. * data-streamer.cc (INCLUDE_MEMORY): Remove. * diagnostic-format-json.cc (INCLUDE_MEMORY): Remove. * diagnostic-format-sarif.cc (INCLUDE_MEMORY): Remove. * diagnostic-format-text.cc (INCLUDE_MEMORY): Remove. * diagnostic-global-context.cc (INCLUDE_MEMORY): Remove. * diagnostic-macro-unwinding.cc (INCLUDE_MEMORY): Remove. * diagnostic-path.cc (INCLUDE_MEMORY): Remove. * diagnostic-show-locus.cc (INCLUDE_MEMORY): Remove. * diagnostic-spec.cc (INCLUDE_MEMORY): Remove. * diagnostic.cc (INCLUDE_MEMORY): Remove. * diagnostic.h: Remove check for INCLUDE_MEMORY. * digraph.cc (INCLUDE_MEMORY): Remove. * dumpfile.cc (INCLUDE_MEMORY): Remove. * dwarf2out.cc (INCLUDE_MEMORY): Remove. * edit-context.cc (INCLUDE_MEMORY): Remove. * except.cc (INCLUDE_MEMORY): Remove. * expr.cc (INCLUDE_MEMORY): Remove. * file-prefix-map.cc (INCLUDE_MEMORY): Remove. * final.cc (INCLUDE_MEMORY): Remove. * fwprop.cc (INCLUDE_MEMORY): Remove. * gcc-plugin.h (INCLUDE_MEMORY): Remove. * gcc-rich-location.cc (INCLUDE_MEMORY): Remove. * gcc-urlifier.cc (INCLUDE_MEMORY): Remove. * gcc.cc (INCLUDE_MEMORY): Remove. * gcov-dump.cc (INCLUDE_MEMORY): Remove. * gcov-tool.cc (INCLUDE_MEMORY): Remove. * gcov.cc (INCLUDE_MEMORY): Remove. * gengtype.cc (open_base_files): Don't print `#define INCLUDE_MEMORY`. * genmatch.cc (INCLUDE_MEMORY): Remove. * gimple-fold.cc (INCLUDE_MEMORY): Remove. * gimple-harden-conditionals.cc (INCLUDE_MEMORY): Remove. * gimple-harden-control-flow.cc (INCLUDE_MEMORY): Remove. * gimple-if-to-switch.cc (INCLUDE_MEMORY): Remove. * gimple-loop-interchange.cc (INCLUDE_MEMORY): Remove. * gimple-loop-jam.cc (INCLUDE_MEMORY): Remove. * gimple-loop-versioning.cc (INCLUDE_MEMORY): Remove. * gimple-lower-bitint.cc (INCLUDE_MEMORY): Remove. * gimple-predicate-analysis.cc (INCLUDE_MEMORY): Remove. * gimple-pretty-print.cc (INCLUDE_MEMORY): Remove. * gimple-range-cache.cc (INCLUDE_MEMORY): Remove. * gimple-range-edge.cc (INCLUDE_MEMORY): Remove. * gimple-range-fold.cc (INCLUDE_MEMORY): Remove. * gimple-range-gori.cc (INCLUDE_MEMORY): Remove. * gimple-range-infer.cc (INCLUDE_MEMORY): Remove. * gimple-range-op.cc (INCLUDE_MEMORY): Remove. * gimple-range-path.cc (INCLUDE_MEMORY): Remove. * gimple-range-phi.cc (INCLUDE_MEMORY): Remove. * gimple-range-trace.cc (INCLUDE_MEMORY): Remove. * gimple-range.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-backprop.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-sprintf.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-store-merging.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-strength-reduction.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-warn-access.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-warn-alloca.cc (INCLUDE_MEMORY): Remove. * gimple-ssa-warn-restrict.cc (INCLUDE_MEMORY): Remove. * gimple-streamer-in.cc (INCLUDE_MEMORY): Remove. * gimple-streamer-out.cc (INCLUDE_MEMORY): Remove. * gimple.cc (INCLUDE_MEMORY): Remove. * gimplify.cc (INCLUDE_MEMORY): Remove. * graph.cc (INCLUDE_MEMORY): Remove. * graphite-dependences.cc (INCLUDE_MEMORY): Remove. * graphite-isl-ast-to-gimple.cc (INCLUDE_MEMORY): Remove. * graphite-optimize-isl.cc (INCLUDE_MEMORY): Remove. * graphite-poly.cc (INCLUDE_MEMORY): Remove. * graphite-scop-detection.cc (INCLUDE_MEMORY): Remove. * graphite-sese-to-poly.cc (INCLUDE_MEMORY): Remove. * graphite.cc (INCLUDE_MEMORY): Remove. * graphviz.cc (INCLUDE_MEMORY): Remove. * input.cc (INCLUDE_MEMORY): Remove. * ipa-cp.cc (INCLUDE_MEMORY): Remove. * ipa-devirt.cc (INCLUDE_MEMORY): Remove. * ipa-fnsummary.cc (INCLUDE_MEMORY): Remove. * ipa-free-lang-data.cc (INCLUDE_MEMORY): Remove. * ipa-icf-gimple.cc (INCLUDE_MEMORY): Remove. * ipa-icf.cc (INCLUDE_MEMORY): Remove. * ipa-inline-analysis.cc (INCLUDE_MEMORY): Remove. * ipa-inline.cc (INCLUDE_MEMORY): Remove. * ipa-modref-tree.cc (INCLUDE_MEMORY): Remove. * ipa-modref.cc (INCLUDE_MEMORY): Remove. * ipa-param-manipulation.cc (INCLUDE_MEMORY): Remove. * ipa-polymorphic-call.cc (INCLUDE_MEMORY): Remove. * ipa-predicate.cc (INCLUDE_MEMORY): Remove. * ipa-profile.cc (INCLUDE_MEMORY): Remove. * ipa-prop.cc (INCLUDE_MEMORY): Remove. * ipa-pure-const.cc (INCLUDE_MEMORY): Remove. * ipa-reference.cc (INCLUDE_MEMORY): Remove. * ipa-split.cc (INCLUDE_MEMORY): Remove. * ipa-sra.cc (INCLUDE_MEMORY): Remove. * ipa-strub.cc (INCLUDE_MEMORY): Remove. * ipa-utils.cc (INCLUDE_MEMORY): Remove. * json-parsing.cc (INCLUDE_MEMORY): Remove. * json.cc (INCLUDE_MEMORY): Remove. * json.h: Don't check INCLUDE_MEMORY. * langhooks.cc (INCLUDE_MEMORY): Remove. * late-combine.cc (INCLUDE_MEMORY): Remove. * lazy-diagnostic-path.cc (INCLUDE_MEMORY): Remove. * libdiagnostics.cc (INCLUDE_MEMORY): Remove. * libsarifreplay.cc (INCLUDE_MEMORY): Remove. * lto-cgraph.cc (INCLUDE_MEMORY): Remove. * lto-compress.cc (INCLUDE_MEMORY): Remove. * lto-opts.cc (INCLUDE_MEMORY): Remove. * lto-section-in.cc (INCLUDE_MEMORY): Remove. * lto-section-out.cc (INCLUDE_MEMORY): Remove. * lto-streamer-in.cc (INCLUDE_MEMORY): Remove. * lto-streamer-out.cc (INCLUDE_MEMORY): Remove. * lto-streamer.cc (INCLUDE_MEMORY): Remove. * lto-wrapper.cc (INCLUDE_MEMORY): Remove. * make-unique.h (GCC_MAKE_UNIQUE): Remove. * multiple_target.cc (INCLUDE_MEMORY): Remove. * omp-expand.cc (INCLUDE_MEMORY): Remove. * omp-general.cc (INCLUDE_MEMORY): Remove. * omp-low.cc (INCLUDE_MEMORY): Remove. * omp-oacc-neuter-broadcast.cc (INCLUDE_MEMORY): Remove. * omp-offload.cc (INCLUDE_MEMORY): Remove. * omp-simd-clone.cc (INCLUDE_MEMORY): Remove. * opt-problem.cc (INCLUDE_MEMORY): Remove. * optinfo-emit-json.cc (INCLUDE_MEMORY): Remove. * optinfo.cc (INCLUDE_MEMORY): Remove. * optinfo.h: Don't check INCLUDE_MEMORY. * opts-common.cc (INCLUDE_MEMORY): Remove. * opts-diagnostic.cc (INCLUDE_MEMORY): Remove. * opts-global.cc (INCLUDE_MEMORY): Remove. * opts.cc (INCLUDE_MEMORY): Remove. * pair-fusion.cc (INCLUDE_MEMORY): Remove. * passes.cc (INCLUDE_MEMORY): Remove. * pointer-query.cc (INCLUDE_MEMORY): Remove. * predict.cc (INCLUDE_MEMORY): Remove. * pretty-print.cc (INCLUDE_MEMORY): Remove. * pretty-print.h: Don't check INCLUDE_MEMORY. * print-rtl.cc (INCLUDE_MEMORY): Remove. * print-tree.cc (INCLUDE_MEMORY): Remove. * profile-count.cc (INCLUDE_MEMORY): Remove. * range-op-float.cc (INCLUDE_MEMORY): Remove. * range-op-ptr.cc (INCLUDE_MEMORY): Remove. * range-op.cc (INCLUDE_MEMORY): Remove. * range.cc (INCLUDE_MEMORY): Remove. * read-rtl-function.cc (INCLUDE_MEMORY): Remove. * rtl-error.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/accesses.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/blocks.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/changes.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/functions.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/insns.cc (INCLUDE_MEMORY): Remove. * rtl-ssa/movement.cc (INCLUDE_MEMORY): Remove. * rtl-tests.cc (INCLUDE_MEMORY): Remove. * sanopt.cc (INCLUDE_MEMORY): Remove. * sched-rgn.cc (INCLUDE_MEMORY): Remove. * selftest-diagnostic-path.cc (INCLUDE_MEMORY): Remove. * selftest-diagnostic.cc (INCLUDE_MEMORY): Remove. * selftest-json.cc (INCLUDE_MEMORY): Remove. * sese.cc (INCLUDE_MEMORY): Remove. * simple-diagnostic-path.cc (INCLUDE_MEMORY): Remove. * splay-tree-utils.cc (INCLUDE_MEMORY): Remove. * sreal.cc (INCLUDE_MEMORY): Remove. * stmt.cc (INCLUDE_MEMORY): Remove. * substring-locations.cc (INCLUDE_MEMORY): Remove. * symtab-clones.cc (INCLUDE_MEMORY): Remove. * symtab-thunks.cc (INCLUDE_MEMORY): Remove. * symtab.cc (INCLUDE_MEMORY): Remove. * system.h: Include memory unconditionally for C++. Also remove support for INCLUDE_MEMORY. * targhooks.cc (INCLUDE_MEMORY): Remove. * text-art/box-drawing.cc (INCLUDE_MEMORY): Remove. * text-art/canvas.cc (INCLUDE_MEMORY): Remove. * text-art/ruler.cc (INCLUDE_MEMORY): Remove. * text-art/selftests.cc (INCLUDE_MEMORY): Remove. * text-art/style.cc (INCLUDE_MEMORY): Remove. * text-art/styled-string.cc (INCLUDE_MEMORY): Remove. * text-art/table.cc (INCLUDE_MEMORY): Remove. * text-art/theme.cc (INCLUDE_MEMORY): Remove. * text-art/tree-widget.cc (INCLUDE_MEMORY): Remove. * text-art/widget.cc (INCLUDE_MEMORY): Remove. * timevar.cc (INCLUDE_MEMORY): Remove. * toplev.cc (INCLUDE_MEMORY): Remove. * trans-mem.cc (INCLUDE_MEMORY): Remove. * tree-affine.cc (INCLUDE_MEMORY): Remove. * tree-assume.cc (INCLUDE_MEMORY): Remove. * tree-call-cdce.cc (INCLUDE_MEMORY): Remove. * tree-cfg.cc (INCLUDE_MEMORY): Remove. * tree-chrec.cc (INCLUDE_MEMORY): Remove. * tree-data-ref.cc (INCLUDE_MEMORY): Remove. * tree-dfa.cc (INCLUDE_MEMORY): Remove. * tree-diagnostic-client-data-hooks.cc (INCLUDE_MEMORY): Remove. * tree-diagnostic.cc (INCLUDE_MEMORY): Remove. * tree-dump.cc (INCLUDE_MEMORY): Remove. * tree-if-conv.cc (INCLUDE_MEMORY): Remove. * tree-inline.cc (INCLUDE_MEMORY): Remove. * tree-into-ssa.cc (INCLUDE_MEMORY): Remove. * tree-logical-location.cc (INCLUDE_MEMORY): Remove. * tree-loop-distribution.cc (INCLUDE_MEMORY): Remove. * tree-nested.cc (INCLUDE_MEMORY): Remove. * tree-nrv.cc (INCLUDE_MEMORY): Remove. * tree-object-size.cc (INCLUDE_MEMORY): Remove. * tree-outof-ssa.cc (INCLUDE_MEMORY): Remove. * tree-parloops.cc (INCLUDE_MEMORY): Remove. * tree-predcom.cc (INCLUDE_MEMORY): Remove. * tree-pretty-print.cc (INCLUDE_MEMORY): Remove. * tree-profile.cc (INCLUDE_MEMORY): Remove. * tree-scalar-evolution.cc (INCLUDE_MEMORY): Remove. * tree-sra.cc (INCLUDE_MEMORY): Remove. * tree-ssa-address.cc (INCLUDE_MEMORY): Remove. * tree-ssa-alias.cc (INCLUDE_MEMORY): Remove. * tree-ssa-ccp.cc (INCLUDE_MEMORY): Remove. * tree-ssa-coalesce.cc (INCLUDE_MEMORY): Remove. * tree-ssa-copy.cc (INCLUDE_MEMORY): Remove. * tree-ssa-dce.cc (INCLUDE_MEMORY): Remove. * tree-ssa-dom.cc (INCLUDE_MEMORY): Remove. * tree-ssa-dse.cc (INCLUDE_MEMORY): Remove. * tree-ssa-forwprop.cc (INCLUDE_MEMORY): Remove. * tree-ssa-ifcombine.cc (INCLUDE_MEMORY): Remove. * tree-ssa-live.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-ch.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-im.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-ivcanon.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-ivopts.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-manip.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-niter.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-prefetch.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-split.cc (INCLUDE_MEMORY): Remove. * tree-ssa-loop-unswitch.cc (INCLUDE_MEMORY): Remove. * tree-ssa-math-opts.cc (INCLUDE_MEMORY): Remove. * tree-ssa-operands.cc (INCLUDE_MEMORY): Remove. * tree-ssa-phiopt.cc (INCLUDE_MEMORY): Remove. * tree-ssa-phiprop.cc (INCLUDE_MEMORY): Remove. * tree-ssa-pre.cc (INCLUDE_MEMORY): Remove. * tree-ssa-propagate.cc (INCLUDE_MEMORY): Remove. * tree-ssa-reassoc.cc (INCLUDE_MEMORY): Remove. * tree-ssa-sccvn.cc (INCLUDE_MEMORY): Remove. * tree-ssa-scopedtables.cc (INCLUDE_MEMORY): Remove. * tree-ssa-sink.cc (INCLUDE_MEMORY): Remove. * tree-ssa-strlen.cc (INCLUDE_MEMORY): Remove. * tree-ssa-structalias.cc (INCLUDE_MEMORY): Remove. * tree-ssa-ter.cc (INCLUDE_MEMORY): Remove. * tree-ssa-threadbackward.cc (INCLUDE_MEMORY): Remove. * tree-ssa-threadupdate.cc (INCLUDE_MEMORY): Remove. * tree-ssa-uninit.cc (INCLUDE_MEMORY): Remove. * tree-ssa.cc (INCLUDE_MEMORY): Remove. * tree-ssanames.cc (INCLUDE_MEMORY): Remove. * tree-stdarg.cc (INCLUDE_MEMORY): Remove. * tree-streamer-in.cc (INCLUDE_MEMORY): Remove. * tree-streamer-out.cc (INCLUDE_MEMORY): Remove. * tree-streamer.cc (INCLUDE_MEMORY): Remove. * tree-switch-conversion.cc (INCLUDE_MEMORY): Remove. * tree-tailcall.cc (INCLUDE_MEMORY): Remove. * tree-vect-data-refs.cc (INCLUDE_MEMORY): Remove. * tree-vect-generic.cc (INCLUDE_MEMORY): Remove. * tree-vect-loop-manip.cc (INCLUDE_MEMORY): Remove. * tree-vect-loop.cc (INCLUDE_MEMORY): Remove. * tree-vect-patterns.cc (INCLUDE_MEMORY): Remove. * tree-vect-slp-patterns.cc (INCLUDE_MEMORY): Remove. * tree-vect-slp.cc (INCLUDE_MEMORY): Remove. * tree-vect-stmts.cc (INCLUDE_MEMORY): Remove. * tree-vectorizer.cc (INCLUDE_MEMORY): Remove. * tree-vrp.cc (INCLUDE_MEMORY): Remove. * tree.cc (INCLUDE_MEMORY): Remove. * ubsan.cc (INCLUDE_MEMORY): Remove. * value-pointer-equiv.cc (INCLUDE_MEMORY): Remove. * value-prof.cc (INCLUDE_MEMORY): Remove. * value-query.cc (INCLUDE_MEMORY): Remove. * value-range-pretty-print.cc (INCLUDE_MEMORY): Remove. * value-range-storage.cc (INCLUDE_MEMORY): Remove. * value-range.cc (INCLUDE_MEMORY): Remove. * value-relation.cc (INCLUDE_MEMORY): Remove. * var-tracking.cc (INCLUDE_MEMORY): Remove. * varpool.cc (INCLUDE_MEMORY): Remove. * vr-values.cc (INCLUDE_MEMORY): Remove. * wide-int-print.cc (INCLUDE_MEMORY): Remove. gcc/c-family/ChangeLog: * c-ada-spec.cc (INCLUDE_MEMORY): Remove. * c-attribs.cc (INCLUDE_MEMORY): Remove. * c-common.cc (INCLUDE_MEMORY): Remove. * c-format.cc (INCLUDE_MEMORY): Remove. * c-gimplify.cc (INCLUDE_MEMORY): Remove. * c-indentation.cc (INCLUDE_MEMORY): Remove. * c-opts.cc (INCLUDE_MEMORY): Remove. * c-pch.cc (INCLUDE_MEMORY): Remove. * c-pragma.cc (INCLUDE_MEMORY): Remove. * c-pretty-print.cc (INCLUDE_MEMORY): Remove. * c-type-mismatch.cc (INCLUDE_MEMORY): Remove. * c-warn.cc (INCLUDE_MEMORY): Remove. * known-headers.cc (INCLUDE_MEMORY): Remove. * name-hint.h: Remove check of INCLUDE_MEMORY. gcc/c/ChangeLog: * c-aux-info.cc (INCLUDE_MEMORY): Remove. * c-convert.cc (INCLUDE_MEMORY): Remove. * c-decl.cc (INCLUDE_MEMORY): Remove. * c-errors.cc (INCLUDE_MEMORY): Remove. * c-fold.cc (INCLUDE_MEMORY): Remove. * c-lang.cc (INCLUDE_MEMORY): Remove. * c-objc-common.cc (INCLUDE_MEMORY): Remove. * c-parser.cc (INCLUDE_MEMORY): Remove. * c-typeck.cc (INCLUDE_MEMORY): Remove. * gimple-parser.cc (INCLUDE_MEMORY): Remove. gcc/cp/ChangeLog: * call.cc (INCLUDE_MEMORY): Remove. * class.cc (INCLUDE_MEMORY): Remove. * constexpr.cc (INCLUDE_MEMORY): Remove. * constraint.cc (INCLUDE_MEMORY): Remove. * contracts.cc (INCLUDE_MEMORY): Remove. * coroutines.cc (INCLUDE_MEMORY): Remove. * cp-gimplify.cc (INCLUDE_MEMORY): Remove. * cp-lang.cc (INCLUDE_MEMORY): Remove. * cp-objcp-common.cc (INCLUDE_MEMORY): Remove. * cp-ubsan.cc (INCLUDE_MEMORY): Remove. * cvt.cc (INCLUDE_MEMORY): Remove. * cxx-pretty-print.cc (INCLUDE_MEMORY): Remove. * decl.cc (INCLUDE_MEMORY): Remove. * decl2.cc (INCLUDE_MEMORY): Remove. * dump.cc (INCLUDE_MEMORY): Remove. * error.cc (INCLUDE_MEMORY): Remove. * except.cc (INCLUDE_MEMORY): Remove. * expr.cc (INCLUDE_MEMORY): Remove. * friend.cc (INCLUDE_MEMORY): Remove. * init.cc (INCLUDE_MEMORY): Remove. * lambda.cc (INCLUDE_MEMORY): Remove. * lex.cc (INCLUDE_MEMORY): Remove. * logic.cc (INCLUDE_MEMORY): Remove. * mangle.cc (INCLUDE_MEMORY): Remove. * mapper-client.cc (INCLUDE_MEMORY): Remove. * mapper-resolver.cc (INCLUDE_MEMORY): Remove. * method.cc (INCLUDE_MEMORY): Remove. * module.cc (INCLUDE_MEMORY): Remove. * name-lookup.cc (INCLUDE_MEMORY): Remove. * optimize.cc (INCLUDE_MEMORY): Remove. * parser.cc (INCLUDE_MEMORY): Remove. * pt.cc (INCLUDE_MEMORY): Remove. * ptree.cc (INCLUDE_MEMORY): Remove. * rtti.cc (INCLUDE_MEMORY): Remove. * search.cc (INCLUDE_MEMORY): Remove. * semantics.cc (INCLUDE_MEMORY): Remove. * tree.cc (INCLUDE_MEMORY): Remove. * typeck.cc (INCLUDE_MEMORY): Remove. * typeck2.cc (INCLUDE_MEMORY): Remove. * vtable-class-hierarchy.cc (INCLUDE_MEMORY): Remove. gcc/d/ChangeLog: * d-attribs.cc (INCLUDE_MEMORY): Remove. * d-builtins.cc (INCLUDE_MEMORY): Remove. * d-codegen.cc (INCLUDE_MEMORY): Remove. * d-convert.cc (INCLUDE_MEMORY): Remove. * d-diagnostic.cc (INCLUDE_MEMORY): Remove. * d-frontend.cc (INCLUDE_MEMORY): Remove. * d-lang.cc (INCLUDE_MEMORY): Remove. * d-longdouble.cc (INCLUDE_MEMORY): Remove. * d-target.cc (INCLUDE_MEMORY): Remove. * decl.cc (INCLUDE_MEMORY): Remove. * expr.cc (INCLUDE_MEMORY): Remove. * intrinsics.cc (INCLUDE_MEMORY): Remove. * modules.cc (INCLUDE_MEMORY): Remove. * toir.cc (INCLUDE_MEMORY): Remove. * typeinfo.cc (INCLUDE_MEMORY): Remove. * types.cc (INCLUDE_MEMORY): Remove. gcc/fortran/ChangeLog: * arith.cc (INCLUDE_MEMORY): Remove. * array.cc (INCLUDE_MEMORY): Remove. * bbt.cc (INCLUDE_MEMORY): Remove. * check.cc (INCLUDE_MEMORY): Remove. * class.cc (INCLUDE_MEMORY): Remove. * constructor.cc (INCLUDE_MEMORY): Remove. * convert.cc (INCLUDE_MEMORY): Remove. * cpp.cc (INCLUDE_MEMORY): Remove. * data.cc (INCLUDE_MEMORY): Remove. * decl.cc (INCLUDE_MEMORY): Remove. * dependency.cc (INCLUDE_MEMORY): Remove. * dump-parse-tree.cc (INCLUDE_MEMORY): Remove. * error.cc (INCLUDE_MEMORY): Remove. * expr.cc (INCLUDE_MEMORY): Remove. * f95-lang.cc (INCLUDE_MEMORY): Remove. * frontend-passes.cc (INCLUDE_MEMORY): Remove. * interface.cc (INCLUDE_MEMORY): Remove. * intrinsic.cc (INCLUDE_MEMORY): Remove. * io.cc (INCLUDE_MEMORY): Remove. * iresolve.cc (INCLUDE_MEMORY): Remove. * match.cc (INCLUDE_MEMORY): Remove. * matchexp.cc (INCLUDE_MEMORY): Remove. * misc.cc (INCLUDE_MEMORY): Remove. * module.cc (INCLUDE_MEMORY): Remove. * openmp.cc (INCLUDE_MEMORY): Remove. * options.cc (INCLUDE_MEMORY): Remove. * parse.cc (INCLUDE_MEMORY): Remove. * primary.cc (INCLUDE_MEMORY): Remove. * resolve.cc (INCLUDE_MEMORY): Remove. * scanner.cc (INCLUDE_MEMORY): Remove. * simplify.cc (INCLUDE_MEMORY): Remove. * st.cc (INCLUDE_MEMORY): Remove. * symbol.cc (INCLUDE_MEMORY): Remove. * target-memory.cc (INCLUDE_MEMORY): Remove. * trans-array.cc (INCLUDE_MEMORY): Remove. * trans-common.cc (INCLUDE_MEMORY): Remove. * trans-const.cc (INCLUDE_MEMORY): Remove. * trans-decl.cc (INCLUDE_MEMORY): Remove. * trans-expr.cc (INCLUDE_MEMORY): Remove. * trans-intrinsic.cc (INCLUDE_MEMORY): Remove. * trans-io.cc (INCLUDE_MEMORY): Remove. * trans-openmp.cc (INCLUDE_MEMORY): Remove. * trans-stmt.cc (INCLUDE_MEMORY): Remove. * trans-types.cc (INCLUDE_MEMORY): Remove. * trans.cc (INCLUDE_MEMORY): Remove. gcc/go/ChangeLog: * go-backend.cc (INCLUDE_MEMORY): Remove. * go-lang.cc (INCLUDE_MEMORY): Remove. gcc/jit/ChangeLog: * dummy-frontend.cc (INCLUDE_MEMORY): Remove. * jit-playback.cc (INCLUDE_MEMORY): Remove. * jit-recording.cc (INCLUDE_MEMORY): Remove. gcc/lto/ChangeLog: * lto-common.cc (INCLUDE_MEMORY): Remove. * lto-dump.cc (INCLUDE_MEMORY): Remove. * lto-partition.cc (INCLUDE_MEMORY): Remove. * lto-symtab.cc (INCLUDE_MEMORY): Remove. * lto.cc (INCLUDE_MEMORY): Remove. gcc/m2/ChangeLog: * gm2-gcc/gcc-consolidation.h (INCLUDE_MEMORY): Remove. * gm2-gcc/m2configure.cc (INCLUDE_MEMORY): Remove. * mc-boot/GASCII.cc (INCLUDE_MEMORY): Remove. * mc-boot/GASCII.h (INCLUDE_MEMORY): Remove. * mc-boot/GArgs.cc (INCLUDE_MEMORY): Remove. * mc-boot/GArgs.h (INCLUDE_MEMORY): Remove. * mc-boot/GAssertion.cc (INCLUDE_MEMORY): Remove. * mc-boot/GAssertion.h (INCLUDE_MEMORY): Remove. * mc-boot/GBreak.cc (INCLUDE_MEMORY): Remove. * mc-boot/GBreak.h (INCLUDE_MEMORY): Remove. * mc-boot/GCOROUTINES.h (INCLUDE_MEMORY): Remove. * mc-boot/GCmdArgs.cc (INCLUDE_MEMORY): Remove. * mc-boot/GCmdArgs.h (INCLUDE_MEMORY): Remove. * mc-boot/GDebug.cc (INCLUDE_MEMORY): Remove. * mc-boot/GDebug.h (INCLUDE_MEMORY): Remove. Remove. * mc-boot/GDynamicStrings.cc (INCLUDE_MEMORY): Remove. * mc-boot/GDynamicStrings.h (INCLUDE_MEMORY): Remove. * mc-boot/GEnvironment.cc (INCLUDE_MEMORY): Remove. * mc-boot/GEnvironment.h (INCLUDE_MEMORY): Remove. * mc-boot/GFIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GFIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GFormatStrings.cc (INCLUDE_MEMORY): Remove. * mc-boot/GFormatStrings.h (INCLUDE_MEMORY): Remove. * mc-boot/GFpuIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GFpuIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GIndexing.cc (INCLUDE_MEMORY): Remove. * mc-boot/GIndexing.h (INCLUDE_MEMORY): Remove. * mc-boot/GM2Dependent.cc (INCLUDE_MEMORY): Remove. * mc-boot/GM2Dependent.h (INCLUDE_MEMORY): Remove. * mc-boot/GM2EXCEPTION.cc (INCLUDE_MEMORY): Remove. * mc-boot/GM2EXCEPTION.h (INCLUDE_MEMORY): Remove. * mc-boot/GM2RTS.cc (INCLUDE_MEMORY): Remove. * mc-boot/GM2RTS.h (INCLUDE_MEMORY): Remove. Remove. * mc-boot/GMemUtils.cc (INCLUDE_MEMORY): Remove. * mc-boot/GMemUtils.h (INCLUDE_MEMORY): Remove. * mc-boot/GNumberIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GNumberIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GPushBackInput.cc (INCLUDE_MEMORY): Remove. * mc-boot/GPushBackInput.h (INCLUDE_MEMORY): Remove. * mc-boot/GRTExceptions.cc (INCLUDE_MEMORY): Remove. * mc-boot/GRTExceptions.h (INCLUDE_MEMORY): Remove. * mc-boot/GRTco.h (INCLUDE_MEMORY): Remove. * mc-boot/GRTentity.h (INCLUDE_MEMORY): Remove. * mc-boot/GRTint.cc (INCLUDE_MEMORY): Remove. * mc-boot/GRTint.h (INCLUDE_MEMORY): Remove. * mc-boot/GSArgs.cc (INCLUDE_MEMORY): Remove. * mc-boot/GSArgs.h (INCLUDE_MEMORY): Remove. * mc-boot/GSFIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GSFIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GSYSTEM.h (INCLUDE_MEMORY): Remove. * mc-boot/GSelective.h (INCLUDE_MEMORY): Remove. * mc-boot/GStdIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStdIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GStorage.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStorage.h (INCLUDE_MEMORY): Remove. * mc-boot/GStrCase.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStrCase.h (INCLUDE_MEMORY): Remove. * mc-boot/GStrIO.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStrIO.h (INCLUDE_MEMORY): Remove. * mc-boot/GStrLib.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStrLib.h (INCLUDE_MEMORY): Remove. * mc-boot/GStringConvert.cc (INCLUDE_MEMORY): Remove. * mc-boot/GStringConvert.h (INCLUDE_MEMORY): Remove. * mc-boot/GSysExceptions.h (INCLUDE_MEMORY): Remove. * mc-boot/GSysStorage.cc (INCLUDE_MEMORY): Remove. * mc-boot/GSysStorage.h (INCLUDE_MEMORY): Remove. * mc-boot/GTimeString.cc (INCLUDE_MEMORY): Remove. * mc-boot/GTimeString.h (INCLUDE_MEMORY): Remove. * mc-boot/GUnixArgs.h (INCLUDE_MEMORY): Remove. * mc-boot/Galists.cc (INCLUDE_MEMORY): Remove. * mc-boot/Galists.h (INCLUDE_MEMORY): Remove. * mc-boot/Gdecl.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gdecl.h (INCLUDE_MEMORY): Remove. * mc-boot/Gdtoa.h (INCLUDE_MEMORY): Remove. * mc-boot/Gerrno.h (INCLUDE_MEMORY): Remove. * mc-boot/Gkeyc.cc (INCLUDE_MEMORY): Remove. (checkGccConfigSystem): Remove printing out `#define INCLUDE_MEMORY`. * mc-boot/Gkeyc.h (INCLUDE_MEMORY): Remove. * mc-boot/Gldtoa.h (INCLUDE_MEMORY): Remove. * mc-boot/Glibc.h (INCLUDE_MEMORY): Remove. * mc-boot/Glibm.h (INCLUDE_MEMORY): Remove. * mc-boot/Glists.cc (INCLUDE_MEMORY): Remove. * mc-boot/Glists.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcComment.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcComment.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcComp.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcComp.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcDebug.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcDebug.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcError.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcError.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcFileName.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcFileName.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcLexBuf.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcLexBuf.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcMetaError.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcMetaError.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcOptions.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcOptions.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcPreprocess.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcPreprocess.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcPretty.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcPretty.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcPrintf.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcPrintf.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcQuiet.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcQuiet.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcReserved.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcReserved.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcSearch.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcSearch.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcStack.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcStack.h (INCLUDE_MEMORY): Remove. * mc-boot/GmcStream.cc (INCLUDE_MEMORY): Remove. * mc-boot/GmcStream.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcflex.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp1.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp1.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp2.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp2.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp3.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp3.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp4.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp4.h (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp5.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gmcp5.h (INCLUDE_MEMORY): Remove. * mc-boot/GnameKey.cc (INCLUDE_MEMORY): Remove. * mc-boot/GnameKey.h (INCLUDE_MEMORY): Remove. * mc-boot/GsymbolKey.cc (INCLUDE_MEMORY): Remove. * mc-boot/GsymbolKey.h (INCLUDE_MEMORY): Remove. * mc-boot/Gtermios.h (INCLUDE_MEMORY): Remove. * mc-boot/Gtop.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gvarargs.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gvarargs.h (INCLUDE_MEMORY): Remove. * mc-boot/Gwlists.cc (INCLUDE_MEMORY): Remove. * mc-boot/Gwlists.h (INCLUDE_MEMORY): Remove. * mc-boot/Gwrapc.h (INCLUDE_MEMORY): Remove. * pge-boot/GIndexing.h (INCLUDE_MEMORY): Remove. * pge-boot/GSEnvironment.h (INCLUDE_MEMORY): Remove. * pge-boot/GScan.h (INCLUDE_MEMORY): Remove. gcc/objc/ChangeLog: * objc-act.cc (INCLUDE_MEMORY): Remove. * objc-encoding.cc (INCLUDE_MEMORY): Remove. * objc-gnu-runtime-abi-01.cc (INCLUDE_MEMORY): Remove. * objc-lang.cc (INCLUDE_MEMORY): Remove. * objc-next-runtime-abi-01.cc (INCLUDE_MEMORY): Remove. * objc-next-runtime-abi-02.cc (INCLUDE_MEMORY): Remove. * objc-runtime-shared-support.cc (INCLUDE_MEMORY): Remove. gcc/objcp/ChangeLog: * objcp-decl.cc (INCLUDE_MEMORY): Remove. * objcp-lang.cc (INCLUDE_MEMORY): Remove. gcc/rust/ChangeLog: * resolve/rust-ast-resolve-expr.cc (INCLUDE_MEMORY): Remove. * rust-attribs.cc (INCLUDE_MEMORY): Remove. * rust-system.h (INCLUDE_MEMORY): Remove. Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>