[PATCH] D61236: [NFC] Add a static function to do the endian check
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Apr 28 01:15:23 PDT 2019
RKSimon added inline comments.
================
Comment at: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:6128
+static bool matchEndian(const SmallVector<int64_t, 4> &ByteOffsets,
+ int64_t FirstOffset, bool &IsBigEndian) {
+ std::function<unsigned(unsigned, unsigned)> LittleEndianByteAt = [](
----------------
Please clang-format the function
================
Comment at: llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp:6132
+ std::function<unsigned(unsigned, unsigned)> BigEndianByteAt = [](
+ unsigned BW, unsigned i) { return BW - i - 1; };
+
----------------
Anyway that we can avoid duplicate copies of LittleEndianByteAt + BigEndianByteAt?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61236/new/
https://reviews.llvm.org/D61236
More information about the llvm-commits
mailing list