Lines Matching refs:tgt
241 def __init__(self, tgt, src=None, threads=None, version=4, argument
260 self.tgt = tgt
266 assert tgt.blocksize == 4096
272 self.AssertPartition(tgt.care_map, tgt.file_map.values())
349 common.OPTIONS.stash_threshold / self.tgt.blocksize)
532 assert max_stashed_blocks * self.tgt.blocksize <= max_allowed, \
534 max_stashed_blocks * self.tgt.blocksize, max_stashed_blocks,
535 self.tgt.blocksize, max_allowed, cache_size,
540 if self.tgt.hashtree_info:
542 self.tgt.hashtree_info.hashtree_range.to_string_raw(),
543 self.tgt.hashtree_info.filesystem_range.to_string_raw(),
544 self.tgt.hashtree_info.hash_algorithm,
545 self.tgt.hashtree_info.salt,
546 self.tgt.hashtree_info.root_hash))
549 if self.tgt.extended:
550 assert (WriteSplitTransfers(out, "zero", self.tgt.extended) ==
551 self.tgt.extended.size())
552 total += self.tgt.extended.size()
560 all_tgt = RangeSet(data=(0, self.tgt.total_blocks))
561 all_tgt_minus_extended = all_tgt.subtract(self.tgt.extended)
562 new_dontcare = all_tgt_minus_extended.subtract(self.tgt.care_map)
582 self._max_stashed_size = max_stashed_blocks * self.tgt.blocksize
630 max_allowed_blocks = cache_size * stash_threshold / self.tgt.blocksize
705 num_of_bytes = new_blocks * self.tgt.blocksize
719 tgt_size = xf.tgt_ranges.size() * self.tgt.blocksize
725 self.tgt.WriteRangeDataToFd(xf.tgt_ranges, new_f)
726 tgt_size = xf.tgt_ranges.size() * self.tgt.blocksize
745 tgt_size = xf.tgt_ranges.size() * self.tgt.blocksize
779 tgt_size = xf.tgt_ranges.size() * self.tgt.blocksize
796 tgt_sha1 = self.tgt.RangeSha1(xf.tgt_ranges)
808 touched = array.array("B", b"\0" * self.tgt.total_blocks)
822 for i in range(s, min(e, self.tgt.total_blocks)):
833 if self.tgt.hashtree_info:
834 for s, e in self.tgt.hashtree_info.hashtree_range:
840 for s, e in self.tgt.care_map:
1171 self.tgt.WriteRangeDataToFd(xf.tgt_ranges, fd)
1184 tgt_data = self.tgt.ReadRangeSet(xf.tgt_ranges)
1317 self.tgt.RangeSha1(tgt_first), self.src.RangeSha1(src_first),
1331 self.tgt.RangeSha1(tgt_ranges), self.src.RangeSha1(src_ranges),
1350 self.tgt.RangeSha1(tgt_ranges), self.src.RangeSha1(src_ranges),
1358 self.tgt.RangeSha1(tgt_ranges) != self.src.RangeSha1(src_ranges)):
1374 self.tgt.RangeSha1(tgt_ranges), self.src.RangeSha1(src_ranges),
1400 if self.src.ReadRangeSet(src_rs) == self.tgt.ReadRangeSet(tgt_rs):
1520 self.tgt.WriteRangeDataToFd(tgt_ranges, tgt_fd)
1563 self.tgt.blocksize)
1565 for tgt_fn, tgt_ranges in sorted(self.tgt.file_map.items()):
1624 self.tgt.RangeSha1(tgt_ranges),