OSDN Git Service

Quick compiler: fix array overrun.
authorbuzbee <buzbee@google.com>
Sat, 31 May 2014 15:59:01 +0000 (08:59 -0700)
committerbuzbee <buzbee@google.com>
Sat, 31 May 2014 16:07:15 +0000 (09:07 -0700)
commit35ba7f3a78d38885ec54e61ed060d2771eeceea7
treeec2d7963f38205bf5eae6b1a35b3f85d0e1da4f8
parente4e04bbd86d1131b9f380a52a46b1a3b83335d5f
Quick compiler: fix array overrun.

MIRGraph::InlineCalls() was using the MIR opcode to recover
Dalvik instruction flags - something that is only valid for
Dalvik opcodes and not the set of extended MIR opcodes.

This is probably the 3rd or 4th time we've had a bug using
the MIR opcode in situations that are only valid for the Dalvik
opcode subset.  I took the opportunity to scan the code for
other cases of this (didn't find any), and did some cleanup while
I was in the neighborhood.

We should probably rework the DalvikOpcode/MirOpcode model whenver we
get around to removing DalvikInstruction from MIR.

Internal bug b/15352667: out-of-bound access in mir_optimization.cc

Change-Id: I75f06780468880892151e3cdd313e14bfbbaa489
compiler/dex/frontend.cc
compiler/dex/mir_analysis.cc
compiler/dex/mir_dataflow.cc
compiler/dex/mir_graph.cc
compiler/dex/mir_graph.h
compiler/dex/mir_optimization.cc
compiler/dex/portable/mir_to_gbc.cc
compiler/dex/quick/dex_file_method_inliner.cc
compiler/dex/quick/mir_to_lir.cc
compiler/dex/quick/x86/utility_x86.cc
compiler/dex/vreg_analysis.cc