This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: g++ compiler generated copy constructor
- From: Oleg Endo <oleg dot endo at t-online dot de>
- To: navin p <navinp1281 at gmail dot com>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Mon, 11 Aug 2014 21:15:12 +0200
- Subject: Re: g++ compiler generated copy constructor
- Authentication-results: sourceware.org; auth=none
- References: <CAKVd3pWt2XddzPmK749SxeE4zEt0f-U5m13yNfyUG7+Nbd4phQ at mail dot gmail dot com>
Hello,
On Mon, 2014-08-11 at 23:24 +0530, navin p wrote:
> Hi,
> Is there any way i can see the compiler generated copy constructor
> and default constructor/destructor as a .cpp file instead of assembly
> ? Any flags to g++,
>
Since you haven't specified what kind of information you want to have
about the generated functions, one can only guess.
Maybe looking at some of the tree/RTL dumps (try option
-fdump-tree-all-details or -fdump-rtl-all-details see
https://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html#Debugging-Options for details) might contain the information you're looking for. Notice however, that the generated functions might get optimized away completely after they have been inlined into the caller.
Cheers,
Oleg