If compilers could do this even with hours of time to spend, that would be absolutely revolutionary. I program in a high level language (C#) and my whole day is usually moving things to the stack instead of the heap, devirtualizing calls, making SoA/AoS changes etc. I doubt we'll ever be in a position where compilers can make these decisions well enough. Much less jit compilers and dynamic runtimes that need to do it with time constraints.
A large desktop app (CAD). But the same thing has popped up in other projects: games, audio plugins, statistics, visualization... Basically anything that is CPU/Memory bound (which is most things except for basic web/database apps I find) needs careful thinking around performance.