[PATCH] D90173: [PowerPC] Exploit splat instruction xxsplti32dx in Power10
Albion Fung via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Dec 2 13:12:38 PST 2020
Conanap added a comment.
Replied to a comment
================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:9213
+
+ if (bot) {
+ SplatNode = DAG.getNode(
----------------
NeHuang wrote:
> I do not quite understand the `if` and `else` logic here, current logic seems we can overwrite `SplatNode` after we execute `SplatNode = DAG.getTargetConstant(0, dl, MVT::v2i64);`
> Is that as expected?
Thanks for bringing this up. `SplatNode` is reused in `if (Lo)` and `if (Hi)`; it just saves a variable and a ternary statement (`if (Hi)` will also have to check if `Lo` created a `SDNode` before deciding between `SplatNode` or the `SDNode` created by `Lo`), but can understandably be confusing. I could separate them in to different variables and if statements to make it easier to understand if that's preferred.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D90173/new/
https://reviews.llvm.org/D90173
More information about the cfe-commits
mailing list