[all-commits] [llvm/llvm-project] e4dd1d: Add assert to avoid unexpected situation

XinWang10 via All-commits all-commits at lists.llvm.org
Tue Apr 18 00:24:07 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: e4dd1d033063c8a669c7e77d9d7f88c1d3058e88
      https://github.com/llvm/llvm-project/commit/e4dd1d033063c8a669c7e77d9d7f88c1d3058e88
  Author: Wang, Xin10 <xin10.wang at intel.com>
  Date:   2023-04-18 (Tue, 18 Apr 2023)

  Changed paths:
    M llvm/include/llvm/CodeGen/MachineBlockFrequencyInfo.h

  Log Message:
  -----------
  Add assert to avoid unexpected situation

In line 68, func getBlockFreqRelativeToEntryBlock assume getEntryFreq() is
non-zero, but the function could return 0, add assert to confirm it.

Reviewed By: HaohaiWen

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




More information about the All-commits mailing list