[PATCH] [SimplifyCFG] Teach when it is profitable to speculate calls to @llvm.cttz/ctlz.
Quentin Colombet
qcolombet at apple.com
Wed Dec 17 09:19:55 PST 2014
Hi Andrea,
> My idea is to do the following (if you agree):
>
> - move this logic into CodeGenPrepare;
> - guard the code against a check on the subtarget (something like 'isCheapToSpeculateCttzCtlz').
> - On X86 that method would return true if we have TZCNT/LZCNT or if we have feature CMOV.
Sounds good to me.
Thanks,
-Quentin
http://reviews.llvm.org/D6679
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
More information about the llvm-commits
mailing list