RFR: 8262491: AArch64: CPU description should contain compatible board list [v5]

Yasumasa Suenaga ysuenaga at openjdk.java.net
Wed Mar 3 12:25:10 UTC 2021


On Wed, 3 Mar 2021 10:49:41 GMT, Andrew Haley <aph at openjdk.org> wrote:

>> Yasumasa Suenaga has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix compile error in Windows AArch64
>
> src/hotspot/os_cpu/linux_aarch64/vm_version_linux_aarch64.cpp line 178:
> 
>> 176:     struct stat statbuf;
>> 177:     fstat(fd, &statbuf);
>> 178:     ssize_t read_sz = read(fd, buf, statbuf.st_size);
> 
> This looks wrong: the read() call should use buflen.

Fixed it in new commit.

> src/hotspot/os_cpu/windows_aarch64/vm_version_windows_aarch64.cpp line 103:
> 
>> 101: void VM_Version::get_compatible_board(char *buf, int buflen) {
>> 102:   assert(buf != NULL, "invalid argument");
>> 103:   *buf = '\0';
> 
> This is wrong too: it should check buflen.

I added assert for buflen in new commit.

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

PR: https://git.openjdk.java.net/jdk/pull/2759


More information about the hotspot-dev mailing list