[PATCH] D37775: Add a verifier test to check the access on both sides of COPY are the same

Roman Tereshin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 18 14:40:13 PST 2018


rtereshin added inline comments.


================
Comment at: lib/CodeGen/MachineVerifier.cpp:985
+      assert(DstSize && "Expecting size here");
+      if (SrcSize != DstSize)
+        // Catch only obvious cases not involving subregs for now.
----------------
What if neither of the registers has a class? That would mean, both registers have LLTs. Then, the check won't complain if those LLTs have the same size in bits, but don't exactly match, like `v2s32` and `v4s16`, for instance.

Shouldn't LLTs match exactly if both are valid?


https://reviews.llvm.org/D37775





More information about the llvm-commits mailing list