[PATCH] D21110: [CFLAA] Add yet another StratifiedAttr
Jia Chen via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 8 15:05:02 PDT 2016
On Wed, Jun 8, 2016 at 4:28 PM, Daniel Berlin <dberlin at dberlin.org> wrote:
> You only need to locally propagate whether something has happened in the
> callee.
>
> Given
>
> int foo()
> {
> bar();
> }
>
> int bar()
> {
> baz();
> }
>
> ...
>
> The order of processing will be baz, then bar, then foo.
Agreed. That's what I was saying.
> If you locally analyze whether the function, and any of its callees (which
> you will have complete info for at that point) alias any globals, you will
> know the answer for each function whether that function does something with
> globals or externals.
This is true. So yes AttrGlobal might be useful if certain client
requires that sort of information. But the same argument doesn't hold
for AttrArg.
>
> Now, the traditional solution is bottom-up followed by top-down propagation,
> but ...
I thought top-down propagation is only safe at link time when the
entire program is available?
More information about the llvm-commits
mailing list