"Leaky" memory usage when using repeat_infinite()
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Accessibilité débutants
- 42/100
- Type d'issue
- Bug
- Clarté
- Plutôt claire
- Activité
- À l'abandon
- Stack technique
- rust
- Domaine
- audio-video-rtc
Piste de recherche
Start by reading the repeat_infinite() implementation and the source types it wraps, then reproduce the reported growth with the Rust 0.20.1 setup: a Sink playing a Decoder over a Cursor<Vec<u8>>. Compare memory use with and without repetition over time. The issue is resolved when repeated playback no longer causes unbounded memory growth; the report does not name a test or file.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Hello,
I'm using Rodio for my application and I'd like for my music to repeat multiple times. I've found the repeat_infinite() function for the Source struct but when I monitored the memory usage I've found out that it's growing about at 10mb every 15 seconds.
I haven't checked if it eventually caps, I only saw that it went from 30mb of memory to 100mb+.
Not using repeat_infinite() works as intended, the memory usage doesn't move.
In my app I create a Sink and I append the Decoder wrapping my music. I assumed that the problem was about buffering more and more music, but in my case the music is in a Cursor<Vec<u8>> so it shouldn't load any more of it (plus my music file is definitely less than 70mb).
System:
OS: Linux X11 pop 22.04
Memory: 61.9 GiB
Architecture: x86_64
GPU: NVIDIA GeForce RTX 4070 || NVIDIA || 560.35.03
Relevant crates:
cpal = "0.15.3"
rodio = "0.20.1"
- Langage dominant
- Rust
- Étoiles
- 2.5k
- Forks
- 338
- Merge moyen
- 1 j 3 h
- PR mergées (30 j)
- 1
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Aucun modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de RustAudio/rodio
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 73/100
-
Difficulté 3/5 1-2 jours Accessibilité débutants 62/100
-
WavDecoder::size_hint underflows (u32 wrap, ~4.29e9) after EOF, causes multi-GB Vec::collect() allocationPeut-être pris @marin-m l’a pris il y a 6 jours. Ouverte
Difficulté 3/5 1-2 jours Accessibilité débutants 72/100
-
Difficulté 4/5 3-5 jours Accessibilité débutants 45/100
Toutes les issues de RustAudio/rodio
Issues similaires
-
bug duplicate enhancement priority: low ui
Difficulté 2/5 1-3 heures Accessibilité débutants 62/100
storytold/pdfcraft#5594 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
documentation good first issue help wanted
Difficulté 2/5 1-3 heures Accessibilité débutants 86/100
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 85/100
open-jarvis/OpenJarvis#1212 ·
Les mainteneurs répondent en général sous 4 jours
-
bug good first issue
Difficulté 2/5 1-3 heures Accessibilité débutants 84/100
CakeRepository/agentshangout#38 ·
Les mainteneurs répondent en général sous 1 jour