github.com/cockroachdb/cockroachdb-parser@v0.23.3-0.20240213214944-911057d40c9a/pkg/sql/colexec/execgen/supported_bin_cmp_ops.go (about) 1 // Copyright 2020 The Cockroach Authors. 2 // 3 // Use of this software is governed by the Business Source License 4 // included in the file licenses/BSL.txt. 5 // 6 // As of the Change Date specified in that file, in accordance with 7 // the Business Source License, use of this software will be governed 8 // by the Apache License, Version 2.0, included in the file 9 // licenses/APL.txt. 10 11 package execgen 12 13 import ( 14 "github.com/cockroachdb/cockroachdb-parser/pkg/sql/sem/tree/treebin" 15 "github.com/cockroachdb/cockroachdb-parser/pkg/sql/sem/tree/treecmp" 16 ) 17 18 // BinaryOpName is a mapping from all binary operators that are supported by 19 // the vectorized engine to their names. 20 var BinaryOpName = map[treebin.BinaryOperatorSymbol]string{ 21 treebin.Bitand: "Bitand", 22 treebin.Bitor: "Bitor", 23 treebin.Bitxor: "Bitxor", 24 treebin.Plus: "Plus", 25 treebin.Minus: "Minus", 26 treebin.Mult: "Mult", 27 treebin.Div: "Div", 28 treebin.FloorDiv: "FloorDiv", 29 treebin.Mod: "Mod", 30 treebin.Pow: "Pow", 31 treebin.Concat: "Concat", 32 treebin.LShift: "LShift", 33 treebin.RShift: "RShift", 34 treebin.JSONFetchVal: "JSONFetchVal", 35 treebin.JSONFetchText: "JSONFetchText", 36 treebin.JSONFetchValPath: "JSONFetchValPath", 37 treebin.JSONFetchTextPath: "JSONFetchTextPath", 38 } 39 40 // ComparisonOpName is a mapping from all comparison operators that are 41 // supported by the vectorized engine to their names. 42 var ComparisonOpName = map[treecmp.ComparisonOperatorSymbol]string{ 43 treecmp.EQ: "EQ", 44 treecmp.NE: "NE", 45 treecmp.LT: "LT", 46 treecmp.LE: "LE", 47 treecmp.GT: "GT", 48 treecmp.GE: "GE", 49 }