Files
clang-p2996/llvm/test/CodeGen/Hexagon/stack-alloca1.ll
Fangrui Song 2208c97c1b [Hexagon,test] Change llc -march= to -mtriple=
Similar to 806761a762

-mtriple= specifies the full target triple while -march= merely sets the
architecture part of the default target triple, leaving a target triple which
may not make sense.

Therefore, -march= is error-prone and not recommended for tests without a target
triple. The issue has been benign as we recognize $unknown-apple-darwin as ELF instead
of rejecting it outrightly.
2024-12-15 10:20:22 -08:00

18 lines
347 B
LLVM

; RUN: llc -O0 -mtriple=hexagon < %s | FileCheck %s
; CHECK: sub(r29,r[[REG:[0-9]+]])
; CHECK: r29 = r[[REG]]
target triple = "hexagon-unknown-unknown"
; Function Attrs: nounwind uwtable
define void @foo(i32 %n) #0 {
entry:
%x = alloca i32, i32 %n
call void @bar(ptr %x)
ret void
}
declare void @bar(ptr) #0
attributes #0 = { nounwind }