[all-commits] [llvm/llvm-project] 416a11: [GlobalOpt] don't hoist constant expressions that ...

RotateRight via All-commits all-commits at lists.llvm.org
Fri Aug 27 05:25:52 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 416a119f9e5ce45df4c26215d19ed5be29b052cd
      https://github.com/llvm/llvm-project/commit/416a119f9e5ce45df4c26215d19ed5be29b052cd
  Author: Sanjay Patel <spatel at rotateright.com>
  Date:   2021-08-27 (Fri, 27 Aug 2021)

  Changed paths:
    M llvm/lib/Transforms/IPO/GlobalOpt.cpp
    M llvm/test/Transforms/GlobalOpt/constant-can-trap.ll

  Log Message:
  -----------
  [GlobalOpt] don't hoist constant expressions that can trap

We try to forward a stored-once-constant-value from one global access
to another, but that's not safe if the constant value is an expression
that can trap.

The tests are reduced from the miscompile examples in:
https://llvm.org/PR47578

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




More information about the All-commits mailing list