added atomic for reduction statements