This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PING: PATCH [mainline] use of save_world/rest_world calls in apple-ppc-darwin prologue/epilogue



Hi Geoff,


Here is the revised patch based on your comments. bootstrapped, dejagnu tested (-mcpu=G5) with no regressions.

Furthermore, to answer one of your questions about size of binary when this patch is applied. Here is size
of cc1 before and after of the patch:


1) Size without this patch:

ls -lt ./gcc/stage2/cc1
-rwxr-xr-x  1 fjahania  admin  18940792  2 Aug 17:51 ./gcc/stage2/cc1

2) Size with this patch:

ls -lt  ./gcc/stage2/cc1
-rwxr-xr-x  1 fjahania  admin  18874176  2 Aug 16:38 ./gcc/stage2/cc1

So, size got somewhat smaller when compiler with patch used to bootstrap. But I am not
sure it is because of my patch or something else.


OK for mainline?

- Thanks, Fariborz

ChangeLog:

2004-07-30 Fariborz Jahanian <fjahanian@apple.com>

        * config/rs6000/altivec.md: Add new patterns for calls to
        save_world/rest_world functions.

        * config/rs6000/rs6000-protos.h: (save_world_operation,
        restore_world_operation) new declarations.

        * config/rs6000/rs6000.c: (struct rs6000_stack) new world_save_p
        field added.
        (rs6000_stack_info): Set world_save_p field.
        (save_world_operation): New function.
        (restore_world_operation): New function.
        (compute_save_world_info): New function.
        (rs6000_stack_info): Call compute_save_world_info.
        (rs6000_emit_prologue): Check for world_save_p and generate
        pattern to call save_world for saving all non-volatile and
        special registers.
        (rs6000_emit_epilogue): Check for world_save_p and generate
        pattern to call rest_world to restore saved registers.

config/rs6000/rs6000.h: macros FIRST_SAVED_ALTIVEC_REGNO,
FIRST_SAVED_FP_REGNO, FIRST_SAVED_GP_REGNO defined.
(rs6000_reg_names): New entries added for save_world_operation and
restore_world_operation.



Attachment: fsf-save-world-patch-1.txt
Description: Text document



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]