mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-13 20:32:21 +00:00
5ba71b01d8
Generate entire ASan asm instrumentation in MC without relying on runtime helper functions. Patch by Yuri Gorshenin. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212455 91177308-0d34-0410-b5e6-96231b3b80d8
65 lines
1.3 KiB
ArmAsm
65 lines
1.3 KiB
ArmAsm
# RUN: llvm-mc %s -triple=x86_64-unknown-linux-gnu -mcpu=corei7 -mattr=+sse2 -asm-instrumentation=address -asan-instrument-assembly | FileCheck %s
|
|
|
|
.text
|
|
.globl mov1b
|
|
.align 16, 0x90
|
|
.type mov1b,@function
|
|
# CHECK-LABEL: mov1b:
|
|
#
|
|
# CHECK: leaq -128(%rsp), %rsp
|
|
# CHECK: callq __asan_report_load1@PLT
|
|
# CHECK: leaq 128(%rsp), %rsp
|
|
#
|
|
# CHECK-NEXT: movb (%rsi), %al
|
|
#
|
|
# CHECK-NEXT: leaq -128(%rsp), %rsp
|
|
# CHECK: callq __asan_report_store1@PLT
|
|
# CHECK: leaq 128(%rsp), %rsp
|
|
#
|
|
# CHECK-NEXT: movb %al, (%rdi)
|
|
mov1b: # @mov1b
|
|
.cfi_startproc
|
|
# BB#0:
|
|
#APP
|
|
movb (%rsi), %al
|
|
movb %al, (%rdi)
|
|
|
|
#NO_APP
|
|
retq
|
|
.Ltmp0:
|
|
.size mov1b, .Ltmp0-mov1b
|
|
.cfi_endproc
|
|
|
|
.globl mov16b
|
|
.align 16, 0x90
|
|
.type mov16b,@function
|
|
# CHECK-LABEL: mov16b:
|
|
#
|
|
# CHECK: leaq -128(%rsp), %rsp
|
|
# CHECK: callq __asan_report_load16@PLT
|
|
# CHECK: leaq 128(%rsp), %rsp
|
|
#
|
|
# CHECK-NEXT: movaps (%rsi), %xmm0
|
|
#
|
|
# CHECK-NEXT: leaq -128(%rsp), %rsp
|
|
# CHECK: callq __asan_report_store16@PLT
|
|
# CHECK: leaq 128(%rsp), %rsp
|
|
#
|
|
# CHECK-NEXT: movaps %xmm0, (%rdi)
|
|
mov16b: # @mov16b
|
|
.cfi_startproc
|
|
# BB#0:
|
|
#APP
|
|
movaps (%rsi), %xmm0
|
|
movaps %xmm0, (%rdi)
|
|
|
|
#NO_APP
|
|
retq
|
|
.Ltmp1:
|
|
.size mov16b, .Ltmp1-mov16b
|
|
.cfi_endproc
|
|
|
|
|
|
.ident "clang version 3.5 "
|
|
.section ".note.GNU-stack","",@progbits
|