> > appro> And even more generally how is it with PIC under Windows > > appro> anyway? Is it an issue? > > > > I've gotten the impression so far that PIC isn't an issue in Windows. > > On the second thought I cam to realize that that form of lea instruction > can't be used in PIC... One has to use mov... But then I can't use > &DWP... On the other hand linker can replace lea with mov... I wish > someone could just say how things are and what is "The Right Thing(TM)" > Can anybody do better that "impression?"
Here are my impressions. The Win32 code isn't really PIC! DLLs are linked at fixed addresses and if that address range happens to be already occupied in the current process address space at run time, then a [costly] relocation procedure is applied which basically obsoletes the idea of code segments being shared among several applications (on the other hand no letter in DLL stands for "shared"). For that reason programmer is more or less expected to pick a base address (link /base:...) which is likely to be unique for his module. I.e. if programmer wants to avoid costly relocation procedure applied at run-time and optimize overall memory usage. So that if nobody can decline the above paragraph, then the only question that is left is if anybody can verify that proposed patch doesn't actually break Windows build. Or should I just let the code appear in a snapshot? A. ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]