Desolation was a Nephite city in the land of the same name, in the borders by the narrow pass that led into the land southward. Mormon gathered his armies there to stop the Lamanites from gaining any Nephite lands, fortifying the city against them (Mormon 3:5-6).
The city changed hands repeatedly during the wars of the fourth century A.D. In the 361st year the Lamanites came down to attack it and were beaten back; they came again the next year and were beaten again, their dead cast into the sea (Mormon 3:7-8). In the 363rd year the Nephites went up out of Desolation to attack, were driven back, and lost the city to a fresh Lamanite army that slew many and took prisoners (Mormon 4:1-2). The survivors fled to the nearby city of Teancum on the seashore (Mormon 4:3). The Nephites retook the city, then lost it again to the more numerous Lamanites (Mormon 4:8, 13). The Lamanites came down against it once more and beat the Nephites in battle there (Mormon 4:19).
Mormon wrote that he could not fully describe the blood and carnage of these years, when both sides delighted in the shedding of blood, and that there had never been such wickedness among the children of Lehi or the house of Israel (Mormon 4:10-12).