Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

It's impossible to bind to a host memory which is not coherent.

Đang mở
#85 5 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
45/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
rust
Lĩnh vực
computer-graphics

Hướng nghiên cứu

Bắt đầu từ các triển khai của Allocator::allocate và Allocator::new, lần theo việc lựa chọn thuộc tính bộ nhớ của MemoryLocation::CpuToGpu và kiểm tra host_visible_not_coherent. Xác nhận các yêu cầu về thuộc tính bộ nhớ của Vulkan, sau đó kiểm tra rằng host-visible, non-coherent memory có thể được chọn mà không làm hỏng nhánh lỗi hiện có đối với bộ nhớ tương thích.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Hi.

Maybe I'm wrong but when I look into the Allocator implementation I see the following in the Allocator::allocate method:

  • If MemoryLocation::CpuToGpu was specified the function tries to find a memory type index for the preferred bits vk::MemoryPropertyFlags::HOST_VISIBLE | vk::MemoryPropertyFlags::HOST_COHERENT | vk::MemoryPropertyFlags::HOST_CACHED.
  • If the previous attempt failed the function tries to find a memory type index for the required bits vk::MemoryPropertyFlags::HOST_VISIBLE | vk::MemoryPropertyFlags::HOST_COHERENT.
  • If the second attempt fails the function returns Err(AllocationError::NoCompatibleMemoryTypeFound).

So there's no chance to allocate a host visible, non-coherent memory.

Also, in Allocator::new, there's no need to check for host_visible_not_coherent. From the Spec 11.2.1. Device Memory Properties:

There must be at least one memory type with both the VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT and VK_MEMORY_PROPERTY_HOST_COHERENT_BIT bits set in its propertyFlags.

Ngôn ngữ chính
Rust
Star
499
Fork
85
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của Traverse-Research/gpu-allocator

Tất cả issue của Traverse-Research/gpu-allocator

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.