brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.5 KiB · d0d871a Raw
106 lines · plain
1!RUN: %flang_fc1 -fdebug-dump-symbols %s | FileCheck %s2 3!REQUIRES: target={{.+}}-aix{{.*}}4 5! Size and alignment of bind(c) derived types6subroutine s1()7  use, intrinsic :: iso_c_binding8  type, bind(c) :: dt19    character(c_char) :: x1    !CHECK: x1 size=1 offset=0:10    real(c_double) :: x2       !CHECK: x2 size=8 offset=4:11  end type12  type, bind(c) :: dt213    character(c_char) :: x1(9) !CHECK: x1 size=9 offset=0:14    real(c_double) :: x2       !CHECK: x2 size=8 offset=12:15  end type16  type, bind(c) :: dt317    integer(c_short) :: x1     !CHECK: x1 size=2 offset=0:18    real(c_double) :: x2       !CHECK: x2 size=8 offset=4:19  end type20  type, bind(c) :: dt421    integer(c_int) :: x1       !CHECK: x1 size=4 offset=0:22    real(c_double) :: x2       !CHECK: x2 size=8 offset=4:23  end type24  type, bind(c) :: dt525    real(c_double) :: x1       !CHECK: x1 size=8 offset=0:26    real(c_double) :: x2       !CHECK: x2 size=8 offset=8:27  end type28  type, bind(c) :: dt629    integer(c_long) :: x1      !CHECK: x1 size=8 offset=0:30    character(c_char) :: x2    !CHECK: x2 size=1 offset=8:31    real(c_double) :: x3       !CHECK: x3 size=8 offset=12:32  end type33  type, bind(c) :: dt734    integer(c_long) :: x1      !CHECK: x1 size=8 offset=0:35    integer(c_long) :: x2      !CHECK: x2 size=8 offset=8:36    character(c_char) :: x3    !CHECK: x3 size=1 offset=16:37    real(c_double) :: x4       !CHECK: x4 size=8 offset=20:38  end type39  type, bind(c) :: dt840    character(c_char) :: x1         !CHECK: x1 size=1 offset=0:41    complex(c_double_complex) :: x2 !CHECK: x2 size=16 offset=4:42  end type43end subroutine44 45subroutine s2()46  use, intrinsic :: iso_c_binding47  type, bind(c) :: dt1048    character(c_char) :: x149    real(c_double) :: x250  end type51  type, bind(c) :: dt1152    type(dt10) :: y1           !CHECK: y1 size=12 offset=0:53    real(c_double) :: y2       !CHECK: y2 size=8 offset=12:54  end type55  type, bind(c) :: dt1256    character(c_char) :: y1    !CHECK: y1 size=1 offset=0:57    type(dt10) :: y2           !CHECK: y2 size=12 offset=4:58    character(c_char) :: y3    !CHECK: y3 size=1 offset=16:59  end type60  type, bind(c) :: dt1361    integer(c_short) :: y1     !CHECK: y1 size=2 offset=0:62    type(dt10) :: y2           !CHECK: y2 size=12 offset=4:63    character(c_char) :: y3    !CHECK: y3 size=1 offset=16:64  end type65 66  type, bind(c) :: dt2067    character(c_char) :: x168    integer(c_short) :: x269  end type70  type, bind(c) :: dt2171    real(c_double) :: y1       !CHECK: y1 size=8 offset=0:72    type(dt20) :: y2           !CHECK: y2 size=4 offset=8:73    real(c_double) :: y3       !CHECK: y3 size=8 offset=12:74  end type75 76  type, bind(c) :: dt3077    character(c_char) :: x178    character(c_char) :: x279  end type80  type, bind(c) :: dt3181     integer(c_long) :: y1     !CHECK: y1 size=8 offset=0:82     type(dt30) :: y2          !CHECK: y2 size=2 offset=8:83     real(c_double) :: y3      !CHECK: y3 size=8 offset=12:84  end type85 86  type, bind(c) :: dt4087    integer(c_short) :: x188    real(c_double) :: x289  end type90  type, bind(c) :: dt4191    real(c_double) :: y1       !CHECK: y1 size=8 offset=0:92    type(dt40) :: y2           !CHECK: y2 size=12 offset=8:93    real(c_double) :: y3       !CHECK: y3 size=8 offset=20:94  end type95 96  type, bind(c) :: dt5097    integer(c_short) :: x198    complex(c_double_complex) :: x299  end type100  type, bind(c) :: dt51101    real(c_double) :: y1            !CHECK: y1 size=8 offset=0:102    type(dt50) :: y2                !CHECK: y2 size=20 offset=8:103    complex(c_double_complex) :: y3 !CHECK: y3 size=16 offset=28:104  end type105end subroutine106