From 7642324bc8a5c839c669aebbb1fba61c05418651 Mon Sep 17 00:00:00 2001 From: Razvan A Lupusoru Date: Mon, 4 Aug 2014 09:38:46 -0700 Subject: ART: Implement kMirOpNullCheck The semantics of kMirOpNullCheck is to check object for null and throw exception in that case. However, the implementation for it is empty. This has been changed and appropriate dataflow have been added to correctly reflect behavior. In order to allow testing of implementation, the SpecialMethodInliner has been updated to get rid of invoke and use this instead. This helps all optimizations which do not check the MIR_INLINED flag because when invoke is left in, they believe that invoke will still be done. Change-Id: I62e425e42bdbc6357246fb949db5f79de73cf358 Signed-off-by: Razvan A Lupusoru --- compiler/dex/compiler_enums.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'compiler/dex/compiler_enums.h') diff --git a/compiler/dex/compiler_enums.h b/compiler/dex/compiler_enums.h index 63f3e640df..47cb4245d7 100644 --- a/compiler/dex/compiler_enums.h +++ b/compiler/dex/compiler_enums.h @@ -114,7 +114,13 @@ enum ExtendedMIROpcode { kMirOpFusedCmpgDouble, kMirOpFusedCmpLong, kMirOpNop, + + // @brief Do a null check on the object register. + // @details The backends may implement this implicitly or explicitly. This MIR is guaranteed + // to have the correct offset as an exception thrower. + // vA: object register kMirOpNullCheck, + kMirOpRangeCheck, kMirOpDivZeroCheck, kMirOpCheck, -- cgit v1.2.3-59-g8ed1b