Check if register class was changed in constrainOperandRegClass()
authorDaniel Sanders <daniel_l_sanders@apple.com>
Tue, 5 Apr 2022 18:23:51 +0000 (11:23 -0700)
committerDaniel Sanders <daniel_l_sanders@apple.com>
Tue, 5 Apr 2022 18:55:07 +0000 (11:55 -0700)
commit93977f37e67eae26d9bc88e5c3970c11d8861dfc
tree43818e5623fb4b98f07c5955e819ea5d8f47f95c
parent9bcaf6ddfe34943e6ae6a319097524c117908913
Check if register class was changed in constrainOperandRegClass()

NFC
When no actual change happens there's no need to notify the
observers about the fact the register class is being constrained.
So we should avoid notifying observers when no change has
happened, because this can dramatically affect compile
time for particular test cases.

Reviewed By: dsanders, arsenm

Differential Revision: https://reviews.llvm.org/D122615
llvm/lib/CodeGen/GlobalISel/Utils.cpp