Andy Polyakov wrote:
Does it actually pass the tests by the way? Point is that push %ebx is not accounted to stack pointer and if "m"(iv) is on stack (and it is), then attempt to reference it from assembler template results on off-by-4 effective address... Provided that we compile with -fomit-frame-pointer (as we do)... What you should do is following:
For me it worked because I only tested without "-fomit-... -O2" but with -g instead and built a static libcrypto.a...
Now I recall - that's why I used "movl %xxx,-4(%esp)" instead of "pushl %xxx" in my previous patches. That's it...
asm volatile ("cpuid; movl %%ebx, (%%edi); movl %%edx, 4(%%edi); movl %%ecx, 8(%%edi)"
: "+a"(eax) : "mD"(vendor_string) : "ebx", "ecx", "edx");
It should also be surrounded by push %ebx and pop %ebx, because as above ebx comes out corrupted in PIC [at lest with compilers I've tested].
But this should be surrounded by push %ebx/pop %ebx by the compiler, shouldn't it?
If it's OK with you I can fix the code to my "liking" and send it back... A.
Indeed ;-)
Thanks!
Michal Ludvig ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]
