From: Pavel P. <pa...@su...> - 2010-07-12 23:06:07
|
> -----Original Message----- > From: Danny Backx [mailto:dan...@sc...] > Sent: Monday, July 12, 2010 16:20 > To: Pavel Pavlov > Cc: ceg...@li... > Subject: RE: [Cegcc-devel] Porting cegcc changes to latest version of cegcc > > On Mon, 2010-07-12 at 14:59 -0400, Pavel Pavlov wrote: > > After checking some files I noticed that VERSIONS file and checked out > > octorer 17 2009 version of binutils. I merged all the changes into > > latest version of binutils. Also, I noticed that versions of binutils > > in cegcc svn has some strange changes, which look to me more likely > > like incorrect merge from previous versions of binutils. Plus, there > > are a bunch of files that simply do not exist in that 0ct17,2009 > > version of binutils. > > The reason I wanted to merge binutils is because I have that strange > > problem that dlls produced with cegcc-4.4.0; dlls are almost twice > > bigger compared to builds with cegcc 4.1.0 (because half of the > > produced dll is filled with zeros). I checked object files that go > > into the dll and all of them are normal and have no zeros, but the > > final dll is full of shi...., I mean zeros. So, it looked as if it was > > a linker problem and the linker is part of binutils package. I thought > > that if I take latest binutils I'll probably get it fixed. > > Still, after I merged changes into latest binutils I got the same > > results and the binaries produced are almost bitexact (at least that's > > a good sign that I didn't screw up with the merge). > > The "twice as big" and "zeroes" issue might be a consequence of my > incomplete work on supporting WinCE 6.1+ DLLs. Incomplete because I got > zero support and then when I was loosing courage, I got the Android device > ... > > You can take out the WinCE 6.* changes and you'll probably see that that > issue is gone. > I don't understand completely what you mean here. What was the original reason for your changes that caused that doubled size&zeroes problem? Is that the infamous problem when binaries did not load on newer phones? By the way, I fixed that problem on my side differently. Because dlls that I load are quite big (around 10MB in total) then I have huge problem on Windows Mobile. Who knows windows mobile memory model will understand that: it's related to 32MB per process slot and all dlls combined take away upper part of that slot. So, either way, 10MB of dll's will likely cripple entire phone and will affect most of apps running on the phone; so I wrote my own dll loader. Basically, I load it using regular fread, parse PE headers, allocate executable pages and do all relocations manually... so, as of now I'm not that worried if gcc builds dll that doesn't load :) it seems that there some strange thing in wince loader, my manually written loader loads them just fine and works well. I'll try to see svn log for your changes to try to figure out what the problem was, maybe I'll have some luck |