RFR (M): 7177003 C1: LogCompilation support (original) (raw)

Christian Thalinger christian.thalinger at oracle.com
Fri Sep 28 08:55:58 PDT 2012


That looks good. I guess you tested a debug build with PrintCompilation and LogCompilation?

-- Chris

On Sep 28, 2012, at 5:08 AM, Vladimir Ivanov <vladimir.x.ivanov at oracle.com> wrote:

Chris,

Nice code cleanup! How about that? [1] Best regards, Vladimir Ivanov [1] http://cr.openjdk.java.net/~vlivanov/7177003/webrev.02 On 09/28/12 02:15, Christian Thalinger wrote:

On Sep 26, 2012, at 8:13 AM, Vladimir Ivanov <vladimir.x.ivanov at oracle.com> wrote:

Thank you, Vladimir and Chris.

Here are updated changes [1]: - merged with the latest changes in hotspot-comp - removed intx->int conversion as you suggested - removed "receiver is statically known" message from PrintInlining output, but left in it the log Looking at this code: void GraphBuilder::printinlining(ciMethod* callee, const char* msg, bool success) { + CompileLog* log = compilation()->log(); + if (log != NULL) { + if (success) { + if (strcmp(msg,"") != 0) + log->inlinesuccess(msg); + else + log->inlinesuccess("receiver is statically known"); + } else { + log->inlinefail(msg); + } + } + if (!PrintInlining) return; assert(msg != NULL, "must be"); CompileTask::printinlining(callee, scope()->level(), bci(), msg); if (success && CIPrintMethodCodes) { callee->printcodes(); I noticed that we now can pass in NULL as msg since CompileTask::printinlining takes care of that (the code before I moved it to CompileTask probably didn't and that's why the assert is there). I suggest to remove the above assert, default GraphBuilder::printinlining's msg argument to NULL and change: - printinlining(callee, ""); + printinlining(callee); Then we can get rid of the strcmp as well. -- Chris

Best regards, Vladimir Ivanov [1] http://cr.openjdk.java.net/~vlivanov/7177003/webrev.01/ On 09/26/12 02:47, Vladimir Kozlov wrote: Good changes! Small thing: in method.cpp and deoptimization.cpp remove (int) cast from os::currentthreadid() if you want tou use UINTX format (it reads 64bit in 64b VM). Thanks, Vladimir Vladimir Ivanov wrote: 7177003: C1: LogCompilation support http://cr.openjdk.java.net/~vlivanov/7177003/

LogCompilation support in C1 - both client [1] and tiered [2] modes. These changes are only for Hotspot. LogCompilation tool changes will be sent separately. Also: - print code cache state (after each nmethod installation) Example: <codecache_ _totalblobs='258'_ _nmethods='50'_ _adapters='133'_ _freecodecache='98839808'_ _largestfreeblock='98832512'/> - consistent nmethod numbering between ordinary and OSR compilations - correct printing of thread id's - added missed tty locks where necessary Thanks! Best regards, Vladimir Ivanov PS: actually, if it simplifies review, I can send cleanup/small enhancements as a separate change. PPS: phew! Finally deciphered how deoptimization in C1 works =) [1] http://cr.openjdk.java.net/~vlivanov/7177003/webrev.00/compilation.client.log [2] http://cr.openjdk.java.net/~vlivanov/7177003/webrev.00/compilation.tiered.log



More information about the hotspot-compiler-dev mailing list