[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-hotspot-runtime-dev
Subject: Re: enhancement of cmpxchg and copy_to_survivor for ppc64
From: David Holmes <david.holmes () oracle ! com>
Date: 2016-05-19 20:08:20
Message-ID: 3fdffecd-75d0-fe77-0ed9-038b24bbf007 () oracle ! com
[Download RAW message or body]
Andrew,
Can you post this to the actual review thread for 8155949 please.
Thanks,
David
On 20/05/2016 1:04 AM, Andrew Haley wrote:
> There is one significant problem with this approach.
>
> Atomic::cmpxchg(jint) is defined like this in atomic.cpp:
>
> unsigned Atomic::cmpxchg(unsigned int exchange_value,
> volatile unsigned int* dest, unsigned int compare_value,
> cmpxchg_memory_order order) {
> assert(sizeof(unsigned int) == sizeof(jint), "more work to do");
> return (unsigned int)Atomic::cmpxchg((jint)exchange_value, (volatile jint*)dest,
> (jint)compare_value, order);
> }
>
> Because this is in atomic.cpp, there is a *runtime* test on the memory
> order: the compiler can't constant propagate it. If we're adding the
> cmpxchg_memory_order I think we should move Atomic::cmpxchg(jint) to
> atomic.inline.hpp.
>
> Andrew.
>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic