brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.6 KiB · 13db528 Raw
98 lines · plain
1# RUN: llc -o - %s -start-after=if-converter | FileCheck %s2 3--- |4  target datalayout = "E-m:e-i64:64-n32:64"5  target triple = "powerpc64-unknown-linux-gnu"6  7  %struct.rwlock_t.0.22.58.68.242.244 = type {}8  9  @tasklist_lock = external global %struct.rwlock_t.0.22.58.68.242.244, align 110  11  ; Function Attrs: nounwind12  define void @mm_update_next_owner(ptr %p1, ptr %p2) #0 {13  entry:14    %0 = load ptr, ptr %p1, align 815    br i1 undef, label %do.body.92, label %for.body.2116  17  for.body.21:                                      ; preds = %entry18    unreachable19  20  do.body.92:                                       ; preds = %entry21    %usage = getelementptr inbounds i8, ptr %0, i64 -4822    %call95 = tail call signext i32 @__raw_read_unlock(ptr nonnull @tasklist_lock) #123    store volatile i32 0, ptr %p2, align 424    tail call void asm sideeffect "#compiler barrier", "~{memory}"() #125    %1 = tail call i32 asm sideeffect "\0Alwsync \0A1:\09lwarx\09$0,0,$1\09\09# atomic_dec_return\0A\09addic\09$0,$0,-1\0A\09stwcx.\09$0,0,$1\0A\09bne-\091b\0Async \0A", "=&r,r,~{cc},~{xer},~{memory}"(ptr %usage) #126    %cmp.i = icmp eq i32 %1, 027    br i1 %cmp.i, label %if.then.i, label %put_task_struct.exit28  29  if.then.i:                                        ; preds = %do.body.9230    unreachable31  32  put_task_struct.exit:                             ; preds = %do.body.9233    ret void34  }35  36  declare signext i32 @__raw_read_unlock(...)37  38  attributes #0 = { nounwind "target-cpu"="pwr7" }39  attributes #1 = { nounwind }40 41...42---43name:            mm_update_next_owner44alignment:       1645exposesReturnsTwice: false46tracksRegLiveness: true47liveins:         48  - { reg: '$x3' }49  - { reg: '$x4' }50frameInfo:       51  isFrameAddressTaken: false52  isReturnAddressTaken: false53  hasStackMap:     false54  hasPatchPoint:   false55  stackSize:       14456  offsetAdjustment: 057  maxAlignment:    058  adjustsStack:    true59  hasCalls:        true60  maxCallFrameSize: 11261  hasOpaqueSPAdjustment: false62  hasVAStart:      false63  hasMustTailInVarArgFunc: false64fixedStack:      65  - { id: 0, type: spill-slot, offset: -16, size: 8, alignment: 16, callee-saved-register: '$x30' }66  - { id: 1, type: spill-slot, offset: -24, size: 8, alignment: 8, callee-saved-register: '$x29' }67body:             |68  bb.0.entry:69    liveins: $x3, $x4, $x29, $x30, $x29, $x3070  71    $x0 = MFLR8 implicit $lr872    STD $x0, 16, $x173    $x1 = STDU $x1, -144, $x174    STD killed $x29, 120, $x1 :: (store (s64) into %fixed-stack.1)75    STD killed $x30, 128, $x1 :: (store (s64) into %fixed-stack.0, align 16)76    $x30 = OR8 $x4, $x477    $x3 = LD 0, killed $x3 :: (load (s64) from %ir.p1)78    $x29 = ADDI8 killed $x3, -4879    $x3 = ADDIStocHA8 $x2, @tasklist_lock80    $x3 = LDtocL @tasklist_lock, killed $x3, implicit $x2 :: (load (s64) from got)81    BL8_NOP @__raw_read_unlock, csr_ppc64_altivec, implicit-def $lr8, implicit $rm, implicit $x3, implicit $x2, implicit-def $r1, implicit-def dead $x382    $r3 = LI 083    STW killed $r3, 0, killed $x30 :: (volatile store (s32) into %ir.p2)84    INLINEASM &"#compiler barrier", 2585    INLINEASM &"\0Alwsync \0A1:\09lwarx\09$0,0,$1\09\09# atomic_dec_return\0A\09addic\09$0,$0,-1\0A\09stwcx.\09$0,0,$1\0A\09bne-\091b\0Async \0A", 25, 131083, def early-clobber $r3, 851977, killed $x29, 12, implicit-def dead early-clobber $cr086    ; CHECK-LABEL: @mm_update_next_owner87    ; CHECK-NOT: lwarx 29, 0, 2988    ; CHECK-NOT: stwcx. 29, 0, 2989    $cr0 = CMPLWI killed $r3, 090    $x30 = LD 128, $x1 :: (load (s64) from %fixed-stack.0, align 16)91    $x29 = LD 120, $x1 :: (load (s64) from %fixed-stack.1)92    $x1 = ADDI8 $x1, 14493    $x0 = LD 16, $x194    MTLR8 $x0, implicit-def $lr895    BLR8 implicit $lr8, implicit $rm96 97...98