[all-commits] [llvm/llvm-project] d8f7c6: AMDGPU/SILoadStoreOptimizer: fix a likely bug intr...

Nicolai Hähnle via All-commits all-commits at lists.llvm.org
Sat Nov 16 02:37:16 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: d8f7c68e28bd0b8eb49f752bd7d26aa767c0b078
      https://github.com/llvm/llvm-project/commit/d8f7c68e28bd0b8eb49f752bd7d26aa767c0b078
  Author: Nicolai Hähnle <nicolai.haehnle at amd.com>
  Date:   2019-11-16 (Sat, 16 Nov 2019)

  Changed paths:
    M llvm/lib/Target/AMDGPU/SILoadStoreOptimizer.cpp

  Log Message:
  -----------
  AMDGPU/SILoadStoreOptimizer: fix a likely bug introduced recently

Summary:
We should check for same instruction class before checking whether they
have the same base address, else we might iterate out of bounds of a
MachineInstr operands list. The InstClass check is also cheaper.

This was introduced in SVN r373630.

Reviewers: tstellar

Subscribers: arsenm, kzhuravl, jvesely, wdng, yaxunl, dstuttard, tpr, t-tye, hiraditya, llvm-commits

Tags: #llvm

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




More information about the All-commits mailing list