brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.7 KiB · 3477121 Raw
72 lines · plain
1# RUN: llc -verify-machineinstrs -x mir -filetype=obj < %s -o %t.o2# RUN: llvm-objdump -dr %t.o | FileCheck %s3# CHECK-LABEL: .read_x4# CHECK: lbz 3, 2(2)5# CHECK-NEXT: R_TOC        x6# CHECK-LABEL: .read_y7# CHECK: lbz 3, 0(2)8# CHECK-NEXT: R_TOC        y9 10--- |11  ; ModuleID = '<stdin>'12  source_filename = "<stdin>"13  target datalayout = "E-m:a-Fi64-i64:64-n32:64-S128-v256:256:256-v512:512:512"14  target triple = "powerpc64-ibm-aix"15  16  @x = local_unnamed_addr global i32 218114560, align 4 #017  @y = external local_unnamed_addr global i32, align 4 #018  19  define signext range(i32 0, 256) i32 @read_x() {20  entry:21    %0 = load i32, ptr @x, align 422    %shr = lshr i32 %0, 823    %and = and i32 %shr, 25524    ret i32 %and25  }26  27  define signext range(i32 0, 256) i32 @read_y() {28  entry:29    %0 = load i32, ptr @y, align 430    %shr = lshr i32 %0, 1631    %and = and i32 %shr, 25532    ret i32 %and33  }34  35  attributes #0 = { "toc-data" }36 37...38---39name:            read_x40alignment:       441tracksRegLiveness: true42registers:43  - { id: 0, class: g8rc }44frameInfo:45  maxAlignment:    846machineFunctionInfo: {}47body:             |48  bb.0.entry:49    liveins: $x3, $x250    %0:g8rc = LBZ8 @x + 2, $x2 :: (dereferenceable load (s8) from @x + 2, align 2, basealign 4)51    $x3 = COPY %052    BLR8 implicit $lr8, implicit $rm, implicit $x353 54...55---56name:            read_y57alignment:       458tracksRegLiveness: true59registers:60  - { id: 0, class: g8rc }61frameInfo:62  maxAlignment:    863machineFunctionInfo: {}64body:             |65  bb.0.entry:66    liveins: $x3, $x267    %0:g8rc = LBZ8 @y + 1, $x2 :: (dereferenceable load (s8) from @y + 1, basealign 4)68    $x3 = COPY %069    BLR8 implicit $lr8, implicit $rm, implicit $x370 71...72