mirror of
https://sourceware.org/git/glibc.git
synced 2024-12-26 20:51:11 +00:00
powerpc64le: Use <gcc-macros.h> in early HWCAP check
This is required so that the checks still work if $(early-cflags) selects a different ISA level. Reviewed-by: Carlos O'Donell <carlos@redhat.com> Tested-by: Carlos O'Donell <carlos@redhat.com>
This commit is contained in:
parent
9ba202c78f
commit
5501164866
@ -19,17 +19,18 @@
|
|||||||
#ifndef _DL_HWCAP_CHECK_H
|
#ifndef _DL_HWCAP_CHECK_H
|
||||||
#define _DL_HWCAP_CHECK_H
|
#define _DL_HWCAP_CHECK_H
|
||||||
|
|
||||||
|
#include <gcc-macros.h>
|
||||||
#include <ldsodefs.h>
|
#include <ldsodefs.h>
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
dl_hwcap_check (void)
|
dl_hwcap_check (void)
|
||||||
{
|
{
|
||||||
#ifdef _ARCH_PWR9
|
#ifdef GCCMACRO_ARCH_PWR9
|
||||||
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_ARCH_3_00) == 0)
|
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_ARCH_3_00) == 0)
|
||||||
_dl_fatal_printf ("\
|
_dl_fatal_printf ("\
|
||||||
Fatal glibc error: CPU lacks ISA 3.00 support (POWER9 or later required)\n");
|
Fatal glibc error: CPU lacks ISA 3.00 support (POWER9 or later required)\n");
|
||||||
#endif
|
#endif
|
||||||
#ifdef __FLOAT128_HARDWARE__
|
#ifdef GCCMACRO__FLOAT128_HARDWARE__
|
||||||
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_HAS_IEEE128) == 0)
|
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_HAS_IEEE128) == 0)
|
||||||
_dl_fatal_printf ("\
|
_dl_fatal_printf ("\
|
||||||
Fatal glibc error: CPU lacks float128 support (POWER 9 or later required)\n");
|
Fatal glibc error: CPU lacks float128 support (POWER 9 or later required)\n");
|
||||||
@ -37,12 +38,12 @@ Fatal glibc error: CPU lacks float128 support (POWER 9 or later required)\n");
|
|||||||
/* This check is not actually reached when building for POWER10 and
|
/* This check is not actually reached when building for POWER10 and
|
||||||
running on POWER9 because there are faulting PCREL instructions
|
running on POWER9 because there are faulting PCREL instructions
|
||||||
before this point. */
|
before this point. */
|
||||||
#if defined _ARCH_PWR10 || defined __PCREL__
|
#if defined GCCMACRO_ARCH_PWR10 || defined GCCMACRO__PCREL__
|
||||||
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_ARCH_3_1) == 0)
|
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_ARCH_3_1) == 0)
|
||||||
_dl_fatal_printf ("\
|
_dl_fatal_printf ("\
|
||||||
Fatal glibc error: CPU lacks ISA 3.10 support (POWER10 or later required)\n");
|
Fatal glibc error: CPU lacks ISA 3.10 support (POWER10 or later required)\n");
|
||||||
#endif
|
#endif
|
||||||
#ifdef __MMA__
|
#ifdef GCCMACRO__MMA__
|
||||||
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_MMA) == 0)
|
if ((GLRO (dl_hwcap2) & PPC_FEATURE2_MMA) == 0)
|
||||||
_dl_fatal_printf ("\
|
_dl_fatal_printf ("\
|
||||||
Fatal glibc error: CPU lacks MMA support (POWER10 or later required)\n");
|
Fatal glibc error: CPU lacks MMA support (POWER10 or later required)\n");
|
||||||
|
Loading…
Reference in New Issue
Block a user