1  /* { dg-final { check-function-bodies "**" "" "-DCHECK_ASM" { target { ! ilp32 } } } } */
       2  
       3  #include "test_sve_acle.h"
       4  
       5  /*
       6  ** ld1uh_gather_s64_tied1:
       7  **	ld1h	z0\.d, p0/z, \[z0\.d\]
       8  **	ret
       9  */
      10  TEST_LOAD_GATHER_ZS (ld1uh_gather_s64_tied1, svint64_t, svuint64_t,
      11  		     z0_res = svld1uh_gather_u64base_s64 (p0, z0),
      12  		     z0_res = svld1uh_gather_s64 (p0, z0))
      13  
      14  /*
      15  ** ld1uh_gather_s64_untied:
      16  **	ld1h	z0\.d, p0/z, \[z1\.d\]
      17  **	ret
      18  */
      19  TEST_LOAD_GATHER_ZS (ld1uh_gather_s64_untied, svint64_t, svuint64_t,
      20  		     z0_res = svld1uh_gather_u64base_s64 (p0, z1),
      21  		     z0_res = svld1uh_gather_s64 (p0, z1))
      22  
      23  /*
      24  ** ld1uh_gather_x0_s64_offset:
      25  **	ld1h	z0\.d, p0/z, \[x0, z0\.d\]
      26  **	ret
      27  */
      28  TEST_LOAD_GATHER_ZS (ld1uh_gather_x0_s64_offset, svint64_t, svuint64_t,
      29  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, x0),
      30  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, x0))
      31  
      32  /*
      33  ** ld1uh_gather_m2_s64_offset:
      34  **	mov	(x[0-9]+), #?-2
      35  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
      36  **	ret
      37  */
      38  TEST_LOAD_GATHER_ZS (ld1uh_gather_m2_s64_offset, svint64_t, svuint64_t,
      39  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, -2),
      40  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, -2))
      41  
      42  /*
      43  ** ld1uh_gather_0_s64_offset:
      44  **	ld1h	z0\.d, p0/z, \[z0\.d\]
      45  **	ret
      46  */
      47  TEST_LOAD_GATHER_ZS (ld1uh_gather_0_s64_offset, svint64_t, svuint64_t,
      48  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, 0),
      49  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, 0))
      50  
      51  /*
      52  ** ld1uh_gather_5_s64_offset:
      53  **	mov	(x[0-9]+), #?5
      54  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
      55  **	ret
      56  */
      57  TEST_LOAD_GATHER_ZS (ld1uh_gather_5_s64_offset, svint64_t, svuint64_t,
      58  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, 5),
      59  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, 5))
      60  
      61  /*
      62  ** ld1uh_gather_6_s64_offset:
      63  **	ld1h	z0\.d, p0/z, \[z0\.d, #6\]
      64  **	ret
      65  */
      66  TEST_LOAD_GATHER_ZS (ld1uh_gather_6_s64_offset, svint64_t, svuint64_t,
      67  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, 6),
      68  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, 6))
      69  
      70  /*
      71  ** ld1uh_gather_62_s64_offset:
      72  **	ld1h	z0\.d, p0/z, \[z0\.d, #62\]
      73  **	ret
      74  */
      75  TEST_LOAD_GATHER_ZS (ld1uh_gather_62_s64_offset, svint64_t, svuint64_t,
      76  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, 62),
      77  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, 62))
      78  
      79  /*
      80  ** ld1uh_gather_64_s64_offset:
      81  **	mov	(x[0-9]+), #?64
      82  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
      83  **	ret
      84  */
      85  TEST_LOAD_GATHER_ZS (ld1uh_gather_64_s64_offset, svint64_t, svuint64_t,
      86  		     z0_res = svld1uh_gather_u64base_offset_s64 (p0, z0, 64),
      87  		     z0_res = svld1uh_gather_offset_s64 (p0, z0, 64))
      88  
      89  /*
      90  ** ld1uh_gather_x0_s64_index:
      91  **	lsl	(x[0-9]+), x0, #?1
      92  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
      93  **	ret
      94  */
      95  TEST_LOAD_GATHER_ZS (ld1uh_gather_x0_s64_index, svint64_t, svuint64_t,
      96  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, x0),
      97  		     z0_res = svld1uh_gather_index_s64 (p0, z0, x0))
      98  
      99  /*
     100  ** ld1uh_gather_m1_s64_index:
     101  **	mov	(x[0-9]+), #?-2
     102  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
     103  **	ret
     104  */
     105  TEST_LOAD_GATHER_ZS (ld1uh_gather_m1_s64_index, svint64_t, svuint64_t,
     106  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, -1),
     107  		     z0_res = svld1uh_gather_index_s64 (p0, z0, -1))
     108  
     109  /*
     110  ** ld1uh_gather_0_s64_index:
     111  **	ld1h	z0\.d, p0/z, \[z0\.d\]
     112  **	ret
     113  */
     114  TEST_LOAD_GATHER_ZS (ld1uh_gather_0_s64_index, svint64_t, svuint64_t,
     115  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, 0),
     116  		     z0_res = svld1uh_gather_index_s64 (p0, z0, 0))
     117  
     118  /*
     119  ** ld1uh_gather_5_s64_index:
     120  **	ld1h	z0\.d, p0/z, \[z0\.d, #10\]
     121  **	ret
     122  */
     123  TEST_LOAD_GATHER_ZS (ld1uh_gather_5_s64_index, svint64_t, svuint64_t,
     124  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, 5),
     125  		     z0_res = svld1uh_gather_index_s64 (p0, z0, 5))
     126  
     127  /*
     128  ** ld1uh_gather_31_s64_index:
     129  **	ld1h	z0\.d, p0/z, \[z0\.d, #62\]
     130  **	ret
     131  */
     132  TEST_LOAD_GATHER_ZS (ld1uh_gather_31_s64_index, svint64_t, svuint64_t,
     133  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, 31),
     134  		     z0_res = svld1uh_gather_index_s64 (p0, z0, 31))
     135  
     136  /*
     137  ** ld1uh_gather_32_s64_index:
     138  **	mov	(x[0-9]+), #?64
     139  **	ld1h	z0\.d, p0/z, \[\1, z0\.d\]
     140  **	ret
     141  */
     142  TEST_LOAD_GATHER_ZS (ld1uh_gather_32_s64_index, svint64_t, svuint64_t,
     143  		     z0_res = svld1uh_gather_u64base_index_s64 (p0, z0, 32),
     144  		     z0_res = svld1uh_gather_index_s64 (p0, z0, 32))
     145  
     146  /*
     147  ** ld1uh_gather_x0_s64_s64offset:
     148  **	ld1h	z0\.d, p0/z, \[x0, z0\.d\]
     149  **	ret
     150  */
     151  TEST_LOAD_GATHER_SZ (ld1uh_gather_x0_s64_s64offset, svint64_t, uint16_t, svint64_t,
     152  		     z0_res = svld1uh_gather_s64offset_s64 (p0, x0, z0),
     153  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z0))
     154  
     155  /*
     156  ** ld1uh_gather_tied1_s64_s64offset:
     157  **	ld1h	z0\.d, p0/z, \[x0, z0\.d\]
     158  **	ret
     159  */
     160  TEST_LOAD_GATHER_SZ (ld1uh_gather_tied1_s64_s64offset, svint64_t, uint16_t, svint64_t,
     161  		     z0_res = svld1uh_gather_s64offset_s64 (p0, x0, z0),
     162  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z0))
     163  
     164  /*
     165  ** ld1uh_gather_untied_s64_s64offset:
     166  **	ld1h	z0\.d, p0/z, \[x0, z1\.d\]
     167  **	ret
     168  */
     169  TEST_LOAD_GATHER_SZ (ld1uh_gather_untied_s64_s64offset, svint64_t, uint16_t, svint64_t,
     170  		     z0_res = svld1uh_gather_s64offset_s64 (p0, x0, z1),
     171  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z1))
     172  
     173  /*
     174  ** ld1uh_gather_ext_s64_s64offset:
     175  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, sxtw\]
     176  **	ret
     177  */
     178  TEST_LOAD_GATHER_SZ (ld1uh_gather_ext_s64_s64offset, svint64_t, uint16_t, svint64_t,
     179  		     z0_res = svld1uh_gather_s64offset_s64 (p0, x0, svextw_s64_x (p0, z1)),
     180  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, svextw_x (p0, z1)))
     181  
     182  /*
     183  ** ld1uh_gather_x0_s64_u64offset:
     184  **	ld1h	z0\.d, p0/z, \[x0, z0\.d\]
     185  **	ret
     186  */
     187  TEST_LOAD_GATHER_SZ (ld1uh_gather_x0_s64_u64offset, svint64_t, uint16_t, svuint64_t,
     188  		     z0_res = svld1uh_gather_u64offset_s64 (p0, x0, z0),
     189  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z0))
     190  
     191  /*
     192  ** ld1uh_gather_tied1_s64_u64offset:
     193  **	ld1h	z0\.d, p0/z, \[x0, z0\.d\]
     194  **	ret
     195  */
     196  TEST_LOAD_GATHER_SZ (ld1uh_gather_tied1_s64_u64offset, svint64_t, uint16_t, svuint64_t,
     197  		     z0_res = svld1uh_gather_u64offset_s64 (p0, x0, z0),
     198  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z0))
     199  
     200  /*
     201  ** ld1uh_gather_untied_s64_u64offset:
     202  **	ld1h	z0\.d, p0/z, \[x0, z1\.d\]
     203  **	ret
     204  */
     205  TEST_LOAD_GATHER_SZ (ld1uh_gather_untied_s64_u64offset, svint64_t, uint16_t, svuint64_t,
     206  		     z0_res = svld1uh_gather_u64offset_s64 (p0, x0, z1),
     207  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, z1))
     208  
     209  /*
     210  ** ld1uh_gather_ext_s64_u64offset:
     211  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, uxtw\]
     212  **	ret
     213  */
     214  TEST_LOAD_GATHER_SZ (ld1uh_gather_ext_s64_u64offset, svint64_t, uint16_t, svuint64_t,
     215  		     z0_res = svld1uh_gather_u64offset_s64 (p0, x0, svextw_u64_x (p0, z1)),
     216  		     z0_res = svld1uh_gather_offset_s64 (p0, x0, svextw_x (p0, z1)))
     217  
     218  /*
     219  ** ld1uh_gather_x0_s64_s64index:
     220  **	ld1h	z0\.d, p0/z, \[x0, z0\.d, lsl 1\]
     221  **	ret
     222  */
     223  TEST_LOAD_GATHER_SZ (ld1uh_gather_x0_s64_s64index, svint64_t, uint16_t, svint64_t,
     224  		     z0_res = svld1uh_gather_s64index_s64 (p0, x0, z0),
     225  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z0))
     226  
     227  /*
     228  ** ld1uh_gather_tied1_s64_s64index:
     229  **	ld1h	z0\.d, p0/z, \[x0, z0\.d, lsl 1\]
     230  **	ret
     231  */
     232  TEST_LOAD_GATHER_SZ (ld1uh_gather_tied1_s64_s64index, svint64_t, uint16_t, svint64_t,
     233  		     z0_res = svld1uh_gather_s64index_s64 (p0, x0, z0),
     234  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z0))
     235  
     236  /*
     237  ** ld1uh_gather_untied_s64_s64index:
     238  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, lsl 1\]
     239  **	ret
     240  */
     241  TEST_LOAD_GATHER_SZ (ld1uh_gather_untied_s64_s64index, svint64_t, uint16_t, svint64_t,
     242  		     z0_res = svld1uh_gather_s64index_s64 (p0, x0, z1),
     243  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z1))
     244  
     245  /*
     246  ** ld1uh_gather_ext_s64_s64index:
     247  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, sxtw 1\]
     248  **	ret
     249  */
     250  TEST_LOAD_GATHER_SZ (ld1uh_gather_ext_s64_s64index, svint64_t, uint16_t, svint64_t,
     251  		     z0_res = svld1uh_gather_s64index_s64 (p0, x0, svextw_s64_x (p0, z1)),
     252  		     z0_res = svld1uh_gather_index_s64 (p0, x0, svextw_x (p0, z1)))
     253  
     254  /*
     255  ** ld1uh_gather_x0_s64_u64index:
     256  **	ld1h	z0\.d, p0/z, \[x0, z0\.d, lsl 1\]
     257  **	ret
     258  */
     259  TEST_LOAD_GATHER_SZ (ld1uh_gather_x0_s64_u64index, svint64_t, uint16_t, svuint64_t,
     260  		     z0_res = svld1uh_gather_u64index_s64 (p0, x0, z0),
     261  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z0))
     262  
     263  /*
     264  ** ld1uh_gather_tied1_s64_u64index:
     265  **	ld1h	z0\.d, p0/z, \[x0, z0\.d, lsl 1\]
     266  **	ret
     267  */
     268  TEST_LOAD_GATHER_SZ (ld1uh_gather_tied1_s64_u64index, svint64_t, uint16_t, svuint64_t,
     269  		     z0_res = svld1uh_gather_u64index_s64 (p0, x0, z0),
     270  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z0))
     271  
     272  /*
     273  ** ld1uh_gather_untied_s64_u64index:
     274  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, lsl 1\]
     275  **	ret
     276  */
     277  TEST_LOAD_GATHER_SZ (ld1uh_gather_untied_s64_u64index, svint64_t, uint16_t, svuint64_t,
     278  		     z0_res = svld1uh_gather_u64index_s64 (p0, x0, z1),
     279  		     z0_res = svld1uh_gather_index_s64 (p0, x0, z1))
     280  
     281  /*
     282  ** ld1uh_gather_ext_s64_u64index:
     283  **	ld1h	z0\.d, p0/z, \[x0, z1\.d, uxtw 1\]
     284  **	ret
     285  */
     286  TEST_LOAD_GATHER_SZ (ld1uh_gather_ext_s64_u64index, svint64_t, uint16_t, svuint64_t,
     287  		     z0_res = svld1uh_gather_u64index_s64 (p0, x0, svextw_u64_x (p0, z1)),
     288  		     z0_res = svld1uh_gather_index_s64 (p0, x0, svextw_x (p0, z1)))