Alive2 right now isn’t happy about this transformation since it assumes that null may alias with inaccessible memory.
It’s true that any function can use the null pointer and access it. But the same reasoning holds for a inttoptr 0x42 pointer. Are we going to mark those as not accessing inaccessible memory as well? (I think we shouldn’t)
That implies that every function for which we have a definition can be marked with memory(inaccessiblemem: none)?
Or does it propagate through the CFG (i.e., a caller of a function that may access inaccessible memory will itself be marked as potentially accessing such memory as well)?
2nd option, yes. If a function transitively can access inaccessible memory we can’t do much, but starting from the leafs we can propagate it.
The Attributor should do that already.