Japan definitely produced some of the most beautiful looking swords, and they are extremely impressive given the quality of iron they are forged out of, but I don't think any sane person would choose one to take into battle given any other option.
Friend is a hobbyist blacksmith and he said it really well.
Japan developed their hugely overdone turned-steel technique because the ore they had to work with was so bad: hammering the garbage out was the only way to get the quality of the steel itself into acceptable levels. As a result, Japanese smiths developed something very close to what we'd now call layered steel.
European swordsmiths (think: Toledo) had access to higher-grade ore, and as a result never needed to develop techniques to work around fundamental problems with their source material.
It would depend a lot on what time period you're talking about. I'm not an expert, but I do a bit of amateur forging and have learned a couple of things just reading about this craft. By the 14 or 1500s, spring steel had been developed in Europe. This would enable a sword to flex rather than break. Japanese swords from the time weren't flexible and were generally more prone to breaking. This had a lot to do with the raw materials that were available. They also tend to have softer mild steel core to help with this problem, with a very hard and sharp edge. If the entire blade were made of the same material as the edge, it would be extremely inflexible and brittle. They're kind of designed in a way where a part of the every hard and brittle edge can crack, but maybe it won't extend all the way up through the blade leaving it somewhat usable. The European longsword from the time might just flex in the same circumstance.
That's not to say that European swords were better than Japanese swords in every way. This is one of many, many factors. And I'm sure there were plenty of crappy longswords at the time (and crappy katans), so you kind of also have to decide if you're comparing the best examples, average examples, or low quality items as well. The skill of the wielder is also important. If you're throwing out a bunch of random soldiers without a ton of training and giving them a sword, you might want to give them something they're less likely to break. My understanding that is there was a period in Japan where only samurai were allowed to carry swords (if my reading is to be believed), who were generally very skilled. They would probably know how to avoid putting their blade in situations where it would be prone to breaking.
And Japanese traditional Japanese sword making techniques are extremely impressive and interesting to read about given the materials that were available at the time.
From what I've heard and seen the quality of metal makes them prone to breaking, and you need skill to take full advantage of the razor sharp edge. I have seen a great video showing katana students cutting bamboo and struggling and then a master going clean through that I wish I could have found again. For the record I don't think they are shit swords, just they look really cool and that has lead to various media elevating their superiority to other swords beyond reality.
I thought Japanase steel wasn't all that impressive in absolute terms, rather it was impressive because of the very bad quality ingredients they started with. It also made ownership of a sword (katana) and accompanying paraphernalia only accessible to a small caste of elite warriors. Both the raw materials and the process were hard to come by.
My understanding is that historically the best steels were made in India/Southern-India where wootz steel comes from and that for more than 2000 years the rest of the world was almost bargain tier in comparison. To the degree that samples of wootz steel were brought back to Europe even in the 18th century in an attempt to replicate the process.
I'm only an amateur metalworker though so I hope someone more knowledgeable can correct any errors.
The pre-modern/medieval Japanese iron industry was actually quite massive! We went to a museum in Izumo and there was a nice map showing the are in ancient times and now and the difference was pretty stark - there were just swamp where the Izumo city is today and the local lake Shinji was like twice as big as today.
All the new land and end of the swamps is apparently the result of hundreds of years of iron ore mining in the nearby mountains. So even with primitive means and shitty ore, if you need the material and go at it for centuries, you can achieve substantial results. Not to mention reclaim some land as a result. :)
Also in related (but much more recent development) there were coal mines in Japan mining from under the seabed via tiny islands!
Hashima is the most extreme example, basically a piece of barely dry rock that has been converted to a concrete city housing many thousands of workers and their families: https://en.wikipedia.org/wiki/Hashima_Island
But there were other such mines, some of the local ones even connected to Hashima via the underground works!
There's a difference between "we have to do more refining to get usable metal" and "there's literally none around unless you go deep underground into a new deposit".
The buried and overgrown remains of any modern junkyard, port, railway depot or rubbish dump would be a decent shallow ore for many metals. During the industrial revolution we have consumed almost all of the shallow fuels, but we haven't consumed any metals, they're right here on the surface and more accessible than before - it's just that they're currently tied up in some products or structures we use.
Japan fielded armies of hundreds of thousands of men, all equipped with swords. I guess if you totalled the weight on metal on them, you could cobble together a battleship. But it's not really about quantity, more quality of the ore.
And the point isn't about that. The point is that the constraint (bad ore quality) forced the Japanese to get better at metalworking. Resource constraints aren't as bad as we think, because we're used to making things without those constraints. But our descendants, having always had those constraints, will find better ways of solving them than we can think of.
Hundreds of thousands? The battles I read about maybe reached tens of thousands, and who knows how many had swords.
Even in Europe, a large part of the armies were peasants with whatever comes to hand. Their resource constraint on metals wasn't the ore, but the availability of the enormous quantities of wood required to process it.
Every Samurai had at least two swords. So at least a million swords. Let's say a sword weighs 1Kg, that's 1000 tonnes of steel. So probably not enough for a battleship, but maybe a small destroyer.
Constraints don't always lead to bad outcomes.