Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 138 for indexByte (0.12 sec)

  1. src/internal/bytealg/indexbyte_riscv64.s

    // Copyright 2019 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    #include "go_asm.h"
    #include "textflag.h"
    
    TEXT ·IndexByte<ABIInternal>(SB),NOSPLIT,$0-40
    	// X10 = b_base
    	// X11 = b_len
    	// X12 = b_cap (unused)
    	// X13 = byte to find
    	AND	$0xff, X13
    	MOV	X10, X12		// store base for later
    	ADD	X10, X11		// end
    	SUB	$1, X10
    
    loop:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 09 13:57:06 UTC 2023
    - 919 bytes
    - Viewed (0)
  2. src/internal/bytealg/indexbyte_mips64x.s

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    //go:build mips64 || mips64le
    
    #include "go_asm.h"
    #include "textflag.h"
    
    TEXT ·IndexByte(SB),NOSPLIT,$0-40
    	MOVV	b_base+0(FP), R1
    	MOVV	b_len+8(FP), R2
    	MOVBU	c+24(FP), R3	// byte to find
    	MOVV	R1, R4		// store base for later
    	ADDV	R1, R2		// end
    	ADDV	$-1, R1
    
    loop:
    	ADDV	$1, R1
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Nov 06 10:24:44 UTC 2021
    - 985 bytes
    - Viewed (0)
  3. operator/pkg/validate/common.go

    	}
    	if !strings.Contains(pn, "[") && !strings.Contains(pn, "]") {
    		return false
    	}
    	indexPattern := pattern[strings.IndexByte(pattern, '[')+1 : strings.IndexByte(pattern, ']')]
    	if indexPattern == "*" {
    		return true
    	}
    	index := pn[strings.IndexByte(pn, '[')+1 : strings.IndexByte(pn, ']')]
    	return indexPattern == index
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Aug 10 15:35:03 UTC 2023
    - 11K bytes
    - Viewed (0)
  4. cmd/os-dirent_namelen_linux.go

    	limit := dirent.Reclen - fixedHdr
    	if limit > nameBufLen {
    		limit = nameBufLen
    	}
    	// Avoid bugs in long file names
    	// https://github.com/golang/tools/commit/5f9a5413737ba4b4f692214aebee582b47c8be74
    	nameLen := bytes.IndexByte(nameBuf[:limit], 0)
    	if nameLen < 0 {
    		return 0, fmt.Errorf("failed to find terminating 0 byte in dirent")
    	}
    	return uint64(nameLen), nil
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Aug 19 01:35:22 UTC 2021
    - 1.5K bytes
    - Viewed (0)
  5. src/internal/bytealg/indexbyte_arm.s

    // Copyright 2018 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    #include "go_asm.h"
    #include "textflag.h"
    
    TEXT ·IndexByte(SB),NOSPLIT,$0-20
    	MOVW	b_base+0(FP), R0
    	MOVW	b_len+4(FP), R1
    	MOVBU	c+12(FP), R2	// byte to find
    	MOVW	$ret+16(FP), R5
    	B	indexbytebody<>(SB)
    
    TEXT ·IndexByteString(SB),NOSPLIT,$0-16
    	MOVW	s_base+0(FP), R0
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 18 07:37:13 UTC 2019
    - 951 bytes
    - Viewed (0)
  6. test/fixedbugs/issue7690.go

    	buf2 := make([]byte, 1000)
    
    	runtime.Stack(buf1, false)      // CALL is last instruction on this line
    	n := runtime.Stack(buf2, false) // CALL is followed by load of result from stack
    
    	buf1 = buf1[:bytes.IndexByte(buf1, 0)]
    	buf2 = buf2[:n]
    
    	re := regexp.MustCompile(`(?m)^main\.main\(\)\n.*/issue7690.go:([0-9]+)`)
    	m1 := re.FindStringSubmatch(string(buf1))
    	if m1 == nil {
    		println("BUG: cannot find main.main in first trace")
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 02 13:43:18 UTC 2016
    - 1.2K bytes
    - Viewed (0)
  7. src/cmd/go/internal/telemetrystats/version_unix.go

    import (
    	"bytes"
    	"fmt"
    	"runtime"
    	"strings"
    
    	"cmd/internal/telemetry"
    
    	"golang.org/x/sys/unix"
    )
    
    func incrementVersionCounters() {
    	convert := func(nullterm []byte) string {
    		end := bytes.IndexByte(nullterm, 0)
    		if end < 0 {
    			end = len(nullterm)
    		}
    		return string(nullterm[:end])
    	}
    
    	var v unix.Utsname
    	err := unix.Uname(&v)
    	if err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 15:44:55 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  8. src/internal/bytealg/indexbyte_mipsx.s

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    //go:build mips || mipsle
    
    #include "go_asm.h"
    #include "textflag.h"
    
    TEXT ·IndexByte(SB),NOSPLIT,$0-20
    	MOVW	b_base+0(FP), R1
    	MOVW	b_len+4(FP), R2
    	MOVBU	c+12(FP), R3	// byte to find
    	ADDU	$1, R1, R4	// store base+1 for later
    	ADDU	R1, R2	// end
    
    loop:
    	BEQ	R1, R2, notfound
    	MOVBU	(R1), R5
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Nov 06 10:24:44 UTC 2021
    - 1012 bytes
    - Viewed (0)
  9. istioctl/pkg/multixds/google.go

    	}
    	const projSeg = "/projects/"
    	i := strings.Index(u.Path, projSeg)
    	if i == -1 {
    		return nil, fmt.Errorf("webhook URL %s doesn't contain the projects segment", u)
    	}
    	i += len(projSeg)
    	j := strings.IndexByte(u.Path[i:], '/')
    	if j == -1 {
    		return nil, fmt.Errorf("webhook URL %s is malformed", u)
    	}
    	ret.gcpProject = u.Path[i : i+j]
    
    	const crSeg = "/ISTIO_META_CLOUDRUN_ADDR/"
    	i += j
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Jun 06 03:39:27 UTC 2022
    - 1.5K bytes
    - Viewed (0)
  10. src/strings/example_test.go

    	fmt.Println(strings.IndexAny("crwth", "aeiouy"))
    	// Output:
    	// 2
    	// -1
    }
    
    func ExampleIndexByte() {
    	fmt.Println(strings.IndexByte("golang", 'g'))
    	fmt.Println(strings.IndexByte("gophers", 'h'))
    	fmt.Println(strings.IndexByte("golang", 'x'))
    	// Output:
    	// 0
    	// 3
    	// -1
    }
    func ExampleIndexRune() {
    	fmt.Println(strings.IndexRune("chicken", 'k'))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 09 22:05:38 UTC 2023
    - 10.7K bytes
    - Viewed (0)
Back to top