Required for both nuclear and mitochondrial DNA synthesis. (6R)-5,10-methylene-5,6,7,8-tetrahydrofolate + dUMP = 7,8-dihydrofolate + dTMP Pyrimidine metabolism; dTTP biosynthesis. In the N-terminal section; belongs to the HFCD (homo-oligomeric flavin containing Cys decarboxylase) superfamily. In the C-terminal section; belongs to the thymidylate synthase family.