This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: C++ and gather-detailed-mem-stats


On 08/15/2012 12:07 PM, Gabriel Dos Reis wrote:

You might try to encode/package information with the
parameters T and A, but essentially you will hit the wall
that __FILE__, __LINE__, and __FUNCTION__ are CPP artifacts.

GNAT has built-in functions which return this information. When they are used in default argument expressions and these arguments are omitted, the functions are evaluated in the context of the caller and return the file position at that point. Perhaps that would be an approach for C++ as well?


(This assumes that gather-detailed-mem-stats is not needed in the first stage compiler.)

--
Florian Weimer / Red Hat Product Security Team


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]