[PATCH] D87674: [AMDGPU] Insert waitcnt after returning from call
Madhur Amilkanthwar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 15 08:44:53 PDT 2020
madhur13490 added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp:885
+ (MI.isReturn() && MI.isCall() && !callWaitsOnFunctionEntry())) {
+ if (callWaitsOnFunctionReturn(MI))
+ Wait = Wait.combined(AMDGPU::Waitcnt::allZero(ST->hasVscnt()));
----------------
please fuse these two "if" conditions. They are already unreadable.
================
Comment at: llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp:1212
+ auto I = ++MI.getIterator();
+ // Don't insert waitcnt if this function returns too
+ if (I.isEnd() || I->isReturn())
----------------
nit: "Don't insert waitcnt if this function returns *immediately*"
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D87674/new/
https://reviews.llvm.org/D87674
More information about the llvm-commits
mailing list