1 ; RUN: llc < %s -march=nvptx -mcpu=sm_20 | FileCheck %s
3 ;;; Need 4-byte alignment on float* passed byval
4 define ptx_device void @t1(float* byval %x) {
6 ; CHECK: .param .align 4 .b8 t1_param_0[4]
11 ;;; Need 8-byte alignment on double* passed byval
12 define ptx_device void @t2(double* byval %x) {
14 ; CHECK: .param .align 8 .b8 t2_param_0[8]
19 ;;; Need 4-byte alignment on float2* passed byval
20 %struct.float2 = type { float, float }
21 define ptx_device void @t3(%struct.float2* byval %x) {
23 ; CHECK: .param .align 4 .b8 t3_param_0[8]
27 ;;; Need at least 4-byte alignment in order to avoid miscompilation by
29 define ptx_device void @t4(i8* byval %x) {
31 ; CHECK: .param .align 4 .b8 t4_param_0[1]
35 ;;; Make sure we adjust alignment at the call site as well.
36 define ptx_device void @t5(i8* align 2 byval %x) {
38 ; CHECK: .param .align 4 .b8 t5_param_0[1]
40 ; CHECK: .param .align 4 .b8 param0[1];
42 call void @t4(i8* byval %x)