Re: How to auto insert logs when use gcc compile a C/C++ source.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2022-05-30 at 08:45 +0800, Mr. Joey via Gcc-help wrote:
> hi,  guys
>      
> How to auto insert logs when use gcc compile a C/C++ source. I thinks
> it’s useful when quickly debug a crash.

I don't understand your intention.  You mean debug a crash in GCC itself
("Internal Compiler Error") or a crash of the executable created by GCC?

For the prior, the output of -fdump-tree-* and -fdump-rtl-* can serve as
a log.  But it's more efficient to just minimize the testcase with a
tool like cvise and debug the compiler with GDB.

For the latter, it's impossible.  You can use a logging library like
boost::log in your program anyway.


-- 
Xi Ruoyao <xry111@xxxxxxxxxxx>
School of Aerospace Science and Technology, Xidian University




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux