Significant slowdown on large files
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Refactorización
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- cpp
- Área
- performance
Línea de trabajo
Start by locating happly's list-property storage and getListProperty API, then profile parsing of the Lucy model from the Stanford repo to confirm the vector-allocation cost. Done means reducing large-file slowdown while preserving the existing list-property APIs and adding the proposed preallocated-list access without breaking backward compatibility.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
The current version of happly is quite slow for large files compared to an home-brewed solution I cooked up. The profiler suggest that the problem is allocating many small vectors in list properties. On the Lucy model from the Stanford repo, happly takes about 16 seconds of which 7 are just vector allocs. My home-brewed solution takes half that time.
I propose the following changes:
- change the storage of list props from
vector<vector<T>> datato three vectors for start, count and datastd::vector<size_t> start; std::vector<uint8_t> count; vector<T> data;, where data has the concatenated list of elements, start has the starting index for each list and count contains the lists sizes - in a backward compatible manner, add
getListProperty(vector<array<T, N>>& data, vector<uint8_t>& count)to read the data in preallocated lists; maintain previous versions for backward compatibility
If this sounds good, I may even take a crack at it, but only if this feels right.
- Lenguaje dominante
- C++
- Estrellas
- 406
- Forks
- 74
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
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 nmwsharp/happly
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 56/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 48/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 55/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 45/100
Todos los issues de nmwsharp/happly
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
flutter-webrtc/flutter-webrtc#2206 ·
-
litertlm-android AAR ships no consumer ProGuard rules → "mid == null" SIGABRT in minified apps Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
google-ai-edge/LiteRT-LM#3739 ·
-
Component: GLib
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
brave/brave-browser#59300 ·
-
Mute ydb/tests/functional/dstool/test_canonical_requests.py.Test.test_group_take_snapshot in main Abiertoai_reviewed
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
ydb-platform/ydb#53974 · 3 comentarios ·