[all-commits] [llvm/llvm-project] 3a0e01: [NVPTX] Lower -1/x to neg.f64(rcp.rn.f64) instead ...

Rajat Bajpai via All-commits all-commits at lists.llvm.org
Tue Jul 16 00:15:44 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 3a0e01543212c1e1c80f5665aee0e12289e06a29
      https://github.com/llvm/llvm-project/commit/3a0e01543212c1e1c80f5665aee0e12289e06a29
  Author: Rajat Bajpai <rbajpai at nvidia.com>
  Date:   2024-07-16 (Tue, 16 Jul 2024)

  Changed paths:
    M llvm/lib/Target/NVPTX/NVPTXInstrInfo.td
    A llvm/test/CodeGen/NVPTX/rcp-opt.ll

  Log Message:
  -----------
  [NVPTX] Lower -1/x to neg.f64(rcp.rn.f64) instead of fdiv (#98343)

The NVPTX backend lowers 1/x to rcp.rn.f64 instruction instead of slower
fdiv instruction. However, in the case of -1/x, it uses the slower fdiv
instruction. After this change, -1/x will be lowered into neg.f64
(rcp.rn.f64).



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list