brintos

brintos / llvm-project-archived public Read only

0
0
Text · 872 B · 9c04ea6 Raw
42 lines · plain
1; RUN: llc -mtriple=x86_64-none-linux -fast-isel -fast-isel-abort=1 -verify-machineinstrs < %s | FileCheck %s2 3define i64 @test_sdiv64(i64 %dividend, i64 %divisor) nounwind {4entry:5  %result = sdiv i64 %dividend, %divisor6  ret i64 %result7}8 9; CHECK-LABEL: test_sdiv64:10; CHECK: cqto11; CHECK: idivq12 13define i64 @test_srem64(i64 %dividend, i64 %divisor) nounwind {14entry:15  %result = srem i64 %dividend, %divisor16  ret i64 %result17}18 19; CHECK-LABEL: test_srem64:20; CHECK: cqto21; CHECK: idivq22 23define i64 @test_udiv64(i64 %dividend, i64 %divisor) nounwind {24entry:25  %result = udiv i64 %dividend, %divisor26  ret i64 %result27}28 29; CHECK-LABEL: test_udiv64:30; CHECK: xorl31; CHECK: divq32 33define i64 @test_urem64(i64 %dividend, i64 %divisor) nounwind {34entry:35  %result = urem i64 %dividend, %divisor36  ret i64 %result37}38 39; CHECK-LABEL: test_urem64:40; CHECK: xorl41; CHECK: divq42