Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 23 for Succs (0.06 sec)

  1. src/cmd/compile/internal/ssa/fuse.go

    	var ss0, ss1 *Block
    	s0 := b.Succs[0].b
    	i0 := b.Succs[0].i
    	if s0.Kind != BlockPlain || !isEmpty(s0) {
    		s0, ss0 = b, s0
    	} else {
    		ss0 = s0.Succs[0].b
    		i0 = s0.Succs[0].i
    	}
    	s1 := b.Succs[1].b
    	i1 := b.Succs[1].i
    	if s1.Kind != BlockPlain || !isEmpty(s1) {
    		s1, ss1 = b, s1
    	} else {
    		ss1 = s1.Succs[0].b
    		i1 = s1.Succs[0].i
    	}
    	if ss0 != ss1 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 31 20:45:54 UTC 2023
    - 9K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/ssa/check.go

    			}
    		case BlockRetJmp:
    			if len(b.Succs) != 0 {
    				f.Fatalf("retjmp block %s len(Succs)==%d, want 0", b, len(b.Succs))
    			}
    			if b.NumControls() != 1 {
    				f.Fatalf("retjmp block %s has nil control", b)
    			}
    			if !b.Controls[0].Type.IsMemory() {
    				f.Fatalf("retjmp block %s has non-memory control value %s", b, b.Controls[0].LongString())
    			}
    		case BlockPlain:
    			if len(b.Succs) != 1 {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 09 16:41:23 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/ssa/block.go

    func (b *Block) removeSucc(i int) {
    	n := len(b.Succs) - 1
    	if i != n {
    		e := b.Succs[n]
    		b.Succs[i] = e
    		// Update the other end of the edge we moved.
    		e.b.Preds[e.i].i = i
    	}
    	b.Succs[n] = Edge{}
    	b.Succs = b.Succs[:n]
    	b.Func.invalidateCFG()
    }
    
    func (b *Block) swapSuccessors() {
    	if len(b.Succs) != 2 {
    		b.Fatalf("swapSuccessors with len(Succs)=%d", len(b.Succs))
    	}
    	e0 := b.Succs[0]
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 15:44:14 UTC 2024
    - 12.2K bytes
    - Viewed (0)
  4. src/cmd/vendor/golang.org/x/tools/go/cfg/cfg.go

    //
    //	if x := f(); x != nil {
    //		T()
    //	} else {
    //		F()
    //	}
    //
    // produces this CFG:
    //
    //	1:  x := f()		Body
    //	    x != nil
    //	    succs: 2, 3
    //	2:  T()			IfThen
    //	    succs: 4
    //	3:  F()			IfElse
    //	    succs: 4
    //	4:			IfDone
    //
    // The CFG does contain Return statements; even implicit returns are
    // materialized (at the position of the function's closing brace).
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/ssa/deadcode.go

    }
    
    // removeEdge removes the i'th outgoing edge from b (and
    // the corresponding incoming edge from b.Succs[i].b).
    // Note that this potentially reorders successors of b, so it
    // must be used very carefully.
    func (b *Block) removeEdge(i int) {
    	e := b.Succs[i]
    	c := e.b
    	j := e.i
    
    	// Adjust b.Succs
    	b.removeSucc(i)
    
    	// Adjust c.Preds
    	c.removePred(j)
    
    	// Remove phi args from c's phis.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Dec 08 00:29:01 UTC 2023
    - 9.2K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/ssa/loopbce.go

    		// is the header block.  This implies that b.Succs[0] is
    		// reached iff ind < limit.
    		if len(b.Succs[0].b.Preds) != 1 {
    			// b.Succs[1] must exit the loop.
    			continue
    		}
    
    		// Second condition: b.Succs[0] dominates nxt so that
    		// nxt is computed when inc < limit.
    		if !sdom.IsAncestorEq(b.Succs[0].b, nxt.Block) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 07 17:37:47 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/ssa/sccp.go

    		break
    	case BlockDefer:
    		// we know nothing about control flow, add all branch destinations
    		t.edges = append(t.edges, block.Succs...)
    	case BlockFirst:
    		fallthrough // always takes the first branch
    	case BlockPlain:
    		t.edges = append(t.edges, block.Succs[0])
    	case BlockIf, BlockJumpTable:
    		cond := block.ControlValues()[0]
    		condLattice := t.getLatticeCell(cond)
    		if condLattice.tag == bottom {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jan 22 16:54:50 UTC 2024
    - 17.6K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/ssa/func_test.go

    				return false
    			}
    			for i := range fb.Values {
    				if !checkVal(fb.Values[i], gb.Values[i]) {
    					return false
    				}
    			}
    			if len(fb.Succs) != len(gb.Succs) {
    				return false
    			}
    			for i := range fb.Succs {
    				if !checkBlk(fb.Succs[i].b, gb.Succs[i].b) {
    					return false
    				}
    			}
    			if len(fb.Preds) != len(gb.Preds) {
    				return false
    			}
    			for i := range fb.Preds {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 08 19:01:04 UTC 2023
    - 13.1K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/ssa/loopreschedchecks.go

    		test.AddEdgeTo(sched)
    
    		// if false, rewrite edge to header.
    		// do NOT remove+add, because that will perturb all the other phi functions
    		// as well as messing up other edges to the header.
    		test.Succs = append(test.Succs, Edge{h, i})
    		h.Preds[i] = Edge{test, 1}
    		headerMemPhi.SetArg(i, mem0)
    
    		test.Likely = BranchUnlikely
    
    		// sched:
    		//    mem1 := call resched (mem0)
    		//    goto header
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 21:17:10 UTC 2023
    - 16K bytes
    - Viewed (0)
  10. src/cmd/vendor/golang.org/x/tools/go/cfg/builder.go

    		Stmt:  stmt,
    	}
    	block.Succs = block.succs2[:0]
    	g.Blocks = append(g.Blocks, block)
    	return block
    }
    
    func (b *builder) add(n ast.Node) {
    	b.current.Nodes = append(b.current.Nodes, n)
    }
    
    // jump adds an edge from the current block to the target block,
    // and sets b.current to nil.
    func (b *builder) jump(target *Block) {
    	b.current.Succs = append(b.current.Succs, target)
    	b.current = nil
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 11.4K bytes
    - Viewed (0)
Back to top