================
@@ -144,6 +144,15 @@ CIRGenModule::CIRGenModule(mlir::MLIRContext &mlirContext,
   theModule->setAttr(cir::CIRDialect::getIntTypeWidthAttrName(),
                      builder.getI32IntegerAttr(target.getIntWidth()));
 
+  llvm::SmallVector<cir::SanitizeKind> sanitizerKinds;
+  if (getLangOpts().Sanitize.has(SanitizerKind::Address))
----------------
Lancern wrote:

`SanitizerMask` is actually a `struct` with two private `uint64_t` for the 
bitmask:

https://github.com/llvm/llvm-project/blob/659faef7717be80c12e47604e61c01f2d7fc4975/clang/include/clang/Basic/Sanitizers.h#L34-L46

So a plain `static_cast` won't do the job easily. Is it a good idea to directly 
embed a `SanitizerMask` object into a CIR attribute?

https://github.com/llvm/llvm-project/pull/220625
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to