To output data from a memory-macro even in the outside of an address space of a memory-macro at testing of a memory-macro.
A memory-macro 10 is composed of a memory cell array 11 storing data, an expected value generating circuit 12 generating a test expected value, an address detecting circuit 13 discriminating whether an external address exists in constitution of the memory-macro 10 or not and outputting a control signal (expected value output command), and a multiplexer 14 (output selecting circuit) selecting either of output data of the memory cell 11 or the expected value generating circuit 12 and outputting as data of the memory-macro 10. The expected value generating circuit 12 generates an expected value when the outside of an address space of the memory cell array 11 is accessed.
Next Patent: OUTSIDE LANE LIGHTING SYSTEM