RFR: 8305056: Avoid unaligned access in emit_intX methods if it's unsupported [v7]
Vladimir Kempik
vkempik at openjdk.org
Sat Apr 22 15:56:48 UTC 2023
On Fri, 21 Apr 2023 13:50:57 GMT, Vladimir Kempik <vkempik at openjdk.org> wrote:
>> Please review this change which attempts to eliminate unaligned memory stores generated by emit_int16/32/64 methods on some platforms.
>>
>> Primary aim is risc-v platform. But I had to change some code in ppc/arm32/x86 to prevent possible perf degradation.
>
> Vladimir Kempik has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains 10 additional commits since the last revision:
>
> - Merge
> - Rewrite few more helpers
> - Add APH's suggestions and remove some whitespace
> - Rework the fix to use memcpy in codeBuffer.hpp
> - Reduce code duplication
> - Fix 32-bit archs
> - Fix typo
> - change long to ulong in type convertion
> - Fix includes
> - 8305056: Avoid unaligned access in emit_intX methods if not enabled
yet to check win64 jvm.dll.
so far godbolt shows me this for msvc 19 -O2
void put_native<unsigned short>(void *,unsigned short) PROC ; put_native<unsigned short>, COMDAT
mov WORD PTR [rcx], dx
ret 0
void put_native<unsigned short>(void *,unsigned short) ENDP ; put_native<unsigned short>
-------------
PR Comment: https://git.openjdk.org/jdk/pull/13227#issuecomment-1518691168
More information about the hotspot-compiler-dev
mailing list