github.com/guyezi/gofrontend@v0.0.0-20200228202240-7a62a49e62c0/libgo/go/math/big/arith_s390x_test.go (about)

     1  // Copyright 2016 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // +build ignore
     6  // +build s390x,!math_big_pure_go
     7  
     8  package big
     9  
    10  import (
    11  	"testing"
    12  )
    13  
    14  // Tests whether the non vector routines are working, even when the tests are run on a
    15  // vector-capable machine
    16  
    17  func TestFunVVnovec(t *testing.T) {
    18  	if hasVX == true {
    19  		for _, a := range sumVV {
    20  			arg := a
    21  			testFunVV(t, "addVV_novec", addVV_novec, arg)
    22  
    23  			arg = argVV{a.z, a.y, a.x, a.c}
    24  			testFunVV(t, "addVV_novec symmetric", addVV_novec, arg)
    25  
    26  			arg = argVV{a.x, a.z, a.y, a.c}
    27  			testFunVV(t, "subVV_novec", subVV_novec, arg)
    28  
    29  			arg = argVV{a.y, a.z, a.x, a.c}
    30  			testFunVV(t, "subVV_novec symmetric", subVV_novec, arg)
    31  		}
    32  	}
    33  }
    34  
    35  func TestFunVWnovec(t *testing.T) {
    36  	if hasVX == true {
    37  		for _, a := range sumVW {
    38  			arg := a
    39  			testFunVW(t, "addVW_novec", addVW_novec, arg)
    40  
    41  			arg = argVW{a.x, a.z, a.y, a.c}
    42  			testFunVW(t, "subVW_novec", subVW_novec, arg)
    43  		}
    44  	}
    45  }