Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,698 for switch3 (0.12 sec)

  1. src/go/scanner/scanner.go

    		case '=':
    			tok = s.switch2(token.ASSIGN, token.EQL)
    		case '!':
    			tok = s.switch2(token.NOT, token.NEQ)
    		case '&':
    			if s.ch == '^' {
    				s.next()
    				tok = s.switch2(token.AND_NOT, token.AND_NOT_ASSIGN)
    			} else {
    				tok = s.switch3(token.AND, token.AND_ASSIGN, '&', token.LAND)
    			}
    		case '|':
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 12:02:03 UTC 2023
    - 24.3K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/walk/switch.go

    // expression switch.
    func walkSwitchExpr(sw *ir.SwitchStmt) {
    	lno := ir.SetPos(sw)
    
    	cond := sw.Tag
    	sw.Tag = nil
    
    	// convert switch {...} to switch true {...}
    	if cond == nil {
    		cond = ir.NewBool(base.Pos, true)
    		cond = typecheck.Expr(cond)
    		cond = typecheck.DefaultLit(cond, nil)
    	}
    
    	// Given "switch string(byteslice)",
    	// with all cases being side-effect free,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:34:01 UTC 2024
    - 30.1K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/tests/tf_executor_ops_invalid.mlir

    // Check that a switch always needs at least two arguments.
    func.func @invalid_switch(%arg0: tensor<*xf32>) {
      tf_executor.graph {
        %true, %false, %ctlSwitch = "tf_executor.Switch"(%arg0) : (tensor<*xf32>) -> (tensor<*xf32>, tensor<*xf32>, !tf_executor.control)
    // expected-error@-1 {{'tf_executor.Switch' op expected 2 or more operands}}
      }
      func.return
    }
    
    // -----
    
    // Check that a switch always needs at least two arguments.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Oct 19 01:12:10 UTC 2023
    - 28.2K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/tensorflow/tests/tf_executor_ops.mlir

      }
      func.return %result : tensor<*xf32>
    }
    
    // CHECK-LABEL: func @switch(%{{.*}}: tensor<*xf32>, %{{.*}}: tensor<i1>) -> tensor<*xf32> {
    func.func @switch(%arg0: tensor<*xf32>, %arg1: tensor<i1>) -> tensor<*xf32> {
      %result = tf_executor.graph {
    // CHECK: tf_executor.Switch %{{.*}}, %{{.*}} : tensor<*xf32>
        %true, %false, %ctlSwitch = tf_executor.Switch %arg0, %arg1 : tensor<*xf32>
        tf_executor.fetch %true : tensor<*xf32>
      }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Mar 28 12:06:33 UTC 2022
    - 25.8K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/tests/breakup-islands.mlir

          tf_executor.yield %add, %less : tensor<*xi32>, tensor<i1>
        }
        %switch:3 = tf_executor.Switch %island0#0, %island0#1 : tensor<*xi32>
        %island1:2 = tf_executor.island {
          %add = "tf.Add"(%switch#0, %arg1) : (tensor<*xi32>, tensor<i32>) -> tensor<*xi32>
          %res = "tf.Print"(%add) { message = "add result 2" } : (tensor<*xi32>) -> (tensor<*xi32>)
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Oct 31 08:59:10 UTC 2023
    - 28.5K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/ir/tf_executor_ops.td

    }
    
    def TfExecutor_SwitchOp : TfExecutor_Op<"Switch",
        [ControlOperandsAfterAllData, HasParent<"GraphOp">,
         PredOpTrait<"data operand must be broadcastable to true result",
                     TF_OpIsBroadcastableToRes<0, 0>>,
         PredOpTrait<"data operand must be broadcastable to false result",
                     TF_OpIsBroadcastableToRes<0, 1>>]>{
      let summary = [{
        The "tf_executor.Switch" operation takes a data operand and a boolean
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Feb 23 19:35:12 UTC 2023
    - 22K bytes
    - Viewed (0)
  7. src/cmd/go/internal/modcmd/download.go

    	if haveExplicitArgs || modload.WorkFilePath() != "" {
    		var sw toolchain.Switcher
    		// Add errors to the Switcher in deterministic order so that they will be
    		// logged deterministically.
    		for _, m := range mods {
    			if erri, ok := downloadErrs.Load(m); ok {
    				sw.Error(erri.(error))
    			}
    		}
    		// Only call sw.Switch if it will actually switch.
    		// Otherwise, we may want to write the errors as JSON
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 08 19:32:39 UTC 2023
    - 13.5K bytes
    - Viewed (0)
  8. src/cmd/go/internal/toolchain/select.go

    	// of the current go.mod or go.work, and let "go run" or "go install"
    	// do the rest, including a toolchain switch.
    	// Our goal instead is, since we have gone to the trouble of handling
    	// unknown flags to some degree, to run the switch now, so that
    	// these commands can switch to a newer toolchain directed by the
    	// go.mod which may actually understand the flag.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 17:25:05 UTC 2024
    - 23.4K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/ir/fmt.go

    	OIF:         -1,
    	OLABEL:      -1,
    	OGO:         -1,
    	ORANGE:      -1,
    	ORETURN:     -1,
    	OSELECT:     -1,
    	OSWITCH:     -1,
    
    	OEND: 0,
    }
    
    // StmtWithInit reports whether op is a statement with an explicit init list.
    func StmtWithInit(op Op) bool {
    	switch op {
    	case OIF, OFOR, OSWITCH:
    		return true
    	}
    	return false
    }
    
    func stmtFmt(n Node, s fmt.State) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 05 15:20:28 UTC 2023
    - 26K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/typecheck/stmt.go

    		t = n.Tag.Type()
    	}
    
    	var nilonly string
    	if t != nil {
    		switch {
    		case t.IsMap():
    			nilonly = "map"
    		case t.Kind() == types.TFUNC:
    			nilonly = "func"
    		case t.IsSlice():
    			nilonly = "slice"
    
    		case !types.IsComparable(t):
    			if t.IsStruct() {
    				base.ErrorfAt(n.Pos(), errors.InvalidExprSwitch, "cannot switch on %L (struct containing %v cannot be compared)", n.Tag, types.IncomparableField(t).Type)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Nov 20 15:10:54 UTC 2023
    - 17.8K bytes
    - Viewed (0)
Back to top