149#if defined(BOTAN_TARGET_CPU_IS_X86_FAMILY)
150 if(tok ==
"sse2" || tok ==
"simd") {
151 return {CPUID::CPUID_SSE2_BIT};
152 }
else if(tok ==
"ssse3") {
153 return {CPUID::CPUID_SSSE3_BIT};
154 }
else if(tok ==
"aesni" || tok ==
"aes_ni") {
156 return {CPUID::CPUID_AESNI_BIT};
157 }
else if(tok ==
"clmul") {
158 return {CPUID::CPUID_CLMUL_BIT};
159 }
else if(tok ==
"avx2") {
160 return {CPUID::CPUID_AVX2_BIT};
161 }
else if(tok ==
"avx512") {
162 return {CPUID::CPUID_AVX512_BIT};
165 else if(tok ==
"sha" || tok ==
"intel_sha") {
166 return {CPUID::CPUID_SHA_BIT};
167 }
else if(tok ==
"rdtsc") {
168 return {CPUID::CPUID_RDTSC_BIT};
169 }
else if(tok ==
"bmi2") {
170 return {CPUID::CPUID_BMI_BIT};
171 }
else if(tok ==
"adx") {
172 return {CPUID::CPUID_ADX_BIT};
173 }
else if(tok ==
"gfni") {
174 return {CPUID::CPUID_GFNI_BIT};
175 }
else if(tok ==
"rdrand") {
176 return {CPUID::CPUID_RDRAND_BIT};
177 }
else if(tok ==
"rdseed") {
178 return {CPUID::CPUID_RDSEED_BIT};
179 }
else if(tok ==
"avx512_aes") {
180 return {CPUID::CPUID_AVX512_AES_BIT};
181 }
else if(tok ==
"avx512_clmul") {
182 return {CPUID::CPUID_AVX512_CLMUL_BIT};
183 }
else if(tok ==
"avx2_vaes") {
184 return {CPUID::CPUID_AVX2_AES_BIT};
185 }
else if(tok ==
"avx2_clmul") {
186 return {CPUID::CPUID_AVX2_CLMUL_BIT};
187 }
else if(tok ==
"intel_sm3") {
188 return {CPUID::CPUID_SM3_BIT};
189 }
else if(tok ==
"intel_sm4") {
190 return {CPUID::CPUID_SM4_BIT};
193#elif defined(BOTAN_TARGET_CPU_IS_PPC_FAMILY)
194 if(tok ==
"altivec" || tok ==
"simd") {
195 return {CPUID::CPUID_ALTIVEC_BIT};
196 }
else if(tok ==
"power_crypto") {
197 return {CPUID::CPUID_POWER_CRYPTO_BIT};
198 }
else if(tok ==
"darn_rng") {
199 return {CPUID::CPUID_DARN_BIT};
202#elif defined(BOTAN_TARGET_CPU_IS_ARM_FAMILY)
203 if(tok ==
"neon" || tok ==
"simd") {
204 return {CPUID::CPUID_ARM_NEON_BIT};
205 }
else if(tok ==
"arm_sve") {
206 return {CPUID::CPUID_ARM_SVE_BIT};
207 }
else if(tok ==
"armv8sha1" || tok ==
"arm_sha1") {
208 return {CPUID::CPUID_ARM_SHA1_BIT};
209 }
else if(tok ==
"armv8sha2" || tok ==
"arm_sha2") {
210 return {CPUID::CPUID_ARM_SHA2_BIT};
211 }
else if(tok ==
"armv8aes" || tok ==
"arm_aes") {
212 return {CPUID::CPUID_ARM_AES_BIT};
213 }
else if(tok ==
"armv8pmull" || tok ==
"arm_pmull") {
214 return {CPUID::CPUID_ARM_PMULL_BIT};
215 }
else if(tok ==
"armv8sha3" || tok ==
"arm_sha3") {
216 return {CPUID::CPUID_ARM_SHA3_BIT};
217 }
else if(tok ==
"armv8sha2_512" || tok ==
"arm_sha2_512") {
218 return {CPUID::CPUID_ARM_SHA2_512_BIT};
219 }
else if(tok ==
"armv8sm3" || tok ==
"arm_sm3") {
220 return {CPUID::CPUID_ARM_SM3_BIT};
221 }
else if(tok ==
"armv8sm4" || tok ==
"arm_sm4") {
222 return {CPUID::CPUID_ARM_SM4_BIT};