brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.6 KiB · 8053b22 Raw
57 lines · plain
1; RUN: llc < %s -mtriple=nvptx -mattr=+ptx60 -mcpu=sm_30 | FileCheck %s2; RUN: llc < %s -mtriple=nvptx64 -mattr=+ptx60 -mcpu=sm_30 | FileCheck %s3; RUN: %if ptxas-isa-6.0 && ptxas-ptr32 %{ llc < %s -mtriple=nvptx -mattr=+ptx60 -mcpu=sm_30 | %ptxas-verify %}4; RUN: %if ptxas-isa-6.0 %{ llc < %s -mtriple=nvptx64 -mattr=+ptx60 -mcpu=sm_30 | %ptxas-verify %}5 6; Verify that the NVPTX target removes invalid symbol names prior to emitting7; PTX.8 9; CHECK-NOT: .str10; CHECK-NOT: <str>11; CHECK-NOT: another-str12; CHECK-NOT: .function.13 14; CHECK-DAG: _$_str15; CHECK-DAG: _$_str_$_16; CHECK-DAG: _$_str117; CHECK-DAG: another_$_str18 19; CHECK-DAG: _$_function_$_20; CHECK-DAG: _$_function_$_221 22target datalayout = "e-i64:64-v16:16-v32:32-n16:32:64"23target triple = "nvptx64-unknown-unknown"24 25 26@.str = private unnamed_addr constant [13 x i8] c"%d %f %c %d\0A\00", align 127@"<str>" = private unnamed_addr constant [13 x i8] c"%d %f %c %d\0A\00", align 128@_$_str = private unnamed_addr constant [13 x i8] c"%d %f %c %d\0A\00", align 129@another-str = private unnamed_addr constant [13 x i8] c"%d %f %c %d\0A\00", align 130 31 32; Function Attrs: nounwind33define internal void @.function.() {34entry:35  %call = call i32 (ptr, ...) @printf(ptr @.str)36  %call2 = call i32 (ptr, ...) @printf(ptr @"<str>")37  ret void38}39 40; Function Attrs: nounwind41define internal void @_$_function_$_() {42entry:43  %call = call i32 (ptr, ...) @printf(ptr @_$_str)44  %call2 = call i32 (ptr, ...) @printf(ptr @another-str)45  ret void46}47 48; Function Attrs: nounwind49define void @global_function() {50entry:51  call void @.function.()52  call void @_$_function_$_()53  ret void54}55 56declare i32 @printf(ptr, ...)57