In a read out mode, a NAND circuit to which latch data of both bit lines are
input
provides an L output when potentials of the bit line pair are constantly identical,
and provides an H output when the potentials of the bit line pair change, even
when the word line rendered active is switched. In a writing mode, the NAND circuit
provides an L output. In a reading mode, H is applied to the gate of a first transistor
that connects a bit line BL with the NAND circuit. In a writing mode, H is applied
to the gate of the first transistor or a second transistor that connects a bit
line /BL with the NAND circuit. Potential change occurs at the bit line pair according
to an output of the NAND circuit.