[all-commits] [llvm/llvm-project] dca4b7: [Analysis] resolveAllCalls - fix use after std::mo...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Sat Oct 3 10:34:59 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: dca4b7130de547860925631295acfce33130a100
      https://github.com/llvm/llvm-project/commit/dca4b7130de547860925631295acfce33130a100
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-10-03 (Sat, 03 Oct 2020)

  Changed paths:
    M llvm/lib/Analysis/StackSafetyAnalysis.cpp

  Log Message:
  -----------
  [Analysis] resolveAllCalls - fix use after std::move warning. NFCI.

We can't use Use.Calls after its std::move()'d to TmpCalls as it will be in an undefined state. Instead, swap with the known empty map in TmpCalls so we can then safely emplace_back into the now empty Use.Calls.

Fixes clang static analyzer warning.


  Commit: 53fc426088d7e48272bfc37a3881a7a6fe405940
      https://github.com/llvm/llvm-project/commit/53fc426088d7e48272bfc37a3881a7a6fe405940
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2020-10-03 (Sat, 03 Oct 2020)

  Changed paths:
    A llvm/test/Transforms/InstCombine/funnel.ll

  Log Message:
  -----------
  [InstCombine] Add tests for or(shl(x,c1),lshr(y,c2)) patterns that could fold to funnel shifts

Some initial test coverage toward fixing PR46896 - these are just copied from rotate.ll


Compare: https://github.com/llvm/llvm-project/compare/be185b6a7355...53fc426088d7


More information about the All-commits mailing list