--- a/src/hotspot/share/runtime/thread.inline.hpp Sat Feb 10 09:25:35 2018 +0100
+++ b/src/hotspot/share/runtime/thread.inline.hpp Sun Feb 11 03:12:15 2018 -0500
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,24 +30,18 @@
#include "runtime/thread.hpp"
inline void Thread::set_suspend_flag(SuspendFlags f) {
- assert(sizeof(jint) == sizeof(_suspend_flags), "size mismatch");
uint32_t flags;
do {
flags = _suspend_flags;
}
- while (Atomic::cmpxchg((jint)(flags | f),
- (volatile jint*)&_suspend_flags,
- (jint)flags) != (jint)flags);
+ while (Atomic::cmpxchg((flags | f), &_suspend_flags, flags) != flags);
}
inline void Thread::clear_suspend_flag(SuspendFlags f) {
- assert(sizeof(jint) == sizeof(_suspend_flags), "size mismatch");
uint32_t flags;
do {
flags = _suspend_flags;
}
- while (Atomic::cmpxchg((jint)(flags & ~f),
- (volatile jint*)&_suspend_flags,
- (jint)flags) != (jint)flags);
+ while (Atomic::cmpxchg((flags & ~f), &_suspend_flags, flags) != flags);
}
inline void Thread::set_has_async_exception() {