Skip to content

Synchronize development branch with GCC's master branch #3761

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 10,000 commits into
base: master
Choose a base branch
from

Conversation

dkm
Copy link
Member

@dkm dkm commented Apr 22, 2025

This branch has a no-op merge as the last commit:

  • one arm is the "current" development branch from github
  • the other arm is a rebased version of the "current" master branch onto a recent GCC's master

The merge is obtained with "git merge --strategy=ours" to only keep the changes from second arm.

@dkm dkm self-assigned this Apr 22, 2025
@dkm dkm marked this pull request as draft April 22, 2025 19:39
@dkm dkm force-pushed the dkm/master-rebased branch 2 times, most recently from 135065f to 64035a8 Compare April 28, 2025 20:07
@powerboat9
Copy link
Collaborator

powerboat9 commented Apr 28, 2025

Wouldn't it be easier to put commits adjusting the expected warnings after the merge commit? Doesn't really matter either way, of course.

@dkm dkm force-pushed the dkm/master-rebased branch from 64035a8 to 6036980 Compare April 29, 2025 17:15
jwakely and others added 2 commits April 29, 2025 19:54
…acro

This is a non-standard feature test macro only used internally, so use
the new no_stdname property for it.

libstdc++-v3/ChangeLog:

	* include/bits/version.def (make_obj_using_allocator): Use
	no_stdname.
	* include/bits/version.h: Regenerate.
In an earlier change, a wrapper function was added to set
CONSTRUCTOR_ZERO_PADDING_BITS on all CONSTRUCTOR nodes. This removes all
the old generated calls to built-in memset and memcpy as zero padding is
now taken care of by the middle-end.

The remaining constructors that weren't getting zero padded was
ARRAY_TYPEs, so now `__builtin_clear_padding' is used to fill in all
alignment holes in constructed array literals where required.

	PR d/103044

gcc/d/ChangeLog:

	* d-tree.h (build_clear_padding_call): New prototype.
	* d-codegen.cc (build_clear_padding_call): New function.
	(build_memset_call): Remove generated call to __builtin_memcpy.
	(build_address): Replace generated call to __builtin_memset with
	__builtin_clear_padding.
	(build_array_from_exprs): Likewise.
	* expr.cc (ExprVisitor::visit (AssignExp *)): Remove generated call to
	__builtin_memset.
	(ExprVisitor::visit (ArrayLiteralExp *)): Likewise.  Insert call to
	__builtin_clear_padding after copying array into GC memory.
	(ExprVisitor::visit (StructLiteralExp *)): Remove generated call to
	__builtin_memset.
	* toir.cc (IRVisitor::visit (ReturnStatement *)): Likewise.
@dkm dkm force-pushed the dkm/master-rebased branch from 6036980 to 4d700f0 Compare April 29, 2025 20:00
Having both an enum and a variable with the same name triggers an error with
gcc 5.

  exploded-graph.h:351:29: error: ‘status’ is not a class, namespace, or enumeration

gcc/analyzer/ChangeLog:
	* exploded-graph.h (set_status): Rename parameter.
	* constraint-manager.cc (bound::ensure_closed): Likewise.
	(range::add_bound): Likewise.

Signed-off-by: Marc Poulhiès <[email protected]>
Reviewed-by: David Malcolm <[email protected]>
Signed-off-by: Marc Poulhiès <[email protected]>
@dkm dkm force-pushed the dkm/master-rebased branch from 4d700f0 to e27c639 Compare April 29, 2025 20:40
As noticed by Martin Jambor, I introduced a bug while simplifying
cs_interesting_for_ipcp_p and reversed condition for
flag_profile_partial_training.  Also I noticed that we probably want to
consider calls with unintialized counts for cloning so the pass does somehting
with -fno-guess-branch-probability even thugh this is probably not very useful
in practice.

gcc/ChangeLog:

	* ipa-cp.cc (cs_interesting_for_ipcp_p): Fix handling of uninitialized
	counts and 0 IPA cost wrt flag_profile_partial_training.
@dkm dkm force-pushed the dkm/master-rebased branch from e27c639 to ae5132f Compare April 29, 2025 20:53
GCC Administrator and others added 17 commits April 30, 2025 00:18
…padwidth and maxwidth [PR109162]

The _Padding_sink was behaving incorrectly, when the predicted width (based on
code units count) was higher than _M_maxwidth, but lower than _M_padwidth.
In this case _M_update() returned without calling _M_force_update() and computing
field width for Unicode encoding, because _M_buffering() returned 'true'.
As a consequence we switched to _M_ignoring() mode, while storing a sequence
with more code units but smaller field width than _M_maxwidth.

We now call _M_force_update() if predicted width is greater or equal to either
_M_padwidth or _M_maxwidth.

This happened for existing test case on 32bit architecture.

	PR libstdc++/109162

libstdc++-v3/ChangeLog:

	* include/std/format (_Padding_sink::_M_update): Fixed condition for
	calling _M_force_update.
	* testsuite/std/format/debug.cc: Add test that reproduces this issue
	on 64bit architecture.
	* testsuite/std/format/ranges/sequence.cc: Another edge value test.
Adapt testsuite v3_target_compile to strip version namespace from compiler
output so that dg-error and dg-warning directives do not need to consider it.

Avoid a aligned_storage check as behavior has been fixed only when using
gnu-versioned-namespace as it is an abi breaking change.

libstdc++-v3/ChangeLog:

	* testsuite/lib/libstdc++.exp (v3_target_compile): Strip version namespace
	from compiler output.
	* testsuite/20_util/aligned_storage/value.cc [_GLIBCXX_INLINE_VERSION]:
	Avoid align_msa check.
	* testsuite/20_util/function/cons/70692.cc: Remove now useless __8 namespace
	pattern.
	* testsuite/23_containers/map/48101_neg.cc: Likewise.
	* testsuite/23_containers/multimap/48101_neg.cc: Likewise.

Co-authored-by: Jonathan Wakely <[email protected]>
[changelog]
	PR ada/112958
	* init.c (__gnat_error_handler) [__FreeBSD__]: Fix typo.
This version is same as v5, but rebase to trunk, send out to trigger CI.

This commit adds intrinsics support for Xsfvcp extension.
Diff with V4: Delete the sifive_vector.h file.

Co-Authored by: Jiawei Chen <[email protected]>
Co-Authored by: Shihua Liao <[email protected]>
Co-Authored by: Yixuan Chen <[email protected]>

gcc/ChangeLog:

	* config/riscv/constraints.md (Ou01): New constraint.
	(Ou02): Ditto.
	* config/riscv/generic-vector-ooo.md (vec_sf_vcp): New reservation.
	* config/riscv/genrvv-type-indexer.cc (main): New type.
	* config/riscv/riscv-c.cc (riscv_pragma_intrinsic): Add xsfvcp strings.
	* config/riscv/riscv-vector-builtins-shapes.cc (struct sf_vcix_se_def):
	New function.
	(struct sf_vcix_def): Ditto.
	(SHAPE): Ditto.
	* config/riscv/riscv-vector-builtins-shapes.h: Ditto.
	* config/riscv/riscv-vector-builtins-types.def (DEF_RVV_X2_U_OPS): New type.
	(DEF_RVV_X2_WU_OPS): Ditto.
	(vuint8mf8_t): Ditto.
	(vuint8mf4_t): Ditto.
	(vuint8mf2_t): Ditto.
	(vuint8m1_t): Ditto.
	(vuint8m2_t): Ditto.
	(vuint8m4_t): Ditto.
	(vuint16mf4_t): Ditto.
	(vuint16mf2_t): Ditto.
	(vuint16m1_t): Ditto.
	(vuint16m2_t): Ditto.
	(vuint16m4_t): Ditto.
	(vuint32mf2_t): Ditto.
	(vuint32m1_t): Ditto.
	(vuint32m2_t): Ditto.
	(vuint32m4_t): Ditto.
	* config/riscv/riscv-vector-builtins.cc (DEF_RVV_X2_U_OPS): New builtins
	def.
	(DEF_RVV_X2_WU_OPS): Ditto.
	(rvv_arg_type_info::get_scalar_float_type): Ditto.
	(function_instance::modifies_global_state_p): Ditto.
	* config/riscv/riscv-vector-builtins.def (v_x): New base type.
	(i): Ditto.
	(v_i): Ditto.
	(xv): Ditto.
	(iv): Ditto.
	(fv): Ditto.
	(vvv): Ditto.
	(xvv): Ditto.
	(ivv): Ditto.
	(fvv): Ditto.
	(vvw): Ditto.
	(xvw): Ditto.
	(ivw): Ditto.
	(fvw): Ditto.
	(v_vv): Ditto.
	(v_xv): Ditto.
	(v_iv): Ditto.
	(v_fv): Ditto.
	(v_vvv): Ditto.
	(v_xvv): Ditto.
	(v_ivv): Ditto.
	(v_fvv): Ditto.
	(v_vvw): Ditto.
	(v_xvw): Ditto.
	(v_ivw): Ditto.
	(v_fvw): Ditto.
	(x2_vector): Ditto.
	(scalar_float): Ditto.
	* config/riscv/riscv-vector-builtins.h (enum required_ext): New extension.
	(required_ext_to_isa_name): Ditto.
	(required_extensions_specified): Ditto.
	(struct rvv_arg_type_info): Ditto.
	(struct function_group_info): Ditto.
	* config/riscv/riscv.md: New attr.
	* config/riscv/sifive-vector-builtins-bases.cc (class sf_vc): New function.
	(BASE): New base_name.
	* config/riscv/sifive-vector-builtins-bases.h: New function_base.
	* config/riscv/sifive-vector-builtins-functions.def
	(REQUIRED_EXTENSIONS): New intrinsics def.
	(sf_vc): Ditto.
	* config/riscv/sifive-vector.md (@sf_vc_x_se<mode>): New RTL mode.
	(@sf_vc_v_x_se<mode>): Ditto.
	(@sf_vc_v_x<mode>): Ditto.
	(@sf_vc_i_se<mode>): Ditto.
	(@sf_vc_v_i_se<mode>): Ditto.
	(@sf_vc_v_i<mode>): Ditto.
	(@sf_vc_vv_se<mode>): Ditto.
	(@sf_vc_v_vv_se<mode>): Ditto.
	(@sf_vc_v_vv<mode>): Ditto.
	(@sf_vc_xv_se<mode>): Ditto.
	(@sf_vc_v_xv_se<mode>): Ditto.
	(@sf_vc_v_xv<mode>): Ditto.
	(@sf_vc_iv_se<mode>): Ditto.
	(@sf_vc_v_iv_se<mode>): Ditto.
	(@sf_vc_v_iv<mode>): Ditto.
	(@sf_vc_fv_se<mode>): Ditto.
	(@sf_vc_v_fv_se<mode>): Ditto.
	(@sf_vc_v_fv<mode>): Ditto.
	(@sf_vc_vvv_se<mode>): Ditto.
	(@sf_vc_v_vvv_se<mode>): Ditto.
	(@sf_vc_v_vvv<mode>): Ditto.
	(@sf_vc_xvv_se<mode>): Ditto.
	(@sf_vc_v_xvv_se<mode>): Ditto.
	(@sf_vc_v_xvv<mode>): Ditto.
	(@sf_vc_ivv_se<mode>): Ditto.
	(@sf_vc_v_ivv_se<mode>): Ditto.
	(@sf_vc_v_ivv<mode>): Ditto.
	(@sf_vc_fvv_se<mode>): Ditto.
	(@sf_vc_v_fvv_se<mode>): Ditto.
	(@sf_vc_v_fvv<mode>): Ditto.
	(@sf_vc_vvw_se<mode>): Ditto.
	(@sf_vc_v_vvw_se<mode>): Ditto.
	(@sf_vc_v_vvw<mode>): Ditto.
	(@sf_vc_xvw_se<mode>): Ditto.
	(@sf_vc_v_xvw_se<mode>): Ditto.
	(@sf_vc_v_xvw<mode>): Ditto.
	(@sf_vc_ivw_se<mode>): Ditto.
	(@sf_vc_v_ivw_se<mode>): Ditto.
	(@sf_vc_v_ivw<mode>): Ditto.
	(@sf_vc_fvw_se<mode>): Ditto.
	(@sf_vc_v_fvw_se<mode>): Ditto.
	(@sf_vc_v_fvw<mode>): Ditto.
	* config/riscv/vector-iterators.md: New iterator.
	* config/riscv/vector.md: New vtype.
This commit adds testcases for Xsfvcp.

Co-Authored by: Jiawei Chen <[email protected]>
Co-Authored by: Shihua Liao <[email protected]>
Co-Authored by: Yixuan Chen <[email protected]>

gcc/testsuite/ChangeLog:

	* gcc.target/riscv/rvv/xsfvector/sf_vc_f.c: New test.
	* gcc.target/riscv/rvv/xsfvector/sf_vc_i.c: New test.
	* gcc.target/riscv/rvv/xsfvector/sf_vc_v.c: New test.
	* gcc.target/riscv/rvv/xsfvector/sf_vc_x.c: New test.
If -msve-vector-bits=128, SVE loads and stores (LD1 and ST1) with a
ptrue predicate can be replaced by neon instructions (LDR and STR),
thus avoiding the predicate altogether. This also enables formation of
LDP/STP pairs.

For example, the test cases

svfloat64_t
ptrue_load (float64_t *x)
{
  svbool_t pg = svptrue_b64 ();
  return svld1_f64 (pg, x);
}
void
ptrue_store (float64_t *x, svfloat64_t data)
{
  svbool_t pg = svptrue_b64 ();
  return svst1_f64 (pg, x, data);
}

were previously compiled to
(with -O2 -march=armv8.2-a+sve -msve-vector-bits=128):

ptrue_load:
        ptrue   p3.b, vl16
        ld1d    z0.d, p3/z, [x0]
        ret
ptrue_store:
        ptrue   p3.b, vl16
        st1d    z0.d, p3, [x0]
        ret

Now the are compiled to:

ptrue_load:
        ldr     q0, [x0]
        ret
ptrue_store:
        str     q0, [x0]
        ret

The implementation includes the if-statement
if (known_eq (GET_MODE_SIZE (mode), 16)
    && aarch64_classify_vector_mode (mode) == VEC_SVE_DATA)
which checks for 128-bit VLS and excludes partial modes with a
mode size < 128 (e.g. VNx2QI).

The patch was bootstrapped and tested on aarch64-linux-gnu, no regression.
OK for mainline?

Signed-off-by: Jennifer Schmitz <[email protected]>

gcc/
	* config/aarch64/aarch64.cc (aarch64_emit_sve_pred_move):
	Fold LD1/ST1 with ptrue to LDR/STR for 128-bit VLS.

gcc/testsuite/
	* gcc.target/aarch64/sve/ldst_ptrue_128_to_neon.c: New test.
	* gcc.target/aarch64/sve/cond_arith_6.c: Adjust expected outcome.
	* gcc.target/aarch64/sve/pcs/return_4_128.c: Likewise.
	* gcc.target/aarch64/sve/pcs/return_5_128.c: Likewise.
	* gcc.target/aarch64/sve/pcs/struct_3_128.c: Likewise.
The Zve32x extension depends on the Zicsr extension.
Currently, enabling Zve32x alone does not automatically imply Zicsr in GCC.

gcc/ChangeLog:

	* common/config/riscv/riscv-common.cc: Add Zve32x depends on Zicsr

gcc/testsuite/ChangeLog:

	* gcc.target/riscv/predef-19.c: set the march to rv64im_zve32x
	instead of rv64gc_zve32x to avoid Zicsr implied by g. Extra m is
	added to avoid current 'V' extension requires 'M' extension

Signed-off-by: Jerry Zhang Jian <[email protected]>
…19832]

Although we already try to set the mode needed to FRM_DYN after a function call,
there are still some corner cases where both FRM_DYN and FRM_DYN_CALL may appear
on incoming edges.

Therefore, we use TARGET_MODE_CONFLUENCE to tell GCC that FRM_DYN, FRM_DYN_CALL,
and FRM_DYN_EXIT modes are compatible.

gcc/ChangeLog:

	PR target/119832
	* config/riscv/riscv.cc (riscv_dynamic_frm_mode_p): New.
	(riscv_mode_confluence): New.
	(TARGET_MODE_CONFLUENCE): Define to riscv_mode_confluence.

gcc/testsuite/ChangeLog:

	PR target/119832
	* g++.target/riscv/pr119832.C: New test.
libgcc's __xload_1...4 is clobbering Z (and also R21 is some cases),
but avr.md had clobbers of respective GPRs only up to reload.
Outcome was that code reading from the same __memx address twice
could be wrong.  This patch adds respective clobbers.

      Forward-port from 2025-04-30 r14-11703
      PR target/119989
gcc/
	* config/avr/avr.md (xload_<mode>_libgcc): Clobber R21, Z.

gcc/testsuite/
	* gcc.target/avr/torture/pr119989.h: New file.
	* gcc.target/avr/torture/pr119989-memx-1.c: New test.
	* gcc.target/avr/torture/pr119989-memx-2.c: New test.
	* gcc.target/avr/torture/pr119989-memx-3.c: New test.
	* gcc.target/avr/torture/pr119989-memx-4.c: New test.
	* gcc.target/avr/torture/pr119989-flashx-1.c: New test.
	* gcc.target/avr/torture/pr119989-flashx-2.c: New test.
	* gcc.target/avr/torture/pr119989-flashx-3.c: New test.
	* gcc.target/avr/torture/pr119989-flashx-4.c: New test.

(cherry picked from commit 1ca1c1fc3b58ae5e1d3db4f5a2014132fe69f82a)
gcc/ada/
	PR ada/112958
	* Makefile.rtl (LIBGNAT_TARGET_PAIRS) [x86 FreeBSD]: Add specific
	version of s-dorepr.adb.
	* libgnat/s-dorepr__freebsd.adb: New file.
The following allows the entry and exit block of a jump thread path
to be equal, which can easily happen when there isn't a forwarder
on the interesting edge for an FSM thread conditional.  We just
don't want to enlarge the path from such a block.

	PR tree-optimization/120003
	* tree-ssa-threadbackward.cc (back_threader::find_paths_to_names):
	Allow block re-use but do not enlarge the path beyond such a
	re-use.

	* gcc.dg/tree-ssa/ssa-thread-23.c: New testcase.
	* gcc.dg/tree-ssa/ssa-dom-thread-7.c: Adjust.
When PTA gets support for special-handling more builtins in
find_func_aliases the corresponding code in find_func_clobbers
needs updating as well since for unhandled cases it assumes
the former will populate ESCAPED accordingly.  The following
fixes a few omissions, the testcase runs into the missing strdup
handling.  I believe the more advanced handling using modref
results and fnspecs opened a larger gap, the proper fix is to
merge both functions, gating the clobber/use part on a parameter
to avoid diverging.

	PR ipa/120006
	* tree-ssa-structalias.cc (find_func_clobbers): Handle
	strdup, strndup, realloc, index, strchr, strrchr, memchr,
	strstr, strpbrk builtins like find_func_aliases does.

	* gcc.dg/torture/pr120006.c: New testcase.
The following addresses a too conservative sanity check of SLP nodes
we want to promote external.  The issue lies in code generation
for such external which relies on get_later_stmt to figure an
insert location.  But get_later_stmt relies on the ability to
totally order stmts, specifically implementation-wise that they
are all from the same BB, which is what is verified at the moment.

The patch changes this to require stmts to be orderable by
dominance queries.  For simplicity and seemingly enough for the
testcase in PR119960, this handles the case of two distinct BBs.

	PR tree-optimization/119960
	* tree-vect-slp.cc (vect_slp_can_convert_to_external):
	Handle cases where defs from multiple BBs are ordered
	by their dominance relation.

	* gcc.dg/vect/bb-slp-pr119960-1.c: New testcase.
The following makes get_later_stmt handle stmts from different
basic-blocks in the case they are orderd and otherwise asserts.

	* tree-vectorizer.h (get_later_stmt): Robustify against
	stmts in different BBs, assert when they are unordered.
The following adds checks that when we search for a vector stmt
insert location we arrive at one where all required operand defs
are dominating the insert location.  At the moment any such
failure only blows up during SSA verification.

There's the long-standing issue that we do not verify there
exists a valid schedule of the SLP graph from BB vectorization
into the existing CFG.  We do not have the ability to insert
vector stmts on the dominance frontier "end", nor to insert
LC PHIs that would be eventually required.

This should be done all differently, computing the schedule
during analysis and failing if we can't schedule.

	PR tree-optimization/119960
	* tree-vect-slp.cc (vect_schedule_slp_node): Sanity
	check dominance check on operand defs.
badumbatish and others added 29 commits May 5, 2025 21:13
ChangeLog:

	* .github/workflows/ccpp.yml:
	Add glibcxx_assertion check

	* .github/glibcxx_ubuntu64b_log_expected_warnings: New file.
ChangeLog:

	* .github/workflows/clang-format.yml: Bump action version to 18.2

Signed-off-by: Pierre-Emmanuel Patry <[email protected]>
ChangeLog:

	* .github/workflows/ccpp.yml: Add job for running tests with
	ASAN.
	* .github/no-bootstrap-asan.mk: New file.

Signed-off-by: Owen Avery <[email protected]>
Add the "Tested-by" prefix to the list of already matched footer
prefixes.
Adjust the error message.
This avoid warnings on commits using it.

Signed-off-by: Marc Poulhiès <[email protected]>
Version 2 of this github action has been deprecated, we shall bump the
version used in the CI.

ChangeLog:

	* .github/workflows/bootstrap.yml: Bump version from 2 to 4.

Signed-off-by: Pierre-Emmanuel Patry <[email protected]>
ChangeLog:

	* .github/alpine_32bit_log_warnings: Adjust.

Signed-off-by: Owen Avery <[email protected]>
ChangeLog:

	* .github/alpine_32bit_log_warnings: Update alpine warning list.

Signed-off-by: Pierre-Emmanuel Patry <[email protected]>
ChangeLog:

	* .github/workflows/ccpp.yml: Make files outside the build
	directory read-only.

Signed-off-by: Owen Avery <[email protected]>
Issue references shall now be used with the Rust GCC prefix in order to
avoid mixing gccrs issues and GCC bugzilla PRs.

ChangeLog:

	* .github/workflows/commit-format.yml: Add a new step to detect issue
	references in commit messages.

Signed-off-by: Pierre-Emmanuel Patry <[email protected]>
We are using github merge queues for some time now, instead of bors.
Remove unmaintained files, and remove bors mentions.

ChangeLog:

	* .github/bors_log_expected_warnings: Move to...
	* .github/log_expected_warnings: ...here.
	* .github/workflows/ccpp.yml:
	* .github/workflows/ccpp32alpine.yml:
	* CONTRIBUTING.md:
	* README.md:
	* .github/bors.toml: Removed.

Signed-off-by: Marc Poulhiès <[email protected]>
GCC's baseline was changed from C++11 -> C++14 and GCC 4.8 -> GCC 5.4
in r15-4719-ga9ec1bc06bd3cc, so adjust the baseline CI job accordingly.

One quirk here is that the Ubuntu image we're using in CI has 5.5.0
rather than 5.4.0. But I think we can eat that difference.

ChangeLog:
	* .github/workflows/ccpp.yml: Use GCC 5.5 instead of GCC 4.8.
ChangeLog:

	* .github/workflows/Remark.yml: Use v4.
	* .github/workflows/bootstrap.yml: Likewise.
	* .github/workflows/ccpp.yml: Likewise.
	* .github/workflows/ccpp32alpine.yml: Likewise.
	* .github/workflows/clang-format.yml: Likewise.
	* .github/workflows/commit-format.yml: Likewise.
	* .github/workflows/docker.yml: Likewise.

Signed-off-by: Marc Poulhiès <[email protected]>
Use a GCC 5.4.0 built from Compiler Explorer and execute everything on
ubuntu 22.04.
Use the caching framework provided by github to avoid downloading every
time from Compiler Explorer's servers.

ChangeLog:

	* .github/workflows/ccpp.yml: Adjust to use gcc-5 on ubuntu 22.04.

Signed-off-by: Marc Poulhiès <[email protected]>
ChangeLog:

	* README.md: Add fedora deps.

Signed-off-by: Jarkko Sakkinen <[email protected]>
ChangeLog:

	* .github/alpine_32bit_log_warnings: Update with new warnings.
ChangeLog:
	* .github/glibcxx_ubuntu64b_log_expected_warnings: Update.
	* .github/log_expected_warnings: Update.
Its broken at the moment.

ChangeLog:

	* .github/workflows/ccpp.yml: comment it out

Signed-off-by: Philip Herron <[email protected]>
ChangeLog:

	* .github/workflows/ccpp.yml: Update actions/upload-artifact
	from v3 to v4, handle any artifact name conflicts.
	* .github/workflows/ccpp32alpine.yml: Likewise.

Signed-off-by: Owen Avery <[email protected]>
Disable network access via 'unshare' in two CI workflows to catch issues
like PR119333 where importing polonius meant bootstrap tried to pull crates
from the internet.

ChangeLog:
	PR rust/119333

	* .github/workflows/bootstrap.yml: Disable network via 'unshare'.
	* .github/workflows/ccpp.yml: Ditto.
ChangeLog:

	* .github/glibcxx_ubuntu64b_log_expected_warnings: Change line number
	for warning from 2230 to 2236.
	* .github/log_expected_warnings: Likewise.
gcc/rust/ChangeLog:

	* resolve/rust-late-name-resolver-2.0.cc (Late::Late): False initialize the
	funny_error field.
gcc/rust/ChangeLog:

	* backend/rust-compile-pattern.h: Split struct pattern compilation into three functions.
	* backend/rust-compile-pattern.cc: Implement them.
Allow matching on a struct instance and rebinding its fields to new names:

match X {
	Foo {
		field0: new_name0,
		field1: new_name1,
	} => {
		do_something(new_name0, new_name1);
	},
}

This will enable us to finish derives for PartialEq and PartialOrd but
isn't a complete implementation of these patterns yet.

gcc/rust/ChangeLog:

	* backend/rust-compile-pattern.cc (CompilePatternBindings::make_struct_access):
	New function.
	(CompilePatternBindings::visit): Properly implement patterns mentioned above
	and call make_struct_accesss.
	* backend/rust-compile-pattern.h: New declaration.

gcc/testsuite/ChangeLog:

	* rust/execute/torture/struct_pattern1.rs: New test.
gcc/rust/ChangeLog:

	* backend/rust-compile-pattern.cc (CompilePatternCheckExpr::visit): Remove old invalid
	checks.
gcc/rust/ChangeLog:

	* ast/rust-ast-builder.cc (Builder::struct_pattern_ident_pattern): New.
	* ast/rust-ast-builder.h: New declaration.
gcc/rust/ChangeLog:

	* expand/rust-derive-partial-eq.cc (DerivePartialEq::match_enum_tuple): Remove debug call.
	(DerivePartialEq::match_enum_struct): Add proper implementation.
	(DerivePartialEq::visit_enum): Call it.

gcc/testsuite/ChangeLog:

	* rust/execute/torture/derive-partialeq2.rs: New test.
gcc/testsuite/ChangeLog:

	* rust/execute/torture/derive-partialeq2.rs: Add missing terminating nul char.

Co-authored-by: Pierre-Emmanuel Patry <[email protected]>
…rebased

This branch has a no-op merge as the last commit:

 - one arm is the "current" development branch from github
 - the other arm is a rebased version of the "current" master branch onto a recent GCC's master

The merge is obtained with "git merge --strategy=ours" to only keep the changes from second arm.
@dkm dkm force-pushed the dkm/master-rebased branch from ae5132f to e57faeb Compare May 5, 2025 20:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.