Net Income (Loss) per Share of Common Stock - Computation of Diluted Net (Loss) Income per Share of Common Stock (Detail) - shares
shares in Thousands
12 Months Ended
Dec. 31, 2016
Dec. 31, 2015
Stock options to purchase common stock and restricted stock units [Member]    
Antidilutive Securities Excluded from Computation of Earnings Per Share [Line Items]    
Dilutive securities excluded from computation of diluted net (loss) income per share 2,587 2,497