aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/rustspec.cc
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-08-04 07:41:58 +0000
committerGitHub <noreply@github.com>2021-08-04 07:41:58 +0000
commit73271c4ce5d33fe51766ce9cc438cad764bf31c1 (patch)
tree1e8ea266706945f4a3ac816125eb48719ff6aea3 /gcc/rust/rustspec.cc
parentc707190b29e1e5b2d20fa9d68dcd7f043659aed4 (diff)
parent4292110a0aecd4ad3b48d16370c640679c3f2adf (diff)
downloadgcc-73271c4ce5d33fe51766ce9cc438cad764bf31c1.zip
gcc-73271c4ce5d33fe51766ce9cc438cad764bf31c1.tar.gz
gcc-73271c4ce5d33fe51766ce9cc438cad764bf31c1.tar.bz2
Merge #607
607: Remove split-stack from backend r=tschwinge a=dkm From Mark Wielaard : https://gcc.gnu.org/pipermail/gcc-rust/2021-August/000110.html > The backend was derived from the go backend which enables split stack > support by default. This inserts a __morestack call at the start of > each function. This is not needed for the rust backend. Remove the > split stack support code from the rust backend and spec. Co-authored-by: Mark Wielaard <mark@klomp.org>
Diffstat (limited to 'gcc/rust/rustspec.cc')
-rw-r--r--gcc/rust/rustspec.cc47
1 files changed, 0 insertions, 47 deletions
diff --git a/gcc/rust/rustspec.cc b/gcc/rust/rustspec.cc
index 28c2d9a..12ec874 100644
--- a/gcc/rust/rustspec.cc
+++ b/gcc/rust/rustspec.cc
@@ -104,9 +104,6 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
/* The total number of arguments with the new stuff. */
int num_args = 1;
- /* Supports split stack */
- int supports_split_stack = 0;
-
/* Whether the -o option was used. */
bool saw_opt_o = false;
@@ -118,11 +115,6 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
/* Whether the -S option was used. */
bool saw_opt_S = false;
-#ifdef TARGET_CAN_SPLIT_STACK_64BIT
- /* Whether the -m64 option is in force. */
- bool is_m64 = TARGET_CAN_SPLIT_STACK_64BIT;
-#endif
-
/* The first input file with an extension of .go. */
const char *first_go_file = NULL;
@@ -159,16 +151,6 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
library = (library == 0) ? 1 : library;
break;
-#ifdef TARGET_CAN_SPLIT_STACK_64BIT
- case OPT_m32:
- is_m64 = false;
- break;
-
- case OPT_m64:
- is_m64 = true;
- break;
-#endif
-
case OPT_pg:
case OPT_p:
saw_profile_flag = true;
@@ -253,23 +235,6 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
/* Copy the 0th argument, i.e., the name of the program itself. */
new_decoded_options[j++] = decoded_options[i++];
-#ifdef TARGET_CAN_SPLIT_STACK
- supports_split_stack = 1;
-#endif
-
-#ifdef TARGET_CAN_SPLIT_STACK_64BIT
- if (is_m64)
- supports_split_stack = 1;
-#endif
-
- /* If we are linking, pass -fsplit-stack if it is supported. */
- if ((library >= 0) && supports_split_stack)
- {
- generate_option (OPT_fsplit_stack, NULL, 1, CL_DRIVER,
- &new_decoded_options[j]);
- j++;
- }
-
/* NOTE: We start at 1 now, not 0. */
while (i < argc)
{
@@ -402,18 +367,6 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options,
generate_option (OPT_shared_libgcc, NULL, 1, CL_DRIVER,
&new_decoded_options[j++]);
- /* libgcc wraps pthread_create to support split stack, however, due to
- relative ordering of -lpthread and -lgcc, we can't just mark
- __real_pthread_create in libgcc as non-weak. But we need to link in
- pthread_create from pthread if we are statically linking, so we work-
- around by passing -u pthread_create to the linker. */
- if (static_link && supports_split_stack)
- {
- generate_option (OPT_Wl_, "-u,pthread_create", 1, CL_DRIVER,
- &new_decoded_options[j]);
- j++;
- }
-
#if defined(TARGET_SOLARIS) && !defined(USE_GLD)
/* We use a common symbol for go$zerovalue. On Solaris, when not
using the GNU linker, the Solaris linker needs an option to not