From 45ad345a09707f947b6ee7322488df85f2ae65a6 Mon Sep 17 00:00:00 2001 From: Robert Kruszewski Date: Wed, 17 Jul 2024 16:18:54 +0100 Subject: [PATCH] Debug compilation caching (#475) --- .github/actions/setup-python/action.yml | 6 ++++ .github/actions/setup-rust/action.yml | 1 + .github/workflows/ci.yml | 2 -- requirements-dev.lock | 1 + requirements.lock | 1 + vortex-array/src/array/struct_/compress.rs | 40 ---------------------- vortex-datafusion/src/eval.rs | 1 + 7 files changed, 10 insertions(+), 42 deletions(-) delete mode 100644 vortex-array/src/array/struct_/compress.rs diff --git a/.github/actions/setup-python/action.yml b/.github/actions/setup-python/action.yml index f62ea6c3cc..80197dc0d6 100644 --- a/.github/actions/setup-python/action.yml +++ b/.github/actions/setup-python/action.yml @@ -15,12 +15,18 @@ runs: path: ~/.rye key: "rye-${{ runner.os }}-${{ inputs.rye-version }}" + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.11.9' + - name: Rye Install shell: bash run: curl -sSf https://rye.astral.sh/get | bash if: steps.rye-cache.outputs.cache-hit != 'true' env: RYE_VERSION: "${{ inputs.rye-version }}" + RYE_TOOLCHAIN_VERSION: "3.11.9" RYE_INSTALL_OPTION: "--yes" - name: Rye Shims diff --git a/.github/actions/setup-rust/action.yml b/.github/actions/setup-rust/action.yml index ca1a860efd..45f96b3ddd 100644 --- a/.github/actions/setup-rust/action.yml +++ b/.github/actions/setup-rust/action.yml @@ -30,6 +30,7 @@ runs: echo "SCCACHE_GHA_ENABLED=true" >> $GITHUB_ENV echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV echo "CARGO_INCREMENTAL=0" >> $GITHUB_ENV + # echo "CARGO_LOG=cargo::core::compiler::fingerprint=info" >> $GITHUB_ENV - name: Download flatc shell: bash diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f7dca30f17..542431d6a7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,8 +16,6 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - with: - submodules: recursive - uses: ./.github/actions/cleanup diff --git a/requirements-dev.lock b/requirements-dev.lock index c5b17d839f..ece7184320 100644 --- a/requirements-dev.lock +++ b/requirements-dev.lock @@ -7,6 +7,7 @@ # all-features: false # with-sources: false # generate-hashes: false +# universal: false -e file:. -e file:pyvortex diff --git a/requirements.lock b/requirements.lock index cb652616f8..64a44c3203 100644 --- a/requirements.lock +++ b/requirements.lock @@ -7,6 +7,7 @@ # all-features: false # with-sources: false # generate-hashes: false +# universal: false -e file:. -e file:pyvortex diff --git a/vortex-array/src/array/struct_/compress.rs b/vortex-array/src/array/struct_/compress.rs deleted file mode 100644 index 3f267899e0..0000000000 --- a/vortex-array/src/array/struct_/compress.rs +++ /dev/null @@ -1,40 +0,0 @@ -use itertools::Itertools; -use vortex_error::VortexResult; - -use crate::array::downcast::DowncastArrayBuiltin; -use crate::array::struct_::{StructArray, StructEncoding}; -use crate::array::{Array, ArrayRef}; -use crate::compress::{CompressConfig, CompressCtx, EncodingCompression}; - -impl EncodingCompression for StructEncoding { - fn can_compress( - &self, - array: &dyn Array, - _config: &CompressConfig, - ) -> Option<&dyn EncodingCompression> { - (array.encoding().id() == Self::ID).then_some(self) - } - - fn compress( - &self, - array: &dyn Array, - like: Option<&dyn Array>, - ctx: CompressCtx, - ) -> VortexResult { - let struct_array = array.as_struct(); - let struct_like = like.map(|like_array| like_array.as_struct()); - - let fields = struct_array - .fields() - .iter() - .enumerate() - .map(|(i, chunk)| { - let like_chunk = struct_like.and_then(|c_like| c_like.fields().get(i)); - ctx.auxiliary(&format!("[{}]", i)) - .compress(chunk, like_chunk) - }) - .try_collect()?; - - Ok(StructArray::new(struct_array.names().clone(), fields, array.len()).into_array()) - } -} diff --git a/vortex-datafusion/src/eval.rs b/vortex-datafusion/src/eval.rs index 33a45b38d1..13edff96d4 100644 --- a/vortex-datafusion/src/eval.rs +++ b/vortex-datafusion/src/eval.rs @@ -1,4 +1,5 @@ use datafusion_expr::{Expr, Operator as DFOperator}; +use vortex::variants::StructArrayTrait; use vortex::{ array::{bool::BoolArray, constant::ConstantArray}, compute::compare,