[PATCH] D134697: [X86] Consider branch probability in avoiding Store Forward Block

wqf via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 26 21:19:54 PDT 2022


shwqf created this revision.
shwqf added reviewers: lsaba, RKSimon, craig.topper.
Herald added subscribers: StephenFan, pengfei, hiraditya.
Herald added a project: All.
shwqf requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Packed memory accesses may be broken because of predecessors, no matter how low the branch probabilities are.

This patch tries to fix two unprofitable cases:

a) Potential blockers from low-branch-probability predecessor.

b) Potential blockers from the block itself (a short self loop), memory address may change in each iteration.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D134697

Files:
  llvm/lib/Target/X86/X86AvoidStoreForwardingBlocks.cpp
  llvm/test/CodeGen/X86/avoid-sfb-g-no-change3.mir
  llvm/test/CodeGen/X86/avoid-sfb.ll
  llvm/test/CodeGen/X86/opt-pipeline.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134697.463083.patch
Type: text/x-patch
Size: 34680 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220927/c8c4b2bc/attachment-0001.bin>


More information about the llvm-commits mailing list