Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 10 for NewIndexExpr (0.17 sec)

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

    			default:
    				step = 1
    			}
    			if step == 1 {
    				comp(
    					ir.NewIndexExpr(base.Pos, cmpl, ir.NewInt(base.Pos, i)),
    					ir.NewIndexExpr(base.Pos, cmpr, ir.NewInt(base.Pos, i)),
    				)
    				i++
    				remains -= t.Elem().Size()
    			} else {
    				elemType := t.Elem().ToUnsigned()
    				cmplw := ir.Node(ir.NewIndexExpr(base.Pos, cmpl, ir.NewInt(base.Pos, i)))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 24 21:55:14 UTC 2023
    - 16.2K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/walk/select.go

    	var pc0, pcs ir.Node
    	if base.Flag.Race {
    		pcs = typecheck.TempAt(base.Pos, ir.CurFunc, types.NewArray(types.Types[types.TUINTPTR], int64(ncas)))
    		pc0 = typecheck.Expr(typecheck.NodAddr(ir.NewIndexExpr(base.Pos, pcs, ir.NewInt(base.Pos, 0))))
    	} else {
    		pc0 = typecheck.NodNil()
    	}
    
    	// register cases
    	for _, cas := range cases {
    		ir.SetPos(cas)
    
    		init = append(init, ir.TakeInit(cas)...)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Aug 22 01:53:41 UTC 2023
    - 7.8K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/walk/complit.go

    		// }
    		i := typecheck.TempAt(base.Pos, ir.CurFunc, types.Types[types.TINT])
    		rhs := ir.NewIndexExpr(base.Pos, vstate, i)
    		rhs.SetBounded(true)
    
    		kidx := ir.NewIndexExpr(base.Pos, vstatk, i)
    		kidx.SetBounded(true)
    
    		// typechecker rewrites OINDEX to OINDEXMAP
    		lhs := typecheck.AssignExpr(ir.NewIndexExpr(base.Pos, m, kidx)).(*ir.IndexExpr)
    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. src/cmd/compile/internal/pkginit/initAsanGlobals.go

    	for i, n := range InstrumentGlobalsSlice {
    		setField := func(f string, val ir.Node, i int) {
    			r := ir.NewAssignStmt(base.Pos, ir.NewSelectorExpr(base.Pos, ir.ODOT,
    				ir.NewIndexExpr(base.Pos, globals, ir.NewInt(base.Pos, int64(i))), lname(f)), val)
    			init.Append(typecheck.Stmt(r))
    		}
    		// globals[i].beg = uintptr(unsafe.Pointer(&n))
    		c = tconv(typecheck.NodAddr(n), types.Types[types.TUNSAFEPTR])
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 17 19:36:24 UTC 2023
    - 8.7K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/walk/range.go

    		if v2 == nil {
    			body = []ir.Node{rangeAssign(nrange, hv1)}
    			break
    		}
    
    		// for v1, v2 := range ha { body }
    		if cheapComputableIndex(elem.Size()) {
    			// v1, v2 = hv1, ha[hv1]
    			tmp := ir.NewIndexExpr(base.Pos, ha, hv1)
    			tmp.SetBounded(true)
    			body = []ir.Node{rangeAssign2(nrange, hv1, tmp)}
    			break
    		}
    
    		// Slice to iterate over
    		var hs ir.Node
    		if t.IsSlice() {
    			hs = ha
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 20 14:52:33 UTC 2023
    - 17.6K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/walk/assign.go

    		ncopy = mkcall1(fn, types.Types[types.TINT], &nodes, ptr1, len1, ptr2, len2, ir.NewInt(base.Pos, elemtype.Size()))
    	} else {
    		// memmove(&s[idx], &l2[0], len(l2)*sizeof(T))
    		ix := ir.NewIndexExpr(base.Pos, s, idx)
    		ix.SetBounded(true)
    		addr := typecheck.NodAddr(ix)
    
    		sptr := ir.NewUnaryExpr(base.Pos, ir.OSPTR, l2)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 17:09:06 UTC 2024
    - 20.3K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/walk/convert.go

    		// individual bytes.
    		staticuint64s := ir.NewLinksymExpr(base.Pos, ir.Syms.Staticuint64s, types.NewArray(types.Types[types.TUINT8], 256*8))
    		xe := ir.NewIndexExpr(base.Pos, staticuint64s, index)
    		xe.SetBounded(true)
    		value = xe
    	case n.Op() == ir.ONAME && n.(*ir.Name).Class == ir.PEXTERN && n.(*ir.Name).Readonly():
    		// n is a readonly global; use it directly.
    		value = n
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 09 17:28:22 UTC 2023
    - 18.2K bytes
    - Viewed (0)
  8. src/cmd/compile/internal/walk/builtin.go

    			newLen,
    			ir.NewUnaryExpr(base.Pos, ir.OCAP, s),
    			num)),
    	}
    
    	l = append(l, nif)
    
    	ls = n.Args[1:]
    	for i, n := range ls {
    		// s[s.len-argc+i] = arg
    		ix := ir.NewIndexExpr(base.Pos, s, ir.NewBinaryExpr(base.Pos, ir.OSUB, newLen, ir.NewInt(base.Pos, int64(argc-i))))
    		ix.SetBounded(true)
    		l = append(l, ir.NewAssignStmt(base.Pos, ix, n))
    	}
    
    	typecheck.Stmts(l)
    	walkStmtList(l)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 22:35:22 UTC 2024
    - 31.2K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/walk/switch.go

    	slice.SetTypecheck(1) // legacy typechecker doesn't handle this op
    	slice.MarkNonNil()
    	// Load the byte we're splitting on.
    	load := ir.NewIndexExpr(base.Pos, slice, ir.NewInt(base.Pos, int64(bestIdx)))
    	// Compare with the value we're splitting on.
    	cmp := ir.Node(ir.NewBinaryExpr(base.Pos, ir.OLE, load, ir.NewInt(base.Pos, int64(bestByte))))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:34:01 UTC 2024
    - 30.1K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/walk/order.go

    		as := ir.NewAssignStmt(base.Pos, m, n)
    		typecheck.Stmt(as)
    		o.stmt(as)
    
    		// Emit eval+insert of dynamic entries, one at a time.
    		for _, r := range dynamics {
    			lhs := typecheck.AssignExpr(ir.NewIndexExpr(base.Pos, m, r.Key)).(*ir.IndexExpr)
    			base.AssertfAt(lhs.Op() == ir.OINDEXMAP, lhs.Pos(), "want OINDEXMAP, have %+v", lhs)
    			lhs.RType = n.RType
    
    			as := ir.NewAssignStmt(base.Pos, lhs, r.Value)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 02:00:33 UTC 2024
    - 42.7K bytes
    - Viewed (0)
Back to top