brintos

brintos / llvm-project-archived public Read only

0
0
Text · 547 B · e12270e Raw
18 lines · plain
1; RUN: llc -mtriple=hexagon < %s | FileCheck %s2 3; Test that global constant GEPs are calculated correctly4;5target triple = "hexagon-unknown--elf"6 7%s.0 = type { i32, i64, [100 x i8] }8 9@g0 = common global %s.0 zeroinitializer, align 810@g1 = global ptr getelementptr inbounds (%s.0, ptr @g0, i32 0, i32 2, i32 10), align 411; CHECK-LABEL: g1:12; CHECK: .word g0+2613 14@g2 = common global [100 x i8] zeroinitializer, align 815@g3 = global ptr getelementptr inbounds ([100 x i8], ptr @g2, i32 0, i32 10), align 416; CHECK-LABEL: g3:17; CHECK: .word g2+1018