It's not a solid military strategy. What it is, is a jobs program.
Every time you see a story with giant robots you have to understand that this happened somewhere:
Adviser 1: "The economy is in a downturn, unemployment is rising steadily, the private sector still shrinking. If we don't do something we could be looking at a second great depression."
Adviser 2: "Even the word 'stimulus' is politically toxic. Increased government spending of any kind has no chance of making it through congress/parliament/committee/whatever, we can't do anything."
Adviser 3: "And we also have the damn Kaiju to deal with. The good news is that our best strategists are on the job and we think we can beat them with our existing resources without having to increase military spending."
Leader (or other smart person): "No."
Adviser 3: "No?"
Leader : "We are not going to use an efficient cost-effective strategy."
Adviser 3: "I'm not sure I'm following you [honorific]."
Leader: "We're going to build giant robots."
Multiple advisers: "WHAT!?"
Leader: "Preferably giant bipedal humanoid robots with swords, but definitely giant robots."
*all at once*
"Wouldn't wheels make more sense?"
"Did someone drug you?"
"I'm not sure that physics allows..."
Leader: "We're going to build giant robots BECAUSE we'll need to make incredible leaps forward in mechanical engineering to do it, that means funding research and thus expanding a vitally important sector of the economy.
"We're going to make giant robots because doing so will be so inefficient that we'll need to employ and army of workers from every region to do it.
"We're going to make giant robots because no one wants to be seen voting against punching Cthulhu in the face.
"We're going to make giant robots because so many jobs will be created doing so that we can bribe any obstructionists by employing their constituents.
"We're going to make giant robots because while 'stimulus' may be a dirty word 'defense' is not, especially with kaiju at the door.
"We're going to make giant robots because it's the kind of massive government spending that can kick-start our economy.
"So get out of here and make it happen! Giant robots!"
Or something to that effect.
That's why you make giant robots. When people make giant robots to fight other people it's because there was a similar need for a jobs program but a lack of kaiju to justify it.
Giant Robots == Jobs Program
The fact that you could get better results with far less effort isn't a reason not to do it, it's a reason to do it. Giant Robots arise in times when inefficiency is a feature, not a bug. When times are good you want things to be efficient so that resources can be devoted to moving forward. When times are really bad you want things to be inefficient because inefficient systems require more people, which means more jobs, which means more employment.
By using the inefficient to maintain a solid employment level you maintain a solid consumer base which means that private industry can steady itself, get back on its feet, and start employing more people again. At which point you want to make government more efficient because there's no longer a need for pointless jobs and giant robots.
Of course, if government functioned properly you'd never need inefficiency even in the worst of times because you could put people to work on actual meaningful jobs. In that case you get no giant robots, but you get things like a solid infrastructure, decent research and development, and maybe a monument or two.