[PATCH] D70479: [MIRVRegNamerUtils] Add additional hashing on MachineInstr flags.
Puyan Lotfi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 10 01:47:13 PST 2019
plotfi marked 2 inline comments as done.
plotfi added inline comments.
================
Comment at: llvm/lib/CodeGen/MIRVRegNamerUtils.cpp:123
+ MIOperands.push_back(MachineInstr::FPExcept);
+
auto HashMI = hash_combine_range(MIOperands.begin(), MIOperands.end());
----------------
aditya_nandakumar wrote:
> I'd probably just do
>
> ```
> if (unsigned Flag = MI.getFlags())
> MIOperands.push_back(Flag);
> ```
> That should be equivalent to what you're doing above.
> In fact, I'd just simplify it to
> ```
> MIOperands.push_back(MI.getFlags());
> ```
> with 0 (no flags) being also valid enough to contribute to the hash.
ditto
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70479/new/
https://reviews.llvm.org/D70479
More information about the llvm-commits
mailing list