equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2003, 2019, Oracle and/or its affiliates. All rights reserved. |
3 * Copyright 2007, 2008, 2011, 2015, Red Hat, Inc. |
3 * Copyright 2007, 2008, 2011, 2015, Red Hat, Inc. |
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 * |
5 * |
6 * This code is free software; you can redistribute it and/or modify it |
6 * This code is free software; you can redistribute it and/or modify it |
7 * under the terms of the GNU General Public License version 2 only, as |
7 * under the terms of the GNU General Public License version 2 only, as |
21 * or visit www.oracle.com if you need additional information or have any |
21 * or visit www.oracle.com if you need additional information or have any |
22 * questions. |
22 * questions. |
23 * |
23 * |
24 */ |
24 */ |
25 |
25 |
26 #ifndef OS_CPU_BSD_ZERO_VM_ATOMIC_BSD_ZERO_HPP |
26 #ifndef OS_CPU_BSD_ZERO_ATOMIC_BSD_ZERO_HPP |
27 #define OS_CPU_BSD_ZERO_VM_ATOMIC_BSD_ZERO_HPP |
27 #define OS_CPU_BSD_ZERO_ATOMIC_BSD_ZERO_HPP |
28 |
28 |
29 #include "runtime/os.hpp" |
29 #include "runtime/os.hpp" |
30 |
30 |
31 // Implementation of class atomic |
31 // Implementation of class atomic |
32 |
32 |
280 T volatile* dest) const { |
280 T volatile* dest) const { |
281 STATIC_ASSERT(8 == sizeof(T)); |
281 STATIC_ASSERT(8 == sizeof(T)); |
282 os::atomic_copy64(reinterpret_cast<const volatile int64_t*>(&store_value), reinterpret_cast<volatile int64_t*>(dest)); |
282 os::atomic_copy64(reinterpret_cast<const volatile int64_t*>(&store_value), reinterpret_cast<volatile int64_t*>(dest)); |
283 } |
283 } |
284 |
284 |
285 #endif // OS_CPU_BSD_ZERO_VM_ATOMIC_BSD_ZERO_HPP |
285 #endif // OS_CPU_BSD_ZERO_ATOMIC_BSD_ZERO_HPP |