This commit is contained in:
Dobromir Popov
2025-09-05 08:49:25 +03:00
parent 614c390692
commit e0c0d886f6
3 changed files with 75 additions and 195 deletions

View File

@@ -5,8 +5,9 @@
using namespace std;
// Let's use a pinned memory vector!
#include <thrust/host_vector.h>
#include <thrust/system/cuda/experimental/pinned_allocator.h>
// Removed Thrust pinned allocator dependency for portability
// #include <thrust/host_vector.h>
// #include <thrust/system/cuda/experimental/pinned_allocator.h>
using u32 = uint32_t;
using u64 = uint64_t;
@@ -228,10 +229,8 @@ void Chunk::compress_chunk(u32 out_flags) {
}
}
using thrust_vector = thrust::host_vector<
Chunk,
thrust::system::cuda::experimental::pinned_allocator<Chunk>
>;
// Fallback alias: use std::vector instead of thrust pinned host vector
using thrust_vector = std::vector<Chunk>;
// The GPU hasher
void light_hash(Chunk*, int, Chunk*, Chunk*);