As in title. Also, the current atomic operations in signal handler might not be async signal safe so we also should fix this.