1 ; RUN: llc < %s -march=nvptx64 -mcpu=sm_35 | FileCheck %s
2 ; RUN: %if ptxas %{ llc < %s -march=nvptx64 -mcpu=sm_35 | %ptxas-verify %}
4 ; 64-bit divides and rems should be split into a fast and slow path where
5 ; the fast path uses a 32-bit operation.
7 define void @sdiv64(i64 %a, i64 %b, ptr %retptr) {
13 store i64 %d, ptr %retptr
17 define void @udiv64(i64 %a, i64 %b, ptr %retptr) {
18 ; CHECK-LABEL: udiv64(
23 store i64 %d, ptr %retptr
27 define void @srem64(i64 %a, i64 %b, ptr %retptr) {
28 ; CHECK-LABEL: srem64(
33 store i64 %d, ptr %retptr
37 define void @urem64(i64 %a, i64 %b, ptr %retptr) {
38 ; CHECK-LABEL: urem64(
43 store i64 %d, ptr %retptr
47 define void @sdiv32(i32 %a, i32 %b, ptr %retptr) {
48 ; CHECK-LABEL: sdiv32(
52 store i32 %d, ptr %retptr
56 define void @udiv32(i32 %a, i32 %b, ptr %retptr) {
57 ; CHECK-LABEL: udiv32(
61 store i32 %d, ptr %retptr
65 define void @srem32(i32 %a, i32 %b, ptr %retptr) {
66 ; CHECK-LABEL: srem32(
70 store i32 %d, ptr %retptr
74 define void @urem32(i32 %a, i32 %b, ptr %retptr) {
75 ; CHECK-LABEL: urem32(
79 store i32 %d, ptr %retptr