http://bugs.winehq.org/show_bug.cgi?id=24549
--- Comment #8 from Julian Seward jseward@acm.org 2010-10-19 07:13:01 CDT --- (In reply to comment #7)
We use signal stacks for this reason. [...]
Well, fair enough. Nevertheless it does cause problems when Valgrinding Windows apps on Wine, for two reasons
* the errors need to be suppressed, which is extra effort, hassle, etc, and can also be slow if it happens millions of times
* when the data is read from below %esp, Memcheck's default rules assume the data is initialised [1]. Hence if the stored value was uninitialised it will be reloaded as initialised, so an outside chance of false negatives.
I looked at the fn and it doesn't look difficult to ensure there is no below-%esp accesses. Is there some reason why the function has this particular below-%esp accesses, or is it just an accident of history?
[1] Yes, I know this sounds stupid. See http://www.valgrind.org/docs/manual/mc-manual.html#mc-manual.together 8th bullet point for rationale.