GAS LISTING /tmp/ccyyAyAp.s page 1 1 .file "virtual-sub.cpp" 2 .text 3 .Ltext0: 4 .section .text._ZN5aBaseD2Ev,"axG",@progbits,_ZN5aBaseD5Ev,comdat 5 .align 2 6 .weak _ZN5aBaseD2Ev 8 _ZN5aBaseD2Ev: 9 .LFB1244: 10 .file 1 "virtual-sub.cpp" 1:virtual-sub.cpp **** #include <iostream> 2:virtual-sub.cpp **** 3:virtual-sub.cpp **** class aBase { 4:virtual-sub.cpp **** int baseData; 5:virtual-sub.cpp **** public: 6:virtual-sub.cpp **** virtual int getBaseData() const; 7:virtual-sub.cpp **** virtual ~aBase() { } 11 .loc 1 7 0 12 .cfi_startproc 13 .LVL0: 14 .LBB2: 15 .loc 1 7 0 16 0000 48C70700 movq $_ZTV5aBase+16, (%rdi) 16 000000 17 0007 C3 ret 18 .LBE2: 19 .cfi_endproc 20 .LFE1244: 22 .weak _ZN5aBaseD1Ev 23 .set _ZN5aBaseD1Ev,_ZN5aBaseD2Ev 24 .text 25 .align 2 26 .globl _ZNK5aBase11getBaseDataEv 28 _ZNK5aBase11getBaseDataEv: 29 .LFB1247: 8:virtual-sub.cpp **** }; 9:virtual-sub.cpp **** 10:virtual-sub.cpp **** class aSub : public virtual aBase { 11:virtual-sub.cpp **** int dataA; 12:virtual-sub.cpp **** public: 13:virtual-sub.cpp **** void setDataA(int a); 14:virtual-sub.cpp **** virtual int getDataA() const; 15:virtual-sub.cpp **** }; 16:virtual-sub.cpp **** 17:virtual-sub.cpp **** int aBase::getBaseData() const { 30 .loc 1 17 0 31 .cfi_startproc 32 .LVL1: 18:virtual-sub.cpp **** return baseData; 33 .loc 1 18 0 34 0000 8B4708 movl 8(%rdi), %eax 19:virtual-sub.cpp **** } 35 .loc 1 19 0 36 0003 C3 ret 37 .cfi_endproc 38 .LFE1247: 40 .align 2 41 .globl _ZNK4aSub8getDataAEv GAS LISTING /tmp/ccyyAyAp.s page 2 43 _ZNK4aSub8getDataAEv: 44 .LFB1249: 20:virtual-sub.cpp **** 21:virtual-sub.cpp **** void aSub::setDataA(int a) { 22:virtual-sub.cpp **** dataA = a; 23:virtual-sub.cpp **** } 24:virtual-sub.cpp **** int aSub::getDataA() const { 45 .loc 1 24 0 46 .cfi_startproc 47 .LVL2: 25:virtual-sub.cpp **** return dataA; 48 .loc 1 25 0 49 0004 8B4708 movl 8(%rdi), %eax 26:virtual-sub.cpp **** } 50 .loc 1 26 0 51 0007 C3 ret 52 .cfi_endproc 53 .LFE1249: 55 .section .text._ZN4aSubD1Ev,"axG",@progbits,_ZN4aSubD1Ev,comdat 56 .align 2 57 .weak _ZN4aSubD1Ev 59 _ZN4aSubD1Ev: 60 .LFB1413: 10:virtual-sub.cpp **** int dataA; 61 .loc 1 10 0 62 .cfi_startproc 63 .LVL3: 64 0000 4883EC08 subq $8, %rsp 65 .cfi_def_cfa_offset 16 66 .LBB3: 10:virtual-sub.cpp **** int dataA; 67 .loc 1 10 0 68 0004 48C70700 movq $_ZTV4aSub+24, (%rdi) 68 000000 69 000b 48C74710 movq $_ZTV4aSub+80, 16(%rdi) 69 00000000 70 0013 4883C710 addq $16, %rdi 71 .LVL4: 72 0017 E8000000 call _ZN5aBaseD2Ev 72 00 73 .LVL5: 74 .LBE3: 75 001c 4883C408 addq $8, %rsp 76 .cfi_def_cfa_offset 8 77 0020 C3 ret 78 .cfi_endproc 79 .LFE1413: 81 .set .LTHUNK0,_ZN4aSubD1Ev 82 .weak _ZTv0_n32_N4aSubD1Ev 84 _ZTv0_n32_N4aSubD1Ev: 85 .LFB1417: 10:virtual-sub.cpp **** int dataA; 86 .loc 1 10 0 87 .cfi_startproc 88 0021 4C8B17 movq (%rdi), %r10 89 0024 49037AE0 addq -32(%r10), %rdi 90 0028 EBD6 jmp .LTHUNK0 GAS LISTING /tmp/ccyyAyAp.s page 3 91 .cfi_endproc 92 .LFE1417: 94 .section .text._ZN5aBaseD0Ev,"axG",@progbits,_ZN5aBaseD0Ev,comdat 95 .align 2 96 .weak _ZN5aBaseD0Ev 98 _ZN5aBaseD0Ev: 99 .LFB1246: 7:virtual-sub.cpp **** }; 100 .loc 1 7 0 101 .cfi_startproc 102 .LVL6: 103 0000 53 pushq %rbx 104 .cfi_def_cfa_offset 16 105 .cfi_offset 3, -16 106 0001 4889FB movq %rdi, %rbx 7:virtual-sub.cpp **** }; 107 .loc 1 7 0 108 0004 E8000000 call _ZN5aBaseD1Ev 108 00 109 .LVL7: 110 0009 4889DF movq %rbx, %rdi 111 000c E8000000 call _ZdlPv 111 00 112 .LVL8: 113 0011 5B popq %rbx 114 .cfi_def_cfa_offset 8 115 .LVL9: 116 0012 C3 ret 117 .cfi_endproc 118 .LFE1246: 120 .section .text._ZN4aSubD0Ev,"axG",@progbits,_ZN4aSubD0Ev,comdat 121 .align 2 122 .weak _ZN4aSubD0Ev 124 _ZN4aSubD0Ev: 125 .LFB1414: 10:virtual-sub.cpp **** int dataA; 126 .loc 1 10 0 127 .cfi_startproc 128 .LVL10: 129 0000 53 pushq %rbx 130 .cfi_def_cfa_offset 16 131 .cfi_offset 3, -16 132 0001 4889FB movq %rdi, %rbx 10:virtual-sub.cpp **** int dataA; 133 .loc 1 10 0 134 0004 E8000000 call _ZN4aSubD1Ev 134 00 135 .LVL11: 136 0009 4889DF movq %rbx, %rdi 137 000c E8000000 call _ZdlPv 137 00 138 .LVL12: 139 0011 5B popq %rbx 140 .cfi_def_cfa_offset 8 141 .LVL13: 142 0012 C3 ret 143 .cfi_endproc GAS LISTING /tmp/ccyyAyAp.s page 4 144 .LFE1414: 146 .set .LTHUNK1,_ZN4aSubD0Ev 147 .weak _ZTv0_n32_N4aSubD0Ev 149 _ZTv0_n32_N4aSubD0Ev: 150 .LFB1418: 10:virtual-sub.cpp **** int dataA; 151 .loc 1 10 0 152 .cfi_startproc 153 0013 4C8B17 movq (%rdi), %r10 154 0016 49037AE0 addq -32(%r10), %rdi 155 001a EBE4 jmp .LTHUNK1 156 .cfi_endproc 157 .LFE1418: 159 .text 161 _Z41__static_initialization_and_destruction_0ii: 162 .LFB1415: 27:virtual-sub.cpp **** 28:virtual-sub.cpp **** void virtualSub() { 29:virtual-sub.cpp **** 30:virtual-sub.cpp **** aSub *ba = new aSub(); 31:virtual-sub.cpp **** 32:virtual-sub.cpp **** int i = ba->getDataA(); 33:virtual-sub.cpp **** 34:virtual-sub.cpp **** aBase *botb = ba; 35:virtual-sub.cpp **** 36:virtual-sub.cpp **** int j = botb->getBaseData(); 37:virtual-sub.cpp **** 38:virtual-sub.cpp **** std::cout << "virtualSub " << i << " " << j << std::endl; 39:virtual-sub.cpp **** } 163 .loc 1 39 0 164 .cfi_startproc 165 .LVL14: 166 0008 83FF01 cmpl $1, %edi 167 000b 752E jne .L14 168 .loc 1 39 0 discriminator 1 169 000d 81FEFFFF cmpl $65535, %esi 169 0000 170 0013 7526 jne .L14 171 .loc 1 39 0 is_stmt 0 172 0015 4883EC08 subq $8, %rsp 173 .cfi_def_cfa_offset 16 174 .file 2 "/usr/include/c++/4.8/iostream" 1:/usr/include/c++/4.8/iostream **** // Standard iostream objects -*- C++ -*- 2:/usr/include/c++/4.8/iostream **** 3:/usr/include/c++/4.8/iostream **** // Copyright (C) 1997-2013 Free Software Foundation, Inc. 4:/usr/include/c++/4.8/iostream **** // 5:/usr/include/c++/4.8/iostream **** // This file is part of the GNU ISO C++ Library. This library is free 6:/usr/include/c++/4.8/iostream **** // software; you can redistribute it and/or modify it under the 7:/usr/include/c++/4.8/iostream **** // terms of the GNU General Public License as published by the 8:/usr/include/c++/4.8/iostream **** // Free Software Foundation; either version 3, or (at your option) 9:/usr/include/c++/4.8/iostream **** // any later version. 10:/usr/include/c++/4.8/iostream **** 11:/usr/include/c++/4.8/iostream **** // This library is distributed in the hope that it will be useful, 12:/usr/include/c++/4.8/iostream **** // but WITHOUT ANY WARRANTY; without even the implied warranty of 13:/usr/include/c++/4.8/iostream **** // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14:/usr/include/c++/4.8/iostream **** // GNU General Public License for more details. 15:/usr/include/c++/4.8/iostream **** GAS LISTING /tmp/ccyyAyAp.s page 5 16:/usr/include/c++/4.8/iostream **** // Under Section 7 of GPL version 3, you are granted additional 17:/usr/include/c++/4.8/iostream **** // permissions described in the GCC Runtime Library Exception, version 18:/usr/include/c++/4.8/iostream **** // 3.1, as published by the Free Software Foundation. 19:/usr/include/c++/4.8/iostream **** 20:/usr/include/c++/4.8/iostream **** // You should have received a copy of the GNU General Public License and 21:/usr/include/c++/4.8/iostream **** // a copy of the GCC Runtime Library Exception along with this program; 22:/usr/include/c++/4.8/iostream **** // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see 23:/usr/include/c++/4.8/iostream **** // <http://www.gnu.org/licenses/>. 24:/usr/include/c++/4.8/iostream **** 25:/usr/include/c++/4.8/iostream **** /** @file include/iostream 26:/usr/include/c++/4.8/iostream **** * This is a Standard C++ Library header. 27:/usr/include/c++/4.8/iostream **** */ 28:/usr/include/c++/4.8/iostream **** 29:/usr/include/c++/4.8/iostream **** // 30:/usr/include/c++/4.8/iostream **** // ISO C++ 14882: 27.3 Standard iostream objects 31:/usr/include/c++/4.8/iostream **** // 32:/usr/include/c++/4.8/iostream **** 33:/usr/include/c++/4.8/iostream **** #ifndef _GLIBCXX_IOSTREAM 34:/usr/include/c++/4.8/iostream **** #define _GLIBCXX_IOSTREAM 1 35:/usr/include/c++/4.8/iostream **** 36:/usr/include/c++/4.8/iostream **** #pragma GCC system_header 37:/usr/include/c++/4.8/iostream **** 38:/usr/include/c++/4.8/iostream **** #include <bits/c++config.h> 39:/usr/include/c++/4.8/iostream **** #include <ostream> 40:/usr/include/c++/4.8/iostream **** #include <istream> 41:/usr/include/c++/4.8/iostream **** 42:/usr/include/c++/4.8/iostream **** namespace std _GLIBCXX_VISIBILITY(default) 43:/usr/include/c++/4.8/iostream **** { 44:/usr/include/c++/4.8/iostream **** _GLIBCXX_BEGIN_NAMESPACE_VERSION 45:/usr/include/c++/4.8/iostream **** 46:/usr/include/c++/4.8/iostream **** /** 47:/usr/include/c++/4.8/iostream **** * @name Standard Stream Objects 48:/usr/include/c++/4.8/iostream **** * 49:/usr/include/c++/4.8/iostream **** * The <iostream> header declares the eight <em>standard stream 50:/usr/include/c++/4.8/iostream **** * objects</em>. For other declarations, see 51:/usr/include/c++/4.8/iostream **** * http://gcc.gnu.org/onlinedocs/libstdc++/manual/bk01pt11ch24.html 52:/usr/include/c++/4.8/iostream **** * and the @link iosfwd I/O forward declarations @endlink 53:/usr/include/c++/4.8/iostream **** * 54:/usr/include/c++/4.8/iostream **** * They are required by default to cooperate with the global C 55:/usr/include/c++/4.8/iostream **** * library's @c FILE streams, and to be available during program 56:/usr/include/c++/4.8/iostream **** * startup and termination. For more information, see the HOWTO 57:/usr/include/c++/4.8/iostream **** * linked to above. 58:/usr/include/c++/4.8/iostream **** */ 59:/usr/include/c++/4.8/iostream **** //@{ 60:/usr/include/c++/4.8/iostream **** extern istream cin; /// Linked to standard input 61:/usr/include/c++/4.8/iostream **** extern ostream cout; /// Linked to standard output 62:/usr/include/c++/4.8/iostream **** extern ostream cerr; /// Linked to standard error (unbuffered) 63:/usr/include/c++/4.8/iostream **** extern ostream clog; /// Linked to standard error (buffered) 64:/usr/include/c++/4.8/iostream **** 65:/usr/include/c++/4.8/iostream **** #ifdef _GLIBCXX_USE_WCHAR_T 66:/usr/include/c++/4.8/iostream **** extern wistream wcin; /// Linked to standard input 67:/usr/include/c++/4.8/iostream **** extern wostream wcout; /// Linked to standard output 68:/usr/include/c++/4.8/iostream **** extern wostream wcerr; /// Linked to standard error (unbuffered) 69:/usr/include/c++/4.8/iostream **** extern wostream wclog; /// Linked to standard error (buffered) 70:/usr/include/c++/4.8/iostream **** #endif 71:/usr/include/c++/4.8/iostream **** //@} 72:/usr/include/c++/4.8/iostream **** GAS LISTING /tmp/ccyyAyAp.s page 6 73:/usr/include/c++/4.8/iostream **** // For construction of filebuffers for cout, cin, cerr, clog et. al. 74:/usr/include/c++/4.8/iostream **** static ios_base::Init __ioinit; 175 .loc 2 74 0 is_stmt 1 176 0019 BF000000 movl $_ZStL8__ioinit, %edi 176 00 177 .LVL15: 178 001e E8000000 call _ZNSt8ios_base4InitC1Ev 178 00 179 .LVL16: 180 0023 BA000000 movl $__dso_handle, %edx 180 00 181 0028 BE000000 movl $_ZStL8__ioinit, %esi 181 00 182 002d BF000000 movl $_ZNSt8ios_base4InitD1Ev, %edi 182 00 183 0032 E8000000 call __cxa_atexit 183 00 184 .LVL17: 185 .loc 1 39 0 186 0037 4883C408 addq $8, %rsp 187 .cfi_def_cfa_offset 8 188 .L14: 189 003b C3 ret 190 .cfi_endproc 191 .LFE1415: 193 .align 2 194 .globl _ZN4aSub8setDataAEi 196 _ZN4aSub8setDataAEi: 197 .LFB1248: 21:virtual-sub.cpp **** dataA = a; 198 .loc 1 21 0 199 .cfi_startproc 200 .LVL18: 22:virtual-sub.cpp **** } 201 .loc 1 22 0 202 003c 897708 movl %esi, 8(%rdi) 203 003f C3 ret 204 .cfi_endproc 205 .LFE1248: 207 .section .text._ZN5aBaseC2Ev,"axG",@progbits,_ZN5aBaseC5Ev,comdat 208 .align 2 209 .weak _ZN5aBaseC2Ev 211 _ZN5aBaseC2Ev: 212 .LFB1253: 3:virtual-sub.cpp **** int baseData; 213 .loc 1 3 0 214 .cfi_startproc 215 .LVL19: 216 .LBB4: 3:virtual-sub.cpp **** int baseData; 217 .loc 1 3 0 218 0000 48C70700 movq $_ZTV5aBase+16, (%rdi) 218 000000 219 0007 C3 ret 220 .LBE4: 221 .cfi_endproc 222 .LFE1253: GAS LISTING /tmp/ccyyAyAp.s page 7 224 .weak _ZN5aBaseC1Ev 225 .set _ZN5aBaseC1Ev,_ZN5aBaseC2Ev 226 .section .text._ZN4aSubC1Ev,"axG",@progbits,_ZN4aSubC1Ev,comdat 227 .align 2 228 .weak _ZN4aSubC1Ev 230 _ZN4aSubC1Ev: 231 .LFB1256: 10:virtual-sub.cpp **** int dataA; 232 .loc 1 10 0 233 .cfi_startproc 234 .LVL20: 235 0000 53 pushq %rbx 236 .cfi_def_cfa_offset 16 237 .cfi_offset 3, -16 238 0001 4889FB movq %rdi, %rbx 239 .LBB5: 10:virtual-sub.cpp **** int dataA; 240 .loc 1 10 0 241 0004 488D7F10 leaq 16(%rdi), %rdi 242 .LVL21: 243 0008 E8000000 call _ZN5aBaseC2Ev 243 00 244 .LVL22: 245 000d 48C70300 movq $_ZTV4aSub+24, (%rbx) 245 000000 246 0014 48C74310 movq $_ZTV4aSub+80, 16(%rbx) 246 00000000 247 .LBE5: 248 001c 5B popq %rbx 249 .cfi_def_cfa_offset 8 250 .LVL23: 251 001d C3 ret 252 .cfi_endproc 253 .LFE1256: 255 .section .rodata.str1.1,"aMS",@progbits,1 256 .LC0: 257 0000 76697274 .string "virtualSub " 257 75616C53 257 75622000 258 .LC1: 259 000c 2000 .string " " 260 .text 261 .globl _Z10virtualSubv 263 _Z10virtualSubv: 264 .LFB1250: 28:virtual-sub.cpp **** 265 .loc 1 28 0 266 .cfi_startproc 267 0040 55 pushq %rbp 268 .cfi_def_cfa_offset 16 269 .cfi_offset 6, -16 270 0041 53 pushq %rbx 271 .cfi_def_cfa_offset 24 272 .cfi_offset 3, -24 273 0042 4883EC08 subq $8, %rsp 274 .cfi_def_cfa_offset 32 275 .LBB6: GAS LISTING /tmp/ccyyAyAp.s page 8 30:virtual-sub.cpp **** 276 .loc 1 30 0 277 0046 BF200000 movl $32, %edi 277 00 278 004b E8000000 call _Znwm 278 00 279 .LVL24: 280 0050 4889C3 movq %rax, %rbx 281 0053 48C70000 movq $0, (%rax) 281 000000 282 005a C7400800 movl $0, 8(%rax) 282 000000 283 0061 48C74010 movq $0, 16(%rax) 283 00000000 284 0069 C7401800 movl $0, 24(%rax) 284 000000 285 0070 4889C7 movq %rax, %rdi 286 0073 E8000000 call _ZN4aSubC1Ev 286 00 287 .LVL25: 32:virtual-sub.cpp **** 288 .loc 1 32 0 289 0078 488B03 movq (%rbx), %rax 290 007b 4889DF movq %rbx, %rdi 291 007e FF10 call *(%rax) 292 .LVL26: 293 0080 89C5 movl %eax, %ebp 294 .LVL27: 34:virtual-sub.cpp **** 295 .loc 1 34 0 296 0082 4885DB testq %rbx, %rbx 297 0085 740C je .L21 34:virtual-sub.cpp **** 298 .loc 1 34 0 is_stmt 0 discriminator 1 299 0087 488B03 movq (%rbx), %rax 300 .LVL28: 301 008a 4889DF movq %rbx, %rdi 302 008d 480378E8 addq -24(%rax), %rdi 303 0091 EB05 jmp .L20 304 .LVL29: 305 .L21: 34:virtual-sub.cpp **** 306 .loc 1 34 0 307 0093 BF000000 movl $0, %edi 307 00 308 .LVL30: 309 .L20: 36:virtual-sub.cpp **** 310 .loc 1 36 0 is_stmt 1 discriminator 3 311 0098 488B07 movq (%rdi), %rax 312 009b FF10 call *(%rax) 313 .LVL31: 314 009d 89C3 movl %eax, %ebx 315 .LVL32: 38:virtual-sub.cpp **** } 316 .loc 1 38 0 discriminator 3 317 009f BE000000 movl $.LC0, %esi GAS LISTING /tmp/ccyyAyAp.s page 9 317 00 318 00a4 BF000000 movl $_ZSt4cout, %edi 318 00 319 00a9 E8000000 call _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc 319 00 320 .LVL33: 321 00ae 89EE movl %ebp, %esi 322 00b0 4889C7 movq %rax, %rdi 323 00b3 E8000000 call _ZNSolsEi 323 00 324 .LVL34: 325 00b8 BE000000 movl $.LC1, %esi 325 00 326 00bd 4889C7 movq %rax, %rdi 327 00c0 E8000000 call _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc 327 00 328 .LVL35: 329 00c5 89DE movl %ebx, %esi 330 00c7 4889C7 movq %rax, %rdi 331 00ca E8000000 call _ZNSolsEi 331 00 332 .LVL36: 333 00cf BE000000 movl $_ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_, %esi 333 00 334 00d4 4889C7 movq %rax, %rdi 335 00d7 E8000000 call _ZNSolsEPFRSoS_E 335 00 336 .LVL37: 337 .LBE6: 338 .loc 1 39 0 discriminator 3 339 00dc 4883C408 addq $8, %rsp 340 .cfi_def_cfa_offset 24 341 00e0 5B popq %rbx 342 .cfi_def_cfa_offset 16 343 .LVL38: 344 00e1 5D popq %rbp 345 .cfi_def_cfa_offset 8 346 .LVL39: 347 00e2 C3 ret 348 .cfi_endproc 349 .LFE1250: 352 _GLOBAL__sub_I__ZNK5aBase11getBaseDataEv: 353 .LFB1416: 354 .loc 1 39 0 355 .cfi_startproc 356 00e3 4883EC08 subq $8, %rsp 357 .cfi_def_cfa_offset 16 358 .loc 1 39 0 359 00e7 BEFFFF00 movl $65535, %esi 359 00 360 00ec BF010000 movl $1, %edi 360 00 361 00f1 E812FFFF call _Z41__static_initialization_and_destruction_0ii 361 FF 362 .LVL40: 363 00f6 4883C408 addq $8, %rsp 364 .cfi_def_cfa_offset 8 GAS LISTING /tmp/ccyyAyAp.s page 10 365 00fa C3 ret 366 .cfi_endproc 367 .LFE1416: 369 .section .init_array,"aw" 370 .align 8 371 0000 00000000 .quad _GLOBAL__sub_I__ZNK5aBase11getBaseDataEv 371 00000000 372 .weak _ZTS5aBase 373 .section .rodata._ZTS5aBase,"aG",@progbits,_ZTS5aBase,comdat 376 _ZTS5aBase: 377 0000 35614261 .string "5aBase" 377 736500 378 .weak _ZTI5aBase 379 .section .rodata._ZTI5aBase,"aG",@progbits,_ZTI5aBase,comdat 380 .align 16 383 _ZTI5aBase: 384 0000 00000000 .quad _ZTVN10__cxxabiv117__class_type_infoE+16 384 00000000 385 0008 00000000 .quad _ZTS5aBase 385 00000000 386 .weak _ZTS4aSub 387 .section .rodata._ZTS4aSub,"aG",@progbits,_ZTS4aSub,comdat 390 _ZTS4aSub: 391 0000 34615375 .string "4aSub" 391 6200 392 .weak _ZTI4aSub 393 .section .rodata._ZTI4aSub,"aG",@progbits,_ZTI4aSub,comdat 394 .align 32 397 _ZTI4aSub: 398 0000 00000000 .quad _ZTVN10__cxxabiv121__vmi_class_type_infoE+16 398 00000000 399 0008 00000000 .quad _ZTS4aSub 399 00000000 400 0010 00000000 .long 0 401 0014 01000000 .long 1 402 0018 00000000 .quad _ZTI5aBase 402 00000000 403 0020 03E8FFFF .quad -6141 403 FFFFFFFF 404 .weak _ZTV5aBase 405 .section .rodata._ZTV5aBase,"aG",@progbits,_ZTV5aBase,comdat 406 .align 32 409 _ZTV5aBase: 410 0000 00000000 .quad 0 410 00000000 411 0008 00000000 .quad _ZTI5aBase 411 00000000 412 0010 00000000 .quad _ZNK5aBase11getBaseDataEv 412 00000000 413 0018 00000000 .quad _ZN5aBaseD1Ev 413 00000000 414 0020 00000000 .quad _ZN5aBaseD0Ev 414 00000000 415 .weak _ZTT4aSub 416 .section .rodata._ZTT4aSub,"aG",@progbits,_ZTV4aSub,comdat 417 .align 16 420 _ZTT4aSub: GAS LISTING /tmp/ccyyAyAp.s page 11 421 0000 00000000 .quad _ZTV4aSub+24 421 00000000 422 0008 00000000 .quad _ZTV4aSub+80 422 00000000 423 .weak _ZTV4aSub 424 .section .rodata._ZTV4aSub,"aG",@progbits,_ZTV4aSub,comdat 425 .align 32 428 _ZTV4aSub: 429 0000 10000000 .quad 16 429 00000000 430 0008 00000000 .quad 0 430 00000000 431 0010 00000000 .quad _ZTI4aSub 431 00000000 432 0018 00000000 .quad _ZNK4aSub8getDataAEv 432 00000000 433 0020 00000000 .quad _ZN4aSubD1Ev 433 00000000 434 0028 00000000 .quad _ZN4aSubD0Ev 434 00000000 435 0030 F0FFFFFF .quad -16 435 FFFFFFFF 436 0038 00000000 .quad 0 436 00000000 437 0040 F0FFFFFF .quad -16 437 FFFFFFFF 438 0048 00000000 .quad _ZTI4aSub 438 00000000 439 0050 00000000 .quad _ZNK5aBase11getBaseDataEv 439 00000000 440 0058 00000000 .quad _ZTv0_n32_N4aSubD1Ev 440 00000000 441 0060 00000000 .quad _ZTv0_n32_N4aSubD0Ev 441 00000000 442 .local _ZStL8__ioinit 443 .comm _ZStL8__ioinit,1,1 444 .text 445 .Letext0: 446 .file 3 "/usr/include/libio.h" 447 .file 4 "/usr/include/stdio.h" 448 .file 5 "<built-in>" 449 .file 6 "/usr/lib/gcc/x86_64-linux-gnu/4.8/include/stddef.h" 450 .file 7 "/usr/include/wchar.h" 451 .file 8 "/usr/include/c++/4.8/cwchar" 452 .file 9 "/usr/include/c++/4.8/bits/exception_ptr.h" 453 .file 10 "/usr/include/x86_64-linux-gnu/c++/4.8/bits/c++config.h" 454 .file 11 "/usr/include/c++/4.8/bits/char_traits.h" 455 .file 12 "/usr/include/c++/4.8/cstdint" 456 .file 13 "/usr/include/c++/4.8/clocale" 457 .file 14 "/usr/include/c++/4.8/cstdlib" 458 .file 15 "/usr/include/c++/4.8/cstdio" 459 .file 16 "/usr/include/c++/4.8/bits/ios_base.h" 460 .file 17 "/usr/include/c++/4.8/cwctype" 461 .file 18 "/usr/include/c++/4.8/bits/ostream.tcc" 462 .file 19 "/usr/include/c++/4.8/ostream" 463 .file 20 "/usr/include/c++/4.8/iosfwd" 464 .file 21 "/usr/include/x86_64-linux-gnu/bits/wchar2.h" GAS LISTING /tmp/ccyyAyAp.s page 12 465 .file 22 "/usr/include/time.h" 466 .file 23 "/usr/include/c++/4.8/ext/new_allocator.h" 467 .file 24 "/usr/include/c++/4.8/ext/numeric_traits.h" 468 .file 25 "/usr/include/c++/4.8/debug/debug.h" 469 .file 26 "/usr/include/stdint.h" 470 .file 27 "/usr/include/locale.h" 471 .file 28 "/usr/include/x86_64-linux-gnu/bits/types.h" 472 .file 29 "/usr/include/x86_64-linux-gnu/c++/4.8/bits/atomic_word.h" 473 .file 30 "/usr/include/stdlib.h" 474 .file 31 "/usr/include/x86_64-linux-gnu/bits/stdlib.h" 475 .file 32 "/usr/include/_G_config.h" 476 .file 33 "/usr/include/x86_64-linux-gnu/bits/stdio2.h" 477 .file 34 "/usr/include/wctype.h" 478 .file 35 "/usr/include/c++/4.8/new" 479 .file 36 "/usr/include/c++/4.8/bits/stl_pair.h" GAS LISTING /tmp/ccyyAyAp.s page 13 DEFINED SYMBOLS *ABS*:0000000000000000 virtual-sub.cpp /tmp/ccyyAyAp.s:8 .text._ZN5aBaseD2Ev:0000000000000000 _ZN5aBaseD2Ev /tmp/ccyyAyAp.s:409 .rodata._ZTV5aBase:0000000000000000 _ZTV5aBase /tmp/ccyyAyAp.s:8 .text._ZN5aBaseD2Ev:0000000000000000 _ZN5aBaseD1Ev /tmp/ccyyAyAp.s:28 .text:0000000000000000 _ZNK5aBase11getBaseDataEv /tmp/ccyyAyAp.s:43 .text:0000000000000004 _ZNK4aSub8getDataAEv /tmp/ccyyAyAp.s:59 .text._ZN4aSubD1Ev:0000000000000000 _ZN4aSubD1Ev /tmp/ccyyAyAp.s:428 .rodata._ZTV4aSub:0000000000000000 _ZTV4aSub /tmp/ccyyAyAp.s:84 .text._ZN4aSubD1Ev:0000000000000021 _ZTv0_n32_N4aSubD1Ev /tmp/ccyyAyAp.s:98 .text._ZN5aBaseD0Ev:0000000000000000 _ZN5aBaseD0Ev /tmp/ccyyAyAp.s:124 .text._ZN4aSubD0Ev:0000000000000000 _ZN4aSubD0Ev /tmp/ccyyAyAp.s:149 .text._ZN4aSubD0Ev:0000000000000013 _ZTv0_n32_N4aSubD0Ev /tmp/ccyyAyAp.s:161 .text:0000000000000008 _Z41__static_initialization_and_destruction_0ii .bss:0000000000000000 _ZStL8__ioinit /tmp/ccyyAyAp.s:196 .text:000000000000003c _ZN4aSub8setDataAEi /tmp/ccyyAyAp.s:211 .text._ZN5aBaseC2Ev:0000000000000000 _ZN5aBaseC2Ev /tmp/ccyyAyAp.s:211 .text._ZN5aBaseC2Ev:0000000000000000 _ZN5aBaseC1Ev /tmp/ccyyAyAp.s:230 .text._ZN4aSubC1Ev:0000000000000000 _ZN4aSubC1Ev /tmp/ccyyAyAp.s:263 .text:0000000000000040 _Z10virtualSubv /tmp/ccyyAyAp.s:352 .text:00000000000000e3 _GLOBAL__sub_I__ZNK5aBase11getBaseDataEv /tmp/ccyyAyAp.s:376 .rodata._ZTS5aBase:0000000000000000 _ZTS5aBase /tmp/ccyyAyAp.s:383 .rodata._ZTI5aBase:0000000000000000 _ZTI5aBase /tmp/ccyyAyAp.s:390 .rodata._ZTS4aSub:0000000000000000 _ZTS4aSub /tmp/ccyyAyAp.s:397 .rodata._ZTI4aSub:0000000000000000 _ZTI4aSub /tmp/ccyyAyAp.s:420 .rodata._ZTT4aSub:0000000000000000 _ZTT4aSub .group:0000000000000000 _ZN5aBaseD5Ev .group:0000000000000000 _ZN5aBaseC5Ev UNDEFINED SYMBOLS _ZdlPv _ZNSt8ios_base4InitC1Ev __dso_handle _ZNSt8ios_base4InitD1Ev __cxa_atexit _Znwm _ZSt4cout _ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc _ZNSolsEi _ZSt4endlIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_ _ZNSolsEPFRSoS_E _ZTVN10__cxxabiv117__class_type_infoE _ZTVN10__cxxabiv121__vmi_class_type_infoE