Skip to content

Commit

Permalink
Bit decomposition builtin updated. Input parameter changed from field…
Browse files Browse the repository at this point in the history
… element to std::uint64_t.#61
  • Loading branch information
nkaskov committed Jul 16, 2023
1 parent f526484 commit c67458e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion clang/include/clang/Basic/BuiltinsAssigner.def
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ BUILTIN(__builtin_assigner_vesta_curve_init, "e2g7g7", "n")
BUILTIN(__builtin_assigner_bls12381_curve_init, "e3g3g3", "n")
BUILTIN(__builtin_assigner_curve25519_curve_init, "e4g5g5", "n")

BUILTIN(__builtin_assigner_bit_decomposition64, "E64g1g1", "n")
BUILTIN(__builtin_assigner_bit_decomposition64, "E64g1ULLi", "n")
BUILTIN(__builtin_assigner_bit_composition128, "g1E64g1E64g1", "n")

#undef BUILTIN
Expand Down
3 changes: 2 additions & 1 deletion clang/lib/CodeGen/CGBuiltin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19920,7 +19920,8 @@ Value *CodeGenFunction::EmitAssignerBuiltinExpr(unsigned int BuiltinID,
ID = Intrinsic::assigner_bit_decomposition64;
auto ElemTy = llvm::GaloisFieldType::get(context,
llvm::GALOIS_FIELD_PALLAS_BASE);
OverloadTypes = {llvm::FixedVectorType::get(ElemTy, 64), ElemTy};
auto IntType = llvm::IntegerType::get(context, 64);
OverloadTypes = {llvm::FixedVectorType::get(ElemTy, 64), IntType};
break;
}
}
Expand Down

0 comments on commit c67458e

Please sign in to comment.