[PATCH] D43329: [SystemZ, MachineScheduler] Refactor GenericScheduler::tryCandidate() to reuse parts in a new SystemZ scheduling strategy.
Jonas Paulsson via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 26 07:36:27 PST 2018
jonpa updated this revision to Diff 135902.
jonpa added a comment.
Herald added subscribers: nhaehnle, arsenm.
Thanks for review and advice, patch updated.
> OK. I think it's very hard to group heuristics in a meaningful way. Some repetition of code on the target side will make it easier to maintain. Backing up a bit, my broader concern is that when Targets become too dependent on the incidental behavior of machine independent code, it really inhibits changes to the machine independent code.
I have updated the patch per your guidelines where the target copies tryCandidate() while reusing only small utility functions like tryLess() etc, which are now declared in MachineScheduler.h.
> ... In your subtarget you can define your own symbolic constant...
OK, I tried that, which is at least a slight improvement to looking it up every time.
I had to wrap the AMDGPU tryLess() and tryGreater() methods in a local namespace to avoid conflict.
Do you still want me to split this into a separate patch without the SystemZ part? (You don't have to approve that)
https://reviews.llvm.org/D43329
Files:
include/llvm/CodeGen/MachineScheduler.h
lib/CodeGen/MachineScheduler.cpp
lib/Target/AMDGPU/SIMachineScheduler.cpp
lib/Target/SystemZ/SystemZMachineScheduler.cpp
lib/Target/SystemZ/SystemZMachineScheduler.h
lib/Target/SystemZ/SystemZTargetMachine.cpp
test/CodeGen/SystemZ/vec-cmp-cmp-logic-select.ll
test/CodeGen/SystemZ/vec-cmpsel.ll
test/CodeGen/SystemZ/vec-ctpop-01.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D43329.135902.patch
Type: text/x-patch
Size: 41846 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180226/e81d98e3/attachment.bin>
More information about the llvm-commits
mailing list