[PATCH] D105360: [PowerPC] Fix popcntb XL Compat Builtin for 32bit

Amy Kwan via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 5 06:36:33 PDT 2021


amyk added inline comments.


================
Comment at: llvm/lib/Target/PowerPC/PPCInstr64Bit.td:830
 
-def POPCNTB : XForm_11<31, 122, (outs g8rc:$rA), (ins g8rc:$rS),
-                       "popcntb $rA, $rS", IIC_IntGeneral,
-                       [(set i64:$rA, (int_ppc_popcntb i64:$rS))]>;
+let isCodeGenOnly = 1 in
+def POPCNTB8 : XForm_11<31, 122, (outs g8rc:$rA), (ins g8rc:$rS),
----------------
Can we add a comment on why this is needed?


================
Comment at: llvm/test/CodeGen/PowerPC/builtins-ppc-xlcompat-sync-32.ll:1
+; RUN: llc -verify-machineinstrs -mtriple=powerpc-unknown-aix \
+; RUN: -mcpu=pwr7 < %s | FileCheck %s
----------------
You can use `update_llc_test_checks.py` to update these. 
Also nit, but might be nice to add `-ppc-asm-full-reg-names`.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105360/new/

https://reviews.llvm.org/D105360



More information about the cfe-commits mailing list