|
From: Bryan M. <om...@br...> - 2005-11-11 23:58:35
|
On Friday 11 Nov 2005 23:44, Nicholas Nethercote wrote: > On Fri, 11 Nov 2005, Bryan Meredith wrote: > > > I need to be able to see writes to spill registers. > > > > I can trap writes to memory and the shadow processor registers but I cant work > > out how to trap writes to the spill registers. > > > > Can someone point me at the relevent bit of documentation or provide a small > > sample of instrumentation please? > > > > The basic state of Omega at the moment is that it mostly works but it tends to > > declare a leak and then out of nowhere, a new reference pops up (which is > > kind of annoying). I added some instrumentation so I could see loads and > > right before the last reference on the stack goes out of scope, there is a > > load of the contents. Unfortunately, I cant see where the data is stored but > > I suspect that it is going into a spill register as it doesn't get written > > into a memory location nor any shadow processor register. This typically > > happens with C++ code - at least I haven't seen it occur with pure C but I am > > still running a limited set of apps in order to test. > > I'm missing something... what do you mean by "spill registers"? Do you > mean spills introduced by Valgrind's code generator? > > N > Yes - there is a memory load into a temporary register. Once that happens, I dont see the value it holds until it is put into a processor register on the simulated cpu. I can only assume that it is being stored in the "spills" area. I need to be able to track this as it is the final live reference to an allocated block and without it, I raise a false leak alert as the stack pointer is moved between the load and the put (then sheepishly free the block later when the code calls free()). Bryan "Brain Murders" Meredith |