github-actions[bot] commented on code in PR #68930:
URL: https://github.com/apache/doris/pull/68930#discussion_r4244659449
##########
be/src/exprs/vliteral.cpp:
##########
@@ -100,8 +100,17 @@ bool VLiteral::equals(const VExpr& other) {
}
uint64_t VLiteral::get_digest(uint64_t seed) const {
- _column_ptr->update_xxHash_with_value(0, 1, seed, nullptr);
- return seed;
+ // ColumnComplexType does not implement xxHash, including when wrapped by
+ // ColumnNullable/ColumnConst. A zero digest disables the condition cache.
+ switch (_data_type->get_primitive_type()) {
+ case TYPE_BITMAP:
+ case TYPE_HLL:
+ case TYPE_QUANTILE_STATE:
+ return 0;
+ default:
Review Comment:
[P1] Cover every literal column without xxHash before hashing. The new
switch still falls through for `TYPE_VARBINARY`: `WHERE md5sum(X'61',
to_binary(CAST(id AS STRING))) <> ''` retains a VARBINARY literal, and
`ColumnVarbinary` inherits the throwing hash method. A folded `ARRAY<BITMAP>`
literal is built by `VArrayLiteral` and hashes its nested `ColumnBitmap`; a
typed NULL `AGG_STATE<sum(int not null)>` uses `ColumnFixedLengthObject`, which
also lacks xxHash. These row-dependent scan predicates fail while
`ScanLocalState` computes the digest with condition caching enabled. Return the
zero sentinel for these unsupported column shapes and cover each in tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]