[all-commits] [llvm/llvm-project] c86fd3: [Attributor] Force update of "newly live" abstract...

Johannes Doerfert via All-commits all-commits at lists.llvm.org
Mon May 11 13:34:43 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: c86fd3333dd4d29b302c93eb1dd7b5a149109904
      https://github.com/llvm/llvm-project/commit/c86fd3333dd4d29b302c93eb1dd7b5a149109904
  Author: Johannes Doerfert <johannes at jdoerfert.de>
  Date:   2020-05-11 (Mon, 11 May 2020)

  Changed paths:
    M llvm/include/llvm/Transforms/IPO/Attributor.h
    M llvm/lib/Transforms/IPO/AttributorAttributes.cpp
    M llvm/test/Transforms/Attributor/ArgumentPromotion/X86/attributes.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/X86/min-legal-vector-width.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/alignment.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/byval-2.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/byval.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/dbg.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/live_called_from_dead.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/musttail.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/profile.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/reserve-tbaa.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/PR16052.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/multiple_callbacks.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/musttail-call.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/naked-return.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/pthreads.ll
    M llvm/test/Transforms/Attributor/alwaysinline.ll
    M llvm/test/Transforms/Attributor/dereferenceable-2.ll
    M llvm/test/Transforms/Attributor/internal-noalias.ll
    M llvm/test/Transforms/Attributor/noreturn_sync.ll
    M llvm/test/Transforms/Attributor/read_write_returned_arguments_scc.ll
    M llvm/test/Transforms/Attributor/readattrs.ll

  Log Message:
  -----------
  [Attributor] Force update of "newly live" abstract attributes

During an update of AAIsDead, new instructions become live. If we query
information from them, the result is often just the initial state, e.g.,
for call site `noreturn` and `nounwind`. We will now trigger an update
for cached attributes during the AAIsDead update, though other AAs might
later use the same API.


  Commit: c115a78f0d2ac59b6f53634fd057f45211e04a96
      https://github.com/llvm/llvm-project/commit/c115a78f0d2ac59b6f53634fd057f45211e04a96
  Author: Johannes Doerfert <johannes at jdoerfert.de>
  Date:   2020-05-11 (Mon, 11 May 2020)

  Changed paths:
    M llvm/include/llvm/Transforms/IPO/Attributor.h
    M llvm/lib/Transforms/IPO/AttributorAttributes.cpp
    M llvm/test/Transforms/Attributor/ArgumentPromotion/X86/thiscall.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/alignment.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/control-flow2.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/dbg.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/fp80.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/live_called_from_dead.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/musttail.ll
    M llvm/test/Transforms/Attributor/ArgumentPromotion/profile.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/multiple_callbacks.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/pthreads.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/return-argument.ll
    M llvm/test/Transforms/Attributor/IPConstantProp/return-constants.ll
    M llvm/test/Transforms/Attributor/align.ll
    M llvm/test/Transforms/Attributor/dereferenceable-1.ll
    M llvm/test/Transforms/Attributor/internal-noalias.ll
    M llvm/test/Transforms/Attributor/liveness.ll
    M llvm/test/Transforms/Attributor/misc.ll
    M llvm/test/Transforms/Attributor/noalias.ll
    M llvm/test/Transforms/Attributor/nocapture-2.ll
    M llvm/test/Transforms/Attributor/nofree.ll
    M llvm/test/Transforms/Attributor/nonnull.ll
    M llvm/test/Transforms/Attributor/norecurse.ll
    M llvm/test/Transforms/Attributor/range.ll
    M llvm/test/Transforms/Attributor/read_write_returned_arguments_scc.ll
    M llvm/test/Transforms/Attributor/readattrs.ll
    M llvm/test/Transforms/Attributor/returned.ll

  Log Message:
  -----------
  [Attributor] Make AAIsDead dependences optional to prevent top state

We should never give up on AAIsDead as it guards other AAs from
unreachable code (in which SSA properties are meaningless). We did
however use required dependences on some queries in AAIsDead which
caused us to invalidate AAIsDead if the queried AA got invalidated.
We now use optional dependences instead. The bug that exposed this is
added to the liveness.ll test and other test changes show the impact.

Bug report by @sdmitriev.


  Commit: 8d94d3c3b44c3a27a69b153cef9be4b8e481150e
      https://github.com/llvm/llvm-project/commit/8d94d3c3b44c3a27a69b153cef9be4b8e481150e
  Author: Johannes Doerfert <johannes at jdoerfert.de>
  Date:   2020-05-11 (Mon, 11 May 2020)

  Changed paths:
    M llvm/lib/Transforms/IPO/Attributor.cpp
    M llvm/test/Transforms/Attributor/misc_crash.ll

  Log Message:
  -----------
  [Attributor][FIX] Disallow function signature rewrite for casted calls

We will now ensure ensure the return type of called function is the type
of all call sites we are going to rewrite. This avoids a problem
partially fixed by D79680. The part that was not covered is a use of
this "weird" casted call site (see `@func3` in `misc_crash.ll`).

misc_crash.ll checks are auto-generated now.


Compare: https://github.com/llvm/llvm-project/compare/6f300105d21e...8d94d3c3b44c


More information about the All-commits mailing list