1 # The test verifies that memory references through %rsp are correctly
2 # adjusted after instrumentation.
4 # RUN: llvm-mc %s -triple=x86_64-unknown-linux-gnu -asm-instrumentation=address -asan-instrument-assembly | FileCheck %s
6 # CHECK-LABEL: rsp_access
7 # CHECK: leaq -128(%rsp), %rsp
11 # CHECK: leaq 160(%rsp), %rdi
12 # CHECK: callq __asan_report_load8@PLT
16 # CHECK: leaq 128(%rsp), %rsp
17 # CHECK: movq 8(%rsp), %rax
22 .type rsp_access,@function
27 # CHECK-LABEL: rsp_32bit_access
28 # CHECK: leaq -128(%rsp), %rsp
32 # CHECK: leaq 2147483647(%rsp), %rdi
33 # CHECK: leaq 145(%rdi), %rdi
34 # CHECK: callq __asan_report_load8@PLT
38 # CHECK: leaq 128(%rsp), %rsp
39 # CHECK: movq 2147483640(%rsp), %rax
41 .globl rsp_32bit_access
42 .type rsp_32bit_access,@function
44 movq
2147483640(%rsp
), %rax