View the pointer to member variables in c ++ from assembly (1)

Source: Internet
Author: User

 

    _x}     _y}     _z   Y y   Z z   y._y =    z._x =    z._y =    z._z =  :*xmp1 = &:_x :*ymp1 = &:_y :*zmp1 = &:_x    :*zmp2 = &:_y    :*zmp3 = &:_z   cout <<  << endl   cout <<  << sizeof(xmp1) << endl   cout <<  << sizeof(ymp1) << endl   cout <<  << sizeof(zmp1) << endl   cout <<  << sizeof(zmp2) << endl   cout <<  << sizeof(zmp3) << endl << endl   printf(, &:_x)   printf(, xmp1)   cout <<  << endl   printf(, &:_y)   printf(, ymp1)   cout <<  << endl   printf(, &:_x)   printf(, &:_y)   printf(, &:_z)   printf(, zmp1)   printf(, zmp2)   printf(, zmp3)   cout <<  << endl   cout <<  << endl   z.*xmp1 =    cout <<  << x.*xmp1 << endl   cout <<  << z.*xmp1 << endl   cout <<  << x._x << endl << endl   zp->*xmp1 =    cout <<  << x.*xmp1 << endl   cout <<  << zp->*xmp1 << endl   cout <<  << x._x << endl   cout <<  << z._x << endl << endl   cout <<  << endl   z.*ymp1 =    cout <<  << y.*ymp1 << endl   cout <<  << z.*ymp1 << endl   cout <<  << y._y << endl   cout <<  << z._y << endl << endl   zp->*ymp1 =    cout <<  << y.*ymp1 << endl   cout <<  << zp->*ymp1 << endl   cout <<  << y._y << endl   cout <<  << z._y << endl << endl   X* xp = zp   xp->*xmp1 =    cout <<  << x.*xmp1 << endl   cout <<  << xp->*xmp1 << endl   cout <<  << x._x << endl   cout <<  << z._x << endl   yp->*ymp1 =    cout <<  << y.*ymp1 << endl   cout <<  << yp->*ymp1 << endl   cout <<  << y._y << endl   cout <<  << z._y << endl  

 z.*ymp1 = ;
 zp->*ymp1 = ;

        DWORD PTR _zp$[ebp],         SHORT $LN11@main        eax, DWORD PTR _zp$[ebp]        eax,         DWORD PTR tv519[ebp], eax        SHORT $LN12@main$        DWORD PTR tv519[ebp], $        ecx, DWORD PTR tv519[ebp]        ecx, DWORD PTR _ymp1$[ebp]        DWORD PTR [ecx], 

        edx, DWORD PTR _z$[ebp]        edx, edx                            eax,             DWORD PTR tv410[ebp],         DWORD PTR [ecx], 

 

 zmp2 = ymp1;

 

        DWORD PTR _ymp1$[ebp], -        SHORT $LN13@main        DWORD PTR tv532[ebp], -        SHORT $LN14@main$        edx, DWORD PTR _ymp1$[ebp]        edx,                                     DWORD PTR tv532[ebp], edx$        eax, DWORD PTR tv532[ebp]        DWORD PTR _zmp2$[ebp], eax

 

 

 

 

 

 

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.