[PATCH] D61257: [CostModel][X86] Reduce masked load/store AVX1/AVX2 costs
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 29 05:48:34 PDT 2019
RKSimon created this revision.
RKSimon added reviewers: andreadb, craig.topper, lebedev.ri, ABataev.
Herald added a project: LLVM.
A mixture of internal tests and review of the scheduler models indicates we're overestimating the cost of a masked load/store, which we're estimating at 4x regular memory ops. More realistic values indicates that its closer to 2x.
e.g. SandyBridge
defm : X86WriteRes<WriteFMaskedLoad, [SBPort23,SBPort05], 8, [1,2], 3>;
defm : X86WriteRes<WriteFMaskedLoadY, [SBPort23,SBPort05], 9, [1,2], 3>;
defm : X86WriteRes<WriteFMaskedStore, [SBPort4,SBPort01,SBPort23], 5, [1,1,1], 3>;
defm : X86WriteRes<WriteFMaskedStoreY, [SBPort4,SBPort01,SBPort23], 5, [1,1,1], 3>;
e.g. Btver2
defm : X86WriteRes<WriteFMaskedLoad, [JLAGU, JFPU01, JFPX], 6, [1, 2, 2], 1>;
defm : X86WriteRes<WriteFMaskedLoadY, [JLAGU, JFPU01, JFPX], 6, [2, 4, 4], 2>;
defm : X86WriteRes<WriteFMaskedStore, [JSAGU, JFPU01, JFPX], 6, [1, 1, 4], 1>;
defm : X86WriteRes<WriteFMaskedStoreY, [JSAGU, JFPU01, JFPX], 6, [2, 2, 4], 2>;
Repository:
rL LLVM
https://reviews.llvm.org/D61257
Files:
lib/Target/X86/X86TargetTransformInfo.cpp
test/Analysis/CostModel/X86/masked-intrinsic-cost-widen.ll
test/Analysis/CostModel/X86/masked-intrinsic-cost.ll
test/Transforms/LoopVectorize/X86/masked_load_store.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61257.197093.patch
Type: text/x-patch
Size: 68404 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190429/ab184c7e/attachment-0001.bin>
More information about the llvm-commits
mailing list