[flang-commits] [flang] [llvm] [flang][MIF] Adding lowering for EVENT POST/WAIT statements (PR #210283)
via flang-commits
flang-commits at lists.llvm.org
Thu Oct 22 22:56:11 PDT 2026
================
@@ -213,6 +260,69 @@ static mlir::Value getSizeInBytes(fir::FirOpBuilder &builder,
return sizeInBytes;
}
+/// Compute an offset in bytes from the beginning of the elements provided in
+/// "val". Basically, if it is not a memory access operation for an array such
+/// as fir::ArrayCoorOp or fir::CoordinateOp, then the element's offset is zero.
+static mlir::Value computeOffsetInBytes(fir::FirOpBuilder &builder,
+ mlir::Location loc, mlir::Value box) {
+ mlir::Operation *defOp = box.getDefiningOp();
+ if (mlir::isa<fir::ConvertOp, fir::EmboxOp>(defOp)) {
+ llvm::TypeSwitch<mlir::Operation *>(defOp)
----------------
MattPD wrote:
Thanks, the Linux and Windows CI builds now pass on 931c148a.
https://github.com/llvm/llvm-project/pull/210283
More information about the flang-commits
mailing list