RFR: 8262491: AArch64: CPU description should contain compatible board list [v2]
Anton Kozlov
akozlov at openjdk.java.net
Tue Mar 2 07:29:40 UTC 2021
On Mon, 1 Mar 2021 14:47:04 GMT, Yasumasa Suenaga <ysuenaga at openjdk.org> wrote:
>> src/hotspot/os_cpu/linux_aarch64/vm_version_linux_aarch64.cpp line 172:
>>
>>> 170:
>>> 171: void VM_Version::get_compatible_board(char *buf, int buflen) {
>>> 172: const char *aarch64_label = "AArch64";
>>
>> All platforms seem to declare themselves `AArch64`, this probably can be in the shared aarch64 code.
>
> VM_Version is not inherited, and platform-specific functions are declared in os_linux and os_windows. So I think it is difficult to declare shared (default) function for this purpose.
> It is the best if we declare shared function, and override it like a virtual function. But it seems to be difficult. Do you have any idea?
Probably we can assume this function to optionally return a board name. IMHO ideally an empty string should a valid output. Now the output from this function is the prefix and the features string is the suffix of the complete string CPU description. What if we start with the constant `AArch64` prefix in the shared CPU code, append output from this function, and then append the features string?
-------------
PR: https://git.openjdk.java.net/jdk/pull/2759
More information about the hotspot-dev
mailing list