Skip to content

Conversation

AmrDeveloper
Copy link
Member

Lowering Neon vsetq_lane_f64

References:
Clang CGBuiltin Implementation
Builtin definition

@ghehg ghehg self-requested a review January 2, 2025 13:19
@ghehg
Copy link
Contributor

ghehg commented Jan 2, 2025

LGTM. Thanks for working on it.

llvm_unreachable("NEON::BI__builtin_neon_vsetq_lane_f64 NYI");
case NEON::BI__builtin_neon_vsetq_lane_f64: {
Ops.push_back(emitScalarExpr(E->getArg(2)));
Ops[1] = builder.createBitcast(
Copy link
Contributor

@ghehg ghehg Jan 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO
To reduce code duplication which OG had, We could consider extracting
`
Ops.push_back(emitScalarExpr(E->getArg(2)));

return builder.createcir::VecInsertOp(getLoc(E->getExprLoc()), Ops[1],
Ops[0], Ops[2]);
`
into a helper function in future case like this.

@bcardosolopes bcardosolopes merged commit a477dfa into llvm:main Jan 6, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants