github.com/apache/arrow/go/v14@v14.0.2/internal/utils/transpose_ints_amd64.go (about)

     1  // Code generated by transpose_ints_amd64.go.tmpl. DO NOT EDIT.
     2  
     3  // Licensed to the Apache Software Foundation (ASF) under one
     4  // or more contributor license agreements.  See the NOTICE file
     5  // distributed with this work for additional information
     6  // regarding copyright ownership.  The ASF licenses this file
     7  // to you under the Apache License, Version 2.0 (the
     8  // "License"); you may not use this file except in compliance
     9  // with the License.  You may obtain a copy of the License at
    10  //
    11  // http://www.apache.org/licenses/LICENSE-2.0
    12  //
    13  // Unless required by applicable law or agreed to in writing, software
    14  // distributed under the License is distributed on an "AS IS" BASIS,
    15  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    16  // See the License for the specific language governing permissions and
    17  // limitations under the License.
    18  
    19  //go:build !noasm
    20  
    21  package utils
    22  
    23  import (
    24  	"golang.org/x/sys/cpu"
    25  )
    26  
    27  var (
    28  	TransposeInt8Int8   func([]int8, []int8, []int32)
    29  	TransposeInt8Uint8  func([]int8, []uint8, []int32)
    30  	TransposeInt8Int16  func([]int8, []int16, []int32)
    31  	TransposeInt8Uint16 func([]int8, []uint16, []int32)
    32  	TransposeInt8Int32  func([]int8, []int32, []int32)
    33  	TransposeInt8Uint32 func([]int8, []uint32, []int32)
    34  	TransposeInt8Int64  func([]int8, []int64, []int32)
    35  	TransposeInt8Uint64 func([]int8, []uint64, []int32)
    36  
    37  	TransposeUint8Int8   func([]uint8, []int8, []int32)
    38  	TransposeUint8Uint8  func([]uint8, []uint8, []int32)
    39  	TransposeUint8Int16  func([]uint8, []int16, []int32)
    40  	TransposeUint8Uint16 func([]uint8, []uint16, []int32)
    41  	TransposeUint8Int32  func([]uint8, []int32, []int32)
    42  	TransposeUint8Uint32 func([]uint8, []uint32, []int32)
    43  	TransposeUint8Int64  func([]uint8, []int64, []int32)
    44  	TransposeUint8Uint64 func([]uint8, []uint64, []int32)
    45  
    46  	TransposeInt16Int8   func([]int16, []int8, []int32)
    47  	TransposeInt16Uint8  func([]int16, []uint8, []int32)
    48  	TransposeInt16Int16  func([]int16, []int16, []int32)
    49  	TransposeInt16Uint16 func([]int16, []uint16, []int32)
    50  	TransposeInt16Int32  func([]int16, []int32, []int32)
    51  	TransposeInt16Uint32 func([]int16, []uint32, []int32)
    52  	TransposeInt16Int64  func([]int16, []int64, []int32)
    53  	TransposeInt16Uint64 func([]int16, []uint64, []int32)
    54  
    55  	TransposeUint16Int8   func([]uint16, []int8, []int32)
    56  	TransposeUint16Uint8  func([]uint16, []uint8, []int32)
    57  	TransposeUint16Int16  func([]uint16, []int16, []int32)
    58  	TransposeUint16Uint16 func([]uint16, []uint16, []int32)
    59  	TransposeUint16Int32  func([]uint16, []int32, []int32)
    60  	TransposeUint16Uint32 func([]uint16, []uint32, []int32)
    61  	TransposeUint16Int64  func([]uint16, []int64, []int32)
    62  	TransposeUint16Uint64 func([]uint16, []uint64, []int32)
    63  
    64  	TransposeInt32Int8   func([]int32, []int8, []int32)
    65  	TransposeInt32Uint8  func([]int32, []uint8, []int32)
    66  	TransposeInt32Int16  func([]int32, []int16, []int32)
    67  	TransposeInt32Uint16 func([]int32, []uint16, []int32)
    68  	TransposeInt32Int32  func([]int32, []int32, []int32)
    69  	TransposeInt32Uint32 func([]int32, []uint32, []int32)
    70  	TransposeInt32Int64  func([]int32, []int64, []int32)
    71  	TransposeInt32Uint64 func([]int32, []uint64, []int32)
    72  
    73  	TransposeUint32Int8   func([]uint32, []int8, []int32)
    74  	TransposeUint32Uint8  func([]uint32, []uint8, []int32)
    75  	TransposeUint32Int16  func([]uint32, []int16, []int32)
    76  	TransposeUint32Uint16 func([]uint32, []uint16, []int32)
    77  	TransposeUint32Int32  func([]uint32, []int32, []int32)
    78  	TransposeUint32Uint32 func([]uint32, []uint32, []int32)
    79  	TransposeUint32Int64  func([]uint32, []int64, []int32)
    80  	TransposeUint32Uint64 func([]uint32, []uint64, []int32)
    81  
    82  	TransposeInt64Int8   func([]int64, []int8, []int32)
    83  	TransposeInt64Uint8  func([]int64, []uint8, []int32)
    84  	TransposeInt64Int16  func([]int64, []int16, []int32)
    85  	TransposeInt64Uint16 func([]int64, []uint16, []int32)
    86  	TransposeInt64Int32  func([]int64, []int32, []int32)
    87  	TransposeInt64Uint32 func([]int64, []uint32, []int32)
    88  	TransposeInt64Int64  func([]int64, []int64, []int32)
    89  	TransposeInt64Uint64 func([]int64, []uint64, []int32)
    90  
    91  	TransposeUint64Int8   func([]uint64, []int8, []int32)
    92  	TransposeUint64Uint8  func([]uint64, []uint8, []int32)
    93  	TransposeUint64Int16  func([]uint64, []int16, []int32)
    94  	TransposeUint64Uint16 func([]uint64, []uint16, []int32)
    95  	TransposeUint64Int32  func([]uint64, []int32, []int32)
    96  	TransposeUint64Uint32 func([]uint64, []uint32, []int32)
    97  	TransposeUint64Int64  func([]uint64, []int64, []int32)
    98  	TransposeUint64Uint64 func([]uint64, []uint64, []int32)
    99  )
   100  
   101  func init() {
   102  	if cpu.X86.HasAVX2 {
   103  
   104  		TransposeInt8Int8 = transposeInt8Int8avx2
   105  		TransposeInt8Uint8 = transposeInt8Uint8avx2
   106  		TransposeInt8Int16 = transposeInt8Int16avx2
   107  		TransposeInt8Uint16 = transposeInt8Uint16avx2
   108  		TransposeInt8Int32 = transposeInt8Int32avx2
   109  		TransposeInt8Uint32 = transposeInt8Uint32avx2
   110  		TransposeInt8Int64 = transposeInt8Int64avx2
   111  		TransposeInt8Uint64 = transposeInt8Uint64avx2
   112  
   113  		TransposeUint8Int8 = transposeUint8Int8avx2
   114  		TransposeUint8Uint8 = transposeUint8Uint8avx2
   115  		TransposeUint8Int16 = transposeUint8Int16avx2
   116  		TransposeUint8Uint16 = transposeUint8Uint16avx2
   117  		TransposeUint8Int32 = transposeUint8Int32avx2
   118  		TransposeUint8Uint32 = transposeUint8Uint32avx2
   119  		TransposeUint8Int64 = transposeUint8Int64avx2
   120  		TransposeUint8Uint64 = transposeUint8Uint64avx2
   121  
   122  		TransposeInt16Int8 = transposeInt16Int8avx2
   123  		TransposeInt16Uint8 = transposeInt16Uint8avx2
   124  		TransposeInt16Int16 = transposeInt16Int16avx2
   125  		TransposeInt16Uint16 = transposeInt16Uint16avx2
   126  		TransposeInt16Int32 = transposeInt16Int32avx2
   127  		TransposeInt16Uint32 = transposeInt16Uint32avx2
   128  		TransposeInt16Int64 = transposeInt16Int64avx2
   129  		TransposeInt16Uint64 = transposeInt16Uint64avx2
   130  
   131  		TransposeUint16Int8 = transposeUint16Int8avx2
   132  		TransposeUint16Uint8 = transposeUint16Uint8avx2
   133  		TransposeUint16Int16 = transposeUint16Int16avx2
   134  		TransposeUint16Uint16 = transposeUint16Uint16avx2
   135  		TransposeUint16Int32 = transposeUint16Int32avx2
   136  		TransposeUint16Uint32 = transposeUint16Uint32avx2
   137  		TransposeUint16Int64 = transposeUint16Int64avx2
   138  		TransposeUint16Uint64 = transposeUint16Uint64avx2
   139  
   140  		TransposeInt32Int8 = transposeInt32Int8avx2
   141  		TransposeInt32Uint8 = transposeInt32Uint8avx2
   142  		TransposeInt32Int16 = transposeInt32Int16avx2
   143  		TransposeInt32Uint16 = transposeInt32Uint16avx2
   144  		TransposeInt32Int32 = transposeInt32Int32avx2
   145  		TransposeInt32Uint32 = transposeInt32Uint32avx2
   146  		TransposeInt32Int64 = transposeInt32Int64avx2
   147  		TransposeInt32Uint64 = transposeInt32Uint64avx2
   148  
   149  		TransposeUint32Int8 = transposeUint32Int8avx2
   150  		TransposeUint32Uint8 = transposeUint32Uint8avx2
   151  		TransposeUint32Int16 = transposeUint32Int16avx2
   152  		TransposeUint32Uint16 = transposeUint32Uint16avx2
   153  		TransposeUint32Int32 = transposeUint32Int32avx2
   154  		TransposeUint32Uint32 = transposeUint32Uint32avx2
   155  		TransposeUint32Int64 = transposeUint32Int64avx2
   156  		TransposeUint32Uint64 = transposeUint32Uint64avx2
   157  
   158  		TransposeInt64Int8 = transposeInt64Int8avx2
   159  		TransposeInt64Uint8 = transposeInt64Uint8avx2
   160  		TransposeInt64Int16 = transposeInt64Int16avx2
   161  		TransposeInt64Uint16 = transposeInt64Uint16avx2
   162  		TransposeInt64Int32 = transposeInt64Int32avx2
   163  		TransposeInt64Uint32 = transposeInt64Uint32avx2
   164  		TransposeInt64Int64 = transposeInt64Int64avx2
   165  		TransposeInt64Uint64 = transposeInt64Uint64avx2
   166  
   167  		TransposeUint64Int8 = transposeUint64Int8avx2
   168  		TransposeUint64Uint8 = transposeUint64Uint8avx2
   169  		TransposeUint64Int16 = transposeUint64Int16avx2
   170  		TransposeUint64Uint16 = transposeUint64Uint16avx2
   171  		TransposeUint64Int32 = transposeUint64Int32avx2
   172  		TransposeUint64Uint32 = transposeUint64Uint32avx2
   173  		TransposeUint64Int64 = transposeUint64Int64avx2
   174  		TransposeUint64Uint64 = transposeUint64Uint64avx2
   175  
   176  	} else if cpu.X86.HasSSE42 {
   177  
   178  		TransposeInt8Int8 = transposeInt8Int8sse4
   179  		TransposeInt8Uint8 = transposeInt8Uint8sse4
   180  		TransposeInt8Int16 = transposeInt8Int16sse4
   181  		TransposeInt8Uint16 = transposeInt8Uint16sse4
   182  		TransposeInt8Int32 = transposeInt8Int32sse4
   183  		TransposeInt8Uint32 = transposeInt8Uint32sse4
   184  		TransposeInt8Int64 = transposeInt8Int64sse4
   185  		TransposeInt8Uint64 = transposeInt8Uint64sse4
   186  
   187  		TransposeUint8Int8 = transposeUint8Int8sse4
   188  		TransposeUint8Uint8 = transposeUint8Uint8sse4
   189  		TransposeUint8Int16 = transposeUint8Int16sse4
   190  		TransposeUint8Uint16 = transposeUint8Uint16sse4
   191  		TransposeUint8Int32 = transposeUint8Int32sse4
   192  		TransposeUint8Uint32 = transposeUint8Uint32sse4
   193  		TransposeUint8Int64 = transposeUint8Int64sse4
   194  		TransposeUint8Uint64 = transposeUint8Uint64sse4
   195  
   196  		TransposeInt16Int8 = transposeInt16Int8sse4
   197  		TransposeInt16Uint8 = transposeInt16Uint8sse4
   198  		TransposeInt16Int16 = transposeInt16Int16sse4
   199  		TransposeInt16Uint16 = transposeInt16Uint16sse4
   200  		TransposeInt16Int32 = transposeInt16Int32sse4
   201  		TransposeInt16Uint32 = transposeInt16Uint32sse4
   202  		TransposeInt16Int64 = transposeInt16Int64sse4
   203  		TransposeInt16Uint64 = transposeInt16Uint64sse4
   204  
   205  		TransposeUint16Int8 = transposeUint16Int8sse4
   206  		TransposeUint16Uint8 = transposeUint16Uint8sse4
   207  		TransposeUint16Int16 = transposeUint16Int16sse4
   208  		TransposeUint16Uint16 = transposeUint16Uint16sse4
   209  		TransposeUint16Int32 = transposeUint16Int32sse4
   210  		TransposeUint16Uint32 = transposeUint16Uint32sse4
   211  		TransposeUint16Int64 = transposeUint16Int64sse4
   212  		TransposeUint16Uint64 = transposeUint16Uint64sse4
   213  
   214  		TransposeInt32Int8 = transposeInt32Int8sse4
   215  		TransposeInt32Uint8 = transposeInt32Uint8sse4
   216  		TransposeInt32Int16 = transposeInt32Int16sse4
   217  		TransposeInt32Uint16 = transposeInt32Uint16sse4
   218  		TransposeInt32Int32 = transposeInt32Int32sse4
   219  		TransposeInt32Uint32 = transposeInt32Uint32sse4
   220  		TransposeInt32Int64 = transposeInt32Int64sse4
   221  		TransposeInt32Uint64 = transposeInt32Uint64sse4
   222  
   223  		TransposeUint32Int8 = transposeUint32Int8sse4
   224  		TransposeUint32Uint8 = transposeUint32Uint8sse4
   225  		TransposeUint32Int16 = transposeUint32Int16sse4
   226  		TransposeUint32Uint16 = transposeUint32Uint16sse4
   227  		TransposeUint32Int32 = transposeUint32Int32sse4
   228  		TransposeUint32Uint32 = transposeUint32Uint32sse4
   229  		TransposeUint32Int64 = transposeUint32Int64sse4
   230  		TransposeUint32Uint64 = transposeUint32Uint64sse4
   231  
   232  		TransposeInt64Int8 = transposeInt64Int8sse4
   233  		TransposeInt64Uint8 = transposeInt64Uint8sse4
   234  		TransposeInt64Int16 = transposeInt64Int16sse4
   235  		TransposeInt64Uint16 = transposeInt64Uint16sse4
   236  		TransposeInt64Int32 = transposeInt64Int32sse4
   237  		TransposeInt64Uint32 = transposeInt64Uint32sse4
   238  		TransposeInt64Int64 = transposeInt64Int64sse4
   239  		TransposeInt64Uint64 = transposeInt64Uint64sse4
   240  
   241  		TransposeUint64Int8 = transposeUint64Int8sse4
   242  		TransposeUint64Uint8 = transposeUint64Uint8sse4
   243  		TransposeUint64Int16 = transposeUint64Int16sse4
   244  		TransposeUint64Uint16 = transposeUint64Uint16sse4
   245  		TransposeUint64Int32 = transposeUint64Int32sse4
   246  		TransposeUint64Uint32 = transposeUint64Uint32sse4
   247  		TransposeUint64Int64 = transposeUint64Int64sse4
   248  		TransposeUint64Uint64 = transposeUint64Uint64sse4
   249  
   250  	} else {
   251  
   252  		TransposeInt8Int8 = transposeInt8Int8
   253  		TransposeInt8Uint8 = transposeInt8Uint8
   254  		TransposeInt8Int16 = transposeInt8Int16
   255  		TransposeInt8Uint16 = transposeInt8Uint16
   256  		TransposeInt8Int32 = transposeInt8Int32
   257  		TransposeInt8Uint32 = transposeInt8Uint32
   258  		TransposeInt8Int64 = transposeInt8Int64
   259  		TransposeInt8Uint64 = transposeInt8Uint64
   260  
   261  		TransposeUint8Int8 = transposeUint8Int8
   262  		TransposeUint8Uint8 = transposeUint8Uint8
   263  		TransposeUint8Int16 = transposeUint8Int16
   264  		TransposeUint8Uint16 = transposeUint8Uint16
   265  		TransposeUint8Int32 = transposeUint8Int32
   266  		TransposeUint8Uint32 = transposeUint8Uint32
   267  		TransposeUint8Int64 = transposeUint8Int64
   268  		TransposeUint8Uint64 = transposeUint8Uint64
   269  
   270  		TransposeInt16Int8 = transposeInt16Int8
   271  		TransposeInt16Uint8 = transposeInt16Uint8
   272  		TransposeInt16Int16 = transposeInt16Int16
   273  		TransposeInt16Uint16 = transposeInt16Uint16
   274  		TransposeInt16Int32 = transposeInt16Int32
   275  		TransposeInt16Uint32 = transposeInt16Uint32
   276  		TransposeInt16Int64 = transposeInt16Int64
   277  		TransposeInt16Uint64 = transposeInt16Uint64
   278  
   279  		TransposeUint16Int8 = transposeUint16Int8
   280  		TransposeUint16Uint8 = transposeUint16Uint8
   281  		TransposeUint16Int16 = transposeUint16Int16
   282  		TransposeUint16Uint16 = transposeUint16Uint16
   283  		TransposeUint16Int32 = transposeUint16Int32
   284  		TransposeUint16Uint32 = transposeUint16Uint32
   285  		TransposeUint16Int64 = transposeUint16Int64
   286  		TransposeUint16Uint64 = transposeUint16Uint64
   287  
   288  		TransposeInt32Int8 = transposeInt32Int8
   289  		TransposeInt32Uint8 = transposeInt32Uint8
   290  		TransposeInt32Int16 = transposeInt32Int16
   291  		TransposeInt32Uint16 = transposeInt32Uint16
   292  		TransposeInt32Int32 = transposeInt32Int32
   293  		TransposeInt32Uint32 = transposeInt32Uint32
   294  		TransposeInt32Int64 = transposeInt32Int64
   295  		TransposeInt32Uint64 = transposeInt32Uint64
   296  
   297  		TransposeUint32Int8 = transposeUint32Int8
   298  		TransposeUint32Uint8 = transposeUint32Uint8
   299  		TransposeUint32Int16 = transposeUint32Int16
   300  		TransposeUint32Uint16 = transposeUint32Uint16
   301  		TransposeUint32Int32 = transposeUint32Int32
   302  		TransposeUint32Uint32 = transposeUint32Uint32
   303  		TransposeUint32Int64 = transposeUint32Int64
   304  		TransposeUint32Uint64 = transposeUint32Uint64
   305  
   306  		TransposeInt64Int8 = transposeInt64Int8
   307  		TransposeInt64Uint8 = transposeInt64Uint8
   308  		TransposeInt64Int16 = transposeInt64Int16
   309  		TransposeInt64Uint16 = transposeInt64Uint16
   310  		TransposeInt64Int32 = transposeInt64Int32
   311  		TransposeInt64Uint32 = transposeInt64Uint32
   312  		TransposeInt64Int64 = transposeInt64Int64
   313  		TransposeInt64Uint64 = transposeInt64Uint64
   314  
   315  		TransposeUint64Int8 = transposeUint64Int8
   316  		TransposeUint64Uint8 = transposeUint64Uint8
   317  		TransposeUint64Int16 = transposeUint64Int16
   318  		TransposeUint64Uint16 = transposeUint64Uint16
   319  		TransposeUint64Int32 = transposeUint64Int32
   320  		TransposeUint64Uint32 = transposeUint64Uint32
   321  		TransposeUint64Int64 = transposeUint64Int64
   322  		TransposeUint64Uint64 = transposeUint64Uint64
   323  
   324  	}
   325  }