On Wed, Nov 9, 2022 at 5:16 PM apinski--- via Gcc-patches
<gcc-patches@gcc.gnu.org> wrote:
>
> From: Andrew Pinski <apin...@marvell.com>
>
> SLOW_SHORT_ACCESS is defined in bfin and i386 target
> headers but the target macro is not used elsewhere.
> So let's remove it from those two headers and poison it.

Just to add, this target macro was defined in GCC 2.8.0 in i386.h but
not used in any other sources.
apinski@xeond:~/src/upstream-gcc/gcc$ git grep SLOW_SHORT_ACCESS
releases/gcc-2.8.0
releases/gcc-2.8.0:gcc/config/i386/i386.h:#define SLOW_SHORT_ACCESS 0

So it looks like it was never used for the last 24+ years and it is
time to finally remove it.

Thanks,
Andrew Pinski


>
> OK? Built x86_64-linux-gnu and bfin-elf.
>
> gcc/ChangeLog:
>
>         * config/bfin/bfin.h (SLOW_SHORT_ACCESS): Delete.
>         * config/i386/i386.h (SLOW_SHORT_ACCESS): Delete.
>         * system.h: Poison SLOW_SHORT_ACCESS
> ---
>  gcc/config/bfin/bfin.h | 1 -
>  gcc/config/i386/i386.h | 3 ---
>  gcc/system.h           | 2 +-
>  3 files changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/gcc/config/bfin/bfin.h b/gcc/config/bfin/bfin.h
> index 4e7753038a8..1d75c655df8 100644
> --- a/gcc/config/bfin/bfin.h
> +++ b/gcc/config/bfin/bfin.h
> @@ -810,7 +810,6 @@ typedef struct {
>     subsequent accesses occur to other fields in the same word of the
>     structure, but to different bytes.  */
>  #define SLOW_BYTE_ACCESS  0
> -#define SLOW_SHORT_ACCESS 0
>
>  /* Define this if most significant bit is lowest numbered
>     in instructions that operate on numbered bit-fields. */
> diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h
> index b32db8da109..a5ad9f387f7 100644
> --- a/gcc/config/i386/i386.h
> +++ b/gcc/config/i386/i386.h
> @@ -1933,9 +1933,6 @@ do {                                                    
>   \
>
>  #define SLOW_BYTE_ACCESS 0
>
> -/* Nonzero if access to memory by shorts is slow and undesirable.  */
> -#define SLOW_SHORT_ACCESS 0
> -
>  /* Define this macro if it is as good or better to call a constant
>     function address than to call an address kept in a register.
>
> diff --git a/gcc/system.h b/gcc/system.h
> index c192b6c3ce7..de9c5c0d2ef 100644
> --- a/gcc/system.h
> +++ b/gcc/system.h
> @@ -1075,7 +1075,7 @@ extern void fancy_abort (const char *, int, const char 
> *)
>         EH_FRAME_IN_DATA_SECTION TARGET_FLT_EVAL_METHOD_NON_DEFAULT        \
>         JCR_SECTION_NAME TARGET_USE_JCR_SECTION SDB_DEBUGGING_INFO         \
>         SDB_DEBUG NO_IMPLICIT_EXTERN_C NOTICE_UPDATE_CC                    \
> -       CC_STATUS_MDEP_INIT CC_STATUS_MDEP CC_STATUS
> +       CC_STATUS_MDEP_INIT CC_STATUS_MDEP CC_STATUS SLOW_SHORT_ACCESS
>
>  /* Hooks that are no longer used.  */
>   #pragma GCC poison LANG_HOOKS_FUNCTION_MARK LANG_HOOKS_FUNCTION_FREE  \
> --
> 2.17.1
>

Reply via email to