ifunc-strcpy.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. /* strcpy variant information on S/390 version.
  2. Copyright (C) 2018-2026 Free Software Foundation, Inc.
  3. This file is part of the GNU C Library.
  4. The GNU C Library is free software; you can redistribute it and/or
  5. modify it under the terms of the GNU Lesser General Public
  6. License as published by the Free Software Foundation; either
  7. version 2.1 of the License, or (at your option) any later version.
  8. The GNU C Library is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  11. Lesser General Public License for more details.
  12. You should have received a copy of the GNU Lesser General Public
  13. License along with the GNU C Library; if not, see
  14. <https://www.gnu.org/licenses/>. */
  15. #if defined USE_MULTIARCH && IS_IN (libc) \
  16. && ! defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
  17. # define HAVE_STRCPY_IFUNC 1
  18. #else
  19. # define HAVE_STRCPY_IFUNC 0
  20. #endif
  21. #ifdef HAVE_S390_VX_ASM_SUPPORT
  22. # define HAVE_STRCPY_IFUNC_AND_VX_SUPPORT HAVE_STRCPY_IFUNC
  23. #else
  24. # define HAVE_STRCPY_IFUNC_AND_VX_SUPPORT 0
  25. #endif
  26. #if defined HAVE_S390_MIN_Z13_ZARCH_ASM_SUPPORT
  27. # define STRCPY_DEFAULT STRCPY_Z13
  28. # define HAVE_STRCPY_Z900_G5 0
  29. # define HAVE_STRCPY_Z13 1
  30. #else
  31. # define STRCPY_DEFAULT STRCPY_Z900_G5
  32. # define HAVE_STRCPY_Z900_G5 1
  33. # define HAVE_STRCPY_Z13 HAVE_STRCPY_IFUNC_AND_VX_SUPPORT
  34. #endif
  35. #if HAVE_STRCPY_Z900_G5
  36. # define STRCPY_Z900_G5 __strcpy_default
  37. #else
  38. # define STRCPY_Z900_G5 NULL
  39. #endif
  40. #if HAVE_STRCPY_Z13
  41. # define STRCPY_Z13 __strcpy_vx
  42. #else
  43. # define STRCPY_Z13 NULL
  44. #endif