RFR: 8219241: Provide basic virtualization related info in the hs_error file on linux/windows x86_64

David Holmes david.holmes at oracle.com
Mon Apr 8 21:54:55 UTC 2019


On 8/04/2019 6:07 pm, Baesken, Matthias wrote:
> 
> Hi David,
> 
>>>>
>>>> So compiler ifdefs in the cpu files is the way to handle this.
>>>>
>>>
>>> Hello, I moved the  coding from
>>>
>>> src/hotspot/os_cpu/linux_x86/vm_version_linux_x86.cpp
>>> src/hotspot/os_cpu/windows_x86/vm_version_windows_x86.cpp
>>>
>>>
>>> Into src/hotspot/cpu/x86/vm_version_x86.cpp   and guarded it with the
>> compiler macros :
>>>
>>> http://cr.openjdk.java.net/~mbaesken/webrevs/8219241.5/
>>
>> I'm not clear why we are still using os-guards as well?
>>
>> + #elif defined(__GNUC__) && defined(__linux__)
>>
>> + #if defined(_LP64) && (defined(__linux__) || defined(_WIN64))
>>
>> won't this code still execute okay on Solaris/BSD/MacOS ?
>>
> 
> It executes  okay on  MacOS .

So why exclude it on Mac?

> Most likely  it works also  on  Solaris x86,  not sure ; only  Solaris Sparc  is in the list of Solaris build platforms supported in JDK13 :
> 
>    https://wiki.openjdk.java.net/display/Build/Supported+Build+Platforms
> 
> I would prefer to keep the  os-guards .

I don't agree with making code unnecessarily platform-specific. I think 
someone may want to extend this for 32-bit support as well.

I'd like to hear other opinions. This latest version needs a second 
review anyway.

Thanks,
David

> Best regards, Matthias
> 


More information about the hotspot-dev mailing list