Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 8 of 8 for addrtaken (0.53 sec)

  1. src/cmd/compile/internal/walk/assign.go

    			// These can't appear in expressions anyway.
    			continue
    		}
    
    		if name.Addrtaken() || !name.OnStack() {
    			// Global variable, heap escaped, or just addrtaken.
    			// Conservatively assume any memory access might alias.
    			memWrite = true
    			continue
    		}
    
    		// Local, non-addrtaken variable.
    		// Assignments can only alias with direct uses of this variable.
    		assigned.Add(name)
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 17:09:06 UTC 2024
    - 20.3K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/liveness/plive.go

    	// variable" ICEs (issue 19632).
    	switch v.Op {
    	case ssa.OpVarDef, ssa.OpVarLive, ssa.OpKeepAlive:
    		if !n.Used() {
    			return -1, 0
    		}
    	}
    
    	if n.Class == ir.PPARAM && !n.Addrtaken() && n.Type().Size() > int64(types.PtrSize) {
    		// Only aggregate-typed arguments that are not address-taken can be
    		// partially live.
    		lv.partLiveArgs[n] = true
    	}
    
    	var effect liveEffect
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 15:22:22 UTC 2024
    - 45.2K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/walk/complit.go

    		return false
    	}
    	x := n.X.(*ir.Name)
    	if !types.Identical(n.X.Type(), n.Y.Type()) {
    		// not a special composite literal assignment
    		return false
    	}
    	if x.Addrtaken() {
    		// If x is address-taken, the RHS may (implicitly) uses LHS.
    		// Not safe to do a special composite literal assignment
    		// (which may expand to multiple assignments).
    		return false
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 19:03:54 UTC 2023
    - 19.5K bytes
    - Viewed (0)
  4. test/live.go

    }
    
    func f39c() (x [10]*int) {
    	x = [10]*int{}
    	x[0] = new(int) // ERROR "live at call to newobject: x$"
    	printnl()       // ERROR "live at call to printnl: x$"
    	return
    }
    
    // issue 8142: lost 'addrtaken' bit on inlined variables.
    // no inlining in this test, so just checking that non-inlined works.
    
    type T40 struct {
    	m map[int]int
    }
    
    //go:noescape
    func useT40(*T40)
    
    func newT40() *T40 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 05 20:34:30 UTC 2023
    - 18K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/walk/order.go

    	// support that (see trybot failures on go.dev/cl/541715, PS1).
    	if ir.IsAddressable(n) {
    		if name, ok := ir.OuterValue(n).(*ir.Name); ok && name.Op() == ir.ONAME {
    			if name.Class == ir.PAUTO && !name.Addrtaken() && ssa.CanSSA(name.Type()) {
    				goto Copy
    			}
    		}
    
    		return n
    	}
    
    Copy:
    	return o.copyExpr(n)
    }
    
    // mapKeyTemp prepares n to be a key in a map runtime call and returns n.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 02:00:33 UTC 2024
    - 42.7K bytes
    - Viewed (0)
  6. test/live_regabi.go

    }
    
    func f39c() (x [10]*int) {
    	x = [10]*int{}
    	x[0] = new(int) // ERROR "live at call to newobject: x$"
    	printnl()       // ERROR "live at call to printnl: x$"
    	return
    }
    
    // issue 8142: lost 'addrtaken' bit on inlined variables.
    // no inlining in this test, so just checking that non-inlined works.
    
    type T40 struct {
    	m map[int]int
    }
    
    //go:noescape
    func useT40(*T40)
    
    func newT40() *T40 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Dec 05 20:34:30 UTC 2023
    - 18.4K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/ssa/func.go

    // analysis.
    func IsMergeCandidate(n *ir.Name) bool {
    	if base.Debug.MergeLocals == 0 ||
    		base.Flag.N != 0 ||
    		n.Class != ir.PAUTO ||
    		n.Type().Size() <= int64(3*types.PtrSize) ||
    		n.Addrtaken() ||
    		n.NonMergeable() ||
    		n.OpenDeferSlot() {
    		return false
    	}
    	return true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 19:44:43 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/staticinit/sched.go

    	}
    	if len(as2body.Lhs) != 1 || as2body.Lhs[0] != dcl.X {
    		return false
    	}
    
    	// Can't remove the parameter variables if an address is taken.
    	for _, v := range as2init.Lhs {
    		if v.(*ir.Name).Addrtaken() {
    			return false
    		}
    	}
    	// Can't move the computation of the args if they have side effects.
    	for _, r := range as2init.Rhs {
    		if AnySideEffects(r) {
    			return false
    		}
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 17:16:14 UTC 2024
    - 30.7K bytes
    - Viewed (0)
Back to top