Lockfree Inter-Thread communication

I got rid of all the mutex/semaphores. There is one case of sleep/polling every 100ms, but it just doesn't matter performance wise.