File: dom-tree.ll

package info (click to toggle)
llvm-toolchain-17 1%3A17.0.6-22
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,799,624 kB
  • sloc: cpp: 6,428,607; ansic: 1,383,196; asm: 793,408; python: 223,504; objc: 75,364; f90: 60,502; lisp: 33,869; pascal: 15,282; sh: 9,684; perl: 7,453; ml: 4,937; awk: 3,523; makefile: 2,889; javascript: 2,149; xml: 888; fortran: 619; cs: 573
file content (42 lines) | stat: -rw-r--r-- 1,491 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
; REQUIRES: arm-registered-target
; RUN: opt -S -loop-unroll -codegenprepare < %s -domtree -verify-dom-info | FileCheck %s
;
; Checks that the dom tree is properly invalidated after an operation that will
; invalidate it in CodeGenPrepare. If the domtree isn't properly invalidated,
; this will likely segfault, or print badref.

; CHECK: @f

target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64"
target triple = "armv7--linux-gnueabihf"

define i32 @f(i32 %a) #0 {
entry:
  br label %for.body

for.cond.cleanup:
  ret i32 %or

for.body:
  %i.08 = phi i32 [ 0, %entry ], [ %inc, %for.body ]
  %b.07 = phi i32 [ 0, %entry ], [ %or, %for.body ]
  %shr = lshr i32 %a, %i.08
  %and = and i32 %shr, 1
  %sub = sub nuw nsw i32 31, %i.08
  %shl = shl i32 %and, %sub
  %or = or i32 %shl, %b.07
  %inc = add nuw nsw i32 %i.08, 1
  %exitcond = icmp eq i32 %inc, 32
  br i1 %exitcond, label %for.cond.cleanup, label %for.body, !llvm.loop !3
}

attributes #0 = { norecurse nounwind readnone "disable-tail-calls"="false" "less-precise-fpmad"="false" "frame-pointer"="all" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "stack-protector-buffer-size"="8" "target-cpu"="cortex-a8" "target-features"="+dsp,+neon,+vfp3" "unsafe-fp-math"="false" "use-soft-float"="false" }

!llvm.module.flags = !{!0, !1}
!llvm.ident = !{!2}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 1, !"min_enum_size", i32 4}
!2 = !{!"clang version 3.8.0"}
!3 = distinct !{!3, !4}
!4 = !{!"llvm.loop.unroll.full"}