By 300 A.D., the spatha had replaced the gladius as the primary Roman infantry sword, although the thrusting spear had become the primary infantry weapon. Precisely when or why the gladius was phased out of service over the latter half of the third century is unclear. From it's similar size to the gladius (about three feet in length), it can be reasonably inferred the adoption of the spatha did not have a profound effect on close-order infantry tactics; far more importance should be placed upon the now widespread use of the thrusting spear. Most soldiers would likely have been equipped with a spatha during the early to mid fourth century.
The production of military equipment was centralized in a system of state-run arsenals (fabricae) during the reign of Diocletian. Although Diocletian is credited with codifying the system of fabricae, it's actual construction was likely a gradual affair, building upon institutions created during the third century for which we lack documentation. Different fabricae specialized in the production of certain types of military equipment. The Notitia Dignitatum records several fabricae as specifically producing swords, though it is unlikely their small number supplied the entire army. Far more fabricae are listed as fabricae armorum, with the arma produced possibly including swords alongside more general defensive equipment.
While the fabricae produced the bulk of the army's equipment, regimental armorers are attested throughout Late Antiquity. They were responsible for repairs on equipment (although soldiers remained responsible for general maintenance), and continued to produce simpler items like spears, arrows, and javelins. While I am unfamiliar with specific circumstances that would cause a Roman sword to bend (I'm not a weapons expert), soldiers would doubtless have sought out armorers for basic repairs.
Cost for replacement equipment was likely born by the state. Although the relative value of military pay in Late Antiquity is debated, soldiers were no longer serviced with pay deductions for rations and equipment. Should a fourth century soldier require a new spatha, the state, not the soldier, would have paid for it.
This poses a question to me, i was thinking, post battle it would be easy to swap a bent sword for a good one. I'd like to ask was it likely soldiers would nab a spare or two or was looting systematic and all spares go to stock? What about swords from foes? You probably wouldn't want centurions selling swords back to the locals, effectively re arming them. Were there general rules about looting is my question I guess?