[llvm] [InferAttrs] Mark floating-point libcalls as errno-writing (PR #124742)
Antonio Frighetto via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 12 11:56:12 PDT 2025
================
@@ -922,6 +922,15 @@ void Function::setOnlyAccessesInaccessibleMemory() {
setMemoryEffects(getMemoryEffects() & MemoryEffects::inaccessibleMemOnly());
}
+/// Determine if the call can access only errno memory.
+bool Function::onlyAccessesErrnoMemory() const {
+ return getMemoryEffects().onlyAccessesErrnoMem();
+}
+void Function::setOnlyAccessesErrnoMemory() {
+ setMemoryEffects(getMemoryEffects() &
+ MemoryEffects::errnoMemOnly(ModRefInfo::Mod));
----------------
antoniofrighetto wrote:
Definitely, thanks for looking into it.
https://github.com/llvm/llvm-project/pull/124742
More information about the llvm-commits
mailing list