Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 85 for cfunc (0.15 sec)

  1. src/cmd/go/testdata/script/cover_coverpkg_partial.txt

    func TestB(t *testing.T) {
    	if BFunc() == 1010101 {
    		t.Fatalf("bad!")
    	}
    }
    -- c/c.go --
    package c
    
    var G int
    
    func CFunc(x, y int) int {
    	G += x
    	G -= y
    	return x + y
    }
    -- c/c_test.go --
    package c
    
    import "testing"
    
    func TestC(t *testing.T) {
    	if CFunc(10, 10) == 1010101 {
    		t.Fatalf("bad!")
    	}
    }
    -- d/d.go --
    package d
    
    const FortyTwo = 42
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 20:12:49 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  2. src/runtime/syscall_windows_test.go

    type uint8Pair struct{ x, y uint8 }
    
    var cbFuncs = []cbFunc{
    	{func(i1, i2 uintptr) uintptr {
    		return i1 + i2
    	}},
    	{func(i1, i2, i3 uintptr) uintptr {
    		return i1 + i2 + i3
    	}},
    	{func(i1, i2, i3, i4 uintptr) uintptr {
    		return i1 + i2 + i3 + i4
    	}},
    	{func(i1, i2, i3, i4, i5 uintptr) uintptr {
    		return i1 + i2 + i3 + i4 + i5
    	}},
    	{func(i1, i2, i3, i4, i5, i6 uintptr) uintptr {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 31 16:31:35 UTC 2023
    - 32.5K bytes
    - Viewed (0)
  3. src/cmd/internal/obj/loong64/obj.go

    			}
    
    			if autosize == 0 && c.cursym.Func().Text.Mark&LEAF == 0 {
    				if c.cursym.Func().Text.From.Sym.NoSplit() {
    					if ctxt.Debugvlog {
    						ctxt.Logf("save suppressed in: %s\n", c.cursym.Name)
    					}
    
    					c.cursym.Func().Text.Mark |= LEAF
    				}
    			}
    
    			p.To.Offset = int64(autosize) - ctxt.Arch.FixedFrameSize
    
    			if c.cursym.Func().Text.Mark&LEAF != 0 {
    				c.cursym.Set(obj.AttrLeaf, true)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 21 19:22:18 UTC 2023
    - 19.7K bytes
    - Viewed (0)
  4. src/cmd/internal/obj/x86/obj6.go

    	pcdata = cursym.Func().SpillRegisterArgs(spill, newprog)
    
    	call := obj.Appendp(pcdata, newprog)
    	call.Pos = cursym.Func().Text.Pos
    	call.As = obj.ACALL
    	call.To.Type = obj.TYPE_BRANCH
    	call.To.Name = obj.NAME_EXTERN
    	morestack := "runtime.morestack"
    	switch {
    	case cursym.CFunc():
    		morestack = "runtime.morestackc"
    	case !cursym.Func().Text.From.Sym.NeedCtxt():
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 18:36:45 UTC 2023
    - 40.9K bytes
    - Viewed (0)
  5. src/cmd/internal/obj/objfile.go

    	}
    	if s.CFunc() {
    		fmt.Fprintf(ctxt.Bso, "cfunc ")
    	}
    	if s.NoSplit() {
    		fmt.Fprintf(ctxt.Bso, "nosplit ")
    	}
    	if s.Func() != nil && s.Func().FuncFlag&abi.FuncFlagTopFrame != 0 {
    		fmt.Fprintf(ctxt.Bso, "topframe ")
    	}
    	if s.Func() != nil && s.Func().FuncFlag&abi.FuncFlagAsm != 0 {
    		fmt.Fprintf(ctxt.Bso, "asm ")
    	}
    	fmt.Fprintf(ctxt.Bso, "size=%d", s.Size)
    	if s.Type == objabi.STEXT {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 19:57:43 UTC 2024
    - 24K bytes
    - Viewed (0)
  6. src/cmd/internal/obj/arm/obj5.go

    const (
    	FOLL  = 1 << 0
    	LABEL = 1 << 1
    	LEAF  = 1 << 2
    )
    
    func preprocess(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	autosize := int32(0)
    
    	if cursym.Func().Text == nil || cursym.Func().Text.Link == nil {
    		return
    	}
    
    	c := ctxt5{ctxt: ctxt, cursym: cursym, newprog: newprog}
    
    	p := c.cursym.Func().Text
    	autoffset := int32(p.To.Offset)
    	if autoffset == -4 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 20 17:19:36 UTC 2023
    - 21.4K bytes
    - Viewed (0)
  7. src/cmd/internal/obj/arm64/obj7.go

    		p2.To.Sym = nil
    	} else {
    		return
    	}
    	obj.Nopout(p)
    }
    
    func preprocess(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	if cursym.Func().Text == nil || cursym.Func().Text.Link == nil {
    		return
    	}
    
    	c := ctxt7{ctxt: ctxt, newprog: newprog, cursym: cursym}
    
    	p := c.cursym.Func().Text
    	textstksiz := p.To.Offset
    	if textstksiz == -8 {
    		// Historical way to mark NOFRAME.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 08 05:46:32 UTC 2023
    - 28.4K bytes
    - Viewed (0)
  8. src/cmd/internal/obj/link.go

    func (a *Attribute) DuplicateOK() bool        { return a.load()&AttrDuplicateOK != 0 }
    func (a *Attribute) MakeTypelink() bool       { return a.load()&AttrMakeTypelink != 0 }
    func (a *Attribute) CFunc() bool              { return a.load()&AttrCFunc != 0 }
    func (a *Attribute) NoSplit() bool            { return a.load()&AttrNoSplit != 0 }
    func (a *Attribute) Leaf() bool               { return a.load()&AttrLeaf != 0 }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 19:57:43 UTC 2024
    - 33.1K bytes
    - Viewed (0)
  9. src/cmd/internal/obj/ppc64/obj9.go

    	} else {
    		return
    	}
    	obj.Nopout(p)
    }
    
    func preprocess(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	// TODO(minux): add morestack short-cuts with small fixed frame-size.
    	if cursym.Func().Text == nil || cursym.Func().Text.Link == nil {
    		return
    	}
    
    	c := ctxt9{ctxt: ctxt, cursym: cursym, newprog: newprog}
    
    	p := c.cursym.Func().Text
    	textstksiz := p.To.Offset
    	if textstksiz == -8 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 18:17:17 UTC 2024
    - 40.8K bytes
    - Viewed (0)
  10. src/cmd/go/testdata/script/cover_coverpkg_with_init.txt

    import (
    	"M/a"
    	"M/b"
    )
    
    func MFunc() string {
    	return "42"
    }
    
    func M2Func() int {
    	return a.AFunc() + b.BFunc()
    }
    
    func init() {
    	println("package 'main' init")
    }
    
    func main() {
    	println(a.AFunc() + b.BFunc())
    }
    -- main/main_test.go --
    package main
    
    import "testing"
    
    func TestMain(t *testing.T) {
    	if MFunc() != "42" {
    		t.Fatalf("bad!")
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Sep 30 12:33:44 UTC 2023
    - 2.4K bytes
    - Viewed (0)
Back to top