- Mar 04, 2022
-
-
Clément Chigot authored
Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/388635
-
Iain Sandoe authored
DECL_MD_FUNCTION_CODE() returns an int, on one particular compiler the code in darwin_fold_builtin() triggers a warning. Fixed thus. Signed-off-by:
Iain Sandoe <iain@sandoe.co.uk> gcc/ChangeLog: * config/darwin.cc (darwin_fold_builtin): Make fcode an int to avoid a mismatch with DECL_MD_FUNCTION_CODE().
-
Iain Sandoe authored
PowerPC Darwin8 is the last version to use an unwind frame fallback routine. This had been omitted from the new shared EH library, along with one more header dependency that only fires there. Signed-off-by:
Iain Sandoe <iain@sandoe.co.uk> libgcc/ChangeLog: * config/rs6000/t-darwin-ehs: Add darwin-fallback.o. * config/t-darwin-ehs: Add dependency on unwind.h.
-
Patrick Palka authored
Fixed by r12-7264. PR c++/103443 gcc/testsuite/ChangeLog: * g++.dg/cpp2a/consteval29.C: New test.
-
Nathan Sidwell authored
This implements a new module mangling ABI as the original one has a few issues: a) it was not demangleable (oops) b) implemented a weak ownership model. This implements a strong ownership model, so that exported entities from named modules are mangled to include their module attachment. This gives more informative linker diagnostics and better module isolation. Weak ownership was hoped to allow backwards compatibility with non-modular code, but in practice was very brittle, and C++20 added new semantics for linkage declarations that cover the needed functionality. FAOD Clang is also moving to this ABI and documentation will be added to the Itanium ABI specification. gcc/cp/ * cp-tree.h (mangle_identifier): Replace with ... (mangle_module_component): ... this. * mangle.cc (dump_substitution_candidates): Adjust. (add_substitution): Likewise. (find_substitution): Likewise. (unmangled_name_p): Likewise. (mangle_module_substitution): Reimplement. (mangle_module_component): New. (write_module, maybe_write_module): Adjust. (write_name): Drop modules here. (write_unqualified): Do them here instead. (mangle_global_init): Adjust. * module.cc (module_state::mangle): Adjust. (mangle_module): Likewise. (get_originating_module): Adjust. gcc/testsuite/ * g++.dg/modules/fn-inline-1_b.C: Adjust. * g++.dg/modules/fn-inline-1_c.C: Adjust. * g++.dg/modules/imp-inline-1_a.C: Adjust. * g++.dg/modules/imp-inline-1_b.C: Adjust. * g++.dg/modules/init-2_a.C: Adjust. * g++.dg/modules/init-2_b.C: Adjust. * g++.dg/modules/init-2_c.C: Adjust. * g++.dg/modules/member-def-2_d.C: Adjust. * g++.dg/modules/mod-sym-1.C: Adjust. * g++.dg/modules/mod-sym-2.C: Adjust. * g++.dg/modules/mod-sym-3.C: Adjust. * g++.dg/modules/sym-subst-1.C: Adjust. * g++.dg/modules/sym-subst-2_b.C: Adjust. * g++.dg/modules/sym-subst-3_a.C: Adjust. * g++.dg/modules/sym-subst-3_b.C: Adjust. * g++.dg/modules/sym-subst-4.C: Adjust. * g++.dg/modules/sym-subst-5.C: Adjust. * g++.dg/modules/sym-subst-6.C: Adjust. * g++.dg/modules/tpl-spec-1_a.C: Adjust. * g++.dg/modules/tpl-spec-2_b.C: Adjust. * g++.dg/modules/tpl-spec-2_d.C: Adjust. * g++.dg/modules/tpl-spec-3_a.C: Adjust. * g++.dg/modules/virt-1_a.C: Adjust. * g++.dg/modules/virt-2_a.C: Adjust. * g++.dg/modules/virt-2_b.C: Adjust. * g++.dg/modules/virt-2_c.C: Adjust. * g++.dg/modules/vtt-1_a.C: Adjust. * g++.dg/modules/vtt-1_b.C: Adjust.
-
Iain Sandoe authored
Follow up discussion to the initial patch for this PR identified that it is preferable to avoid the LRA change, and arrange for the target to reject the hi and lo_sum selections when presented with an invalid address. We split the Darwin high/low selectors into two: 1. One that handles non-PIC addresses (kernel mode, mdynamic-no-pic). 2. One that handles PIC addresses and rejects SYMBOL_REFs unless they are suitably wrapped in the MACHOPIC_OFFSET unspec. The second case is handled by providing a new predicate (macho_pic_address) that checks the requirements. Signed-off-by:
Iain Sandoe <iain@sandoe.co.uk> PR target/104117 gcc/ChangeLog: * config/rs6000/darwin.md (@machopic_high_<mode>): New. (@machopic_low_<mode>): New. * config/rs6000/predicates.md (macho_pic_address): New. * config/rs6000/rs6000.cc (rs6000_legitimize_address): Do not apply the TLS processing to Darwin. * lra-constraints.cc (process_address_1): Revert the changes in r12-7209.
-
Peter Bergner authored
The glibc build is showing a build error due to extra "error" checking from my PR87496 fix. That checking was overeager, disallowing setting the long double size to 64-bits if the 128-bit long double ABI had already been specified. Now we only emit an error if we specify a 128-bit long double ABI if our long double size is not 128 bits. This also fixes an erroneous error when -mabi=ieeelongdouble is used and ISA 2.06 is not enabled, but the long double size has been changed to 64 bits. 2022-03-04 Peter Bergner <bergner@linux.ibm.com> gcc/ PR target/87496 PR target/104208 * config/rs6000/rs6000.cc (rs6000_option_override_internal): Make the ISA 2.06 requirement for -mabi=ieeelongdouble conditional on -mlong-double-128. Move the -mabi=ieeelongdouble and -mabi=ibmlongdouble error checking from here... * common/config/rs6000/rs6000-common.cc (rs6000_handle_option): ... to here. gcc/testsuite/ PR target/87496 PR target/104208 * gcc.target/powerpc/pr104208-1.c: New test. * gcc.target/powerpc/pr104208-2.c: Likewise. * gcc.target/powerpc/pr87496-2.c: Swap long double options to trigger the expected error. * gcc.target/powerpc/pr87496-3.c: Likewise.
-
Thomas Schwinge authored
Before recent commit 8935589b "OMP lowering: Regimplify 'OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE' DECLs [PR100280, PR104132, PR104133]", 'libgomp.oacc-c' testing already worked fine, but 'libgomp.oacc-c++' testing ICEed. Via the commit mentioned, the C++ testing ICEs are now resolved, but the underlying issue remains to be looked into: PR104784 "OpenACC 'kernels' decomposition: C vs. C++ differences". PR middle-end/104784 libgomp/ * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-1.c: Test with '--param=openacc-kernels=decompose'. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-6.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-vector-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-vector-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-6.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-7.c: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-3.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-6.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-vector-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-vector-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-3.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-4.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-5.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-6.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-7.f90: Likewise.
-
Jakub Jelinek authored
The following testcase regressed when SRA started punting on stores to TREE_READONLY vars. We document that: "In a VAR_DECL, PARM_DECL or FIELD_DECL, or any kind of ..._REF node, nonzero means it may not be the lhs of an assignment." so the SRA change looks desirable. On the other side, at least in this testcase the TREE_READONLY is set there intentionally from the PR85873 fix, because gimplify_init_constructor itself uses TREE_READONLY on the object to determine if it can perform promotion to static const or not. So, similarly to other spots in the gimplifier where we also clear TREE_READONLY when we emit IL that stores into the object, this does the same in gimplify_init_constructor, but in the way so that the TREE_READONLY test for the promotion to static const keeps working and doesn't change anything for notify_temp_creation mode, which doesn't emit any IL, just tests if it would need a temporary or not. This keeps PR85873 testcase working as before and fixes this regression. 2022-03-04 Jakub Jelinek <jakub@redhat.com> PR middle-end/104529 * gimplify.cc (gimplify_init_constructor): Clear TREE_READONLY on automatic objects which will be runtime initialized. * g++.dg/tree-ssa/pr104529.C: New test.
-
Thomas Schwinge authored
libgomp/ * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-1.c: Test '-fopt-info-omp-all'. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-local-worker-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-gang-6.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-vector-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-vector-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-1.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-2.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-3.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-4.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-5.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-6.c: Likewise. * testsuite/libgomp.oacc-c-c++-common/kernels-private-vars-loop-worker-7.c: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-3.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-gang-6.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-vector-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-vector-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-1.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-2.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-3.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-4.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-5.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-6.f90: Likewise. * testsuite/libgomp.oacc-fortran/kernels-private-vars-loop-worker-7.f90: Likewise.
-
Thomas Schwinge authored
OMP lowering: Regimplify 'OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE' DECLs [PR100280, PR104132, PR104133] ... by generalizing the existing 'gcc/omp-low.cc:task_shared_vars'. Fix-up for commit 9b32c166 "OpenACC 'kernels' decomposition: Mark variables used in synthesized data clauses as addressable [PR100280]". PR middle-end/100280 PR middle-end/104132 PR middle-end/104133 gcc/ * omp-low.cc (task_shared_vars): Rename to 'make_addressable_vars'. Adjust all users. (scan_sharing_clauses) <OMP_CLAUSE_MAP> Use it for 'OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE' DECLs, too. gcc/testsuite/ * c-c++-common/goacc/kernels-decompose-pr104061-1-3.c: Adjust. * c-c++-common/goacc/kernels-decompose-pr104061-1-4.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104132-1.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104133-1.c: Likewise. libgomp/ * testsuite/libgomp.oacc-c-c++-common/kernels-decompose-1.c: Extend.
-
Thomas Schwinge authored
... in preparation for later changes. No functional change. Follow-up to commit 9b32c166 "OpenACC 'kernels' decomposition: Mark variables used in synthesized data clauses as addressable [PR100280]". PR middle-end/100280 gcc/ * tree.h (OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE): New. * tree-core.h: Document it. * omp-low.cc (scan_sharing_clauses) <OMP_CLAUSE_MAP>: Handle 'OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE'. * omp-oacc-kernels-decompose.cc (maybe_build_inner_data_region): Set 'OMP_CLAUSE_MAP_DECL_MAKE_ADDRESSABLE' instead of 'TREE_ADDRESSABLE'. gcc/testsuite/ * c-c++-common/goacc/classify-kernels-unparallelized.c: Adjust. * c-c++-common/goacc/classify-kernels.c: Likewise. * c-c++-common/goacc/kernels-decompose-2.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr100280-1.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-2.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-3.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-4.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104132-1.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104133-1.c: Likewise. libgomp/ * testsuite/libgomp.oacc-c-c++-common/f-asyncwait-1.c: Adjust. * testsuite/libgomp.oacc-c-c++-common/kernels-decompose-1.c: Likewise.
-
Thomas Schwinge authored
Add diagnostic: "note: OpenACC 'kernels' decomposition: variable '[...]' declared in block made addressable" [PR100280] Follow-up to commit 9b32c166 "OpenACC 'kernels' decomposition: Mark variables used in synthesized data clauses as addressable [PR100280]". PR middle-end/100280 gcc/ * omp-oacc-kernels-decompose.cc (maybe_build_inner_data_region): Add diagnostic: "note: OpenACC 'kernels' decomposition: variable '[...]' declared in block made addressable". gcc/testsuite/ * c-c++-common/goacc/classify-kernels-unparallelized.c: Add '--param=openacc-privatization=noisy'. * c-c++-common/goacc/classify-kernels.c: Likewise. * c-c++-common/goacc/kernels-decompose-2.c: Adjust. * c-c++-common/goacc/kernels-decompose-pr100280-1.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-2.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-3.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104061-1-4.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104132-1.c: Likewise. * c-c++-common/goacc/kernels-decompose-pr104133-1.c: Likewise. libgomp/ * testsuite/libgomp.oacc-c-c++-common/f-asyncwait-1.c: Adjust. * testsuite/libgomp.oacc-c-c++-common/kernels-decompose-1.c: Likewise.
-
Thomas Schwinge authored
Actually fixing it is a separate task, but it seems prudent to at least catch it, and document via a few test cases. gcc/ PR middle-end/100400 PR middle-end/103836 PR middle-end/104061 * omp-oacc-kernels-decompose.cc (decompose_kernels_region_body): Catch 'GIMPLE_DEBUG'. gcc/testsuite/ PR middle-end/100400 PR middle-end/103836 PR middle-end/104061 * c-c++-common/goacc/kernels-decompose-pr100400-1-1.c: New. * c-c++-common/goacc/kernels-decompose-pr100400-1-2.c: New. * c-c++-common/goacc/kernels-decompose-pr100400-1-3.c: New. * c-c++-common/goacc/kernels-decompose-pr100400-1-4.c: New. * c-c++-common/goacc/kernels-decompose-pr103836-1-1.c: New. * c-c++-common/goacc/kernels-decompose-pr103836-1-2.c: New. * c-c++-common/goacc/kernels-decompose-pr103836-1-3.c: New. * c-c++-common/goacc/kernels-decompose-pr103836-1-4.c: New. * c-c++-common/goacc/kernels-decompose-pr104061-1-1.c: New. * c-c++-common/goacc/kernels-decompose-pr104061-1-2.c: New. * c-c++-common/goacc/kernels-decompose-pr104061-1-3.c: New. * c-c++-common/goacc/kernels-decompose-pr104061-1-4.c: New.
-
Thomas Schwinge authored
..., currently XFAILed with 'dg-ice'. PR middle-end/104133 gcc/testsuite/ * c-c++-common/goacc/kernels-decompose-pr104133-1.c: New file.
-
Thomas Schwinge authored
..., currently XFAILed with 'dg-ice'. PR middle-end/104132 gcc/testsuite/ * c-c++-common/goacc/kernels-decompose-pr104132-1.c: New file.
-
Thomas Schwinge authored
... to use 'dg-line', simplifying later changes. Also some minor miscellaneous diagnostics scanning maintenance. gcc/testsuite/ * c-c++-common/goacc/classify-kernels-parloops.c: Update. * c-c++-common/goacc/classify-kernels-unparallelized-parloops.c: Likewise. * c-c++-common/goacc/classify-kernels-unparallelized.c: Likewise. * c-c++-common/goacc/classify-kernels.c: Likewise. * c-c++-common/goacc/classify-parallel.c: Likewise. * c-c++-common/goacc/classify-routine-nohost.c: Likewise. * c-c++-common/goacc/classify-routine.c: Likewise. * c-c++-common/goacc/classify-serial.c: Likewise. * gfortran.dg/goacc/classify-kernels-parloops.f95: Likewise. * gfortran.dg/goacc/classify-kernels-unparallelized-parloops.f95: Likewise. * gfortran.dg/goacc/classify-kernels-unparallelized.f95: Likewise. * gfortran.dg/goacc/classify-kernels.f95: Likewise. * gfortran.dg/goacc/classify-parallel.f95: Likewise. * gfortran.dg/goacc/classify-routine-nohost.f95: Likewise. * gfortran.dg/goacc/classify-routine.f95: Likewise. * gfortran.dg/goacc/classify-serial.f95: Likewise.
-
Jonathan Wakely authored
libstdc++-v3/ChangeLog: * libsupc++/compare (strong_order::_S_fp_cmp): Move typedef inside #if condition.
-
Jakub Jelinek authored
The r12-7287-g1b71bc7c8b18bd1b change improved the -Wdeprecated warning for C++, but regressed it for C, in particular in gcc.dg/deprecated.c testcase we now report a type that actually isn't deprecated as deprecated instead of the one that is deprecated. The following change tries to find the middle ground between what we used to do before and what r12-7287 change does. If TYPE_STUB_DECL (node) is non-NULL (that is what happens with those C tests), then it will do what it used to do before (just smarter, there is no need to lookup_attribute when it is called again a few lines below this), if it is NULL, it will try TYPE_STUB_DECL (TYPE_MAIN_VARIANT (node)) - what the deprecated-16.C test needs. 2022-03-04 Jakub Jelinek <jakub@redhat.com> PR c/104627 * tree.cc (warn_deprecated_use): For types prefer to use node and only use TYPE_MAIN_VARIANT (node) if TYPE_STUB_DECL (node) is NULL.
-
H.J. Lu authored
ix86_gen_scratch_sse_rtx returns XMM7/XMM15/XMM31 as a scratch vector register to prevent RTL optimizers from removing vector register. It introduces a conflict with explicit XMM7/XMM15/XMM31 usage and when it is called by RTL optimizers, it may introduce conflicting usages of XMM7/XMM15/XMM31. Change ix86_gen_scratch_sse_rtx to always return a pseudo register and xfail x86 tests which are optimized with a hard scratch register. gcc/ PR target/104704 * config/i386/i386.cc (ix86_gen_scratch_sse_rtx): Always return a pseudo register. gcc/testsuite/ PR target/104704 * gcc.target/i386/incoming-11.c: Xfail. * gcc.target/i386/pieces-memset-3.c: Likewise. * gcc.target/i386/pieces-memset-37.c: Likewise. * gcc.target/i386/pieces-memset-39.c: Likewise. * gcc.target/i386/pieces-memset-46.c: Likewise. * gcc.target/i386/pieces-memset-47.c: Likewise. * gcc.target/i386/pieces-memset-48.c: Likewise. * gcc.target/i386/pr90773-5.c: Likewise. * gcc.target/i386/pr90773-14.c: Likewise. * gcc.target/i386/pr90773-17.c: Likewise. * gcc.target/i386/pr100865-8a.c: Likewise. * gcc.target/i386/pr100865-8c.c: Likewise. * gcc.target/i386/pr100865-9c.c: Likewise. * gcc.target/i386/pieces-memset-21.c: Always expect vzeroupper. * gcc.target/i386/pr82941-1.c: Likewise. * gcc.target/i386/pr82942-1.c: Likewise. * gcc.target/i386/pr82990-1.c: Likewise. * gcc.target/i386/pr82990-3.c: Likewise. * gcc.target/i386/pr82990-5.c: Likewise. * gcc.target/i386/pr100865-11b.c: Expect vmovdqa instead of vmovdqa64. * gcc.target/i386/pr100865-12b.c: Likewise. * gcc.target/i386/pr100865-8b.c: Likewise. * gcc.target/i386/pr100865-9b.c: Likewise. * gcc.target/i386/pr104704-1.c: New test. * gcc.target/i386/pr104704-2.c: Likewise. * gcc.target/i386/pr104704-3.c: Likewise. * gcc.target/i386/pr104704-4.c: Likewise. * gcc.target/i386/pr104704-5.c: Likewise. * gcc.target/i386/pr104704-6.c: Likewise.
-
GCC Administrator authored
-
- Mar 03, 2022
-
-
Jonathan Wakely authored
The std::__debug::vector isn't usable in constant expressions, so this test fails in debug mode. Until the debug vector is fixed we can just make the test use the non-debug one. libstdc++-v3/ChangeLog: PR libstdc++/104748 * testsuite/std/ranges/adaptors/all.cc: Use non-debug vector for constexpr test.
-
Jonathan Wakely authored
This fixes a test failure due to a non-reserved name in an AIX system header (included via <pthread.h>). That name clashes with one of the names we check our own headers for, so skip checking that name on AIX. libstdc++-v3/ChangeLog: * testsuite/17_intro/names.cc (func): Undef on AIX.
-
Jonathan Wakely authored
This removes a FIXME in <compare>, defining the total order for floating-point types. I originally opened PR96526 to request a new compiler built-in to implement this, but now that we have std::bit_cast it can be done entirely in the library. The implementation is based on the glibc definitions of totalorder, totalorderf, totalorderl etc. I think this works for all the types that satisfy std::floating_point today, and should also work for the types expected to be added by P1467 except for std::bfloat16_t. It also supports some additional types that don't currently satisfy std::floating_point, such as __float80, but we probably do want that to satisfy the concept for non-strict modes. libstdc++-v3/ChangeLog: PR libstdc++/96526 * libsupc++/compare (strong_order): Add missing support for floating-point types. * testsuite/18_support/comparisons/algorithms/strong_order_floats.cc: New test.
-
Martin Sebor authored
Resolves: PR middle-end/104761 - bogus -Wdangling-pointer with cleanup and infinite loop gcc/ChangeLog: PR middle-end/104761 * gimple-ssa-warn-access.cc (pass_waccess::execute): Call mark_dfs_back_edges. gcc/testsuite/ChangeLog: PR middle-end/104761 * g++.dg/warn/Wdangling-pointer-4.C: New test. * gcc.dg/Wdangling-pointer-4.c: New test.
-
Martin Liska authored
gcc/ChangeLog: * configure.ac: Use linker plug-in by default. * configure: Regenerate.
-
Martin Liska authored
gcc/ChangeLog: * configure.ac: Now ld.mold support LTO plugin API, use it. * configure: Regenerate.
-
Kwok Cheung Yeung authored
This rejects variables that are array types, array elements or derived type members when used as the event handle inside a detach clause (in accordance with the OpenMP specification). This would previously lead to an ICE. 2022-03-03 Kwok Cheung Yeung <kcy@codesourcery.com> gcc/fortran/ PR fortran/104131 * openmp.cc (gfc_match_omp_detach): Move check for type of event handle to... (resolve_omp_clauses) ...here. Also check that the event handle is not an array, or an array access or structure element access. gcc/testsuite/ PR fortran/104131 * gfortran.dg/gomp/pr104131.f90: New. * gfortran.dg/gomp/task-detach-1.f90: Update expected error message.
-
Tom de Vries authored
In gcc-5 to gcc-11, the ptx isa version was 3.1. On trunk, the default is now 6.0, which is also what will be the value in the libraries. Consequently, there may be setups with an older driver that worked with gcc-11, but will become unsupported with gcc-12. Fix this by building the libraries with mptx=3.1. After this, setups with an older driver still won't work out of the box with gcc-12, because the default ptx isa version has changed, but should work after specifying mptx=3.1. gcc/ChangeLog: 2022-03-03 Tom de Vries <tdevries@suse.de> * config/nvptx/t-nvptx (MULTILIB_EXTRA_OPTS): Add mptx=3.1.
-
Tom de Vries authored
In gcc-11, when specifying -misa=sm_30, an executable may still contain sm_35 code (due to libraries being built with the default -misa=sm_35), so it won't run on an sm_30 board. Fix this by building libraries with sm_30, as was the case in gcc-5 to gcc-10. gcc/ChangeLog: 2022-03-03 Tom de Vries <tdevries@suse.de> PR target/104758 * config/nvptx/t-nvptx (MULTILIB_EXTRA_OPTS): Add misa=sm_30.
-
Tom de Vries authored
In PR97348, we ran into the problem that recent CUDA dropped support for sm_30, which inhibited the build when building with CUDA bin in the path, because the nvptx-tools assembler uses CUDA's ptxas to do ptx verification. To fix this, in gcc-11 the default sm_xx was moved from sm_30 to sm_35. This however broke support for sm_30 boards: an executable build for sm_30 might contain sm_35 code from the libraries, which are build with the default sm_xx (PR104758). We want to fix this by going back to having the libraries build with sm_30, as was the case for gcc-5 to gcc-10. That however reintroduces the problem from PR97348. Deal with PR97348 in the simplest way possible: when calling the assembler for sm_30, specify --no-verify. This has the unfortunate effect that after fixing PR104758 by building libraries with sm_30, the libraries are no longer verified. This can be improved upon by: - adding a configure test in gcc that tests if CUDA supports sm_30, and if so disabling this patch - dealing with this in nvptx-tools somehow, either: - detect at ptxas execution time that it doesn't support sm_30, or - detect this at nvptx-tool configure time. gcc/ChangeLog: 2022-03-03 Tom de Vries <tdevries@suse.de> * config/nvptx/nvptx.h (ASM_SPEC): Add %{misa=sm_30:--no-verify}.
-
Tom de Vries authored
With target board nvptx-none-run/-mptx=3.1 we run into: ... cc1: error: PTX version (-mptx) needs to be at least 4.2 to support \ selected -misa (sm_53)^M compiler exited with status 1 FAIL: gcc.target/nvptx/sm53.c (test for excess errors) ... Fix this by adding -mptx=_ in sm53.c and similar. Tested on nvptx. gcc/testsuite/ChangeLog: 2022-03-03 Tom de Vries <tdevries@suse.de> * gcc.target/nvptx/sm53.c: Add -mptx=_. * gcc.target/nvptx/sm70.c: Same. * gcc.target/nvptx/sm75.c: Same. * gcc.target/nvptx/sm80.c: Same.
-
Jakub Jelinek authored
When offloading to nvptx is enabled, scan_omp_simd duplicates the simd region including its clauses and body using inliner's copy_gimple_seq_and_replace_locals. That works nicely for decls, remaps only those that are seen in the nested bind expr vars (i.e. local variables) and doesn't remap other vars. But for SSA_NAMEs it remaps them always, doesn't know if their def stmt is outside of the simd (then it better shouldn't be remapped) or inside of it (then it should) and without cfg/dominators that is pretty hard to figure out (well, we could walk the region twice, once note SSA_NAMEs defined by each stmt seen there and once do the remapping of only those visited SSA_NAMEs). This patch uses a simpler way, disables temporarily into_ssa for the clauses and body of each simd region; we already disable into_ssa e.g. in parallel/target/task etc. regions through push_gimplify_context () but for simd we don't push any gimplification context and appart from into_ssa I think we don't need it. 2022-03-03 Jakub Jelinek <jakub@redhat.com> PR middle-end/104757 * gimplify.cc (gimplify_omp_loop): Call gimplify_expr rather than gimplify_omp_for. (gimplify_expr) <case OMP_SIMD>: Temporarily disable gimplify_ctxp->into_ssa around call to gimplify_omp_for. * gfortran.dg/gomp/pr104757.f90: New test. * gcc.dg/gomp/pr104757.c: New test.
-
Jakub Jelinek authored
calls: When bypassing emit_push_insn for 0 sized arg, emit at least anti_adjust_stack for alignment pad if needed [PR104558] The following testcase ICEs on x86_64 when asked to use the pre-GCC 8 ABI where zero sized arguments weren't ignored. In GCC 7 the emit_push_insn calls in store_one_arg were unconditional, it is true that they didn't actually push anything because it had zero size, but because arg->locate.alignment_pad is 8 in this case, emit_push_insn at the end performs if (alignment_pad && args_addr == 0) anti_adjust_stack (alignment_pad); and an assert larger on is upset if we don't do it. The following patch keeps the emit_push_insn conditional but calls the anti_adjust_stack when needed by hand for the zero sized arguments. For the new x86_64 ABI where zero sized arguments are ignored arg->locate.alignment_pad is 0 in this case, so nothing changes - we in that case really do ignore it. There is another emit_push_insn call earlier in store_one_arg, also made conditional on non-zero size by Marek in GCC 8, but that one is for arguments with non-BLKmode and the only way those can be zero size is if they are TYPE_EMPTY_P aka when they are completely ignored. But I believe arg->locate.alignment_pad should be 0 in that case, so IMHO there is no need to do anything in the second spot. 2022-03-03 Jakub Jelinek <jakub@redhat.com> PR middle-end/104558 * calls.cc (store_one_arg): When not calling emit_push_insn because size_rtx is const0_rtx, call at least anti_adjust_stack on arg->locate.alignment_pad if !argblock and the alignment might be non-zero. * gcc.dg/pr104558.c: New test.
-
GCC Administrator authored
-
- Mar 02, 2022
-
-
Harald Anlauf authored
gcc/fortran/ChangeLog: PR fortran/104573 * resolve.cc (resolve_structure_cons): Avoid NULL pointer dereference when there is no valid component. gcc/testsuite/ChangeLog: PR fortran/104573 * gfortran.dg/assumed_type_14.f90: New test.
-
David Edelsohn authored
The testcase references a vector type that elicits a psabi warning. This patch adds the option to suppress the warning. * c-c++-common/pr104505.c: Add -Wno-psabi.
-
Iain Buclaw authored
D Runtime changes: - Fix stdc.stdio bindings to not depend on druntime (PR104729). - Implement stdc.math for Solaris (PR104735). gcc/d/ChangeLog: * dmd/MERGE: Merge upstream dmd 423f19b41. libphobos/ChangeLog: * libdruntime/MERGE: Merge upstream druntime 100a608c. * src/MERGE: Merge upstream phobos a1f8c4c07.
-
Alexandre Oliva authored
Unlike e.g. remove_inheritance_pseudos, undo_optional_reloads didn't deal with subregs, so instead of removing multi-word moves, it replaced the reload pseudo with the original pseudo. Besides the redundant move, that retained the clobber of the dest, that starts a multi-word move. After the remap, the sequence that should have become a no-op move starts by clobbering the original pseudo and then moving its pieces onto themselves. The problem is the clobber: it makes earlier sets of the original pseudo to be regarded as dead: if the optional reload sequence was an output reload, the insn for which the output reload was attempted may be regarded as dead and deleted. I've arranged for undo_optional_reloads to accept SUBREGs and use get_regno, like remove_inheritance_pseudo, adjusted its insn-removal loop to tolerate iterating over a removed clobber, and added logic to catch any left-over reload clobbers that could trigger the problem. for gcc/ChangeLog * lra-constraints.cc (undo_optional_reloads): Recognize and drop insns of multi-word move sequences, tolerate removal iteration on an already-removed clobber, and refuse to substitute original pseudos into clobbers.
-
Qing Zhao authored
At the same time, adding -Wtrivial-auto-var-init and update documentation. -Wtrivial-auto-var-init and update documentation. for the following testing case: 1 int g(int *); 2 int f1() 3 { 4 switch (0) { 5 int x; 6 default: 7 return g(&x); 8 } 9 } compiling with -O -ftrivial-auto-var-init causes spurious warning: warning: statement will never be executed [-Wswitch-unreachable] 5 | int x; | ^ This is due to the compiler-generated initialization at the point of the declaration. We could avoid the warning to exclude the following cases: when flag_auto_var_init > AUTO_INIT_UNINITIALIZED And 1) call to .DEFERRED_INIT 2) call to __builtin_clear_padding if the 2nd argument is present and non-zero 3) a gimple assign store right after the .DEFERRED_INIT call that has the LHS as RHS However, we still need to warn users about the incapability of the option -ftrivial-auto-var-init by adding a new warning option -Wtrivial-auto-var-init to report cases when it cannot initialize the auto variable. At the same time, update documentation for -ftrivial-auto-var-init to connect it with the new warning option -Wtrivial-auto-var-init, and add documentation for -Wtrivial-auto-var-init. gcc/ChangeLog: PR middle-end/102276 * common.opt (-Wtrivial-auto-var-init): New option. * doc/invoke.texi (-Wtrivial-auto-var-init): Document new option. (-ftrivial-auto-var-init): Update option; * gimplify.cc (emit_warn_switch_unreachable): New function. (warn_switch_unreachable_r): Rename to ... (warn_switch_unreachable_and_auto_init_r): This. (maybe_warn_switch_unreachable): Rename to ... (maybe_warn_switch_unreachable_and_auto_init): This. (gimplify_switch_expr): Update calls to renamed function. gcc/testsuite/ChangeLog: PR middle-end/102276 * gcc.dg/auto-init-pr102276-1.c: New test. * gcc.dg/auto-init-pr102276-2.c: New test. * gcc.dg/auto-init-pr102276-3.c: New test. * gcc.dg/auto-init-pr102276-4.c: New test.
-