[LLVMdev] x86 code emitter ebp and esp conflicts
Peng Cheng
gm4cheng at gmail.com
Wed Jan 30 08:27:04 PST 2013
Hi,
I recently ran into a case, where x86 fails to run correctly.
Checking into the emitted code, it seems that the local memory anchored at
ebp has conflict with stack memory anchored at esp prepared for function
calls.
For example, let us say:
foo()
{
...
call bar();
}
There is some local data for foo() at ebp-170h. while preparing the call
to bar, some data is written to esp+17h. The problem is that esp+17h and
ebp-170h point to the same address, and therefore the data is corrupted.
Has anyone seen this problem before? and is there any fix or work around
for that?
Thanks!
-Peng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130130/bc15b08f/attachment.html>
More information about the llvm-dev
mailing list