This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Help in Load Store Instrumentation
- From: Jim Wilson <wilson at specifixinc dot com>
- To: Rajkishore Barik <rkbarik at yahoo dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Wed, 30 Jun 2004 18:57:45 -0700
- Subject: Re: Help in Load Store Instrumentation
- References: <20040628073748.4743.qmail@web40007.mail.yahoo.com>
Rajkishore Barik wrote:
I am a newbie to GCC development community. Can
someone help me in instrumenting loads/stores in GCC?
There are many places that loads/stores can be emitted, so this may not
be very easy. emit_move_insn is a good place to start though. Also, a
typical program has many loads/stores, so trying to instrument them is
likely to add a lot of overheard.
You might try looking at some solutions implemented by other people.
Current sources have mudflap which does some load/store instrumentation
to detect programming errors.
There were the gcc patches for Checker. I don't know if there is a
current maintained version of these patches, but if you grab a copy of
gcc-2.8.1 from the old-releases directory on our web site, and grep for
flag_check_memory_usage you can see what these patches did.
> want to get the runtime values back into the GCC
> component in the next run. Any help will be highly
Maybe you want to look at the value profiling support in the current gcc
sources then. See the gcc/value-prof.c file. See the options
-fprofile-values and -fpvt (profile value transformations). See also
-fprofile-generate and -fprofile-use which turn these options on.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com