Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 46 for SHL (0.16 sec)

  1. okhttp/src/test/java/okhttp3/internal/idn/IdnaMappingTableTest.kt

        assertThat(compactTable.sections.length).isLessThan(1 shl 14)
    
        // Less than 65,536 bytes, because we binary search on a 14-bit index with a stride of 4 bytes.
        assertThat(compactTable.ranges.length).isLessThan((1 shl 14) * 4)
    
        // Less than 16,384 chars, because we index on a 14-bit index in the ranges table.
        assertThat(compactTable.mappings.length).isLessThan(1 shl 14)
    
        // Confirm the data strings are ASCII.
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/syntax/tokens.go

    	Leq // <=
    	Gtr // >
    	Geq // >=
    
    	// precAdd
    	Add // +
    	Sub // -
    	Or  // |
    	Xor // ^
    
    	// precMul
    	Mul    // *
    	Div    // /
    	Rem    // %
    	And    // &
    	AndNot // &^
    	Shl    // <<
    	Shr    // >>
    )
    
    // Operator precedences
    const (
    	_ = iota
    	precOrOr
    	precAndAnd
    	precCmp
    	precAdd
    	precMul
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 20 14:52:38 UTC 2023
    - 2.6K bytes
    - Viewed (0)
  3. okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerReader.kt

                throw ProtocolException("invalid encoding for length")
              }
    
              for (i in 1 until lengthBytes) {
                lengthBits = lengthBits shl 8
                lengthBits += source.readByte().toInt() and 0xff
              }
    
              if (lengthBits < 0) throw ProtocolException("length > Long.MAX_VALUE")
    
              lengthBits
            }
            else -> {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  4. src/math/big/nat_test.go

    				break
    			}
    		}
    	}
    }
    
    func BenchmarkZeroShifts(b *testing.B) {
    	x := rndNat(800)
    
    	b.Run("Shl", func(b *testing.B) {
    		for i := 0; i < b.N; i++ {
    			var z nat
    			z.shl(x, 0)
    		}
    	})
    	b.Run("ShlSame", func(b *testing.B) {
    		for i := 0; i < b.N; i++ {
    			x.shl(x, 0)
    		}
    	})
    
    	b.Run("Shr", func(b *testing.B) {
    		for i := 0; i < b.N; i++ {
    			var z nat
    			z.shr(x, 0)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 09 15:29:36 UTC 2024
    - 26.2K bytes
    - Viewed (0)
  5. src/math/big/rat.go

    	// - the low-order 1 will be used during rounding then discarded.
    	exp := alen - blen
    	var a2, b2 nat
    	a2 = a2.set(a)
    	b2 = b2.set(b)
    	if shift := Msize2 - exp; shift > 0 {
    		a2 = a2.shl(a2, uint(shift))
    	} else if shift < 0 {
    		b2 = b2.shl(b2, uint(-shift))
    	}
    
    	// 2. Compute quotient and remainder (q, r).  NB: due to the
    	// extra shift, the low-order bit of q is logically the
    	// high-order bit of r.
    	var q nat
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 11:59:09 UTC 2023
    - 13.5K bytes
    - Viewed (0)
  6. src/math/big/arith_test.go

    	}
    }
    
    func TestIssue31084(t *testing.T) {
    	// compute 10^n via 5^n << n.
    	const n = 165
    	p := nat(nil).expNN(nat{5}, nat{n}, nil, false)
    	p = p.shl(p, n)
    	got := string(p.utoa(10))
    	want := "1" + strings.Repeat("0", n)
    	if got != want {
    		t.Errorf("shl(%v, %v)\n\tgot  %s\n\twant %s", p, n, got, want)
    	}
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 02 14:43:52 UTC 2022
    - 19.9K bytes
    - Viewed (0)
  7. test/codegen/bits.go

    	// s390x:"RISBGZ\t[$]48, [$]15, [$]0,"
    	return x & 0xffff00000000ffff
    }
    
    func issue44228a(a []int64, i int) bool {
    	// amd64: "BTQ", -"SHL"
    	return a[i>>6]&(1<<(i&63)) != 0
    }
    func issue44228b(a []int32, i int) bool {
    	// amd64: "BTL", -"SHL"
    	return a[i>>5]&(1<<(i&31)) != 0
    }
    
    func issue48467(x, y uint64) uint64 {
    	// arm64: -"NEG"
    	d, borrow := bits.Sub64(x, y, 0)
    	return x - d&(-borrow)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 19:02:52 UTC 2024
    - 7.8K bytes
    - Viewed (0)
  8. src/math/big/float.go

    	switch {
    	case ex < ey:
    		if al {
    			t := nat(nil).shl(y.mant, uint(ey-ex))
    			z.mant = z.mant.add(x.mant, t)
    		} else {
    			z.mant = z.mant.shl(y.mant, uint(ey-ex))
    			z.mant = z.mant.add(x.mant, z.mant)
    		}
    	default:
    		// ex == ey, no shift needed
    		z.mant = z.mant.add(x.mant, y.mant)
    	case ex > ey:
    		if al {
    			t := nat(nil).shl(x.mant, uint(ex-ey))
    			z.mant = z.mant.add(t, y.mant)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 15:46:54 UTC 2024
    - 44.5K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/tools/go/analysis/passes/shift/shift.go

    	}
    	inspect.Preorder(nodeFilter, func(node ast.Node) {
    		if dead[node] {
    			// Skip shift checks on unreachable nodes.
    			return
    		}
    
    		switch node := node.(type) {
    		case *ast.BinaryExpr:
    			if node.Op == token.SHL || node.Op == token.SHR {
    				checkLongShift(pass, node, node.X, node.Y)
    			}
    		case *ast.AssignStmt:
    			if len(node.Lhs) != 1 || len(node.Rhs) != 1 {
    				return
    			}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  10. src/math/big/ftoa.go

    	// x (i.e., for mant we want x.prec + 1 bits).
    	mant := nat(nil).set(x.mant)
    	exp := int(x.exp) - mant.bitLen()
    	s := mant.bitLen() - int(x.prec+1)
    	switch {
    	case s < 0:
    		mant = mant.shl(mant, uint(-s))
    	case s > 0:
    		mant = mant.shr(mant, uint(+s))
    	}
    	exp += s
    	// x = mant * 2**exp with lsb(mant) == 1/2 ulp of x.prec
    
    	// 2) Compute lower bound by subtracting 1/2 ulp.
    	var lower decimal
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 11:59:09 UTC 2023
    - 13.5K bytes
    - Viewed (0)
Back to top