Skip to content

Commit

Permalink
[VL] Daily Update Velox Version (2024_04_28) (#5558)
Browse files Browse the repository at this point in the history
* [VL] Daily Update Velox Version (2024_04_28)
Velox changes:
```
adc5219b5 by Jacob Wujciak-Jens, Fix workflow syntax for build-metrix.yml (9642)
47970417a by Yihong Wang, Add word_stem Presto function (9363)
6bcf11edd by Daniel Munoz, Fix bug in DwrfReader onRead
c2526ba83 by rui-mo, Throw user error for decimal overflow in decimal divide Presto function (9632)
f9c8fd4cb by PHILO-HE, Add year_of_week Spark function (9481)
029d89ab1 by xiaoxmeng, Prevent driver thread running again if task reclaim failed (9633)
959f939a1 by Jimmy Lu, Fix crash when map subfield is pruned but we still want to add non-null filter on its keys
97160cdc3 by xiaoxmeng, Avoid unnecessary memory capacity growth in case of concurrent arbitr… (9557)
32289f986 by Tengfei Huang, Add flatten Spark function (9593)
```
  • Loading branch information
GlutenPerfBot authored Apr 28, 2024
1 parent 26edf4f commit b62bc2f
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
7 changes: 7 additions & 0 deletions cpp/velox/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,13 @@ target_link_libraries(velox PUBLIC Folly::folly)
find_re2()
target_link_libraries(velox PUBLIC ${RE2_LIBRARY})

# since https://github.com/facebookincubator/velox/commit/47970417ac92135e862c0fde350d4d60fa2f1423
if(Stemmer_FOUND)
target_link_libraries(velox PUBLIC stemmer::stemmer)
else()
add_velox_dependency(velox "${VELOX_BUILD_PATH}/_deps/libstemmer/src/libstemmer/libstemmer.a")
endif()

if(ENABLE_GLUTEN_VCPKG)
find_package(Thrift CONFIG)
else()
Expand Down
13 changes: 12 additions & 1 deletion cpp/velox/memory/VeloxMemoryManager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,19 @@ class ListenableArbitrator : public velox::memory::MemoryArbitrator {

private:
uint64_t growPoolLocked(velox::memory::MemoryPool* pool, uint64_t bytes) {
// Since
// https://github.com/facebookincubator/velox/pull/9557/files#diff-436e44b7374032f8f5d7eb45869602add6f955162daa2798d01cc82f8725724dL812-L820,
// We should pass bytes as parameter "reservationBytes" when calling ::grow.
const uint64_t freeBytes = pool->freeBytes();
if (freeBytes >= bytes) {
bool reserved = pool->grow(0, bytes);
GLUTEN_CHECK(
reserved,
"Unexpected: Failed to reserve " + std::to_string(bytes) +
" bytes although there is enough space, free bytes: " + std::to_string(freeBytes));
}
listener_->allocationChanged(bytes);
return pool->grow(bytes);
return pool->grow(bytes, bytes);
}

uint64_t releaseMemoryLocked(velox::memory::MemoryPool* pool, uint64_t bytes) {
Expand Down
2 changes: 1 addition & 1 deletion ep/build-velox/src/get_velox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
set -exu

VELOX_REPO=https://github.com/oap-project/velox.git
VELOX_BRANCH=2024_04_26_2
VELOX_BRANCH=2024_04_28
VELOX_HOME=""

#Set on run gluten on HDFS
Expand Down

0 comments on commit b62bc2f

Please sign in to comment.