a semiconductor device includes first integrated circuit comprising first to third mosfet having same channel type , and first to third mosfets including gate electrode and gate sidewall insulating film on sidewall of gate electrode , and distance between gate electrodes of first and second mosfets , and distance between gate electrodes of first and third mosfets being same first distance , and a second integrated circuit comprising fourth mosfet of which at least one of film thickness of gate insulating film and channel type is different from those of first mosfet , fifth mosfet and sixth mosfet , fourth to sixth mosfets having same channel type , and fourth to sixth mosfets including gate electrode and gate sidewall insulating film on sidewall of gate electrode , and distance between gate electrodes of fourth and fifth mosfets , and distance between gate electrodes of fourth and sixth mosfets being same second distance which is different from first distance .