Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; template< class T > boost::shared_ptr< T > make_shared()
- ; 103: {
- 010411C0 push 0FFFFFFFFh
- 010411C2 push offset __ehhandler$??$make_shared@VCDerived@@@boost@@YA?AV?$shared_ptr@VCDerived@@@0@XZ (1041E49h)
- 010411C7 mov eax,dword ptr fs:[00000000h]
- 010411CD push eax
- 010411CE mov dword ptr fs:[0],esp
- 010411D5 sub esp,20h
- 010411D8 push ebx
- 010411D9 push esi
- 010411DA xor ebx,ebx
- 010411DC push edi
- 010411DD mov edi,dword ptr [esp+3Ch]
- 010411E1 mov dword ptr [esp+0Ch],ebx
- ; 104: boost::shared_ptr< T > pt( static_cast< T* >( 0 ), detail::sp_ms_deleter< T >() );
- 010411E5 mov byte ptr [esp+1Ch],bl
- 010411E9 sub esp,8
- 010411EC mov dword ptr [esp+3Ch],1
- 010411F4 mov eax,esp
- 010411F6 mov dword ptr [esp+1Ch],ebx
- 010411FA lea ecx,[esp+20h]
- 010411FE mov dword ptr [esp+18h],esp
- 01041202 mov byte ptr [eax],bl
- 01041204 call boost::detail::shared_count::shared_count<CDerived *,boost::detail::sp_ms_deleter<CDerived> > (1041340h)
- 01041209 push ebx
- 0104120A lea eax,[esp+18h]
- 0104120E push ebx
- 0104120F push eax
- 01041210 call boost::detail::sp_enable_shared_from_this (1041040h)
- 01041215 add esp,0Ch
- 01041218 mov byte ptr [esp+34h],bl
- 0104121C cmp byte ptr [esp+1Ch],bl
- 01041220 je boost::make_shared<CDerived>+73h (1041233h) ; <--------------- JUMP OCCURS
- 01041222 mov edx,dword ptr [esp+20h]
- 01041226 mov eax,dword ptr [edx]
- 01041228 push ebx
- 01041229 lea ecx,[esp+24h]
- 0104122D call eax
- 0104122F mov byte ptr [esp+1Ch],bl
- 01041233 mov dword ptr [esp+34h],2
- ; 105:
- ; 106: detail::sp_ms_deleter< T > * pd = boost::get_deleter< detail::sp_ms_deleter< T > >( pt );
- 0104123B mov ecx,dword ptr [esp+18h]
- 0104123F cmp ecx,ebx
- 01041241 je boost::make_shared<CDerived>+91h (1041251h) ; <------------------ NO JUMP
- 01041243 mov edx,dword ptr [ecx]
- 01041245 mov eax,dword ptr [edx+0Ch]
- 01041248 push offset boost::detail::sp_ms_deleter<CDerived> `RTTI Type Descriptor` (10430F4h)
- 0104124D call eax
- 0104124F jmp boost::make_shared<CDerived>+93h (1041253h)
- 01041251 xor eax,eax
- ; 107:
- ; 108: void * pv = pd->address();
- 01041253 lea esi,[eax+4]
- ; 109:
- ; 110: ::new( pv ) T();
- 01041256 cmp esi,ebx
- 01041258 je boost::make_shared<CDerived>+0A0h (1041260h) ; <--------------------- NO JUMP
- 0104125A mov dword ptr [esi],offset CDerived::`vftable` (104212Ch)
- ; 111: pd->set_initialized();
- ; 112:
- ; 113: T * pt2 = static_cast< T* >( pv );
- ; 114:
- ; 115: boost::detail::sp_enable_shared_from_this( &pt, pt2, pt2 );
- 01041260 push esi
- 01041261 lea ecx,[esp+18h]
- 01041265 push esi
- 01041266 push ecx
- 01041267 mov byte ptr [eax],1
- 0104126A call boost::detail::sp_enable_shared_from_this (1041040h)
- ; 116: return boost::shared_ptr< T >( pt, pt2 );
- 0104126F mov eax,dword ptr [esp+24h]
- 01041273 add esp,0Ch
- 01041276 mov dword ptr [edi],esi
- 01041278 mov dword ptr [edi+4],eax
- 0104127B cmp eax,ebx
- 0104127D je boost::make_shared<CDerived>+0CFh (104128Fh) ; <--------------- NO JUMP
- 0104127F add eax,4
- 01041282 mov edx,1
- 01041287 lock xadd dword ptr [eax],edx ; <----------------------- CALLED
- 0104128B mov eax,dword ptr [esp+18h]
- 0104128F mov dword ptr [esp+0Ch],1
- 01041297 mov byte ptr [esp+34h],bl
- 0104129B cmp eax,ebx
- 0104129D je boost::make_shared<CDerived>+10Bh (10412CBh) ; <---------- NO JUMP
- 0104129F mov esi,eax
- 010412A1 add eax,4
- 010412A4 or ecx,0FFFFFFFFh
- 010412A7 lock xadd dword ptr [eax],ecx ; <---------------------- CALLED
- 010412AB jne boost::make_shared<CDerived>+10Bh (10412CBh) ; <-------------- JUMP OCCURS
- 010412AD mov edx,dword ptr [esi]
- 010412AF mov eax,dword ptr [edx+4]
- 010412B2 mov ecx,esi
- 010412B4 call eax
- 010412B6 lea ecx,[esi+8]
- 010412B9 or edx,0FFFFFFFFh
- 010412BC lock xadd dword ptr [ecx],edx
- 010412C0 jne boost::make_shared<CDerived>+10Bh (10412CBh)
- 010412C2 mov eax,dword ptr [esi]
- 010412C4 mov edx,dword ptr [eax+8]
- 010412C7 mov ecx,esi
- 010412C9 call edx
- ; 117: }
- 010412CB mov ecx,dword ptr [esp+2Ch]
- 010412CF mov eax,edi
- 010412D1 pop edi
- 010412D2 pop esi
- 010412D3 mov dword ptr fs:[0],ecx
- 010412DA pop ebx
- 010412DB add esp,2Ch
- 010412DE ret
Advertisement
Add Comment
Please, Sign In to add comment