[clang] [CIR] Add pass_object_size hidden parameter support (PR #191482)
Andy Kaylor via cfe-commits
cfe-commits at lists.llvm.org
Fri Apr 10 15:47:27 PDT 2026
================
@@ -2578,11 +2578,33 @@ mlir::Value CIRGenFunction::emitVAArg(VAArgExpr *ve) {
return cir::VAArgOp::create(builder, loc, type, vaList);
}
+/// Checks if using the result of __builtin_object_size(p, @p from) in place of
+/// __builtin_object_size(p, @p to) is correct.
+static bool areBOSTypesCompatible(int from, int to) {
+ return from == to || (from == 0 && to == 1) || (from == 3 && to == 2);
+}
+
mlir::Value CIRGenFunction::emitBuiltinObjectSize(const Expr *e, unsigned type,
cir::IntType resType,
mlir::Value emittedE,
bool isDynamic) {
- assert(!cir::MissingFeatures::opCallImplicitObjectSizeArgs());
----------------
andykaylor wrote:
This should also be deleted from MissingFeatures.h now.
https://github.com/llvm/llvm-project/pull/191482
More information about the cfe-commits
mailing list