A
semiconductor device comprising: a first circuit (10_2); and a second circuit (10_3) adjacent to the first circuit (10_2), wherein the first circuit (10_2) comprises a first to fifth
transistor, wherein the second circuit (10_3) comprises a sixth to tenth
transistor, wherein one of a source and a drain of the first
transistor (103) is directly connected to a first
clock line (21), wherein the other of the source and the drain of the first transistor (103) is directly connected to a first wiring (27) configured to output a
signal, wherein one of a source and a drain of the second transistor (104) is directly connected to a first power supply line (31), the other of the source and drain of the second transistor (104) being directly connected to the first wiring (27), wherein one of a source and a drain of the third transistor (108) is directly connected to a gate of the second transistor (104), wherein the other of the source and drain of the third transistor (108) is directly connected to a second power supply line (32), wherein a gate of the third transistor (108) is directly connected to a second
clock line (22), wherein one of a source and a drain of the fourth transistor (107) is directly connected to a gate of the first transistor (103), wherein a gate of the fourth transistor (107) is directly connected to the second power supply line (32), wherein one of a source and a drain of the fifth transistor (106) is directly connected to the first power supply line (31), wherein a gate of the fifth transistor (106) is directly connected to the gate of the second transistor (104), wherein one of a source and a drain of the sixth transistor is directly connected to the second
clock line (22), wherein the other of the source and the drain of the sixth transistor is directly connected to a second wiring configured to output a
signal, wherein one of a source and a drain of the seventh transistor is directly connected to the first power supply line (31), the other of the source and drain of the seventh transistor being directly connected to the second wiring, wherein one of a source and a drain of the eighth transistor is directly connected to a gate of the seventh transistor, the other of the source and drain of the eighth transistor being directly connected to the second power supply line (32), wherein one of a source and a drain of the ninth transistor is directly connected to a gate of the sixth transistor, wherein a gate of the ninth transistor is directly connected to the second power supply line (32), wherein one of a source and a drain of the tenth transistor is directly connected to the first power supply line (31), wherein a gate of the tenth transistor is directly connected to the gate of the seventh transistor, wherein a potential of the first power supply line (31) is supplied to the other of the source and the drain of the fourth transistor (107) at least through a channel formation region of the fifth transistor (106) when the first power supply line (31) has an electrical continuity with the other of the source and the drain of the fourth transistor (107) at least through the channel formation region of the fifth transistor (106), wherein the potential of the first power supply line (31) is supplied to the other of the source and the drain of the ninth transistor at least through a channel formation region of the tenth transistor when the first power supply line (31) has an electrical continuity with the other of the source and the drain of the ninth transistor at least through the channel formation region of the tenth transistor, and wherein the eighth transistor is configured to control a timing when a potential of the second power supply line (32) is supplied to the gate of the seventh transistor and the gate of the tenth transistor at least through a channel formation region of the eighth transistor.