Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am tuning my sound interface latency with

alsaloop -C hw:1,0 -P hw:1,0 -t $LATENCY_US

When I set $LATENCY_US to 30000, I get around 20% CPU usage.

I can restart this a few times and make some noise, and after a few trials I suddenly get 100% CPU usage (most of that spent in the kernel, red in htop). Restarting alsaloop multiple times then does not help, until I "give it some time" before starting it again - then it is back to normal and I can repeat the whole procedure. Note that alsaloop gives no output here.

Question 1: What is happening here?

If I set $LATENCY_US as low as 4000, CPU usage spikes up to 100% for a second; then alsaloop reports underrun for playback hw:1,0, CPU is low and stays so.

Question 2: What happens in this case? Why does it calm down? Is it still recording with the latency I set after the underrun?

Thank you.

share|improve this question

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.