A compound of formula or a pharmaceutically acceptable salt thereof, wherein: R 1 and R 2 are independently selected from hydrogen, C 3 -C 6 cycloalkyl, and C 1 -C 3 alkyl wherein the C 1 -C 3 alkyl is optionally substituted with one, two, or three groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkylamino, amino, cyano, C 1 -C 3 dialkylamino, halo, and hydroxy; or R 1 and R 2 together are oxo; or R 1 and R 2, together with the carbon atom to which they are attached, form an oxetane ring; R 3 is C 1 -C 3 alkyl-Y or C 2 -C 8 alkyl, wherein the C 2 -C 8 alkyl is optionally substituted with one, two, three, or four groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkylamino, C 1 -C 3 alkoxyC 2 -C 3 alkylamino, amino, aryl, halo, C 1 -C 3 haloalkylamino, C 1 -C 3 haloalkylcarbonylamino, hydroxy, -NR x R y, and C 3 -C 8 cycloalkyl, wherein the cycloalkyl is further optionally substituted with one, two, or three groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkyl, C 1 -C 3 alkylamino, C 1 -C 3 alkoxyC 2 -C 3 alkylamino, amino, aryl, arylC 1 -C 3 alkyl, halo, C 1 -C 3 haloalkyl, C 1 -C 3 haloalkylamino and hydroxy; R 4 is selected from hydrogen, C 1 -C 3 alkoxy, C 1 -C 3 alkoxycarbonylamino, C 1 -C 3 alkyl, C 1 -C 3 alkylamino, C 1 -C 3 alkylcarbonylamino, amino, arylamino, arylcarbonylamino, C 3 -C 6 cycloalkylamino, C 3 -C 6 cycloalkylcarbonylamino, C 3 -C 6 cycloalkyloxy, halo, C 1 -C 3 haloalkoxy, C 2 -C 3 haloalkylamino, C 2 -C 3 haloalkylcarbonylamino, and hydroxy; R 5 is selected from hydrogen, C 1 -C 3 alkyl, cyano, C 3 cycloalkyl, and halo; R 6 is selected from hydrogen, C 1 -C 3 alkyl, C 1 -C 3 alkylcarbonylamino, amino, R 7 is selected from hydrogen, C 1 -C 3 alkoxy, C 1 -C 3 alkyl, cyano, -CH 2 OH,-CH 2 OCH 3, CH(CH 3)OH, C(CH 3) 2 OH, halo, and C 1 -C 3 haloalkyl; R 8 is selected from hydrogen, C 1 -C 3 alkoxy, cyano, and halo; R x and R y, together with the nitrogen atom to which they are attached, form a three- to six-membered ring; and Y is selected from wherein R 9 is selected from hydrogen, C 1 -C 6 alkyl, C 3 -C 6 cycloalkyl, and C 1 -C 6 alkylcarbonyl; n is 0, 1, 2, or 3; each R 10 is independently selected from hydrogen, C 1 -C 6 alkyl, aryl, arylC 1 -C 3 alkyl, C 3 -C 6 cycloalkyl, halo, and C 1 -C 3 haloalkyl; and each R 11 is independently selected from hydrogen, C 1 -C 3 alkoxy and hydroxy. R 1 and R 2 are independently selected from hydrogen, C 3 -C 6 cycloalkyl, and C 1 -C 3 alkyl wherein the C 1 -C 3 alkyl is optionally substituted with one, two, or three groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkylamino, amino, cyano, C 1 -C 3 dialkylamino, halo, and hydroxy; or R 1 and R 2 together are oxo; or R 1 and R 2, together with the carbon atom to which they are attached, form an oxetane ring; R 3 is C 1 -C 3 alkyl-Y or C 2 -C 8 alkyl, wherein the C 2 -C 8 alkyl is optionally substituted with one, two, three, or four groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkylamino, C 1 -C 3 alkoxyC 2 -C 3 alkylamino, amino, aryl, halo, C 1 -C 3 haloalkylamino, C 1 -C 3 haloalkylcarbonylamino, hydroxy, -NR x R y, and C 3 -C 8 cycloalkyl, wherein the cycloalkyl is further optionally substituted with one, two, or three groups independently selected from C 1 -C 3 alkoxy, C 1 -C 3 alkyl, C 1 -C 3 alkylamino, C 1 -C 3 alkoxyC 2 -C 3 alkylamino, amino, aryl, arylC 1 -C 3 alkyl, halo, C 1 -C 3 haloalkyl, C 1 -C 3 haloalkylamino and hydroxy; R 4 is selected from hydrogen, C 1 -C 3 alkoxy, C 1 -C 3 alkoxycarbonylamino, C 1 -C 3 alkyl, C 1 -C 3 alkylamino, C 1 -C 3 alkylcarbonylamino, amino, arylamino, arylcarbonylamino, C 3 -C 6 cycloalkylamino, C 3 -C 6 cycloalkylcarbonylamino, C 3 -C 6 cycloalkyloxy, halo, C 1 -C 3 haloalkoxy, C 2 -C 3 haloalkylamino, C 2 -C 3 haloalkylcarbonylamino, and hydroxy; R 5 is selected from hydrogen, C 1 -C 3 alkyl, cyano, C 3 cycloalkyl, and halo; R 6 is selected from hydrogen, C 1 -C 3 alkyl, C 1 -C 3 alkylcarbonylamino, amino, R 7 is selected from hydrogen, C 1 -C 3 alkoxy, C 1 -C 3 alkyl, cyano, -CH 2 OH,-CH 2 OCH 3, CH(CH 3)OH, C(CH 3) 2 OH, halo, and C 1 -C 3 haloalkyl; R 8 is selected from hydrogen, C 1 -C 3 alkoxy, cyano, and halo; R x and R y, together with the nitrogen atom to which they are attached, form a three- to six-membered ring; and Y is selected from wherein R 9 is selected from hydrogen, C 1 -C 6 alkyl, C 3 -C 6 cycloalkyl, and C 1 -C 6 alkylcarbonyl; n is 0, 1, 2, or 3; each R 10 is independently selected from hydrogen, C 1 -C 6 alkyl, aryl, arylC 1 -C 3 alkyl, C 3 -C 6 cycloalkyl, halo, and C 1 -C 3 haloalkyl; and each R 11 is independently selected from hydrogen, C 1 -C 3 alkoxy and hydroxy.