Skip to content

Commit

Permalink
dbg
Browse files Browse the repository at this point in the history
  • Loading branch information
philsippl committed Jul 25, 2024
1 parent 87f27bb commit ed80a56
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/dot/share_db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ impl ShareDB {
.alloc(max_size * IRIS_CODE_LENGTH)
.unwrap()
};
println!("db1 pointer for dev {}: {:#x}", idx, *slice.device_ptr() as u64);
println!("{}: db1 pointer for dev {}: {:#x}", self.peer_id, idx, *slice.device_ptr() as u64);

Check failure on line 473 in src/dot/share_db.rs

View workflow job for this annotation

GitHub Actions / clippy

casting to the same type is unnecessary (`u64` -> `u64`)

error: casting to the same type is unnecessary (`u64` -> `u64`) --> src/dot/share_db.rs:473:82 | 473 | println!("{}: db1 pointer for dev {}: {:#x}", self.peer_id, idx, *slice.device_ptr() as u64); | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `{ *slice.device_ptr() }` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast = note: `-D clippy::unnecessary-cast` implied by `-D warnings` = help: to override `-D warnings` add `#[allow(clippy::unnecessary_cast)]`
self.device_manager
.htod_copy_into(chunk.to_vec(), &mut slice, idx)
.unwrap();
Expand All @@ -487,7 +487,7 @@ impl ShareDB {
.alloc(max_size * IRIS_CODE_LENGTH)
.unwrap()
};
println!("db0 pointer for dev {}: {:#x}", idx, *slice.device_ptr() as u64);
println!("{}: db0 pointer for dev {}: {:#x}", self.peer_id, idx, *slice.device_ptr() as u64);

Check failure on line 490 in src/dot/share_db.rs

View workflow job for this annotation

GitHub Actions / clippy

casting to the same type is unnecessary (`u64` -> `u64`)

error: casting to the same type is unnecessary (`u64` -> `u64`) --> src/dot/share_db.rs:490:82 | 490 | println!("{}: db0 pointer for dev {}: {:#x}", self.peer_id, idx, *slice.device_ptr() as u64); | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `{ *slice.device_ptr() }` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
self.device_manager
.htod_copy_into(chunk.to_vec(), &mut slice, idx)
.unwrap();
Expand Down
12 changes: 8 additions & 4 deletions src/server/actor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,8 @@ impl ServerActor {
] {
unsafe {
println!(
"Inserting into db0 at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
"{}: Inserting into db0 at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
self.party_id,
*db.code_gr.limb_0[i].device_ptr(),
self.current_db_sizes[i] * IRIS_CODE_LENGTH,
*query.limb_0[i].device_ptr(),
Expand All @@ -704,7 +705,8 @@ impl ServerActor {
);

println!(
"Inserting into db1 at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
"{}: Inserting into db1 at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
self.party_id,
*db.code_gr.limb_1[i].device_ptr(),
self.current_db_sizes[i] * IRIS_CODE_LENGTH,
*query.limb_1[i].device_ptr(),
Expand All @@ -722,7 +724,8 @@ impl ServerActor {
);

println!(
"Inserting into db0_sums at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
"{}: Inserting into db0_sums at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
self.party_id,
*db.code_sums_gr.limb_0[i].device_ptr(),
self.current_db_sizes[i] * mem::size_of::<u32>(),
*sums.limb_0[i].device_ptr(),
Expand All @@ -742,7 +745,8 @@ impl ServerActor {
);

println!(
"Inserting into db1sums at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
"{}: Inserting into db1sums at {:#x} + {:#x} from {:#x} + {:#x} with len {:?}",
self.party_id,
*db.code_sums_gr.limb_1[i].device_ptr(),
self.current_db_sizes[i] * mem::size_of::<u32>(),
*sums.limb_1[i].device_ptr(),
Expand Down

0 comments on commit ed80a56

Please sign in to comment.