Extensive monitoring of device characteristics in the manufacturing of ULSI with advanced LOCOS isolation revealed the strong dependence of device leakage currents on the process of patterning of silicon nitride films applied as a hard mask for local oxidation of silicon wafers. At the same time, the level of the leakage currents strongly correlated to stress-induced dislocation density in the device structures. Formation of microtrenches on the wafer surface at the nitride film edges was identified to have a major impact on the leakage currents. Surprisingly, structures having nitride film edge profiles with feet were consistently dislocation-free after the local oxidation. This showed that nitride etching process created surface damage that provided effective sites for crystal defect nucleation in silicon at the film edges. Computer simulations demonstrated that the feet at nitride edges substantially suppress stress growth during local oxidation.