[all-commits] [llvm/llvm-project] 69a89b: [NFC] Change isFPPredicate comparison to ignore lo...

David Stuttard via All-commits all-commits at lists.llvm.org
Fri Jul 10 04:12:37 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 69a89b54c62696d45731b48c26686cc4f9d652c6
      https://github.com/llvm/llvm-project/commit/69a89b54c62696d45731b48c26686cc4f9d652c6
  Author: dstuttar <david.stuttard at amd.com>
  Date:   2020-07-10 (Fri, 10 Jul 2020)

  Changed paths:
    M llvm/include/llvm/IR/InstrTypes.h
    M llvm/lib/Target/AMDGPU/SIISelLowering.cpp

  Log Message:
  -----------
  [NFC] Change isFPPredicate comparison to ignore lower bound

Summary:
Since changing the Predicate to be an unsigned enum, the lower bound check for
isFPPredicate no longer needs to check the lower bound, since
it will always evaluate to true.

Also fixed a similar issue in SIISelLowering.cpp by removing the need for
comparing to FIRST and LAST predicates

Added an assert to the isFPPredicate comparison to flag if the
FIRST_FCMP_PREDICATE is ever changed to anything other than 0, in which case the
logic will break.

Without this change warnings are generated in VS.

Change-Id: I358f0daf28c0628c7bda8ad4cab4e1757b761bab

Subscribers: arsenm, jvesely, nhaehnle, hiraditya, kerbowa, llvm-commits

Tags: #llvm

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




More information about the All-commits mailing list