On Mon, 4 May 2026 10:37:43 GMT, Joel Sikström <[email protected]> wrote:

>> This implements "jcmd on core files" for Linux, and for MiniDumps on Windows 
>> (MacOS is "future work").
>> jcmd "revives" the VM memory and .so/.dll from the core/minidump, and runs 
>> the existing native diagnostic command parser and command implementations.
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> src/hotspot/share/runtime/os.hpp line 274:
> 
>> 272:                                                // and VM ergonomics 
>> processing
>> 273: 
>> 274:   static void revive_init();                   // Process revival
> 
> To me it looks like this is only implemented on AIX/BSD, as no-ops. Windows 
> and Linux doesn't implement this function, but `os::win32::revive_init` and 
> `os::Linux::revive_init` respectively instead. Should they all implement the 
> global, shared, one instead?
> 
> Then we could change the code in `threads.cpp` to something like the 
> following, maybe with a fatal @YaSuenag suggests:
> 
> #if defined(LINUX) || defined(_WINDOWS)
>   os::revive_init();
> #else
>   // maybe a fatal
> #endif

Yes, thanks for both comments, I was meaning to tidy this up...

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/31011#discussion_r3188625404

Reply via email to