[all-commits] [llvm/llvm-project] 0bf479: [WinEH] Fix inttoptr+phi optimization in presence ...

Reid Kleckner via All-commits all-commits at lists.llvm.org
Mon Mar 2 02:41:03 PST 2020


  Branch: refs/heads/release/10.x
  Home:   https://github.com/llvm/llvm-project
  Commit: 0bf4795d069642afe2a430521f3549e425f092c9
      https://github.com/llvm/llvm-project/commit/0bf4795d069642afe2a430521f3549e425f092c9
  Author: Reid Kleckner <rnk at google.com>
  Date:   2020-03-02 (Mon, 02 Mar 2020)

  Changed paths:
    M llvm/lib/Transforms/InstCombine/InstCombinePHI.cpp
    A llvm/test/Transforms/InstCombine/intptr8.ll

  Log Message:
  -----------
  [WinEH] Fix inttoptr+phi optimization in presence of catchswitch

getFirstInsertionPt's return value must be checked for validity before
casting it to Instruction*. Don't attempt to insert casts after a phi in
a catchswitch block.

Fixes PR45033, introduced in D37832.

Reviewed By: davidxl, hfinkel

Differential Revision: https://reviews.llvm.org/D75381

(cherry picked from commit 1adbe86d87bd4ecffc73ab17c7da56f44816f424)




More information about the All-commits mailing list