Andre Przywara | c7d10e3 | 2020-10-16 12:06:57 +0100 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2021 ARM Limited |
| 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | * |
| 6 | * The definitions below are a subset of what we would normally get by using |
| 7 | * the compiler's version of arm_acle.h. We can't use that directly because |
| 8 | * we specify -nostdinc in the Makefiles. |
| 9 | * |
| 10 | * We just define the functions we need so far. |
| 11 | */ |
| 12 | |
| 13 | #ifndef ARM_ACLE_H |
| 14 | #define ARM_ACLE_H |
| 15 | |
| 16 | #if !defined(__aarch64__) || defined(__clang__) |
Manish V Badarkhe | 7a86792 | 2021-04-22 14:41:27 +0100 | [diff] [blame] | 17 | # define __crc32b __builtin_arm_crc32b |
Andre Przywara | c7d10e3 | 2020-10-16 12:06:57 +0100 | [diff] [blame] | 18 | # define __crc32w __builtin_arm_crc32w |
| 19 | #else |
Manish V Badarkhe | 7a86792 | 2021-04-22 14:41:27 +0100 | [diff] [blame] | 20 | # define __crc32b __builtin_aarch64_crc32b |
Andre Przywara | c7d10e3 | 2020-10-16 12:06:57 +0100 | [diff] [blame] | 21 | # define __crc32w __builtin_aarch64_crc32w |
| 22 | #endif |
| 23 | |
| 24 | #endif /* ARM_ACLE_H */ |