[PATCH] D127554: [PowerPC] Allow llvm.ppc.cfence to accept pointer types

ChenZheng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 16 21:21:01 PDT 2022


shchenz added a comment.

LGTM with one nit.

Thanks for fixing this.



================
Comment at: llvm/include/llvm/IR/IntrinsicsPowerPC.td:1500
+// Backend is supposed to lower these types to appropriate MVTs.
+def int_ppc_cfence : Intrinsic<[], [llvm_any_ty], []>;
 
----------------
Maybe we need to add assertion in `PPCTargetLowering::emitTrailingFence` to explicitly check when we generate ppc_cfence, we are not generating fence for any undesired types? After this change, any type is accepted, for example fp128 or vector types.

IR level verifier can be disabled and the assertion when lower this intrinsic in ISEL is a little late IMO.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D127554



More information about the llvm-commits mailing list