And in the case of iPhone, the software takes advantage of custom-made, powerful, performant, and yet efficient chips that would make snapping photos take forever on older or non-specialised chips.
In what way does it seem that Apple is failing at that? Are you saying iPhone sales have just completely slumped? That's not what the data is saying.
Apple and other phone makers set the benchmark years ago, people don't seem too interested in going back. Even when they're buying non-Apple phones, they're buying other companies' flagships: Samsung, LG, Huawei, Xiaomi. Those phones are no slouches either.
The physical focal length of a phone lens is about 3 to 4.5mm. There's not a lot of light-physics you cam do in that much space. Even a cheap point-and-shoot fixed-lens camera will be superior and will cost much less than the phone upgrade increment.
And as the Pixel 3 has shown the software makes far more of a difference to the quality of the photo then the hardware.