diff --git a/toolchain/gcc/patches-13.x/110-Fix-MIPS-PR-84790.patch b/toolchain/gcc/patches-13.x/110-Fix-MIPS-PR-84790.patch deleted file mode 100644 index 856fd6a46c..0000000000 --- a/toolchain/gcc/patches-13.x/110-Fix-MIPS-PR-84790.patch +++ /dev/null @@ -1,20 +0,0 @@ -Fix https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84790. -MIPS16 functions have a static assembler prologue which clobbers -registers v0 and v1. Add these register clobbers to function call -instructions. - ---- a/gcc/config/mips/mips.cc -+++ b/gcc/config/mips/mips.cc -@@ -3134,6 +3134,12 @@ mips_emit_call_insn (rtx pattern, rtx or - emit_insn (gen_update_got_version ()); - } - -+ if (TARGET_MIPS16 && TARGET_USE_GOT) -+ { -+ clobber_reg (&CALL_INSN_FUNCTION_USAGE (insn), MIPS16_PIC_TEMP); -+ clobber_reg (&CALL_INSN_FUNCTION_USAGE (insn), MIPS_PROLOGUE_TEMP (word_mode)); -+ } -+ - if (TARGET_MIPS16 - && TARGET_EXPLICIT_RELOCS - && TARGET_CALL_CLOBBERED_GP) diff --git a/toolchain/gcc/patches-13.x/300-mips_Os_cpu_rtx_cost_model.patch b/toolchain/gcc/patches-13.x/300-mips_Os_cpu_rtx_cost_model.patch index 87a3cab838..3a6d536fbc 100644 --- a/toolchain/gcc/patches-13.x/300-mips_Os_cpu_rtx_cost_model.patch +++ b/toolchain/gcc/patches-13.x/300-mips_Os_cpu_rtx_cost_model.patch @@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau --- a/gcc/config/mips/mips.cc +++ b/gcc/config/mips/mips.cc -@@ -20228,7 +20228,7 @@ mips_option_override (void) +@@ -20222,7 +20222,7 @@ mips_option_override (void) flag_pcc_struct_return = 0; /* Decide which rtx_costs structure to use. */ diff --git a/toolchain/gcc/patches-14.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch b/toolchain/gcc/patches-14.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch index da355535c3..db25be919a 100644 --- a/toolchain/gcc/patches-14.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch +++ b/toolchain/gcc/patches-14.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch @@ -31,8 +31,6 @@ the u8 literals everywhere are worth it either. libcody/server.cc | 28 ++++++++++++++-------------- 3 files changed, 55 insertions(+), 31 deletions(-) -diff --git a/libcody/client.cc b/libcody/client.cc -index ae69d190cb7..147fecdbe50 100644 --- a/libcody/client.cc +++ b/libcody/client.cc @@ -97,7 +97,7 @@ int Client::CommunicateWithServer () @@ -44,7 +42,7 @@ index ae69d190cb7..147fecdbe50 100644 e.append (strerror (err)); return Packet (Client::PC_ERROR, std::move (e)); -@@ -110,33 +110,34 @@ Packet Client::ProcessResponse (std::vector &words, +@@ -110,33 +110,34 @@ Packet Client::ProcessResponse (std::vec { if (e == EINVAL) { @@ -87,7 +85,7 @@ index ae69d190cb7..147fecdbe50 100644 result.GetString () = std::move (msg); } else if (result.GetCode () == Client::PC_CONNECT) -@@ -199,7 +200,7 @@ Packet Client::Connect (char const *agent, char const *ident, +@@ -199,7 +200,7 @@ Packet Client::Connect (char const *agen size_t alen, size_t ilen) { write.BeginLine (); @@ -96,7 +94,7 @@ index ae69d190cb7..147fecdbe50 100644 write.AppendInteger (Version); write.AppendWord (agent, true, alen); write.AppendWord (ident, true, ilen); -@@ -211,7 +212,8 @@ Packet Client::Connect (char const *agent, char const *ident, +@@ -211,7 +212,8 @@ Packet Client::Connect (char const *agen // HELLO $version $agent [$flags] Packet ConnectResponse (std::vector &words) { @@ -115,7 +113,7 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_PATHNAME, std::move (words[1])); return Packet (Client::PC_ERROR, u8""); -@@ -256,7 +258,7 @@ Packet PathnameResponse (std::vector &words) +@@ -256,7 +258,7 @@ Packet PathnameResponse (std::vector &words) { @@ -124,7 +122,7 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_OK); else return Packet (Client::PC_ERROR, -@@ -319,11 +321,11 @@ Packet Client::IncludeTranslate (char const *include, Flags flags, size_t ilen) +@@ -319,11 +321,11 @@ Packet Client::IncludeTranslate (char co // PATHNAME $cmifile Packet IncludeTranslateResponse (std::vector &words) { @@ -140,8 +138,6 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_BOOL, 1); else return Packet (Client::PC_ERROR, u8""); -diff --git a/libcody/cody.hh b/libcody/cody.hh -index 789ce9e70b7..93bce93aa94 100644 --- a/libcody/cody.hh +++ b/libcody/cody.hh @@ -47,12 +47,21 @@ namespace Detail { @@ -193,8 +189,6 @@ index 789ce9e70b7..93bce93aa94 100644 Packet (unsigned c, std::vector &&v) : vector (std::move (v)), cat (VECTOR), code (c) { -diff --git a/libcody/server.cc b/libcody/server.cc -index e2fa069bb93..c18469fae84 100644 --- a/libcody/server.cc +++ b/libcody/server.cc @@ -36,12 +36,12 @@ static RequestPair @@ -245,7 +239,7 @@ index e2fa069bb93..c18469fae84 100644 msg.append (strerror (err)); } resolver->ErrorResponse (this, std::move (msg)); -@@ -176,7 +176,7 @@ Resolver *ConnectRequest (Server *s, Resolver *r, +@@ -176,7 +176,7 @@ Resolver *ConnectRequest (Server *s, Res return nullptr; if (words.size () == 3) @@ -254,6 +248,3 @@ index e2fa069bb93..c18469fae84 100644 unsigned version = ParseUnsigned (words[1]); if (version == ~0u) return nullptr; --- -2.53.0 - diff --git a/toolchain/gcc/patches-15.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch b/toolchain/gcc/patches-15.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch index da355535c3..db25be919a 100644 --- a/toolchain/gcc/patches-15.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch +++ b/toolchain/gcc/patches-15.x/004-libcody-Make-it-buildable-by-C-11-to-C-26.patch @@ -31,8 +31,6 @@ the u8 literals everywhere are worth it either. libcody/server.cc | 28 ++++++++++++++-------------- 3 files changed, 55 insertions(+), 31 deletions(-) -diff --git a/libcody/client.cc b/libcody/client.cc -index ae69d190cb7..147fecdbe50 100644 --- a/libcody/client.cc +++ b/libcody/client.cc @@ -97,7 +97,7 @@ int Client::CommunicateWithServer () @@ -44,7 +42,7 @@ index ae69d190cb7..147fecdbe50 100644 e.append (strerror (err)); return Packet (Client::PC_ERROR, std::move (e)); -@@ -110,33 +110,34 @@ Packet Client::ProcessResponse (std::vector &words, +@@ -110,33 +110,34 @@ Packet Client::ProcessResponse (std::vec { if (e == EINVAL) { @@ -87,7 +85,7 @@ index ae69d190cb7..147fecdbe50 100644 result.GetString () = std::move (msg); } else if (result.GetCode () == Client::PC_CONNECT) -@@ -199,7 +200,7 @@ Packet Client::Connect (char const *agent, char const *ident, +@@ -199,7 +200,7 @@ Packet Client::Connect (char const *agen size_t alen, size_t ilen) { write.BeginLine (); @@ -96,7 +94,7 @@ index ae69d190cb7..147fecdbe50 100644 write.AppendInteger (Version); write.AppendWord (agent, true, alen); write.AppendWord (ident, true, ilen); -@@ -211,7 +212,8 @@ Packet Client::Connect (char const *agent, char const *ident, +@@ -211,7 +212,8 @@ Packet Client::Connect (char const *agen // HELLO $version $agent [$flags] Packet ConnectResponse (std::vector &words) { @@ -115,7 +113,7 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_PATHNAME, std::move (words[1])); return Packet (Client::PC_ERROR, u8""); -@@ -256,7 +258,7 @@ Packet PathnameResponse (std::vector &words) +@@ -256,7 +258,7 @@ Packet PathnameResponse (std::vector &words) { @@ -124,7 +122,7 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_OK); else return Packet (Client::PC_ERROR, -@@ -319,11 +321,11 @@ Packet Client::IncludeTranslate (char const *include, Flags flags, size_t ilen) +@@ -319,11 +321,11 @@ Packet Client::IncludeTranslate (char co // PATHNAME $cmifile Packet IncludeTranslateResponse (std::vector &words) { @@ -140,8 +138,6 @@ index ae69d190cb7..147fecdbe50 100644 return Packet (Client::PC_BOOL, 1); else return Packet (Client::PC_ERROR, u8""); -diff --git a/libcody/cody.hh b/libcody/cody.hh -index 789ce9e70b7..93bce93aa94 100644 --- a/libcody/cody.hh +++ b/libcody/cody.hh @@ -47,12 +47,21 @@ namespace Detail { @@ -193,8 +189,6 @@ index 789ce9e70b7..93bce93aa94 100644 Packet (unsigned c, std::vector &&v) : vector (std::move (v)), cat (VECTOR), code (c) { -diff --git a/libcody/server.cc b/libcody/server.cc -index e2fa069bb93..c18469fae84 100644 --- a/libcody/server.cc +++ b/libcody/server.cc @@ -36,12 +36,12 @@ static RequestPair @@ -245,7 +239,7 @@ index e2fa069bb93..c18469fae84 100644 msg.append (strerror (err)); } resolver->ErrorResponse (this, std::move (msg)); -@@ -176,7 +176,7 @@ Resolver *ConnectRequest (Server *s, Resolver *r, +@@ -176,7 +176,7 @@ Resolver *ConnectRequest (Server *s, Res return nullptr; if (words.size () == 3) @@ -254,6 +248,3 @@ index e2fa069bb93..c18469fae84 100644 unsigned version = ParseUnsigned (words[1]); if (version == ~0u) return nullptr; --- -2.53.0 - diff --git a/toolchain/gcc/patches-15.x/110-Fix-MIPS-PR-84790.patch b/toolchain/gcc/patches-15.x/110-Fix-MIPS-PR-84790.patch deleted file mode 100644 index ea8625eca2..0000000000 --- a/toolchain/gcc/patches-15.x/110-Fix-MIPS-PR-84790.patch +++ /dev/null @@ -1,20 +0,0 @@ -Fix https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84790. -MIPS16 functions have a static assembler prologue which clobbers -registers v0 and v1. Add these register clobbers to function call -instructions. - ---- a/gcc/config/mips/mips.cc -+++ b/gcc/config/mips/mips.cc -@@ -3293,6 +3293,12 @@ mips_emit_call_insn (rtx pattern, rtx or - emit_insn (gen_update_got_version ()); - } - -+ if (TARGET_MIPS16 && TARGET_USE_GOT) -+ { -+ clobber_reg (&CALL_INSN_FUNCTION_USAGE (insn), MIPS16_PIC_TEMP); -+ clobber_reg (&CALL_INSN_FUNCTION_USAGE (insn), MIPS_PROLOGUE_TEMP (word_mode)); -+ } -+ - if (TARGET_MIPS16 - && TARGET_EXPLICIT_RELOCS - && TARGET_CALL_CLOBBERED_GP) diff --git a/toolchain/gcc/patches-15.x/300-mips_Os_cpu_rtx_cost_model.patch b/toolchain/gcc/patches-15.x/300-mips_Os_cpu_rtx_cost_model.patch index fe9e69b35a..27b9657a63 100644 --- a/toolchain/gcc/patches-15.x/300-mips_Os_cpu_rtx_cost_model.patch +++ b/toolchain/gcc/patches-15.x/300-mips_Os_cpu_rtx_cost_model.patch @@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau --- a/gcc/config/mips/mips.cc +++ b/gcc/config/mips/mips.cc -@@ -20605,7 +20605,7 @@ mips_option_override (void) +@@ -20599,7 +20599,7 @@ mips_option_override (void) flag_pcc_struct_return = 0; /* Decide which rtx_costs structure to use. */