Faster `ClassTable::UpdateClass()`.

In the `ClassTable::UpdateClass()`, both the old and the new
`Class` objects reference the same dex file and type index.
Therefore it's better to do the lookup with the new `Class`
object as the `Class:DescriptorEquals(ObjPtr<Class>)` can
avoid the string comparison for the descriptor match in this
case and we compare descriptors only for hash conflicts.

Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Bug: 338123769
Change-Id: I23960c9c3b34b7f7fdd2fce6b191fd9c4efe7320
3 files changed