RFR (S): 8012260: ciReplay: Include PID into the name of replay data file
Vladimir Kozlov
vladimir.kozlov at oracle.com
Wed Apr 17 08:54:01 PDT 2013
Missing check (fd != -1) before fdopen:
1036 FILE* replay_data_file = fdopen(fd, "w");
Vladimir
On 4/17/13 8:19 AM, Vladimir Ivanov wrote:
> Thanks for feedback, Vladimir!
>
> Here's updated version:
> http://cr.openjdk.java.net/~vlivanov/8012260/webrev.01
>
> Best regards,
> Vladimir Ivanov
>
> On 4/17/13 9:22 AM, Vladimir Kozlov wrote:
>> Make it product flag since it is ON by default (and it is not diagnostic
>> but error dump).
>>
>> Also why not reuse code which opens ErrorFile (hs_err*)?
>>
>> Compilation::compile_only_this_method() allocates fileStream on stack:
>>
>> fileStream stream(fopen("c1_compile_only", "wt"));
>>
>> thanks,
>> Vladimir
>>
>> On 4/16/13 5:01 PM, Vladimir Ivanov wrote:
>>> http://cr.openjdk.java.net/~vlivanov/8012260/webrev.00
>>> 43 lines changed: 16 ins; 21 del; 6 mod;
>>>
>>> Changed naming scheme for compilation replay data files from
>>> 'replay.txt' to 'replay_pid%p.log', where %p is substituted w/ pid. It
>>> allows to easily correspond replay file with hs_err file and makes
>>> overwriting of existing files very unlikely.
>>>
>>> Also, converted ReplayDataFile & DumpReplayDataOnError flags from
>>> develop to diagnostic, since they are useful in product binaries. Did
>>> some small cleanups.
>>>
>>> One question still bothers me. There's a memory allocation in
>>> VMError::report_and_die() I don't know how to avoid:
>>> + fileStream* replay_data_stream = new (ResourceObj::C_HEAP,
>>> mtCompiler) fileStream(replay_data_file);
>>>
>>> It's not new, I just moved it up from auxiliary method. Any ideas how to
>>> make VMError::report_and_die() allocation-free again? :-)
>>>
>>> Best regards,
>>> Vladimir Ivanov
>>>
More information about the hotspot-compiler-dev
mailing list