Skip to content
  1. Feb 27, 2020
  2. Feb 26, 2020
    • Hiroshi Yamauchi's avatar
      Devirtualize a call on alloca without waiting for post inline cleanup and next · 59fb9cde
      Hiroshi Yamauchi authored
      DevirtSCCRepeatedPass iteration.  Needs ReviewPublic
      
      This aims to fix a missed inlining case.
      
      If there's a virtual call in the callee on an alloca (stack allocated object) in
      the caller, and the callee is inlined into the caller, the post-inline cleanup
      would devirtualize the virtual call, but if the next iteration of
      DevirtSCCRepeatedPass doesn't happen (under the new pass manager), which is
      based on a heuristic to determine whether to reiterate, we may miss inlining the
      devirtualized call.
      
      This enables inlining in clang/test/CodeGenCXX/member-function-pointer-calls.cpp.
      59fb9cde
  3. Feb 25, 2020
    • Johannes Doerfert's avatar
      [OpenMP][Opt] Combine `struct ident_t*` during deduplication · 396b7253
      Johannes Doerfert authored
      If we deduplicate OpenMP runtime calls we have multiple `ident_t*` that
      represent information like source location. So far, we simply kept the
      one used by the replacement call. However, as exposed by PR44893, that
      can cause problems if we have stack allocated `ident_t` objects. While
      we need to revisit the use of these as well, it is clear that we
      eventually want to merge source location information in some way. With
      this patch we add the infrastructure to do so but without doing the
      actual merge. Instead we pick a global `ident_t` from the replaced
      calls, if possible, or create a new one with an unknown location
      instead.
      
      Reviewed By: JonChesterfield
      
      Differential Revision: https://reviews.llvm.org/D74925
      396b7253
    • Hideto Ueno's avatar
  4. Feb 24, 2020
  5. Feb 21, 2020
  6. Feb 20, 2020
  7. Feb 18, 2020
  8. Feb 17, 2020
  9. Feb 16, 2020
  10. Feb 15, 2020
  11. Feb 13, 2020
    • Johannes Doerfert's avatar
      [Attributor] Use fine-grained liveness in all helpers · 23f41f16
      Johannes Doerfert authored
      We used coarse-grained liveness before, thus we looked if the
      instruction was executed, but we did not use fine-grained liveness,
      hence if the instruction was needed or could be deleted even if the
      surrounding ones are live. This patches introduces this level of
      liveness checks together with other liveness queries, e.g., for uses.
      
      For more control we enforce that all liveness queries go through the
      Attributor.
      
      Test have been adjusted to reflect the changes or augmented to prevent
      deletion of the parts we want to check.
      
      Reviewed By: sstefan1
      
      Differential Revision: https://reviews.llvm.org/D73313
      23f41f16
    • Johannes Doerfert's avatar
      [Attributor] Ignore uses if a value is simplified · b2c76002
      Johannes Doerfert authored
      If we have a replacement for a value, via AAValueSimplify, the original
      value will lose all its uses. Thus, as long as a value is simplified we
      can skip the uses in checkForAllUses, given that these uses are
      transitive uses for the simplified version and will therefore affect the
      simplified version as necessary.
      
      Since this allowed us to remove calls without side-effects and a known
      return value, we need to make sure not to eliminate `musttail` calls.
      Those we keep around, or later remove the entire `musttail` call chain.
      b2c76002
    • Johannes Doerfert's avatar
      [Attributor] Use assumed information to determine side-effects · 86509e8c
      Johannes Doerfert authored
      We relied on wouldInstructionBeTriviallyDead before but that functions
      does not take assumed information, especially for calls, into account.
      The replacement, AAIsDead::isAssumeSideEffectFree, does.
      
      This change makes AAIsDeadCallSiteReturn more complex as we can have
      a dead call or only dead users.
      
      The test have been modified to include a side effect where there was
      none in order to keep the coverage.
      
      Reviewed By: sstefan1
      
      Differential Revision: https://reviews.llvm.org/D73311
      86509e8c
  12. Feb 12, 2020
  13. Feb 11, 2020
Loading