Skip to content

Commit

Permalink
rocr: Fix HostQueue to obey the alignment requirement
Browse files Browse the repository at this point in the history
Change-Id: I06542e9ff94e826ca0abba0328b301fec50a95ea
  • Loading branch information
benvanik authored and dayatsin-amd committed Jan 24, 2025
1 parent 7ea25eb commit 7d64fe4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/hsa-runtime/core/inc/host_queue.h
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ class HostQueue : public Queue {
}

void* operator new(size_t size) {
return _aligned_malloc(size, HSA_QUEUE_ALIGN_BYTES);
return _aligned_malloc(AlignUp(size, HSA_QUEUE_ALIGN_BYTES), HSA_QUEUE_ALIGN_BYTES);
}

void* operator new(size_t size, void* ptr) { return ptr; }
Expand Down

0 comments on commit 7d64fe4

Please sign in to comment.