Add an ImtConflictTable to better resolve IMT conflicts.
- Attach a ImtConflictTable to conflict runtime ArtMethod.
- Initially 0, a new one will be created at the first hit of
the conflict method.
- If the assembly code does not find a target method in the table,
we will create a new one again, copying the data from the previous
table and adding the new mapping.
Implemented for arm/arm64/x86/x64.
bug:27556801
bug:24769046
Change-Id: Ie74d1c77cf73d451a1142bdc5e3683f9f84bb4e7
diff --git a/compiler/image_writer.cc b/compiler/image_writer.cc
index 07bd0e3..c747ffa 100644
--- a/compiler/image_writer.cc
+++ b/compiler/image_writer.cc
@@ -1986,7 +1986,7 @@
const ImageInfo& image_info,
bool* quick_is_interpreted) {
DCHECK(!method->IsResolutionMethod()) << PrettyMethod(method);
- DCHECK(!method->IsImtConflictMethod()) << PrettyMethod(method);
+ DCHECK_NE(method, Runtime::Current()->GetImtConflictMethod()) << PrettyMethod(method);
DCHECK(!method->IsImtUnimplementedMethod()) << PrettyMethod(method);
DCHECK(method->IsInvokable()) << PrettyMethod(method);
DCHECK(!IsInBootImage(method)) << PrettyMethod(method);