[PATCH] D72225: Align branches within 32-Byte boundary(Prefix padding)

Kan Shengchen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jan 5 04:48:08 PST 2020


skan created this revision.
skan added reviewers: annita.zhang, LuoYuanke, craig.topper, jyknight, reames, MaskRay.
Herald added subscribers: llvm-commits, hiraditya.
Herald added a project: LLVM.
skan added a parent revision: D72047:  Add an interface emitPrefix for MCCodeEmitter.

1. First we try to add segment prefixes to instructions before a branch.
2. If there is no sufficient room to add segment prefixes, NOP will be inserted before a branch.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D72225

Files:
  llvm/include/llvm/MC/MCAsmBackend.h
  llvm/include/llvm/MC/MCFragment.h
  llvm/include/llvm/MC/MCObjectStreamer.h
  llvm/lib/MC/MCAssembler.cpp
  llvm/lib/MC/MCFragment.cpp
  llvm/lib/MC/MCObjectStreamer.cpp
  llvm/lib/Target/X86/MCTargetDesc/X86AsmBackend.cpp
  llvm/test/MC/X86/align-branch-32-1a.s
  llvm/test/MC/X86/align-branch-32-2a.s
  llvm/test/MC/X86/align-branch-32-3a.s
  llvm/test/MC/X86/align-branch-32-4a.s
  llvm/test/MC/X86/align-branch-64-1e.s
  llvm/test/MC/X86/align-branch-64-2d.s
  llvm/test/MC/X86/align-branch-64-7a.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D72225.236235.patch
Type: text/x-patch
Size: 36596 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200105/86aef31d/attachment.bin>


More information about the llvm-commits mailing list