cesium-native icon indicating copy to clipboard operation
cesium-native copied to clipboard

Replace std::unordered_map and std::map with Parallel Hashmap

Open joseph-kaile opened this issue 3 years ago • 16 comments

Trying to fix #375.

Conclusion: Testing with upsampleGltfForRasterOverlays, there is an improvement (like 10%). In upsampling OSM buildings, when the file sizes can get up to 3 megabytes, the discrepancy is higher, maybe around 25% faster.

However, in this test,

  Model model;

  long long total_count = 0;

  const int size = 10000000;

  std::vector<std::byte> bigVector;

  for (int i = 0; i < size; i++) {
    bigVector.push_back(std::byte(23));
  }

  auto start = high_resolution_clock::now();
  for (int i = 0; i < 1000; i++) {
    // create buffer
    model.buffers.emplace_back();
    Buffer& buffer = model.buffers.back();
    buffer.cesium.data.resize(size);
    std::memcpy(buffer.cesium.data.data(), bigVector.data(), bigVector.size());
  }
  auto stop = high_resolution_clock::now();

  auto duration = duration_cast<microseconds>(stop - start);
  total_count += duration.count();

  std::cout << "duration: " << total_count << std::endl;


}

the phmap is over 10x faster, 2,712,062 microseconds vs 32,561,647 microseconds

joseph-kaile avatar Aug 04 '22 22:08 joseph-kaile

According to this link (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90415), G++ version 9 is unable to compile std::any in a tuple but is able to compile std::experimental::any.

joseph-kaile avatar Aug 06 '22 19:08 joseph-kaile

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Sep 10 '22 02:09 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Oct 10 '22 02:10 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Nov 09 '22 03:11 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Dec 09 '22 03:12 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jan 08 '23 03:01 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Feb 07 '23 03:02 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Mar 09 '23 03:03 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Apr 08 '23 02:04 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar May 08 '23 02:05 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jun 07 '23 02:06 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jul 07 '23 02:07 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Aug 06 '23 02:08 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Sep 05 '23 02:09 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Oct 05 '23 02:10 cesium-concierge

Thanks again for your contribution @joseph-kaile!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Nov 04 '23 02:11 cesium-concierge