Added license file. Fixed atomic memory orderings.