Patent ID: 8375160

Claim:
A memory controller connected to a nonvolatile memory, the memory controller reading and writing data according to an external access instruction comprising: an address management unit for managing at least free area of said nonvolatile memory and selecting a writing destination area from the free area of said nonvolatile memory at data writing; a recording state judgement unit for performing swap necessity judgement of a storage area based on a recording state of said nonvolatile memory; and a reading and writing control unit for controlling data reading and writing, determining a swap target area according to a judgement result of said recording state judgement unit and performing swap processing, wherein said memory controller further includes: a system condition reception unit for receiving a system condition designated from outside: and a system condition judgement unit for performing swap possibility judgement of a storage area based on said system condition, and said reading and writing control unit controls data reading and writing and performs determination of a swap target area and swap processing according to judgement results of said recording state judgement unit and said system condition judgement unit.