From 81bc509784e1bf20f9d92ce01ab9702123e2ef92 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Fri, 30 Sep 2011 17:25:59 -0700 Subject: Silence a misleading compiler warning. Now we use this code for wide volatiles, it can't always complain about the field being unresolved. Change-Id: Ieb0663d654f8af99890d4925cd8897f5c95c6001 --- src/compiler/codegen/arm/MethodCodegenDriver.cc | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'src/compiler/codegen/arm/MethodCodegenDriver.cc') diff --git a/src/compiler/codegen/arm/MethodCodegenDriver.cc b/src/compiler/codegen/arm/MethodCodegenDriver.cc index 9e026bea9f..80118d81fb 100644 --- a/src/compiler/codegen/arm/MethodCodegenDriver.cc +++ b/src/compiler/codegen/arm/MethodCodegenDriver.cc @@ -187,8 +187,7 @@ STATIC void genSput(CompilationUnit* cUnit, MIR* mir, RegLocation rlSrc) oatFlushAllRegs(cUnit); if (SLOW_FIELD_PATH || field == NULL) { // Slow path - LOG(INFO) << "Field " << fieldNameFromIndex(cUnit->method, fieldIdx) - << " unresolved at compile time"; + warnIfUnresolved(cUnit, fieldIdx, field); int funcOffset = isObject ? OFFSETOF_MEMBER(Thread, pSetObjStatic) : OFFSETOF_MEMBER(Thread, pSet32Static); loadWordDisp(cUnit, rSELF, funcOffset, rLR); @@ -252,8 +251,7 @@ STATIC void genSputWide(CompilationUnit* cUnit, MIR* mir, RegLocation rlSrc) bool isVolatile = false; #endif if (SLOW_FIELD_PATH || field == NULL || isVolatile) { - LOG(INFO) << "Field " << fieldNameFromIndex(cUnit->method, fieldIdx) - << " unresolved at compile time"; + warnIfUnresolved(cUnit, fieldIdx, field); loadWordDisp(cUnit, rSELF, OFFSETOF_MEMBER(Thread, pSet64Static), rLR); loadConstant(cUnit, r0, mir->dalvikInsn.vB); loadCurrMethodDirect(cUnit, r1); @@ -304,8 +302,7 @@ STATIC void genSgetWide(CompilationUnit* cUnit, MIR* mir, #endif oatFlushAllRegs(cUnit); if (SLOW_FIELD_PATH || field == NULL || isVolatile) { - LOG(INFO) << "Field " << fieldNameFromIndex(cUnit->method, fieldIdx) - << " unresolved at compile time"; + warnIfUnresolved(cUnit, fieldIdx, field); loadWordDisp(cUnit, rSELF, OFFSETOF_MEMBER(Thread, pGet64Static), rLR); loadConstant(cUnit, r0, mir->dalvikInsn.vB); loadCurrMethodDirect(cUnit, r1); @@ -354,9 +351,8 @@ STATIC void genSget(CompilationUnit* cUnit, MIR* mir, (mir->dalvikInsn.opcode == OP_SGET_OBJECT_VOLATILE)); oatFlushAllRegs(cUnit); if (SLOW_FIELD_PATH || field == NULL) { - LOG(INFO) << "Field " << fieldNameFromIndex(cUnit->method, fieldIdx) - << " unresolved at compile time"; // Slow path + warnIfUnresolved(cUnit, fieldIdx, field); int funcOffset = isObject ? OFFSETOF_MEMBER(Thread, pGetObjStatic) : OFFSETOF_MEMBER(Thread, pGet32Static); loadWordDisp(cUnit, rSELF, funcOffset, rLR); -- cgit v1.2.3-59-g8ed1b