Fix relocate in place to handle arbitrary app image layout

Previously the relocation had bugs where it would not work correctly
if the iftable was after the class since the object arrays would not
yet be updated to be the relocated address when we went through them
to fixup the ArtMethod pointers.

Also fixes a bug where the superclass of a class could not be
updated when we walk through it for visiting instance fields of
large objects.

Changed RelocateInPlace to use a simplier single pass approach.

Bug: 27906566
Bug: 22858531

(cherry picked from commit 564289c753cbe3521f9523b350bd713c1fe2fbd4)

Change-Id: I97affab6ff353dfdc4d1bf31df69ceb96a0c7a1a
2 files changed