|
31 | 31 | // Check if we have a verified version: this is the hot path.
|
32 | 32 | let memo_guard = self.get_memo_from_table_for(zalsa, id, memo_ingredient_index);
|
33 | 33 | if let Some(memo) = memo_guard {
|
34 |
| - if self.shallow_verify_memo(db, zalsa, database_key_index, memo) { |
| 34 | + if self.shallow_verify_memo(zalsa, database_key_index, memo) { |
35 | 35 | return if memo.revisions.changed_at > revision {
|
36 | 36 | MaybeChangedAfter::Yes
|
37 | 37 | } else {
|
@@ -118,7 +118,6 @@ where
|
118 | 118 | #[inline]
|
119 | 119 | pub(super) fn shallow_verify_memo(
|
120 | 120 | &self,
|
121 |
| - db: &C::DbView, |
122 | 121 | zalsa: &Zalsa,
|
123 | 122 | database_key_index: DatabaseKeyIndex,
|
124 | 123 | memo: &Memo<C::Output<'_>>,
|
@@ -146,13 +145,8 @@ where
|
146 | 145 | );
|
147 | 146 | if last_changed <= verified_at {
|
148 | 147 | // No input of the suitable durability has changed since last verified.
|
149 |
| - memo.mark_as_verified( |
150 |
| - db, |
151 |
| - revision_now, |
152 |
| - database_key_index, |
153 |
| - memo.revisions.accumulated_inputs.load(), |
154 |
| - ); |
155 |
| - memo.mark_outputs_as_verified(zalsa, db.as_dyn_database(), database_key_index); |
| 148 | + memo.mark_as_verified(revision_now, memo.revisions.accumulated_inputs.load()); |
| 149 | + memo.mark_outputs_as_verified(zalsa, database_key_index); |
156 | 150 | return true;
|
157 | 151 | }
|
158 | 152 |
|
@@ -181,7 +175,7 @@ where
|
181 | 175 | old_memo = old_memo.tracing_debug()
|
182 | 176 | );
|
183 | 177 |
|
184 |
| - if self.shallow_verify_memo(db, zalsa, database_key_index, old_memo) { |
| 178 | + if self.shallow_verify_memo(zalsa, database_key_index, old_memo) { |
185 | 179 | return true;
|
186 | 180 | }
|
187 | 181 |
|
@@ -241,16 +235,12 @@ where
|
241 | 235 | // by this function cannot be read until this function is marked green,
|
242 | 236 | // so even if we mark them as valid here, the function will re-execute
|
243 | 237 | // and overwrite the contents.
|
244 |
| - dependency_index.mark_validated_output( |
245 |
| - zalsa, |
246 |
| - dyn_db, |
247 |
| - database_key_index, |
248 |
| - ); |
| 238 | + dependency_index.mark_validated_output(zalsa, database_key_index); |
249 | 239 | }
|
250 | 240 | }
|
251 | 241 | }
|
252 | 242 |
|
253 |
| - old_memo.mark_as_verified(db, zalsa.current_revision(), database_key_index, inputs); |
| 243 | + old_memo.mark_as_verified(zalsa.current_revision(), inputs); |
254 | 244 | true
|
255 | 245 | }
|
256 | 246 | }
|
|
0 commit comments