The problem is an incentive structure that rewards constantly adding scope to projects. There are a lot of ways to think about why, but I tend to break it down to two things: Economics and culture.
First, economics. Money is allocated through the federal budget. This budget does not obey the normal laws of physics. There are myriad reasons why (down to the fact that the government can just go ahead and print new money sometimes), but the important thing to understand is that it's harder to remove lines from the budget than it is to add them.
Private industry has a wonderful garbage collection mechanism called "going out of business". In the public sector, projects have a tendency to keep existing. It's not because people in management want to sit around and collect an easy paycheck-- It's because they often have zero control over where the money goes. That ability belongs to congress.
Second, culture. And here, I actually am going to do some finger-pointing. Moving up in the hierarchy almost always means controlling more personnel, and vice-versa, having more people under you means you're higher in the pecking order. If you suddenly find yourself in charge of a 500-person department, well, you might be in line for a promotion to SES. This leads to a strange territorial game where high-level management has no incentive to shrink the size of projects.
The hierarchy tends to self-enforce, notably through the way it communicates[1] (Always Outlook, rarely any type of tool that allows easy communication between management and staff). This is made exponentially worse by the fact that written correspondence can and often does become public record, making it even harder for people to talk openly and honestly with one another.
I think the budget problem is unsolvable, at least by us Silicon Valley types. But one area where we can contribute is project management. Thinking about projects in terms of actual deliverables (SLAs, APIs, usage levels, etc.) and flattening communications channels would really solve a lot of problems.
You spend all year working on a system, then the time comes for you to demonstrate it's capabilities. It is 2 months to BIG_IMPORTANT_SEASON. A few faults are found in your solution. Not wanting to risk downtime during literally the only time your company matters, your superiors put your system on hold and you get relegated to support work.
The IRS probably works the same way. I am guessing the IT division gets about 6 months to do their work before everyone stops the presses because it's tax season and you don't fuck with stuff any time around tax season.
There's also all the extensions that get filed each year.
$3,180,000,000,000 annually
So I see no validity to your point(s).
North Carolina's annual budget for providing all of those services is $23 billion - only twice the budget of the IRS.
NCDOR—the North Carolina analog of the IRS—has an annual budget of $177 million, compared to NCs total annual budget of $23 billion, or about 1/130 of the budget of the government it gathers revenue for.
IRS budget is $11.5 billion, compared to the US annual budget of $3.3 trillion. The IRS costs 1/286 of the budget of the government it gathers revenue for.
If you are going to try to say that NC makes the IRS look too expensive for what it does, you are going to need to do more than just point at the size of the state budget to make your argument.
As non-intuitive as it sounds, you really do want competence here.
So the issue isn't a lack of funding or personnel, it's bureaucratic incompetence.