[all-commits] [llvm/llvm-project] ec9a94: [X86] Use MVT::i8 instead of MVT::i64 for shift am...

topperc via All-commits all-commits at lists.llvm.org
Thu Feb 6 13:32:27 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: ec9a94af4d5fb3270f2451fcbec5a3a99f4ac03a
      https://github.com/llvm/llvm-project/commit/ec9a94af4d5fb3270f2451fcbec5a3a99f4ac03a
  Author: Craig Topper <craig.topper at intel.com>
  Date:   2020-02-06 (Thu, 06 Feb 2020)

  Changed paths:
    M llvm/lib/Target/X86/X86ISelLowering.cpp
    A llvm/test/CodeGen/X86/pr44812.ll

  Log Message:
  -----------
  [X86] Use MVT::i8 instead of MVT::i64 for shift amount in BuildSDIVPow2

X86 uses i8 for shift amounts. This code can fail on a 32-bit target
if it runs after type legalization.

This code was copied from AArch64 and modified for X86, but the
shift amount wasn't changed to the correct type for X86.

Fixes PR44812




More information about the All-commits mailing list