Subject: Re: random signals kill my processes with -current
To: John F. Woods <email@example.com>
From: Chris G. Demetriou <firstname.lastname@example.org>
Date: 01/27/1997 22:22:51
> I was going to suggest this, but decided it was too obvious to mention :-).
> However, now that it's been brought up, I'll add the interesting wrinkle
> I wanted to ask about: this kind of checking works better the more frequently
> you check (obviously); is there any way to convince gcc to alter the function
> entry/exit code? In particular, to have it generate a call instruction to
> some user-defined functions. This way, you could arrange to check the
> signature of the current U area on every function entry and exit. [ ... ]
Obviously not a general solution to the problem, but one that could
work for many situations (helpful for tracking down unhelpful bugs):
compile with profiling enabled, replace the mcount() function which
normally collects profiling data with something more to your liking.
Yes, it's evil, but man cannot live on good alone... 8-)