[PATCH] D90431: [x86] add cost overrides for mul with overflow

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 29 14:20:00 PDT 2020


spatel created this revision.
spatel added reviewers: RKSimon, craig.topper, pengfei.
Herald added subscribers: hiraditya, mcrosier.
Herald added a project: LLVM.
spatel requested review of this revision.

I'm assuming the standard size integer instructions for this end up as something like:
	mulq	%rsi
	seto	%al

And the 'mul' generally has reciprocal throughput of 1 on typical implementations (higher latency, but that's not handled here).
The default costs may end up much higher than that, and that's what we see in the test diffs.


https://reviews.llvm.org/D90431

Files:
  llvm/lib/Target/X86/X86TargetTransformInfo.cpp
  llvm/test/Analysis/CostModel/X86/arith-overflow.ll
  llvm/test/Analysis/CostModel/X86/intrinsic-cost-kinds.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D90431.301753.patch
Type: text/x-patch
Size: 71482 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201029/e407cdbd/attachment.bin>


More information about the llvm-commits mailing list