Skip to content

Commit c8e90f7

Browse files
committed
Test
1 parent 0382d24 commit c8e90f7

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

include/cuco/detail/storage/flat_storage.inl

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -144,13 +144,12 @@ template <typename T, int32_t BucketSize, typename Extent>
144144
__device__ constexpr flat_storage_ref<T, BucketSize, Extent>::bucket_type
145145
flat_storage_ref<T, BucketSize, Extent>::operator[](size_type index) const noexcept
146146
{
147+
return *reinterpret_cast<bucket_type*>(this->data() + index);
147148
/*
148-
return *reinterpret_cast<bucket_type*>(
149-
__builtin_assume_aligned(this->data() + index, sizeof(value_type) * bucket_size));
150-
*/
151-
bucket_type res;
152-
memcpy(res.data(), this->data() + index, sizeof(value_type) * bucket_size);
153-
return res;
149+
bucket_type res;
150+
memcpy(res.data(), this->data() + index, sizeof(value_type) * bucket_size);
151+
return res;
152+
*/
154153
}
155154

156155
template <typename T, int32_t BucketSize, typename Extent>

0 commit comments

Comments
 (0)