Blame sysdeps/arm/arm-features.h

Packit 6c4009
/* Macros to test for CPU features on ARM.  Generic ARM version.
Packit 6c4009
   Copyright (C) 2012-2018 Free Software Foundation, Inc.
Packit 6c4009
   This file is part of the GNU C Library.
Packit 6c4009
Packit 6c4009
   The GNU C Library is free software; you can redistribute it and/or
Packit 6c4009
   modify it under the terms of the GNU Lesser General Public
Packit 6c4009
   License as published by the Free Software Foundation; either
Packit 6c4009
   version 2.1 of the License, or (at your option) any later version.
Packit 6c4009
Packit 6c4009
   The GNU C Library is distributed in the hope that it will be useful,
Packit 6c4009
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit 6c4009
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit 6c4009
   Lesser General Public License for more details.
Packit 6c4009
Packit 6c4009
   You should have received a copy of the GNU Lesser General Public
Packit 6c4009
   License along with the GNU C Library.  If not, see
Packit 6c4009
   <http://www.gnu.org/licenses/>.  */
Packit 6c4009
Packit 6c4009
#ifndef _ARM_ARM_FEATURES_H
Packit 6c4009
#define _ARM_ARM_FEATURES_H 1
Packit 6c4009
Packit 6c4009
/* An OS-specific arm-features.h file should define ARM_HAVE_VFP to
Packit 6c4009
   an appropriate expression for testing at runtime whether the VFP
Packit 6c4009
   hardware is present.  We'll then redefine it to a constant if we
Packit 6c4009
   know at compile time that we can assume VFP.  */
Packit 6c4009
Packit 6c4009
#ifndef __SOFTFP__
Packit 6c4009
/* The compiler is generating VFP instructions, so we're already
Packit 6c4009
   assuming the hardware exists.  */
Packit 6c4009
# undef ARM_HAVE_VFP
Packit 6c4009
# define ARM_HAVE_VFP	1
Packit 6c4009
#endif
Packit 6c4009
Packit 6c4009
/* An OS-specific arm-features.h file may define ARM_ASSUME_NO_IWMMXT
Packit 6c4009
   to indicate at compile time that iWMMXt hardware is never present
Packit 6c4009
   at runtime (or that we never care about its state) and so need not
Packit 6c4009
   be checked for.  */
Packit 6c4009
Packit 6c4009
/* A more-specific arm-features.h file may define ARM_ALWAYS_BX to indicate
Packit 6c4009
   that instructions using pc as a destination register must never be used,
Packit 6c4009
   so a "bx" (or "blx") instruction is always required.  */
Packit 6c4009
Packit 6c4009
/* The log2 of the minimum alignment required for an address that
Packit 6c4009
   is the target of a computed branch (i.e. a "bx" instruction).
Packit 6c4009
   A more-specific arm-features.h file may define this to set a more
Packit 6c4009
   stringent requirement.
Packit 6c4009
Packit 6c4009
   Using this only makes sense for code in ARM mode (where instructions
Packit 6c4009
   always have a fixed size of four bytes), or for Thumb-mode code that is
Packit 6c4009
   specifically aligning all the related branch targets to match (since
Packit 6c4009
   Thumb instructions might be either two or four bytes).  */
Packit 6c4009
#ifndef ARM_BX_ALIGN_LOG2
Packit 6c4009
# define ARM_BX_ALIGN_LOG2	2
Packit 6c4009
#endif
Packit 6c4009
Packit 6c4009
/* An OS-specific arm-features.h file may define ARM_NO_INDEX_REGISTER to
Packit 6c4009
   indicate that the two-register addressing modes must never be used.  */
Packit 6c4009
Packit 6c4009
#endif  /* arm-features.h */