Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- define {i64, i1} @addo.apint.i64 ( i64 %left, i64 %right )
- {
- entry:
- %extleft = zext i64 %left to i65
- %extright = zext i64 %right to i65
- %sum = add i65 %extleft, %extright
- %res.0 = trunc i65 %sum to i64
- %overflow = and i65 %sum, -18446744073709551616
- %res.1 = icmp ne i65 %overflow, 0
- %final0 = insertvalue {i64, i1} undef, i64 %res.0, 0
- %final1 = insertvalue {i64, i1} %final0, i1 %res.1, 1
- ret {i64, i1} %final1
- }
- define {i64, i1} @addo.intrinsics.i64 ( i64 %left, i64 %right )
- {
- entry:
- %call = call {i64, i1} @llvm.uadd.with.overflow.i64 ( i64 %left, i64 %right )
- ret {i64, i1} %call
- }
- declare {i64, i1} @llvm.uadd.with.overflow.i64 ( i64 %left, i64 %right ) nounwind readnone
Add Comment
Please, Sign In to add comment