Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

expression: implement vectorized evaluation for builtinNameConstJSONSig #13384

Merged
merged 13 commits into from
Nov 18, 2019
4 changes: 2 additions & 2 deletions expression/builtin_miscellaneous_vec.go
Original file line number Diff line number Diff line change
Expand Up @@ -324,11 +324,11 @@ func (b *builtinNameConstDecimalSig) vecEvalDecimal(input *chunk.Chunk, result *
}

func (b *builtinNameConstJSONSig) vectorized() bool {
return false
return true
}

func (b *builtinNameConstJSONSig) vecEvalJSON(input *chunk.Chunk, result *chunk.Column) error {
return errors.Errorf("not implemented")
return b.args[1].VecEvalJSON(b.ctx, input, result)
}

func (b *builtinInet6AtonSig) vectorized() bool {
Expand Down
1 change: 1 addition & 0 deletions expression/builtin_miscellaneous_vec_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ var vecBuiltinMiscellaneousCases = map[string][]vecExprBenchCase{
{retEvalType: types.ETDecimal, childrenTypes: []types.EvalType{types.ETString, types.ETDecimal}},
{retEvalType: types.ETInt, childrenTypes: []types.EvalType{types.ETString, types.ETInt}},
{retEvalType: types.ETReal, childrenTypes: []types.EvalType{types.ETString, types.ETReal}},
{retEvalType: types.ETJSON, childrenTypes: []types.EvalType{types.ETString, types.ETJSON}},
qw4990 marked this conversation as resolved.
Show resolved Hide resolved
{retEvalType: types.ETTimestamp, childrenTypes: []types.EvalType{types.ETString, types.ETTimestamp}},
},
}
Expand Down