diff options
Diffstat (limited to 'meta/recipes-devtools/gcc/gcc-4.7/ppc_no_crtsavres.patch')
-rw-r--r-- | meta/recipes-devtools/gcc/gcc-4.7/ppc_no_crtsavres.patch | 72 |
1 files changed, 0 insertions, 72 deletions
diff --git a/meta/recipes-devtools/gcc/gcc-4.7/ppc_no_crtsavres.patch b/meta/recipes-devtools/gcc/gcc-4.7/ppc_no_crtsavres.patch deleted file mode 100644 index 92a5d9e176..0000000000 --- a/meta/recipes-devtools/gcc/gcc-4.7/ppc_no_crtsavres.patch +++ /dev/null | |||
@@ -1,72 +0,0 @@ | |||
1 | Upstream-Status: Backport | ||
2 | |||
3 | Signed-off-by: Khem Raj | ||
4 | |||
5 | Source-url: http://gcc.gnu.org/ml/gcc-patches/2012-05/msg01362.html | ||
6 | |||
7 | Currently, powerpc-linux gcc -Os -mno-multiple uses out-of-linux gpr | ||
8 | save and restore functions when saving/restoring just one gpr. That's | ||
9 | quite silly since the function call requires more instructions and is | ||
10 | slower than an inline save/restore. The only case where it might win | ||
11 | is when no fprs are restored and the restore function can tear down | ||
12 | the frame and exit (also loading up lr on ppc64). I guess that's how | ||
13 | GP_SAVE_INLINE came to be like it is, ie. it's optimised for the | ||
14 | common case using ldm in the prologue and no fprs. Still, it isn't | ||
15 | difficult to choose the best combination in all cases, but it does | ||
16 | mean different logic is needed for restores. I could have implemented | ||
17 | GP_RESTORE_INLINE and FP_RESORE_INLINE macros but it seemed simpler to | ||
18 | just move everything into the one place the macros are invoked. AIX | ||
19 | and Darwin register cutoff doesn't change with this patch. | ||
20 | |||
21 | This patch also enables out-of-line restores in cases that were | ||
22 | previously disabled due to using inline saves. | ||
23 | |||
24 | Bootstrapped and regression tested powerpc-linux. OK to apply? | ||
25 | |||
26 | * aix.h (FP_SAVE_INLINE, GP_SAVE_INLINE): Delete. | ||
27 | * darwin.h (FP_SAVE_INLINE, GP_SAVE_INLINE): Delete. | ||
28 | * sysv4.h (FP_SAVE_INLINE, GP_SAVE_INLINE, V_SAVE_INLINE): Delete. | ||
29 | * config/rs6000/rs6000.c (V_SAVE_INLINE): Delete. | ||
30 | (rs6000_savres_strategy): Reimplement GP/FP/V_SAVE_INLINE logic. | ||
31 | For ELF targets, use out-of-line restores for -Os and any number | ||
32 | of regs if the restore exits, and out-of-line gp save for two or | ||
33 | more regs. Use save_reg_p to test for holes in reg restore set. | ||
34 | Replace "#if" with "if". | ||
35 | |||
36 | Index: gcc-4_7-branch/gcc/config/rs6000/aix.h | ||
37 | =================================================================== | ||
38 | --- gcc-4_7-branch.orig/gcc/config/rs6000/aix.h 2012-09-07 12:35:35.000000000 -0700 | ||
39 | +++ gcc-4_7-branch/gcc/config/rs6000/aix.h 2012-09-07 15:27:55.215290315 -0700 | ||
40 | @@ -207,11 +207,6 @@ | ||
41 | { "link_syscalls", LINK_SYSCALLS_SPEC }, \ | ||
42 | { "link_libg", LINK_LIBG_SPEC } | ||
43 | |||
44 | -/* Define cutoff for using external functions to save floating point. */ | ||
45 | -#define FP_SAVE_INLINE(FIRST_REG) ((FIRST_REG) == 62 || (FIRST_REG) == 63) | ||
46 | -/* And similarly for general purpose registers. */ | ||
47 | -#define GP_SAVE_INLINE(FIRST_REG) ((FIRST_REG) < 32) | ||
48 | - | ||
49 | #define PROFILE_HOOK(LABEL) output_profile_hook (LABEL) | ||
50 | |||
51 | /* No version of AIX fully supports AltiVec or 64-bit instructions in | ||
52 | Index: gcc-4_7-branch/gcc/config/rs6000/darwin.h | ||
53 | =================================================================== | ||
54 | --- gcc-4_7-branch.orig/gcc/config/rs6000/darwin.h 2012-09-07 12:35:35.000000000 -0700 | ||
55 | +++ gcc-4_7-branch/gcc/config/rs6000/darwin.h 2012-09-07 15:27:55.223290316 -0700 | ||
56 | @@ -173,16 +173,6 @@ | ||
57 | (RS6000_ALIGN (crtl->outgoing_args_size, 16) \ | ||
58 | + (STACK_POINTER_OFFSET)) | ||
59 | |||
60 | -/* Define cutoff for using out-of-line functions to save registers. | ||
61 | - Currently on Darwin, we implement FP and GPR out-of-line-saves plus the | ||
62 | - special routine for 'save everything'. */ | ||
63 | - | ||
64 | -#undef FP_SAVE_INLINE | ||
65 | -#define FP_SAVE_INLINE(FIRST_REG) ((FIRST_REG) > 60 && (FIRST_REG) < 64) | ||
66 | - | ||
67 | -#undef GP_SAVE_INLINE | ||
68 | -#define GP_SAVE_INLINE(FIRST_REG) ((FIRST_REG) > 29 && (FIRST_REG) < 32) | ||
69 | - | ||
70 | /* Darwin uses a function call if everything needs to be saved/restored. */ | ||
71 | |||
72 | #undef WORLD_SAVE_P | ||