Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 902 for float2 (0.13 sec)

  1. test/codegen/floats.go

    	return x, y, z
    }
    
    func indexLoad(b0 []float32, b1 float32, idx int) float32 {
    	// arm64:`FMOVS\s\(R[0-9]+\)\(R[0-9]+<<2\),\sF[0-9]+`
    	return b0[idx] * b1
    }
    
    func indexStore(b0 []float64, b1 float64, idx int) {
    	// arm64:`FMOVD\sF[0-9]+,\s\(R[0-9]+\)\(R[0-9]+<<3\)`
    	b0[idx] = b1
    }
    
    // ----------- //
    //    Fused    //
    // ----------- //
    
    func FusedAdd32(x, y, z float32) float32 {
    	// s390x:"FMADDS\t"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 04 15:24:29 UTC 2024
    - 4.9K bytes
    - Viewed (0)
  2. src/reflect/float32reg_riscv64.s

    #include "textflag.h"
    
    // riscv64 allows 32-bit floats to live in the bottom
    // part of the register, it expects them to be NaN-boxed.
    // These functions are needed to ensure correct conversions
    // on riscv64.
    
    // Convert float32->uint64
    TEXT ·archFloat32ToReg(SB),NOSPLIT,$0-16
    	MOVF	val+0(FP), F1
    	MOVD	F1, ret+8(FP)
    	RET
    
    // Convert uint64->float32
    TEXT ·archFloat32FromReg(SB),NOSPLIT,$0-12
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 04 13:38:32 UTC 2022
    - 794 bytes
    - Viewed (0)
  3. src/internal/fuzz/encoding_test.go

    			//   * math.Float32bits(float32(math.NaN()))+1
    			in: `go test fuzz v1
    float32(-0)
    float64(-0)
    float32(+Inf)
    float32(-Inf)
    float32(NaN)
    float64(+Inf)
    float64(-Inf)
    float64(NaN)
    math.Float64frombits(0x7ff8000000000002)
    math.Float32frombits(0x7fc00001)`,
    		},
    		{
    			desc: "int variations",
    			// Although we arbitrarily choose default integer bases (0 or 16), we may
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 07 00:20:34 UTC 2024
    - 8.2K bytes
    - Viewed (0)
  4. src/runtime/float.go

    //
    // Special cases are:
    //
    //	abs(±Inf) = +Inf
    //	abs(NaN) = NaN
    func abs(x float64) float64 {
    	const sign = 1 << 63
    	return float64frombits(float64bits(x) &^ sign)
    }
    
    // copysign returns a value with the magnitude
    // of x and the sign of y.
    func copysign(x, y float64) float64 {
    	const sign = 1 << 63
    	return float64frombits(float64bits(x)&^sign | float64bits(y)&sign)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Oct 26 02:39:39 UTC 2022
    - 1.4K bytes
    - Viewed (0)
  5. src/internal/types/testdata/spec/conversions.go

    func _[X Unsigned, T Integer](x X) T { return T(x) }
    func _[X Float, T Integer](x X) T    { return T(x) }
    
    func _[X Integer, T Unsigned](x X) T  { return T(x) }
    func _[X Unsigned, T Unsigned](x X) T { return T(x) }
    func _[X Float, T Unsigned](x X) T    { return T(x) }
    
    func _[X Integer, T Float](x X) T  { return T(x) }
    func _[X Unsigned, T Float](x X) T { return T(x) }
    func _[X Float, T Float](x X) T    { return T(x) }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:27 UTC 2023
    - 7.4K bytes
    - Viewed (0)
  6. src/internal/types/testdata/examples/constraints.go

    type (
    	Integer interface{ ~int|~int8|~int16|~int32|~int64 }
    	Unsigned interface{ ~uint|~uint8|~uint16|~uint32|~uint64 }
    	Floats interface{ ~float32|~float64 }
    	Complex interface{ ~complex64|~complex128 }
    	Number interface{ Integer|Unsigned|Floats|Complex }
    	Ordered interface{ Integer|Unsigned|Floats|~string }
    
    	_ interface{ Number | error /* ERROR "cannot use error in union" */ }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:27 UTC 2023
    - 2.9K bytes
    - Viewed (0)
  7. src/strconv/ftoa_test.go

    				t.Errorf("failed roundtrip %v => %s => %v", f, s, x)
    			}
    		}
    		f32 := float32(f)
    		if !math.IsInf(float64(f32), 0) {
    			s := FormatFloat(float64(f32), 'e', -1, 32)
    			if x, _ := ParseFloat(s, 32); float32(x) != f32 {
    				t.Errorf("failed roundtrip %v => %s => %v", f32, s, float32(x))
    			}
    		}
    	}
    }
    
    func TestFtoaRandom(t *testing.T) {
    	N := int(1e4)
    	if testing.Short() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 24 23:50:20 UTC 2022
    - 9.3K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/primitives/FloatArrayAsListTest.java

          Float[] suffix = {(float) 86, (float) 99};
          Float[] all = concat(concat(prefix, elements), suffix);
          return asList(all).subList(2, elements.length + 2);
        }
      }
    
      private static Float[] concat(Float[] left, Float[] right) {
        Float[] result = new Float[left.length + right.length];
        System.arraycopy(left, 0, result, 0, left.length);
        System.arraycopy(right, 0, result, left.length, right.length);
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Jun 01 09:32:35 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/primitives/FloatArrayAsListTest.java

          Float[] suffix = {(float) 86, (float) 99};
          Float[] all = concat(concat(prefix, elements), suffix);
          return asList(all).subList(2, elements.length + 2);
        }
      }
    
      private static Float[] concat(Float[] left, Float[] right) {
        Float[] result = new Float[left.length + right.length];
        System.arraycopy(left, 0, result, 0, left.length);
        System.arraycopy(right, 0, result, left.length, right.length);
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Jun 01 09:32:35 UTC 2023
    - 5.6K bytes
    - Viewed (0)
  10. src/runtime/minmax.go

    	if y > x {
    		return y
    	}
    	return x
    }
    
    func fmin32(x, y float32) float32 { return fmin(x, y) }
    func fmin64(x, y float64) float64 { return fmin(x, y) }
    func fmax32(x, y float32) float32 { return fmax(x, y) }
    func fmax64(x, y float64) float64 { return fmax(x, y) }
    
    type floaty interface{ ~float32 | ~float64 }
    
    func fmin[F floaty](x, y F) F {
    	if y != y || y < x {
    		return y
    	}
    	if x != x || x < y || x != 0 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 23 18:15:22 UTC 2023
    - 1.5K bytes
    - Viewed (0)
Back to top