-
Notifications
You must be signed in to change notification settings - Fork 406
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build: Replace robin-hood-hashing with unordered_dense #7558
base: main
Are you sure you want to change the base?
Conversation
CI Vulkan-ValidationLayers build queued with queue ID 137774. |
CI Vulkan-ValidationLayers build # 15859 running. |
0a82f7c
to
1b97cd3
Compare
CI Vulkan-ValidationLayers build queued with queue ID 137784. |
CI Vulkan-ValidationLayers build # 15860 running. |
@@ -667,7 +667,7 @@ std::vector<VkPresentModeKHR> Surface::GetPresentModes(VkPhysicalDevice phys_dev | |||
assert(phys_dev); | |||
std::vector<VkPresentModeKHR> result; | |||
if (auto search = present_modes_data_.find(phys_dev); search != present_modes_data_.end()) { | |||
for (auto mode = search->second.begin(); mode != search->second.end(); mode++) { | |||
for (auto mode = search->second.begin(); mode != search->second.end(); ++mode) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jeremyg-lunarg so this is the type of issue failing the build before 😆
CI Vulkan-ValidationLayers build # 15860 failed. |
1b97cd3
to
5257776
Compare
CI Vulkan-ValidationLayers build queued with queue ID 138426. |
CI Vulkan-ValidationLayers build # 15875 running. |
5257776
to
bf60c81
Compare
CI Vulkan-ValidationLayers build queued with queue ID 138471. |
CI Vulkan-ValidationLayers build # 15877 running. |
bf60c81
to
13deb08
Compare
CI Vulkan-ValidationLayers build queued with queue ID 138518. |
CI Vulkan-ValidationLayers build # 15878 running. |
CI Vulkan-ValidationLayers build # 15878 passed. |
CI Vulkan-ValidationLayers build queued with queue ID 139599. |
CI Vulkan-ValidationLayers build # 15895 running. |
164554d
to
70f3a2d
Compare
CI Vulkan-ValidationLayers build queued with queue ID 139628. |
CI Vulkan-ValidationLayers build # 15897 running. |
CI Vulkan-ValidationLayers build # 15897 passed. |
70f3a2d
to
eb4e48d
Compare
CI Vulkan-ValidationLayers build queued with queue ID 144130. |
CI Vulkan-ValidationLayers build # 16004 running. |
CI Vulkan-ValidationLayers build # 16004 passed. |
if (USE_ROBIN_HOOD_HASHING) | ||
target_link_libraries(VkLayer_utils PUBLIC robin_hood::robin_hood) | ||
target_compile_definitions(VkLayer_utils PUBLIC USE_ROBIN_HOOD_HASHING) | ||
find_package(unordered_dense CONFIG) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Switching from USE_ROBIN_...* to USE_UNORDERED_* is going to require changes in Internal CI and the SDK build stuff. I wonder if we should do something like USE_CUSTOM_HASHMAP instead in case we ever decide to change implementations again. Curious what others think about this...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea I think. I only used this name in replacement of the C++ define, explicit mentions of unordered dense are still there in files like vvl.yml
CI Vulkan-ValidationLayers build queued with queue ID 145333. |
CI Vulkan-ValidationLayers build # 16031 running. |
CI Vulkan-ValidationLayers build # 16031 passed. |
From what I understand original robin-hood library implements drop-in replacement of std::unordered{map/set}. The new library ignores std iterator validity requirements, for performance reasons (please correct me early, since I did not dig deep into this). My question how we should support switching between std and custom library? With robin-hood it was easy because the interfaces were compatible. With new library it's possible to write code that won't work correctly with std (but you might want it because that's the reason why new lib is faster). Is it a valid concern? Are there use cases that require hash container from a standard stl implementation, so we need to support both options? |
331faa2
to
d032769
Compare
CI Vulkan-ValidationLayers build queued with queue ID 149495. |
CI Vulkan-ValidationLayers build # 16107 running. |
CI Vulkan-ValidationLayers build # 16107 passed. |
d032769
to
4f7ccb9
Compare
CI Vulkan-ValidationLayers build queued with queue ID 150694. |
CI Vulkan-ValidationLayers build # 16131 running. |
CI Vulkan-ValidationLayers build # 16131 passed. |
Would it make sense to error out (or emit some warning) if For example: https://github.com/msys2/MINGW-packages/blob/master/mingw-w64-vulkan-validation-layers/PKGBUILD#L68 |
I agree, @arno-lunarg just add if (USE_ROBIN_HOOD_HASHING)
message(WARNING "USE_ROBIN_HOOD_HASHING was removed, please use USE_CUSTOM_HASH_MAP now .")
endif () |
nit: there is an extraneous space before the ending colon.
|
robin-hood-hashing is no longer developed. unordered_dense is its replacement, by the same author.
4f7ccb9
to
90b6179
Compare
CI Vulkan-ValidationLayers build queued with queue ID 151977. |
CI Vulkan-ValidationLayers build # 16141 running. |
CI Vulkan-ValidationLayers build # 16141 aborted. |
CI Vulkan-ValidationLayers build queued with queue ID 152168. |
CI Vulkan-ValidationLayers build # 16150 running. |
CI Vulkan-ValidationLayers build # 16150 failed. |
CI Vulkan-ValidationLayers build queued with queue ID 152212. |
CI Vulkan-ValidationLayers build # 16153 running. |
CI Vulkan-ValidationLayers build queued with queue ID 152239. |
CI Vulkan-ValidationLayers build # 16155 running. |
CI Vulkan-ValidationLayers build # 16155 passed. |
Follow up to #7473
Code is not compiling when using
ankerl::unordered_dense::map
, but does when usingankerl::unordered_dense::segmented_map
(locally, on windows), a version that better mitigates memory allocation made when adding new elements. This is also a goal, next step is to measure if it indeed improves our memory footprint when initializing static maps.