As far as I understand, C++ attribute
[[noreturn]] int main()
noreturn is mostly useful for callers of functions, not for the functions themselves, and in the case of
main() the caller of
main() is the C++ runtime, which is ready-made, so the compiler does not get to compile it, so there is nothing to optimize there.
However, there is a tiny benefit to be gained within your
main(), since theoretically, the
noreturn version will produce slightly smaller code, since the compiler can omit the sequence of instructions known as epilogue.
These performance (speed/size) gains are trivial and not really worth paying much attention to. What is more interesting is the possibility of receiving a warning if you have written any code right after a call to a
noreturn function. In this case the compiler should be able to warn you that this code of yours will never be executed. I find this a lot more useful.