Looking around, I see mostly questions about demangling C++ symbols rather than how to mangle them. Yes, one could invoke g++, using the -S option, on
g++
-S
Quote from gcc's sources(https://github.com/gcc-mirror/gcc/blob/master/gcc/cp/mangle.c):
This file implements mangling of C++ names according to the IA64 C++ ABI specification.
And here is the rules from this specification: https://itanium-cxx-abi.github.io/cxx-abi/abi.html#mangling