--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
Marshall, this could be related to how you build CEF in a separate DLL. I think the entire binary should use the same memory allocator for things to stay sane.

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
I'm fairly out of date with our current TCMalloc use, but I didn't know we were using debugallocation on Windows. This stack looks really weird. It appears to be a startup crash, that's somehow invoking atexit()? Where's the code for this initializer? I can't find it in cs.chromium.org. Sounds like a bug in the static initializer.
So fundamentally what's going on is we aren't initializing the PageHeap (either at all, or in the wrong order). That means we're probably not executing the TCMallocGuard (which will register it). In our very complicated TCMalloc setup code, we leverage allocator_shim.cc to hook _heap_init(), which will invoke the TCMallocGuard.If people who hit this bug could run their code in the debugger to see if TCMallocGuard is getting executed, that'd narrow down the problem. If it's not getting executed before the crash, then that initialization code is the problem. Of course, I have no idea why 200327 would have changed this.
On Jun 3, 2013, at 7:19 PM, Paweł Hajdan, Jr. <phajd...@chromium.org> wrote:Marshall, this could be related to how you build CEF in a separate DLL. I think the entire binary should use the same memory allocator for things to stay sane.Thanks, I'll try building the executable with tcmalloc to see if that resolves the problem. If that's the only solution then I'll likely have to disable debugallocation when building CEF since not all users will be able/willing to use tcmalloc with their applications.Is debugallocation enabled by default on OS-X? I didn't experience any crashes on that platform even though CEF is loaded from a dylib.
PawełOn Mon, Jun 3, 2013 at 4:02 PM, Marshall Greenblatt <magree...@gmail.com> wrote:
Hi All,The below crash occurs while loading the Chromium Embedded Framework (CEF) DLL on Windows. It started when I synced past Chromium revision 200327 which enables tcmalloc's debugallocation. If I disable debugallocation by setting disable_debugallocation=1 in GYP then the crash disappears and the application loads normally. Any suggestions on what this crash means and whether it's a bug in my application or in debugallocation?Thanks,MarshallFirst-chance exception at 0x0f69e8c4 (libcef.dll) in cefclient.exe: 0xC0000005: Access violation reading location 0x0287e2ec.> libcef.dll!TCMalloc_PageMap1_LazyCommit<20>::get(unsigned int k) Line 297 + 0x8 bytes C++libcef.dll!tcmalloc::PageHeap::GetDescriptor(unsigned int p) Line 145 C++libcef.dll!TCMallocImplementation::GetOwnership(const void * ptr) Line 805 + 0x10 bytes C++libcef.dll!DebugMallocImplementation::GetOwnership(const void * p) Line 1065 + 0xc bytes C++libcef.dll!DebugMallocImplementation::GetAllocatedSize(const void * p) Line 1055 + 0x13 bytes C++libcef.dll!_msize(void * p) Line 232 + 0x1b bytes C++libcef.dll!_onexit_nolock(int (void)* func) Line 118 + 0x6 bytes Clibcef.dll!_onexit(int (void)* func) Line 87 + 0x8 bytes Clibcef.dll!atexit(void (void)* func) Line 162 + 0x8 bytes Clibcef.dll!`anonymous namespace'::`dynamic initializer for 'google_initializer_module_debugallocation''() Line 1094 + 0x23 bytes C++libcef.dll!_cinit(int initFloatingPrecision) Line 288 + 0x19 bytes Clibcef.dll!_CRT_INIT(void * hDllHandle, unsigned long dwReason, void * lpreserved) Line 132 + 0x19 bytes Clibcef.dll!__DllMainCRTStartup(void * hDllHandle, unsigned long dwReason, void * lpreserved) Line 324 + 0x8 bytes Clibcef.dll!_DllMainCRTStartup(void * hDllHandle, unsigned long dwReason, void * lpreserved) Line 293 + 0xe bytes Cntdll.dll!77bc9950()
--