X86 汇编:.text.startup 部分和 .text 部分有什么区别

sya*_*cer 3 x86 assembly gcc gnu-assembler sections

    .file   "test-instr.c"
    .text
.Ltext0:
    .section    .rodata.str1.1,"aMS",@progbits,1
.LC0:
    .string "Hum?"
.LC1:
    .string "Looks like a zero to me!"
.LC2:
    .string "A non-zero value? How quaint!"
    .section    .text.startup,"ax",@progbits
    .p2align 4,,15
    .globl  main
    .type   main, @function
main:
/* --- trampoline malloc shm space begin --- */ 

.align 4 

.section .data 
shmSize: .quad 8 * 4 * 0x10000 
.global shmptr
shmptr: .quad 0
.section .text
.extern malloc 
movq (shmSize), %rdi 
call malloc 
movq %rax, (shmptr) 
/* --- trampoline malloc shm spacd end --- */ 
 
.LFB52:
    .file 1 "test-instr.c"
    .loc 1 21 0
    .cfi_startproc
.LVL0:
    subq    $24, %rsp
    .cfi_def_cfa_offset 32
.LBB10:
.LBB11:
    .file 2 "/usr/include/x86_64-linux-gnu/bits/unistd.h"
    .loc 2 44 0
    xorl    %edi, %edi
.LVL1:
    movl    $8, %edx
    movq    %rsp, %rsi
.LVL2:

   movq %rax, %rbx
.LBE11:
.LBE10:
    .loc 1 21 0
    movq    %fs:40, %rax
    movq    %rax, 8(%rsp)
    xorl    %eax, %eax
.LVL3:
.LBB13:
.LBB12:
    .loc 2 44 0
    call    read@PLT
.LVL4:
.LBE12:
.LBE13:
    .loc 1 25 0
    testq   %rax, %rax
    jle .L8
    .loc 1 30 0
    cmpb    $48, (%rsp)
    je  .L9
.LVL5:
.LBB14:
.LBB15:
    .file 3 "/usr/include/x86_64-linux-gnu/bits/stdio2.h"
    .loc 3 104 0
    leaq    .LC2(%rip), %rdi
    call    puts@PLT
.LVL6:
.L4:
.LBE15:
.LBE14:
    .loc 1 35 0
    xorl    %edi, %edi
    call    exit@PLT
.LVL7:
.L9:
.LBB16:
.LBB17:
    .loc 3 104 0
    leaq    .LC1(%rip), %rdi
    call    puts@PLT
.LVL8:
    jmp .L4
.LVL9:
.L8:
.LBE17:
.LBE16:
.LBB18:
.LBB19:
    leaq    .LC0(%rip), %rdi
    call    puts@PLT
.LVL10:
.LBE19:
.LBE18:
    .loc 1 27 0
    movl    $1, %edi
    call    exit@PLT
.LVL11:
    .cfi_endproc
.LFE52:
    .size   main, .-main
    .text
.Letext0:
    .file 4 "/usr/lib/gcc/x86_64-linux-gnu/7/include/stddef.h"
    .file 5 "/usr/include/x86_64-linux-gnu/bits/types.h"
    .file 6 "/usr/include/x86_64-linux-gnu/bits/libio.h"
    .file 7 "/usr/include/stdio.h"
    .file 8 "/usr/include/x86_64-linux-gnu/bits/sys_errlist.h"
    .file 9 "/usr/include/unistd.h"
    .file 10 "/usr/include/x86_64-linux-gnu/bits/getopt_core.h"
    .file 11 "<built-in>"
    .file 12 "/usr/include/stdlib.h"
    .section    .debug_info,"",@progbits
.Ldebug_info0:
    .long   0x5bc
    .value  0x4
    .long   .Ldebug_abbrev0
    .byte   0x8
    .uleb128 0x1
    .long   .LASF73
    .byte   0xc
    .long   .LASF74
    .long   .LASF75
    .long   .Ldebug_ranges0+0x30
    .quad   0
    .long   .Ldebug_line0
    .uleb128 0x2
    .long   .LASF7
    .byte   0x4
    .byte   0xd8
    .long   0x34
    .uleb128 0x3
    .byte   0x8
    .byte   0x7
    .long   .LASF0
    .uleb128 0x3
    .byte   0x1
    .byte   0x8
    .long   .LASF1
    .uleb128 0x3
    .byte   0x2
    .byte   0x7
    .long   .LASF2
    .uleb128 0x3
    .byte   0x4
    .byte   0x7
    .long   .LASF3
    .uleb128 0x3
    .byte   0x1
    .byte   0x6
    .long   .LASF4
    .uleb128 0x3
    .byte   0x2
    .byte   0x5
    .long   .LASF5
    .uleb128 0x4
    .byte   0x4
    .byte   0x5
    .string "int"
    .uleb128 0x3
    .byte   0x8
    .byte   0x5
    .long   .LASF6
    .uleb128 0x2
    .long   .LASF8
    .byte   0x5
    .byte   0x8c
    .long   0x65
    .uleb128 0x2
    .long   .LASF9
    .byte   0x5
    .byte   0x8d
    .long   0x65
    .uleb128 0x5
    .byte   0x8
    .uleb128 0x2
    .long   .LASF10
    .byte   0x5
    .byte   0xb5
    .long   0x65
    .uleb128 0x6
    .byte   0x8
    .long   0x95
    .uleb128 0x3
    .byte   0x1
    .byte   0x6
    .long   .LASF11
    .uleb128 0x7
    .long   0x95
    .uleb128 0x8
    .long   .LASF41
    .byte   0xd8
    .byte   0x6
    .byte   0xf5
    .long   0x221
    .uleb128 0x9
    .long   .LASF12
    .byte   0x6
    .byte   0xf6
    .long   0x5e
    .byte   0
    .uleb128 0x9
    .long   .LASF13
    .byte   0x6
    .byte   0xfb
    .long   0x8f
    .byte   0x8
    .uleb128 0x9
    .long   .LASF14
    .byte   0x6
    .byte   0xfc
    .long   0x8f
    .byte   0x10
    .uleb128 0x9
    .long   .LASF15
    .byte   0x6
    .byte   0xfd
    .long   0x8f
    .byte   0x18
    .uleb128 0x9
    .long   .LASF16
    .byte   0x6
    .byte   0xfe
    .long   0x8f
    .byte   0x20
    .uleb128 0x9
    .long   .LASF17
    .byte   0x6
    .byte   0xff
    .long   0x8f
    .byte   0x28
    .uleb128 0xa
    .long   .LASF18
    .byte   0x6
    .value  0x100
    .long   0x8f
    .byte   0x30
    .uleb128 0xa
    .long   .LASF19
    .byte   0x6
    .value  0x101
    .long   0x8f
    .byte   0x38
    .uleb128 0xa
    .long   .LASF20
    .byte   0x6
    .value  0x102
    .long   0x8f
    .byte   0x40
    .uleb128 0xa
    .long   .LASF21
    .byte   0x6
    .value  0x104
    .long   0x8f
    .byte   0x48
    .uleb128 0xa
    .long   .LASF22
    .byte   0x6
    .value  0x105
    .long   0x8f
    .byte   0x50
    .uleb128 0xa
    .long   .LASF23
    .byte   0x6
    .value  0x106
    .long   0x8f
    .byte   0x58
    .uleb128 0xa
    .long   .LASF24
    .byte   0x6
    .value  0x108
    .long   0x259
    .byte   0x60
    .uleb128 0xa
    .long   .LASF25
    .byte   0x6
    .value  0x10a
    .long   0x25f
    .byte   0x68
    .uleb128 0xa
    .long   .LASF26
    .byte   0x6
    .value  0x10c
    .long   0x5e
    .byte   0x70
    .uleb128 0xa
    .long   .LASF27
    .byte   0x6
    .value  0x110
    .long   0x5e
    .byte   0x74
    .uleb128 0xa
    .long   .LASF28
    .byte   0x6
    .value  0x112
    .long   0x6c
    .byte   0x78
    .uleb128 0xa
    .long   .LASF29
    .byte   0x6
    .value  0x116
    .long   0x42
    .byte   0x80
    .uleb128 0xa
    .long   .LASF30
    .byte   0x6
    .value  0x117
    .long   0x50
    .byte   0x82
    .uleb128 0xa
    .long   .LASF31
    .byte   0x6
    .value  0x118
    .long   0x265
    .byte   0x83
    .uleb128 0xa
    .long   .LASF32
    .byte   0x6
    .value  0x11c
    .long   0x275
    .byte   0x88
    .uleb128 0xa
    .long   .LASF33
    .byte   0x6
    .value  0x125
    .long   0x77
    .byte   0x90
    .uleb128 0xa
    .long   .LASF34
    .byte   0x6
    .value  0x12d
    .long   0x82
    .byte   0x98
    .uleb128 0xa
    .long   .LASF35
    .byte   0x6
    .value  0x12e
    .long   0x82
    .byte   0xa0
    .uleb128 0xa
    .long   .LASF36
    .byte   0x6
    .value  0x12f
    .long   0x82
    .byte   0xa8
    .uleb128 0xa
    .long   .LASF37
    .byte   0x6
    .value  0x130
    .long   0x82
    .byte   0xb0
    .uleb128 0xa
    .long   .LASF38
    .byte   0x6
    .value  0x132
    .long   0x29
    .byte   0xb8
    .uleb128 0xa
    .long   .LASF39
    .byte   0x6
    .value  0x133
    .long   0x5e
    .byte   0xc0
    .uleb128 0xa
    .long   .LASF40
    .byte   0x6
    .value  0x135
    .long   0x27b
    .byte   0xc4
    .byte   0
    .uleb128 0xb
    .long   .LASF76
    .byte   0x6
    .byte   0x9a
    .uleb128 0x8
    .long   .LASF42
    .byte   0x18
    .byte   0x6
    .byte   0xa0
    .long   0x259
    .uleb128 0x9
    .long   .LASF43
    .byte   0x6
    .byte   0xa1
    .long   0x259
    .byte   0
    .uleb128 0x9
    .long   .LASF44
    .byte   0x6
    .byte   0xa2
    .long   0x25f
    .byte   0x8
    .uleb128 0x9
    .long   .LASF45
    .byte   0x6
    .byte   0xa6
    .long   0x5e
    .byte   0x10
    .byte   0
    .uleb128 0x6
    .byte   0x8
    .long   0x228
    .uleb128 0x6
    .byte   0x8
    .long   0xa1
    .uleb128 0xc
    .long   0x95
    .long   0x275
    .uleb128 0xd
    .long   0x34
    .byte   0
    .byte   0
    .uleb128 0x6
    .byte   0x8
    .long   0x221
    .uleb128 0xc
    .long   0x95
    .long   0x28b
    .uleb128 0xd
    .long   0x34
    .byte   0x13
    .byte   0
    .uleb128 0xe
    .long   .LASF77
    .uleb128 0xf
    .long   .LASF46
    .byte   0x6
    .value  0x13f
    .long   0x28b
    .uleb128 0xf
    .long   .LASF47
    .byte   0x6
    .value  0x140
    .long   0x28b
    .uleb128 0xf
    .long   .LASF48
    .byte   0x6
    .value  0x141
    .long   0x28b
    .uleb128 0x6
    .byte   0x8
    .long   0x9c
    .uleb128 0x7
    .long   0x2b4
    .uleb128 0x10
    .long   0x2b4
    .uleb128 0x2
    .long   .LASF49
    .byte   0x7
    .byte   0x47
    .long   0x84
    .uleb128 0x11
    .long   .LASF50
    .byte   0x7
    .byte   0x87
    .long   0x25f
    .uleb128 0x11
    .long   .LASF51
    .byte   0x7
    .byte   0x88
    .long   0x25f
    .uleb128 0x11
    .long   .LASF52
    .byte   0x7
    .byte   0x89
    .long   0x25f
    .uleb128 0x11
    .long   .LASF53
    .byte   0x8
    .byte   0x1a
    .long   0x5e
    .uleb128 0xc
    .long   0x2ba
    .long   0x306
    .uleb128 0x12
    .byte   0
    .uleb128 0x7
    .long   0x2fb
    .uleb128 0x11
    .long   .LASF54
    .byte   0x8
    .byte   0x1b
    .long   0x306
    .uleb128 0x3
    .byte   0x8
    .byte   0x5
    .long   .LASF55
    .uleb128 0x3
    .byte   0x8
    .byte   0x7
    .long   .LASF56
    .uleb128 0xc
    .long   0x95
    .long   0x334
    .uleb128 0xd
    .long   0x34
    .byte   0x7
    .byte   0
    .uleb128 0xf
    .long   .LASF57
    .byte   0x9
    .value  0x222
    .long   0x340
    .uleb128 0x6
    .byte   0x8
    .long   0x8f
    .uleb128 0x11
    .long   .LASF58
    .byte   0xa
    .byte   0x24
    .long   0x8f
    .uleb128 0x11
    .long   .LASF59
    .byte   0xa
    .byte   0x32
    .long   0x5e
    .uleb128 0x11
    .long   .LASF60
    .byte   0xa
    .byte   0x37
    .long   0x5e
    .uleb128 0x11
    .long   .LASF61
    .byte   0xa
    .byte   0x3b
    .long   0x5e
    .uleb128 0x13
    .long   .LASF78
    .byte   0x1
    .byte   0x15
    .long   0x5e
    .quad   .LFB52
    .quad   .LFE52-.LFB52
    .uleb128 0x1
    .byte   0x9c
    .long   0x4fb
    .uleb128 0x14
    .long   .LASF62
    .byte   0x1
    .byte   0x15
    .long   0x5e
    .long   .LLST0
    .uleb128 0x14
    .long   .LASF63
    .byte   0x1
    .byte   0x15
    .long   0x340
    .long   .LLST1
    .uleb128 0x15
    .string "buf"
    .byte   0x1
    .byte   0x17
    .long   0x324
    .uleb128 0x2
    .byte   0x91
    .sleb128 -32
    .uleb128 0x16
    .long   0x4fb
    .quad   .LBB10
    .long   .Ldebug_ranges0+0
    .byte   0x1
    .byte   0x19
    .long   0x410
    .uleb128 0x17
    .long   0x521
    .long   .LLST2
    .uleb128 0x17
    .long   0x516
    .long   .LLST3
    .uleb128 0x17
    .long   0x50b
    .long   .LLST4
    .uleb128 0x18
    .quad   .LVL4
    .long   0x54a
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x1
    .byte   0x30
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x54
    .uleb128 0x2
    .byte   0x77
    .sleb128 0
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x51
    .uleb128 0x1
    .byte   0x38
    .byte   0
    .byte   0
    .uleb128 0x1a
    .long   0x52d
    .quad   .LBB14
    .quad   .LBE14-.LBB14
    .byte   0x1
    .byte   0x21
    .long   0x450
    .uleb128 0x17
    .long   0x53d
    .long   .LLST5
    .uleb128 0x18
    .quad   .LVL6
    .long   0x57c
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x9
    .byte   0x3
    .quad   .LC2
    .byte   0
    .byte   0
    .uleb128 0x1a
    .long   0x52d
    .quad   .LBB16
    .quad   .LBE16-.LBB16
    .byte   0x1
    .byte   0x1f
    .long   0x490
    .uleb128 0x17
    .long   0x53d
    .long   .LLST6
    .uleb128 0x18
    .quad   .LVL8
    .long   0x57c
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x9
    .byte   0x3
    .quad   .LC1
    .byte   0
    .byte   0
    .uleb128 0x1a
    .long   0x52d
    .quad   .LBB18
    .quad   .LBE18-.LBB18
    .byte   0x1
    .byte   0x1a
    .long   0x4d0
    .uleb128 0x17
    .long   0x53d
    .long   .LLST7
    .uleb128 0x18
    .quad   .LVL10
    .long   0x57c
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x9
    .byte   0x3
    .quad   .LC0
    .byte   0
    .byte   0
    .uleb128 0x1b
    .quad   .LVL7
    .long   0x5b3
    .long   0x4e7
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x1
    .byte   0x30
    .byte   0
    .uleb128 0x18
    .quad   .LVL11
    .long   0x5b3
    .uleb128 0x19
    .uleb128 0x1
    .byte   0x55
    .uleb128 0x1
    .byte   0x31
    .byte   0
    .byte   0
    .uleb128 0x1c
    .long   .LASF67
    .byte   0x2
    .byte   0x22
    .long   0x2c4
    .byte   0x3
    .long   0x52d
    .uleb128 0x1d
    .long   .LASF64
    .byte   0x2
    .byte   0x22
    .long   0x5e
    .uleb128 0x1d
    .long   .LASF65
    .byte   0x2
    .byte   0x22
    .long   0x82
    .uleb128 0x1d
    .long   .LASF66
    .byte   0x2
    .byte   0x22
    .long   0x29
    .byte   0
    .uleb128 0x1c
    .long   .LASF68
    .byte   0x3
    .byte   0x66
    .long   0x5e
    .byte   0x3
    .long   0x54a
    .uleb128 0x1d
    .long   .LASF69
    .byte   0x3
    .byte   0x66
    .long   0x2bf
    .uleb128 0x1e
    .byte   0
    .uleb128 0x1f
    .long   .LASF67
    .long   .LASF71
    .byte   0x2
    .byte   0x19
    .long   .LASF67
    .uleb128 0x20
    .uleb128 0x21
    .byte   0x9e
    .uleb128 0x1f
    .byte   0x41
    .byte   0x20
    .byte   0x6e
    .byte   0x6f
    .byte   0x6e
    .byte   0x2d
    .byte   0x7a
    .byte   0x65
    .byte   0x72
    .byte   0x6f
    .byte   0x20
    .byte   0x76
    .byte   0x61
    .byte   0x6c
    .byte   0x75
    .byte   0x65
    .byte   0x3f
    .byte   0x20
    .byte   0x48
    .byte   0x6f
    .byte   0x77
    .byte   0x20
    .byte   0x71
    .byte   0x75
    .byte   0x61
    .byte   0x69
    .byte   0x6e
    .byte   0x74
    .byte   0x21
    .byte   0xa
    .byte   0
    .uleb128 0x1f
    .long   .LASF70
    .long   .LASF72
    .byte   0xb
    .byte   0
    .long   .LASF70
    .uleb128 0x20
    .uleb128 0x1c
    .byte   0x9e
    .uleb128 0x1a
    .byte   0x4c
    .byte   0x6f
    .byte   0x6f
    .byte   0x6b
    .byte   0x73
    .byte   0x20
    .byte   0x6c
    .byte   0x69
    .byte   0x6b
    .byte   0x65
    .byte   0x20
    .byte   0x61
    .byte   0x20
    .byte   0x7a
    .byte   0x65
    .byte   0x72
    .byte   0x6f
    .byte   0x20
    .byte   0x74
    .byte   0x6f
    .byte   0x20
    .byte   0x6d
    .byte   0x65
    .byte   0x21
    .byte   0xa
    .byte   0
    .uleb128 0x20
    .uleb128 0x8
    .byte   0x9e
    .uleb128 0x6
    .byte   0x48
    .byte   0x75
    .byte   0x6d
    .byte   0x3f
    .byte   0xa
    .byte   0
    .uleb128 0x21
    .long   .LASF79
    .long   .LASF79
    .byte   0xc
    .value  0x266
    .byte   0
    .section    .debug_abbrev,"",@progbits
.Ldebug_abbrev0:
    .uleb128 0x1
    .uleb128 0x11
    .byte   0x1
    .uleb128 0x25
    .uleb128 0xe
    .uleb128 0x13
    .uleb128 0xb
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x1b
    .uleb128 0xe
    .uleb128 0x55
    .uleb128 0x17
    .uleb128 0x11
    .uleb128 0x1
    .uleb128 0x10
    .uleb128 0x17
    .byte   0
    .byte   0
    .uleb128 0x2
    .uleb128 0x16
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x3
    .uleb128 0x24
    .byte   0
    .uleb128 0xb
    .uleb128 0xb
    .uleb128 0x3e
    .uleb128 0xb
    .uleb128 0x3
    .uleb128 0xe
    .byte   0
    .byte   0
    .uleb128 0x4
    .uleb128 0x24
    .byte   0
    .uleb128 0xb
    .uleb128 0xb
    .uleb128 0x3e
    .uleb128 0xb
    .uleb128 0x3
    .uleb128 0x8
    .byte   0
    .byte   0
    .uleb128 0x5
    .uleb128 0xf
    .byte   0
    .uleb128 0xb
    .uleb128 0xb
    .byte   0
    .byte   0
    .uleb128 0x6
    .uleb128 0xf
    .byte   0
    .uleb128 0xb
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x7
    .uleb128 0x26
    .byte   0
    .uleb128 0x49
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x8
    .uleb128 0x13
    .byte   0x1
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0xb
    .uleb128 0xb
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x1
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x9
    .uleb128 0xd
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x38
    .uleb128 0xb
    .byte   0
    .byte   0
    .uleb128 0xa
    .uleb128 0xd
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0x5
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x38
    .uleb128 0xb
    .byte   0
    .byte   0
    .uleb128 0xb
    .uleb128 0x16
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .byte   0
    .byte   0
    .uleb128 0xc
    .uleb128 0x1
    .byte   0x1
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x1
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0xd
    .uleb128 0x21
    .byte   0
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x2f
    .uleb128 0xb
    .byte   0
    .byte   0
    .uleb128 0xe
    .uleb128 0x13
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3c
    .uleb128 0x19
    .byte   0
    .byte   0
    .uleb128 0xf
    .uleb128 0x34
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0x5
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x3f
    .uleb128 0x19
    .uleb128 0x3c
    .uleb128 0x19
    .byte   0
    .byte   0
    .uleb128 0x10
    .uleb128 0x37
    .byte   0
    .uleb128 0x49
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x11
    .uleb128 0x34
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x3f
    .uleb128 0x19
    .uleb128 0x3c
    .uleb128 0x19
    .byte   0
    .byte   0
    .uleb128 0x12
    .uleb128 0x21
    .byte   0
    .byte   0
    .byte   0
    .uleb128 0x13
    .uleb128 0x2e
    .byte   0x1
    .uleb128 0x3f
    .uleb128 0x19
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x27
    .uleb128 0x19
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x11
    .uleb128 0x1
    .uleb128 0x12
    .uleb128 0x7
    .uleb128 0x40
    .uleb128 0x18
    .uleb128 0x2117
    .uleb128 0x19
    .uleb128 0x1
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x14
    .uleb128 0x5
    .byte   0
    .uleb128 0x3
    .uleb128 0xe
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x2
    .uleb128 0x17
    .byte   0
    .byte   0
    .uleb128 0x15
    .uleb128 0x34
    .byte   0
    .uleb128 0x3
    .uleb128 0x8
    .uleb128 0x3a
    .uleb128 0xb
    .uleb128 0x3b
    .uleb128 0xb
    .uleb128 0x49
    .uleb128 0x13
    .uleb128 0x2
    .uleb128 0x18
    .byte   0
    .byte   0
    .uleb128 0x16
    .uleb128 0x1d
    .byte   0x1
    .uleb128 0x31
    .uleb128 0x13
    .uleb128 0x52
    .uleb128 0x1
    .uleb128 0x55
    .uleb128 0x17
    .uleb128 0x58
    .uleb128 0xb
    .uleb128 0x59
    .uleb128 0xb
    .uleb128 0x1
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x17
    .uleb128 0x5
    .byte   0
    .uleb128 0x31
    .uleb128 0x13
    .uleb128 0x2
    .uleb128 0x17
    .byte   0
    .byte   0
    .uleb128 0x18
    .uleb128 0x4109
    .byte   0x1
    .uleb128 0x11
    .uleb128 0x1
    .uleb128 0x31
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x19
    .uleb128 0x410a
    .byte   0
    .uleb128 0x2
    .uleb128 0x18
    .uleb128 0x2111
    .uleb128 0x18
    .byte   0
    .byte   0
    .uleb128 0x1a
    .uleb128 0x1d
    .byte   0x1
    .uleb128 0x31
    .uleb128 0x13
    .uleb128 0x11
    .uleb128 0x1
    .uleb128 0x12
    .uleb128 0x7
    .uleb128 0x58
    .uleb128 0xb
    .uleb128 0x59
    .uleb128 0xb
    .uleb128 0x1
    .uleb128 0x13
    .byte   0
    .byte   0
    .uleb128 0x1b
    .uleb128 0x4109
    .byte   0x1
    .uleb128 0x11
    .uleb128 0x1
    .uleb128 0x31
 

Pet*_*des 6

当您切换乐器中的部分时使用.pushsection/ 。.popsection 这允许您返回到代码之前汇编器当前所在的任何部分。(气体手册


GCC 用于.text.startup将“冷”启动之类的main代码分组在一起,以便在程序启动后可以将其从缓存/iTLB 中逐出,甚至从 RAM 中分页。和/或为了程序实际启动阶段的更好的局部性/性能,这样它可以用更少的从磁盘引入的页面取得更多的进展。(想必_start也进去了.text.startup

它和文本段.text都链接到文本(读取+执行),但其中的所有函数都.text.startup在一端分组在一起。


同样,__attribute__((cold))会让 GCC 了解要放置在 中的其他函数.text.unlikely,这些函数也被分组在一起。

或者使用-fprofile-generate/ -fprofile-usePGO 让 GCC 识别“冷”函数(要么仅在启动时使用,仅在关闭时使用,或者在与 PGO 一起使用的非错误典型情况下根本不使用)。(GCC函数属性

要覆盖 GCC 选择的部分,请使用
__attribute__((section(".text"))) int main() { ... }

https://godbolt.org/z/z5c7zo