Skip to content

Commit 520a509

Browse files
feedback
1 parent 98650ae commit 520a509

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

llvm/lib/Target/X86/MCA/X86CustomBehaviour.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,9 @@ void X86InstrPostProcess::useStackEngine(std::unique_ptr<Instruction> &Inst,
4141
// TODO(boomanaiden154): We currently do not handle PUSHF/POPF because we
4242
// have not done the necessary benchmarking to see if they are also
4343
// optimized by the stack engine.
44+
// TODO: We currently just remove all RSP writes from stack operations. This
45+
// is not fully correct because we do not model sync uops which will
46+
// delay subsequent rsp using non-stack instructions.
4447
if (X86::isPOP(MCI.getOpcode()) || X86::isPUSH(MCI.getOpcode())) {
4548
auto *StackRegisterDef =
4649
llvm::find_if(Inst->getDefs(), [](const WriteState &State) {

0 commit comments

Comments
 (0)