mirror of
https://github.com/openjdk/jdk.git
synced 2026-05-12 14:39:49 +00:00
8288051: Loom: Extend the compilation warning workaround in stack chunk copy
Reviewed-by: coleenp
This commit is contained in:
parent
3419beec7f
commit
7e1cce8cb5
@ -316,6 +316,12 @@ inline void stackChunkOopDesc::copy_from_stack_to_chunk(intptr_t* from, intptr_t
|
||||
assert(to >= start_address(), "Chunk underflow");
|
||||
assert(to + size <= end_address(), "Chunk overflow");
|
||||
|
||||
#if !defined(AMD64) || !defined(AARCH64) || defined(ZERO)
|
||||
// Suppress compilation warning-as-error on unimplemented architectures
|
||||
// that stub out arch-specific methods. Some compilers are smart enough
|
||||
// to figure out the argument is always null and then warn about it.
|
||||
if (to != nullptr)
|
||||
#endif
|
||||
memcpy(to, from, size << LogBytesPerWord);
|
||||
}
|
||||
|
||||
@ -330,7 +336,9 @@ inline void stackChunkOopDesc::copy_from_chunk_to_stack(intptr_t* from, intptr_t
|
||||
assert(from + size <= end_address(), "");
|
||||
|
||||
#if !defined(AMD64) || !defined(AARCH64) || defined(ZERO)
|
||||
// Suppress compilation error from dummy function (somewhere).
|
||||
// Suppress compilation warning-as-error on unimplemented architectures
|
||||
// that stub out arch-specific methods. Some compilers are smart enough
|
||||
// to figure out the argument is always null and then warn about it.
|
||||
if (to != nullptr)
|
||||
#endif
|
||||
memcpy(to, from, size << LogBytesPerWord);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user