Adult patients with American Society of Anesthesiologists status @ to @ after primary total unilateral knee or hip replacement under general anesthesia or with spinal anesthesia that did not include intrathecal opioids were eligible .