Files
Michael Liao 4034ad44e4 [NVPTX] Fix PR41651
Summary:
- Use the passed `DL` directly as retrieving data layout from CS by
  checking the called function is not reliable. Under indirect function
  call, there is no called function.

Subscribers: jholewinski, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D65468

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@367349 91177308-0d34-0410-b5e6-96231b3b80d8
2019-07-30 19:52:01 +00:00

14 lines
301 B
LLVM

; RUN: llc -filetype=asm -o - %s | FileCheck %s
target datalayout = "e-i64:64-i128:128-v16:16-v32:32-n16:32:64"
target triple = "nvptx64-nvidia-cuda"
%func = type { i32 (i32, i32)** }
; CHECK: foo
; CHECK: call
; CHECK: ret
define void @foo() {
%call = call %func undef(i32 0, i32 1)
ret void
}