--- old/src/os/bsd/vm/os_bsd.hpp 2017-05-17 02:58:29.694786099 -0400 +++ new/src/os/bsd/vm/os_bsd.hpp 2017-05-17 02:58:27.802677740 -0400 @@ -114,7 +114,6 @@ static sigset_t* unblocked_signals(); static sigset_t* vm_signals(); - static sigset_t* allowdebug_blocked_signals(); // For signal-chaining static struct sigaction *get_chained_signal_action(int sig); @@ -168,57 +167,4 @@ static int get_node_by_cpu(int cpu_id); }; - -class PlatformEvent : public CHeapObj { - private: - double CachePad[4]; // increase odds that _mutex is sole occupant of cache line - volatile int _Event; - volatile int _nParked; - pthread_mutex_t _mutex[1]; - pthread_cond_t _cond[1]; - double PostPad[2]; - Thread * _Assoc; - - public: // TODO-FIXME: make dtor private - ~PlatformEvent() { guarantee(0, "invariant"); } - - public: - PlatformEvent() { - int status; - status = pthread_cond_init(_cond, NULL); - assert_status(status == 0, status, "cond_init"); - status = pthread_mutex_init(_mutex, NULL); - assert_status(status == 0, status, "mutex_init"); - _Event = 0; - _nParked = 0; - _Assoc = NULL; - } - - // Use caution with reset() and fired() -- they may require MEMBARs - void reset() { _Event = 0; } - int fired() { return _Event; } - void park(); - void unpark(); - int park(jlong millis); - void SetAssociation(Thread * a) { _Assoc = a; } -}; - -class PlatformParker : public CHeapObj { - protected: - pthread_mutex_t _mutex[1]; - pthread_cond_t _cond[1]; - - public: // TODO-FIXME: make dtor private - ~PlatformParker() { guarantee(0, "invariant"); } - - public: - PlatformParker() { - int status; - status = pthread_cond_init(_cond, NULL); - assert_status(status == 0, status, "cond_init"); - status = pthread_mutex_init(_mutex, NULL); - assert_status(status == 0, status, "mutex_init"); - } -}; - #endif // OS_BSD_VM_OS_BSD_HPP