--- old/src/hotspot/share/code/codeCache.cpp 2019-11-21 11:54:56.088714346 +0100 +++ new/src/hotspot/share/code/codeCache.cpp 2019-11-21 11:54:55.836710085 +0100 @@ -749,7 +749,7 @@ for (;;) { ExceptionCache* purge_list_head = Atomic::load(&_exception_cache_purge_list); entry->set_purge_list_next(purge_list_head); - if (Atomic::cmpxchg(entry, &_exception_cache_purge_list, purge_list_head) == purge_list_head) { + if (Atomic::cmpxchg(&_exception_cache_purge_list, purge_list_head, entry) == purge_list_head) { break; } }