================ @@ -1026,6 +1030,71 @@ void SystemZAsmPrinter::emitADASection() { OutStreamer->popSection(); } +static uint32_t getProductVersion(Module &M) { + if (auto *VersionVal = mdconst::extract_or_null<ConstantInt>( + M.getModuleFlag("zos_product_major_version"))) + return VersionVal->getValue().getZExtValue(); ---------------- uweigand wrote:
I don't think you need the separate `getValue()` here any more. Also, you should be making the change to use `mdconst` not only in this one place, but in all places where you use `getModuleFlag` to retrieve an integer constant. https://github.com/llvm/llvm-project/pull/68926 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits