Skip to content

Commit 3712c99

Browse files
authored
Remove dead code: timepoint_max (#10008)
Unused code.
1 parent 29eb895 commit 3712c99

File tree

5 files changed

+3
-25
lines changed

5 files changed

+3
-25
lines changed

crates/store/re_chunk/src/chunk.rs

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ use nohash_hasher::IntMap;
1515
use re_arrow_util::ArrowArrayDowncastRef as _;
1616
use re_byte_size::SizeBytes as _;
1717
use re_log_types::{
18-
EntityPath, NonMinI64, ResolvedTimeRange, TimeInt, TimePoint, TimeType, Timeline, TimelineName,
18+
EntityPath, NonMinI64, ResolvedTimeRange, TimeInt, TimeType, Timeline, TimelineName,
1919
};
2020
use re_types_core::{
2121
ArchetypeName, ComponentDescriptor, ComponentName, DeserializationError, Loggable as _,
@@ -1240,16 +1240,6 @@ impl Chunk {
12401240
pub fn components(&self) -> &ChunkComponents {
12411241
&self.components
12421242
}
1243-
1244-
/// Computes the maximum value for each and every timeline present across this entire chunk,
1245-
/// and returns the corresponding [`TimePoint`].
1246-
#[inline]
1247-
pub fn timepoint_max(&self) -> TimePoint {
1248-
self.timelines
1249-
.values()
1250-
.map(|info| (info.timeline, info.time_range.max()))
1251-
.collect()
1252-
}
12531243
}
12541244

12551245
impl std::fmt::Display for Chunk {

crates/store/re_chunk/src/transport.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,6 @@ impl Chunk {
242242
pub fn from_arrow_msg(msg: &re_log_types::ArrowMsg) -> ChunkResult<Self> {
243243
let re_log_types::ArrowMsg {
244244
chunk_id: _,
245-
timepoint_max: _,
246245
batch,
247246
on_release: _,
248247
} = msg;
@@ -256,8 +255,7 @@ impl Chunk {
256255
self.sanity_check()?;
257256

258257
Ok(re_log_types::ArrowMsg {
259-
chunk_id: re_tuid::Tuid::from_u128(self.id().as_u128()),
260-
timepoint_max: self.timepoint_max(),
258+
chunk_id: self.id().as_tuid(),
261259
batch: self.to_record_batch()?,
262260
on_release: None,
263261
})

crates/store/re_log_types/src/arrow_msg.rs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ use std::sync::Arc;
77

88
use arrow::array::RecordBatch as ArrowRecordBatch;
99

10-
use crate::TimePoint;
11-
1210
/// An arbitrary callback to be run when an [`ArrowMsg`], and more specifically the
1311
/// [`ArrowRecordBatch`] within it, goes out of scope.
1412
///
@@ -72,12 +70,6 @@ pub struct ArrowMsg {
7270
/// Unique identifier for the chunk in this message.
7371
pub chunk_id: re_tuid::Tuid,
7472

75-
/// The maximum values for all timelines across the entire batch of data.
76-
///
77-
/// Used to timestamp the batch as a whole for e.g. latency measurements without having to
78-
/// deserialize the arrow payload.
79-
pub timepoint_max: TimePoint,
80-
8173
/// Schema and data for all control & data columns.
8274
pub batch: ArrowRecordBatch,
8375

crates/store/re_log_types/src/lib.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -784,12 +784,11 @@ impl SizeBytes for ArrowMsg {
784784
fn heap_size_bytes(&self) -> u64 {
785785
let Self {
786786
chunk_id,
787-
timepoint_max,
788787
batch,
789788
on_release: _,
790789
} = self;
791790

792-
chunk_id.heap_size_bytes() + timepoint_max.heap_size_bytes() + batch.heap_size_bytes()
791+
chunk_id.heap_size_bytes() + batch.heap_size_bytes()
793792
}
794793
}
795794

crates/top/rerun/src/commands/rrd/migrate.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ fn migrate_from_to(from_path: &Utf8PathBuf, to_path: &Utf8PathBuf) -> anyhow::Re
120120
store_id,
121121
re_log_types::ArrowMsg {
122122
chunk_id: arrow_msg.chunk_id,
123-
timepoint_max: arrow_msg.timepoint_max.clone(),
124123
batch,
125124
on_release: None,
126125
},

0 commit comments

Comments
 (0)