brintos

brintos / llvm-project-archived public Read only

0
0
Text · 950 B · 084436f Raw
27 lines · plain
1; RUN: llc -mtriple=thumbv7-w64-mingw32 < %s -o - | FileCheck --check-prefix=MINGW %s2 3declare void @llvm.lifetime.start.p0(i64, ptr nocapture)4declare dso_local void @other(ptr)5declare void @llvm.lifetime.end.p0(i64, ptr nocapture)6 7define dso_local void @func() sspstrong {8entry:9; MINGW-LABEL: func:10; MINGW: movw [[REG:r[0-9]+]], :lower16:.refptr.__stack_chk_guard11; MINGW: movt [[REG]], :upper16:.refptr.__stack_chk_guard12; MINGW: ldr [[REG2:r[0-9]+]], [[[REG]]]13; MINGW: ldr {{r[0-9]+}}, [[[REG2]]]14; MINGW: bl other15; MINGW: movw [[REG3:r[0-9]+]], :lower16:.refptr.__stack_chk_guard16; MINGW: movt [[REG3]], :upper16:.refptr.__stack_chk_guard17; MINGW: ldr [[REG4:r[0-9]+]], [[[REG3]]]18; MINGW: ldr {{r[0-9]+}}, [[[REG4]]]19; MINGW: bl __stack_chk_fail20 21  %c = alloca i8, align 122  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %c)23  call void @other(ptr nonnull %c)24  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %c)25  ret void26}27