================
@@ -2953,14 +2956,28 @@ std::unique_ptr<cir::LowerModule>
prepareLowerModule(mlir::ModuleOp module) {
return {};
return cir::createLowerModule(module, rewriter);
}
+static unsigned
+getNumericASFromCIRAS(mlir::ptr::MemorySpaceAttrInterface asAttr,
+ [[maybe_unused]] cir::LowerModule *lowerModule) {
+ if (!asAttr)
+ return 0; // default AS
+ if (auto targetAddrSpaceAttr =
+ mlir::dyn_cast_if_present<cir::TargetAddressSpaceAttr>(asAttr))
+ return targetAddrSpaceAttr.getValue();
+
+ if (mlir::isa_and_present<cir::LangAddressSpaceAttr>(asAttr))
+ llvm_unreachable("lowering LangAddressSpaceAttr NYI");
----------------
RiverDave wrote:
Support for this is later provided on:
https://github.com/llvm/llvm-project/pull/179084
https://github.com/llvm/llvm-project/pull/179073
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits