Skip to content

[Clang] VectorExprEvaluator::VisitCallExpr / InterpretBuiltin - allow PCLMULQDQ intrinsics to be used in constexpr #168741

@RKSimon

Description

@RKSimon
__m128i _mm_clmulepi64_si128 (__m128i a, __m128i b, const int imm8)
__m256i _mm256_clmulepi64_epi128 (__m256i b, __m256i c, const int Imm8)
__m512i _mm512_clmulepi64_epi128 (__m512i b, __m512i c, const int Imm8)

Now that we have #168527 we should be able to easily constant fold PCLMULQDQ builtins for constant expressions

Ensure you consult https://www.intel.com/content/www/us/en/docs/intrinsics-guide/index.html#text=clmul and handle the imm8 mask correctly, preferably with offline testing.

Metadata

Metadata

Labels

backend:X86clang:bytecodeIssues for the clang bytecode constexpr interpreterclang:frontendLanguage frontend issues, e.g. anything involving "Sema"clang:headersHeaders provided by Clang, e.g. for intrinsicsconstexprAnything related to constant evaluationgood first issuehttps://github.com/llvm/llvm-project/contribute

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions