1.1 --- a/src/share/vm/runtime/compilationPolicy.cpp Thu May 15 18:23:26 2014 -0400 1.2 +++ b/src/share/vm/runtime/compilationPolicy.cpp Thu May 22 15:52:41 2014 -0400 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -170,7 +170,7 @@ 1.11 void NonTieredCompPolicy::trace_osr_completion(nmethod* osr_nm) { 1.12 if (TraceOnStackReplacement) { 1.13 if (osr_nm == NULL) tty->print_cr("compilation failed"); 1.14 - else tty->print_cr("nmethod " INTPTR_FORMAT, osr_nm); 1.15 + else tty->print_cr("nmethod " INTPTR_FORMAT, p2i(osr_nm)); 1.16 } 1.17 } 1.18 #endif // !PRODUCT 1.19 @@ -417,6 +417,7 @@ 1.20 } 1.21 1.22 #ifndef PRODUCT 1.23 +PRAGMA_FORMAT_NONLITERAL_IGNORED_EXTERNAL 1.24 void NonTieredCompPolicy::trace_frequency_counter_overflow(methodHandle m, int branch_bci, int bci) { 1.25 if (TraceInvocationCounterOverflow) { 1.26 MethodCounters* mcs = m->method_counters(); 1.27 @@ -428,7 +429,10 @@ 1.28 bci == InvocationEntryBci 1.29 ? "comp-policy cntr ovfl @ %d in entry of " 1.30 : "comp-policy cntr ovfl @ %d in loop of "; 1.31 +PRAGMA_DIAG_PUSH 1.32 +PRAGMA_FORMAT_NONLITERAL_IGNORED_INTERNAL 1.33 tty->print(msg, bci); 1.34 +PRAGMA_DIAG_POP 1.35 m->print_value(); 1.36 tty->cr(); 1.37 ic->print(); 1.38 @@ -503,7 +507,7 @@ 1.39 if (TraceCompilationPolicy) { 1.40 tty->print("method invocation trigger: "); 1.41 m->print_short_name(tty); 1.42 - tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", (address)m(), m->code_size()); 1.43 + tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", p2i((address)m()), m->code_size()); 1.44 } 1.45 RegisterMap reg_map(thread, false); 1.46 javaVFrame* triggerVF = thread->last_java_vframe(®_map); 1.47 @@ -512,7 +516,7 @@ 1.48 1.49 if (first->top_method()->code() != NULL) { 1.50 // called obsolete method/nmethod -- no need to recompile 1.51 - if (TraceCompilationPolicy) tty->print_cr(" --> " INTPTR_FORMAT, first->top_method()->code()); 1.52 + if (TraceCompilationPolicy) tty->print_cr(" --> " INTPTR_FORMAT, p2i(first->top_method()->code())); 1.53 } else { 1.54 if (TimeCompilationPolicy) accumulated_time()->start(); 1.55 GrowableArray<RFrame*>* stack = new GrowableArray<RFrame*>(50); 1.56 @@ -640,7 +644,7 @@ 1.57 if (TraceCompilationPolicy && Verbose) { 1.58 tty->print("\n\t check caller: "); 1.59 next_m->print_short_name(tty); 1.60 - tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", (address)next_m(), next_m->code_size()); 1.61 + tty->print(" ( interpreted " INTPTR_FORMAT ", size=%d ) ", p2i((address)next_m()), next_m->code_size()); 1.62 } 1.63 1.64 current = next;