MCPcopy Create free account
hub / github.com/1a1a11a/libCacheSim / write_metadata

Method write_metadata

libCacheSim/dataStructure/sparsepp/spp.h:2356–2366  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2354
2355 template <typename OUTPUT>
2356 bool write_metadata(OUTPUT *fp) const
2357 {
2358 if (!write_32_or_64(fp, MAGIC_NUMBER)) return false;
2359 if (!write_32_or_64(fp, _table_size)) return false;
2360 if (!write_32_or_64(fp, _num_buckets)) return false;
2361
2362 for (const group_type *group = _first_group; group != _last_group; ++group)
2363 if (group->write_metadata(fp) == false)
2364 return false;
2365 return true;
2366 }
2367
2368 // Reading destroys the old table contents! Returns true if read ok.
2369 template <typename INPUT>

Callers

nothing calls this directly

Calls 1

write_metadataMethod · 0.45

Tested by

no test coverage detected