< prev index next >

src/os/windows/vm/os_windows.hpp

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2013, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. --- 1,7 ---- /* ! * Copyright (c) 1997, 2017, 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 * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 109,122 **** * To be able to use this - don't take locks, don't rely on destructors, * don't make OS library calls, don't allocate memory, don't print, * don't call code that could leave the heap / memory in an inconsistent state, * or anything else where we are not in control if we suddenly jump out. */ ! class WatcherThreadCrashProtection : public StackObj { public: ! WatcherThreadCrashProtection(); bool call(os::CrashProtectionCallback& cb); }; class PlatformEvent : public CHeapObj<mtInternal> { private: double CachePad [4] ; // increase odds that _Event is sole occupant of cache line --- 109,130 ---- * To be able to use this - don't take locks, don't rely on destructors, * don't make OS library calls, don't allocate memory, don't print, * don't call code that could leave the heap / memory in an inconsistent state, * or anything else where we are not in control if we suddenly jump out. */ ! class ThreadCrashProtection : public StackObj { public: ! static bool is_crash_protected(Thread* thr) { ! return _crash_protection != NULL && _protected_thread == thr; ! } ! ! ThreadCrashProtection(); bool call(os::CrashProtectionCallback& cb); + private: + static Thread* _protected_thread; + static ThreadCrashProtection* _crash_protection; + static volatile intptr_t _crash_mux; }; class PlatformEvent : public CHeapObj<mtInternal> { private: double CachePad [4] ; // increase odds that _Event is sole occupant of cache line
< prev index next >