Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for StructMakeOp (0.3 sec)

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

    	decomposeUserPhi(elem)
    }
    
    // MaxStruct is the maximum number of fields a struct
    // can have and still be SSAable.
    const MaxStruct = 4
    
    // StructMakeOp returns the opcode to construct a struct with the
    // given number of fields.
    func StructMakeOp(nf int) Op {
    	switch nf {
    	case 0:
    		return OpStructMake0
    	case 1:
    		return OpStructMake1
    	case 2:
    		return OpStructMake2
    	case 3:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 23 21:22:15 UTC 2022
    - 13.4K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/ssa/expand_calls.go

    			addArg(e)
    			pos = pos.WithNotStmt()
    		}
    		if at.NumFields() > 4 {
    			panic(fmt.Errorf("Too many fields (%d, %d bytes), container=%s", at.NumFields(), at.Size(), container.LongString()))
    		}
    		a = makeOf(a, StructMakeOp(at.NumFields()), args)
    		x.commonSelectors[sk] = a
    		return a
    
    	case types.TSLICE:
    		addArg(x.rewriteSelectOrArg(pos, b, container, nil, m0, at.Elem().PtrTo(), rc.next(x.typs.BytePtr)))
    		pos = pos.WithNotStmt()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 28 05:13:40 UTC 2023
    - 31.9K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/ssagen/ssa.go

    			t := left.X.Type()
    			nf := t.NumFields()
    			idx := fieldIdx(left)
    
    			// Grab old value of structure.
    			old := s.expr(left.X)
    
    			// Make new structure.
    			new := s.newValue0(ssa.StructMakeOp(t.NumFields()), t)
    
    			// Add fields as args.
    			for i := 0; i < nf; i++ {
    				if i == idx {
    					new.AddArg(right)
    				} else {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 19:44:43 UTC 2024
    - 284.9K bytes
    - Viewed (0)
Back to top