Last Comment Bug 773724 - XPCOM preloads delay load modules on Windows
: XPCOM preloads delay load modules on Windows
Status: RESOLVED FIXED
completed-elm
:
Product: Core
Classification: Components
Component: Widget: Win32 (show other bugs)
: Trunk
: x86_64 Windows 8.1
: -- normal (vote)
: mozilla17
Assigned To: Mike Hommey [:glandium]
:
: Jim Mathies [:jimm]
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-13 10:59 PDT by Jim Mathies [:jimm]
Modified: 2014-07-24 11:06 PDT (History)
3 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch (3.08 KB, patch)
2012-07-16 13:28 PDT, Jim Mathies [:jimm]
no flags Details | Diff | Splinter Review
patch (3.53 KB, patch)
2012-07-16 13:42 PDT, Jim Mathies [:jimm]
mh+mozilla: review-
Details | Diff | Splinter Review
Skip delayload libraries in dependentlibs.py (1.59 KB, patch)
2012-07-17 01:30 PDT, Mike Hommey [:glandium]
khuey: review+
Details | Diff | Splinter Review

Description Jim Mathies [:jimm] 2012-07-13 10:59:58 PDT
Really weird behavior now that we include vccorlib110 in our distribution. This doesn't get in the way of running the app, but it does generate an error that you can dismiss. There are some hackish ways around this but I'd like to try and understand why windows is temporarily loading a delay load module when it shouldn't.

'firefox.exe' (Win32): Loaded 'C:\Users\jim\Desktop\firefox\msvcp110.dll'.
'firefox.exe' (Win32): Loaded 'C:\Users\jim\Desktop\firefox\gkmedias.dll'.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msdmo.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msimg32.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Users\jim\Desktop\firefox\vccorlib110.dll'.
'firefox.exe' (Win32): Unloaded 'C:\Users\jim\Desktop\firefox\vccorlib110.dll'
'firefox.exe' (Win32): Loaded 'C:\Users\jim\Desktop\firefox\xul.dll'.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\version.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\IPHLPAPI.DLL'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\winnsi.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\uxtheme.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\setupapi.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cfgmgr32.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Windows\SysWOW64\devobj.dll'. Symbols loaded.
'firefox.exe' (Win32): Loaded 'C:\Users\jim\Desktop\firefox\dummyvccorlib.dll'.
Comment 1 Jim Mathies [:jimm] 2012-07-16 13:28:39 PDT
Created attachment 642702 [details] [diff] [review]
patch

Turns out this isn't Windows, it's our preloading logic in xpcomglue which loads a list of dependency libs on startup, including vccorlib110.dll.
Comment 2 Jim Mathies [:jimm] 2012-07-16 13:42:37 PDT
Created attachment 642712 [details] [diff] [review]
patch

w/needed make logic
Comment 3 Jim Mathies [:jimm] 2012-07-16 13:48:25 PDT
https://hg.mozilla.org/projects/elm/rev/bf5acae0c984

testing this on elm first to be sure it's working as expected.
Comment 4 Jim Mathies [:jimm] 2012-07-16 14:34:49 PDT
Comment on attachment 642712 [details] [diff] [review]
patch

Slight enhancement to dependentlibs.py which allows callers to filter certain libs out of the resulting list. We use this on Win8 to avoid loading a delay load module which will fail to load on os < Win8.
Comment 5 Mike Hommey [:glandium] 2012-07-17 01:30:44 PDT
Created attachment 642888 [details] [diff] [review]
Skip delayload libraries in dependentlibs.py

Jim, can you test this?
Comment 6 Mike Hommey [:glandium] 2012-07-17 01:31:52 PDT
Comment on attachment 642712 [details] [diff] [review]
patch

Better not to rely on manual work when the required data is already there in the dlls.
Comment 7 Jim Mathies [:jimm] 2012-07-17 03:43:26 PDT
Comment on attachment 642712 [details] [diff] [review]
patch

Yes, that seems to do the trick.
Comment 9 Ed Morley [:emorley] 2012-07-24 03:03:57 PDT
https://hg.mozilla.org/mozilla-central/rev/41f7e82c794c

Note You need to log in before you can comment on or make changes to this bug.