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

build: bump toolchain to nightly-2024-03-12 #15722

Merged
merged 45 commits into from
May 15, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
3f47d55
fix use of btree cursor api
stdrc Feb 1, 2024
0ef75ea
remove stablized features
xxchan Feb 3, 2024
02c9d5d
update is_sorted_by api
xxchan Feb 3, 2024
bdca242
trigger ci on push
xxchan Feb 3, 2024
2a6cb2a
fix split_array and btree_cursors
xxchan Feb 3, 2024
427d75e
fix btree_cursor for over_window
xxchan Feb 3, 2024
0d4316a
bump hashbrown, ahash, crc32c, curve25519-dalek to fix SIMD
xxchan Feb 23, 2024
e5a4a97
fix "non-defining opaque type use in defining scope" in metrics
xxchan Mar 17, 2024
601e35e
bump
xxchan Mar 17, 2024
6c1cfc5
fix storage compile error according to the compiler's suggestion (I H…
xxchan Mar 18, 2024
03d923e
Merge remote-tracking branch 'origin/main' into xxchan/latest-nightly…
MrCroxx Apr 11, 2024
d55b9f7
fix: upgrade jsonbb to fix panic
MrCroxx Apr 11, 2024
5263667
Merge remote-tracking branch 'origin/main' into xxchan/latest-nightly…
MrCroxx Apr 11, 2024
2316d96
chore: remove reduntant uses
MrCroxx Apr 11, 2024
6281c7d
chore: fix more fmt`
MrCroxx Apr 11, 2024
b450502
chore: i mean, more
MrCroxx Apr 11, 2024
0372b40
chore: fix more
MrCroxx Apr 11, 2024
2d86e89
chore: bump toolchain to nightly-2024-04-12
MrCroxx Apr 12, 2024
819cbca
remove stable feature `associated_type_bounds`
stdrc Apr 16, 2024
a897e54
fix btree cursor use in over_partition
stdrc Apr 16, 2024
ef6eb21
fix lints
xxchan Apr 18, 2024
d4dbe20
Merge branch 'main' into xxchan/latest-nightly-rust
xxchan Apr 18, 2024
84d7681
lint
xxchan Apr 18, 2024
e87c4e0
resolve comment
xxchan Apr 18, 2024
2df472a
bump ci image
xxchan Apr 18, 2024
802ff0e
lint
xxchan Apr 18, 2024
e663132
fix
xxchan Apr 18, 2024
50600bf
fix GHA disk out of space
xxchan Apr 19, 2024
9cb8888
update madsim
wangrunji0408 Apr 19, 2024
f684b05
Merge branch 'main' into xxchan/latest-nightly-rust
xxchan Apr 21, 2024
210ea3b
fix clippy
xxchan Apr 22, 2024
6689da1
more recent toolchain
xxchan Apr 22, 2024
59fa2e0
chore: try something new
MrCroxx Apr 24, 2024
a9ffd0d
downgrade to 2024-03-12
bakjos May 14, 2024
237219b
Merge branch 'main' into xxchan/latest-nightly-rust
xxchan May 14, 2024
955ee2b
fix lints
xxchan May 14, 2024
85bcba8
Merge branch 'main' into xxchan/latest-nightly-rust
xxchan May 14, 2024
ed09ac7
fix lints
xxchan May 14, 2024
9cc432a
fix dylint
xxchan May 14, 2024
f24e0d2
fix dylint
xxchan May 14, 2024
3b4259d
fix lint
xxchan May 14, 2024
9efed19
fix lints
xxchan May 14, 2024
8a9b4a8
one last fix
xxchan May 14, 2024
723e23a
fix test
zwang28 May 15, 2024
c0df28b
fix test
wangrunji0408 May 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/nightly-rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ name: Build with Latest Nightly Rust
on:
schedule:
- cron: "0 0 * * *"
push:
branches:
- xxchan/latest-nightly-rust
workflow_dispatch:

jobs:
Expand Down
2 changes: 0 additions & 2 deletions src/batch/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,11 @@
#![feature(is_sorted)]
#![recursion_limit = "256"]
#![feature(let_chains)]
#![feature(bound_map)]
#![feature(int_roundings)]
#![feature(allocator_api)]
#![feature(impl_trait_in_assoc_type)]
#![feature(assert_matches)]
#![feature(lazy_cell)]
#![feature(array_methods)]
#![feature(error_generic_member_access)]

pub mod error;
Expand Down
6 changes: 5 additions & 1 deletion src/common/src/estimate_size/collections/btreemap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,11 @@ where

// [ left, [mid], right ]
let mut mid_right = self.inner.split_off(start);
let mid_right_split_key = mid_right.lower_bound(Bound::Excluded(end)).key().cloned();
let mid_right_split_key = mid_right
.lower_bound(Bound::Excluded(end))
.peek_next()
.map(|(k, _)| k)
.cloned();
let right = if let Some(ref mid_right_split_key) = mid_right_split_key {
mid_right.split_off(mid_right_split_key)
} else {
Expand Down
3 changes: 0 additions & 3 deletions src/common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,12 @@
#![feature(inline_const_pat)]
#![allow(incomplete_features)]
#![feature(iterator_try_collect)]
#![feature(round_ties_even)]
#![feature(iter_order_by)]
#![feature(exclusive_range_pattern)]
#![feature(binary_heap_into_iter_sorted)]
#![feature(impl_trait_in_assoc_type)]
#![feature(map_entry_replace)]
#![feature(negative_impls)]
#![feature(bound_map)]
#![feature(array_methods)]
#![feature(btree_cursors)]

#[cfg_attr(not(test), allow(unused_extern_crates))]
Expand Down
1 change: 0 additions & 1 deletion src/expr/impl/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
#![feature(iterator_try_collect)]
#![feature(exclusive_range_pattern)]
#![feature(lazy_cell)]
#![feature(round_ties_even)]
#![feature(coroutines)]
#![feature(test)]
#![feature(iter_array_chunks)]
Expand Down
1 change: 0 additions & 1 deletion src/frontend/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
#![feature(impl_trait_in_assoc_type)]
#![feature(result_flattening)]
#![feature(error_generic_member_access)]
#![feature(round_ties_even)]
#![feature(iterator_try_collect)]
#![feature(used_with_arg)]
#![recursion_limit = "256"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1224,13 +1224,7 @@ pub fn validate_version(version: &HummockVersion) -> Vec<String> {
let mut prev_table_info: Option<&SstableInfo> = None;
for table_info in &level.table_infos {
// Ensure table_ids are sorted and unique
if !table_info.table_ids.is_sorted_by(|a, b| {
if a < b {
Some(Ordering::Less)
} else {
Some(Ordering::Greater)
}
}) {
if !table_info.table_ids.is_sorted_by(|a, b| a < b) {
res.push(format!(
"{} SST {}: table_ids not sorted",
level_identifier, table_info.object_id
Expand Down
6 changes: 5 additions & 1 deletion src/storage/hummock_sdk/src/key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,11 @@ impl<T: AsRef<[u8]>> TableKey<T> {
"too short table key: {:?}",
self.0.as_ref()
);
let (vnode, inner_key) = self.0.as_ref().split_array_ref::<{ VirtualNode::SIZE }>();
let (vnode, inner_key) = self
.0
.as_ref()
.split_first_chunk::<{ VirtualNode::SIZE }>()
.unwrap();
(VirtualNode::from_be_bytes(*vnode), inner_key)
}

Expand Down
2 changes: 0 additions & 2 deletions src/storage/hummock_sdk/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,11 @@
#![feature(hash_extract_if)]
#![feature(lint_reasons)]
#![feature(map_many_mut)]
#![feature(bound_map)]
#![feature(type_alias_impl_trait)]
#![feature(impl_trait_in_assoc_type)]
#![feature(is_sorted)]
#![feature(let_chains)]
#![feature(btree_cursors)]
#![feature(split_array)]

mod key_cmp;
use std::cmp::Ordering;
Expand Down
13 changes: 4 additions & 9 deletions src/storage/hummock_sdk/src/table_watermark.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

use std::cmp::Ordering;
use std::collections::hash_map::Entry;
use std::collections::{btree_map, BTreeMap, HashMap, HashSet};
use std::mem::size_of;
Expand Down Expand Up @@ -93,7 +92,8 @@ impl TableWatermarksIndex {
self.index.get(&vnode).and_then(|epoch_watermarks| {
epoch_watermarks
.upper_bound(Included(&epoch))
.value()
.peek_next()
.map(|(_, v)| v)
stdrc marked this conversation as resolved.
Show resolved Hide resolved
.cloned()
})
}
Expand Down Expand Up @@ -554,13 +554,8 @@ impl TableWatermarks {
// epoch watermark are added from later epoch to earlier epoch.
// reverse to ensure that earlier epochs are at the front
result_epoch_watermark.reverse();
assert!(
result_epoch_watermark.is_sorted_by(|(first_epoch, _), (second_epoch, _)| {
let ret = first_epoch.cmp(second_epoch);
assert_ne!(ret, Ordering::Equal);
Some(ret)
})
);
assert!(result_epoch_watermark
.is_sorted_by(|(first_epoch, _), (second_epoch, _)| { first_epoch < second_epoch }));
*self = TableWatermarks {
watermarks: result_epoch_watermark,
direction: self.direction,
Expand Down
1 change: 0 additions & 1 deletion src/storage/hummock_test/src/bin/replay/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.

#![feature(bound_map)]
#![feature(coroutines)]
#![feature(stmt_expr_attributes)]
#![feature(proc_macro_hygiene)]
Expand Down
1 change: 0 additions & 1 deletion src/storage/hummock_test/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#![feature(proc_macro_hygiene, stmt_expr_attributes)]
#![feature(custom_test_frameworks)]
#![test_runner(risingwave_test_runner::test_runner::run_failpont_tests)]
#![feature(bound_map)]
#![feature(type_alias_impl_trait)]
#![feature(associated_type_bounds)]

Expand Down
1 change: 0 additions & 1 deletion src/storage/hummock_trace/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

#![feature(lazy_cell)]
#![feature(cursor_remaining)]
#![feature(bound_map)]
#![feature(trait_alias)]
#![feature(coroutines)]

Expand Down
2 changes: 1 addition & 1 deletion src/storage/src/hummock/store/version.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ impl StagingSstableInfo {
imm_size: usize,
) -> Self {
// the epochs are sorted from higher epoch to lower epoch
assert!(epochs.is_sorted_by(|epoch1, epoch2| epoch2.partial_cmp(epoch1)));
assert!(epochs.is_sorted_by(|epoch1, epoch2| epoch2 <= epoch1));
Self {
sstable_infos,
epochs,
Expand Down
1 change: 0 additions & 1 deletion src/storage/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

#![feature(allocator_api)]
#![feature(bound_as_ref)]
#![feature(bound_map)]
#![feature(custom_test_frameworks)]
#![feature(extract_if)]
#![feature(coroutines)]
Expand Down
1 change: 0 additions & 1 deletion src/stream/spill_test/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
// limitations under the License.
#![feature(proc_macro_hygiene, stmt_expr_attributes)]
#![feature(custom_test_frameworks)]
#![feature(bound_map)]
#![feature(type_alias_impl_trait)]
#![feature(associated_type_bounds)]

Expand Down
38 changes: 19 additions & 19 deletions src/stream/src/executor/over_window/over_partition.rs
stdrc marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -90,25 +90,25 @@ pub(super) fn shrink_partition_cache(

let mut cursor = range_cache.inner().upper_bound(Bound::Excluded(&ck_start));
for _ in 0..MAGIC_JITTER_PREVENTION {
if cursor.key().is_none() {
if cursor.prev().is_none() {
break;
}
cursor.move_prev();
}
let start = cursor
.key()
.peek_prev()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.first_key_value().unwrap().0)
.clone();

let mut cursor = range_cache.inner().lower_bound(Bound::Excluded(&ck_end));
let mut cursor = range_cache.inner().lower_bound(Bound::Included(&ck_start));
for _ in 0..MAGIC_JITTER_PREVENTION {
if cursor.key().is_none() {
if cursor.next().is_none() {
break;
}
cursor.move_next();
}
let end = cursor
.key()
.peek_next()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.last_key_value().unwrap().0)
.clone();

Expand All @@ -127,27 +127,27 @@ pub(super) fn shrink_partition_cache(
let mut cursor = range_cache.inner().upper_bound(Bound::Excluded(&ck_start));
// go back for at most `MAGIC_JITTER_PREVENTION` entries
for _ in 0..MAGIC_JITTER_PREVENTION {
if cursor.key().is_none() {
if cursor.prev().is_none() {
break;
}
cursor.move_prev();
capacity_remain -= 1;
}
let start = cursor
.key()
.peek_prev()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.first_key_value().unwrap().0)
.clone();

let mut cursor = range_cache.inner().lower_bound(Bound::Included(&ck_start));
// go forward for at most `capacity_remain` entries
for _ in 0..capacity_remain {
if cursor.key().is_none() {
if cursor.next().is_none() {
break;
}
cursor.move_next();
}
let end = cursor
.key()
.peek_next()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.last_key_value().unwrap().0)
.clone();

Expand All @@ -167,27 +167,27 @@ pub(super) fn shrink_partition_cache(
let mut cursor = range_cache.inner().lower_bound(Bound::Excluded(&ck_end));
// go forward for at most `MAGIC_JITTER_PREVENTION` entries
for _ in 0..MAGIC_JITTER_PREVENTION {
if cursor.key().is_none() {
if cursor.next().is_none() {
break;
}
cursor.move_next();
capacity_remain -= 1;
}
let end = cursor
.key()
.peek_next()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.last_key_value().unwrap().0)
.clone();

let mut cursor = range_cache.inner().upper_bound(Bound::Included(&ck_end));
// go back for at most `capacity_remain` entries
for _ in 0..capacity_remain {
if cursor.key().is_none() {
if cursor.prev().is_none() {
break;
}
cursor.move_prev();
}
let start = cursor
.key()
.peek_prev()
.map(|(k, _)| k)
.unwrap_or_else(|| range_cache.first_key_value().unwrap().0)
.clone();

Expand Down
1 change: 0 additions & 1 deletion src/stream/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
#![feature(lazy_cell)]
#![feature(error_generic_member_access)]
#![feature(btree_extract_if)]
#![feature(bound_map)]
#![feature(iter_order_by)]
#![feature(exact_size_is_empty)]
#![feature(impl_trait_in_assoc_type)]
Expand Down
1 change: 0 additions & 1 deletion src/tests/compaction_test/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
#![warn(clippy::map_flatten)]
#![warn(clippy::await_holding_lock)]
#![deny(rustdoc::broken_intra_doc_links)]
#![feature(bound_map)]
#![feature(register_tool)]
#![register_tool(rw)]
#![allow(rw::format_error)] // test code
Expand Down
Loading