Before this patch AAMemoryLocationCallSite did basically mirror the
corresponding AAMemoryLocationFunction. This has multiple drawbacks:
- Things like the "ONLY_ARGMEMONLY" bit in the state mean different things for a store to an argument and a call since the latter is referring to the callee arguments.
- We duplicated all accesses of the callee in the call site AA even though this is neither helpful nor can should we look at the instructions and pointers pointers in the context of the caller.
The new behavior decouples the call site argmemonly and
inaccessiblememorargmemonly attributes from the state such that the
call site can represent memory locations with regards to the caller. We
will only iterate over callee accesses to arguments and globals now and
we will use the call as the instruction that performs the access. If
accesses have argument pointers we translate them to improve the result,
though that was happening in a weird way before as well. Pointers to
globals are kept as well, if they were present. All other access kinds
are simply attributed to the call without any particular pointer
Since we now track attributes wrt. the caller not callee we cannot
manifest the result easily. This can be revisited later.