[Vulkan][32-bit] non-dispatchable handles do not fit in void* on i586
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 55/100
Línea de trabajo
Comienza en src/vt/vulkan/vulkan_context.cpp siguiendo las aserciones estáticas de VkBuffer y VkDeviceMemory; después inspecciona las rutas Pack/Unpack y los campos públicos del contexto del backend que almacenan estos handles. Compila v0.0.2 con -DVLLM_CPP_VULKAN=ON en i586; el trabajo estará terminado cuando el backend de Vulkan compile sin pasar handles no despachables a través de void*.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem
The Vulkan backend does not compile on 32-bit x86/i586. In src/vt/vulkan/vulkan_context.cpp, it asserts that Vulkan handles fit in void*:
static_assert(sizeof(VkBuffer) <= sizeof(void*), "VkBuffer must fit in void*");
static_assert(sizeof(VkDeviceMemory) <= sizeof(void*), "VkDeviceMemory must fit in void*");
With the Vulkan headers on i586, the assertions fail because the comparison is 8 <= 4. Vulkan non-dispatchable handles such as VkBuffer and VkDeviceMemory are 64-bit values even when the host pointer size is 32-bit.
The backend then packs these handles through void* in Pack/Unpack, and the public backend context stores buffer and memory handles as void*, so simply removing the assertions would not be sufficient.
Reproducer
Build v0.0.2 on i586 with:
-DVLLM_CPP_VULKAN=ON
The build fails in src/vt/vulkan/vulkan_context.cpp with:
error: static assertion failed: VkBuffer must fit in void*
the comparison reduces to (8 <= 4)
error: static assertion failed: VkDeviceMemory must fit in void*
the comparison reduces to (8 <= 4)
Proposed direction
Use an architecture-independent opaque handle representation, such as a dedicated 64-bit storage type for non-dispatchable handles, and avoid packing them into void*. Dispatchable pointer handles can remain pointer-sized.
The openSUSE package currently disables the Vulkan backend on 32-bit x86 as a downstream workaround.
- Lenguaje dominante
- C++
- Estrellas
- 423
- Forks
- 53
- Merge medio
- 1 d 5 h
- PR fusionados (30 d)
- 376
Preparar el entorno
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de mudler/vllm.cpp
-
[Windows] full build fails in tools/bench/conv1d_scaling_probe.cpp (POSIX-only sys/resource.h)Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
Todos los issues de mudler/vllm.cpp
Issues similares
-
Dificultad 2/5 Medio día Aptitud para principiantes 84/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 88/100
ROCm/rocm-libraries#12703 ·
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 1/5 1-3 horas Aptitud para principiantes 88/100
isl-org/Open3D#7585 · 1 comentario ·
Los mantenedores suelen responder en 2 días
-
Feature request
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
qbittorrent/qBittorrent#24975 ·
Los mantenedores suelen responder en 3 días