Don't copy fill array data to quick literal pool.
Currently quick copies the fill array data from the dex file to the literal
pool. It then has to go through hoops to pass this PC relative address down
to out-of-line code. Instead, pass the offset of the table to the out-of-line
code and use the CodeItem data associated with the ArtMethod. This reduces
the size of oat code while greatly simplifying it.
Unify the FillArrayData implementation in quick, portable and the interpreters.
Change-Id: I9c6971cf46285fbf197856627368c0185fdc98ca
diff --git a/compiler/dex/mir_graph.h b/compiler/dex/mir_graph.h
index f14b187..fe6fb75 100644
--- a/compiler/dex/mir_graph.h
+++ b/compiler/dex/mir_graph.h
@@ -338,7 +338,7 @@
uint32_t method_lowering_info;
} meta;
- explicit MIR():offset(0), optimization_flags(0), m_unit_index(0), bb(NullBasicBlockId),
+ explicit MIR() : offset(0), optimization_flags(0), m_unit_index(0), bb(NullBasicBlockId),
next(nullptr), ssa_rep(nullptr) {
memset(&meta, 0, sizeof(meta));
}
@@ -572,7 +572,7 @@
* @return Returns the raw table pointer.
*/
const uint16_t* GetTable(MIR* mir, uint32_t table_offset) const {
- return GetInsns(mir->m_unit_index) + mir->offset + table_offset;
+ return GetInsns(mir->m_unit_index) + mir->offset + static_cast<int32_t>(table_offset);
}
unsigned int GetNumBlocks() const {