To load threadirqs edit etc/default/grub
and add threadirqs to the line
GRUB_CMDLINE_LINUX_DEFAULT=
Then update grub with
Code: Select all
$ sudo grub-mkconfig -o /boot/grub/grub.cfg
Moderators: MattKingUSA, khz
To load threadirqs edit etc/default/grub
and add threadirqs to the line
GRUB_CMDLINE_LINUX_DEFAULT=
Then update grub with
Code: Select all
$ sudo grub-mkconfig -o /boot/grub/grub.cfg
bluzee wrote: ↑Thu Jul 27, 2023 4:17 pmI'm now running the latest Pipewire on my Ham Radio computer and I can run the SDR software which is Pulse as well as Carla which is Jack to add multi band compressor for microphone. Latency is acceptable and qpwgraph makes routing easy. I can not get the latency low enough to play live with guitarix so my guitarix computer remains on Jack with Pipewire and Pulseaudio disabled. Perhaps one day Pipewire will do low enough latency, but it's not there yet.
@wtay has stated that it has been determined that the current pipewire scheduler is not adequate for the low latency xrun free audio that pro audio requires. His plan is to change the scheduler to behave like the JACK scheduler does, and use IRQ based scheduling. This will involve a fundamental change in the way Pipewire is currently working, and will take time to implement. Until that happens, Pipewire will not function as well except for a lucky few with specific hardware configurations. It will take time, but many of us are waiting "patiently" for this fix.
Impostor wrote: ↑Wed Jul 26, 2023 12:36 pmgabtram wrote: ↑Wed Jul 26, 2023 11:40 amKernel 6.4.4-arch1-1 without 'threadirqs' parameter or real-time capabilities found. See also https://wiki.linuxaudio.org/wiki/system … ime_kernel
I followed the guidem can't find kernel file in boot and trying to unzip the kernel file and change the configuration maybe can't understand somethingFrom my notes (always take notes when tweaking your system!):
-Open /etc/default/grub. Look for GRUB_CMDLINE_LINUX_DEFAULT and add threadirqs to the list of options:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash threadirqs"
Save the file and update the grub configuration:
sudo update-grub
Now reboot and you should have threaded IRQs.
Don't forget to make sure the preemption is changed from "Voluntary" to "Full". It is the combination of the two kernel parameters that make the generic kernel act like a realtime kernel.
Audiojunkie wrote: ↑Tue Sep 12, 2023 4:00 pmDon't forget to make sure the preemption is changed from "Voluntary" to "Full". It is the combination of the two kernel parameters that make the generic kernel act like a realtime kernel. :)
Isn't that only possible when compiling your own kernel?
Impostor wrote: ↑Tue Sep 12, 2023 7:40 pmAudiojunkie wrote: ↑Tue Sep 12, 2023 4:00 pmDon't forget to make sure the preemption is changed from "Voluntary" to "Full". It is the combination of the two kernel parameters that make the generic kernel act like a realtime kernel.
Isn't that only possible when compiling your own kernel?
Dynamic preemption was introduced in Linux 5.12 kernels - https://www.phoronix.com/news/Linux-5.1 ... ic-Preempt
You can grep your kernel config to see it is included, eg.:
Code: Select all
$ grep PREEMPT_DYNAMIC /boot/config-6.0.0-0.deb11.6-amd64
CONFIG_PREEMPT_DYNAMIC=y
CONFIG_HAVE_PREEMPT_DYNAMIC=y
CONFIG_HAVE_PREEMPT_DYNAMIC_CALL=y
Preemption options are none, voluntary, and full. The default, in Debian kernels at least, is voluntary. To set full preemption, add to kernel options
Code: Select all
preempt=full
I use Liquorix kernel in which full preemption is default, so dynamic is not set and the kernel option is pointless.
Audiojunkie wrote: ↑Tue Sep 12, 2023 3:56 pm@wtay has stated that it has been determined that the current pipewire scheduler is not adequate for the low latency xrun free audio that pro audio requires. His plan is to change the scheduler to behave like the JACK scheduler does, and use IRQ based scheduling. This will involve a fundamental change in the way Pipewire is currently working, and will take time to implement. Until that happens, Pipewire will not function as well except for a lucky few with specific hardware configurations. It will take time, but many of us are waiting "patiently" for this fix.
Is there link for this statement, would like to link that on some discussions.
Linux veteran & Novice musician
Latest track: https://www.youtube.com/watch?v=ycVrgGtrBmM
tavasti wrote: ↑Wed Sep 13, 2023 7:08 amAudiojunkie wrote: ↑Tue Sep 12, 2023 3:56 pm@wtay has stated that it has been determined that the current pipewire scheduler is not adequate for the low latency xrun free audio that pro audio requires. His plan is to change the scheduler to behave like the JACK scheduler does, and use IRQ based scheduling. This will involve a fundamental change in the way Pipewire is currently working, and will take time to implement. Until that happens, Pipewire will not function as well except for a lucky few with specific hardware configurations. It will take time, but many of us are waiting "patiently" for this fix.
Is there link for this statement, would like to link that on some discussions.
Yes, on page 2 of this discussion:
In fact, the whole thread is very informative, and may be the best discussion of the issue in all the internet—it is, at least, to my current knowledge.
I do believe that with the current version of Pipewire and a current kernel, it is indeed possible to get excellent performance with Pipewire. As I have mentioned elsewhere, I'm getting performance at least as good as what I was able to do under JACK (<5 ms/32 samples) and I'm not even running a low-latency kernel, although I am using System76's custom scheduler. This is on a rather beefy, brand-new machine, but even my old Thinkpad was giving decent performance when I was testing it a few months back.
I do think that it's probably best to start from scratch, though - fresh install on a distro that has never had JACK or PulseAudio installed, and a proper configuration (i.e., one that the distro has configured out of the box, rather than a manual install.)
matyas wrote: ↑Thu Sep 14, 2023 10:36 pmI do believe that with the current version of Pipewire and a current kernel, it is indeed possible to get excellent performance with Pipewire. As I have mentioned elsewhere, I'm getting performance at least as good as what I was able to do under JACK (<5 ms/32 samples) and I'm not even running a low-latency kernel, although I am using System76's custom scheduler. This is on a rather beefy, brand-new machine, but even my old Thinkpad was giving decent performance when I was testing it a few months back.
I do think that it's probably best to start from scratch, though - fresh install on a distro that has never had JACK or PulseAudio installed, and a proper configuration (i.e., one that the distro has configured out of the box, rather than a manual install.)
Are you using special or custom configs for PipeWire? If so, care to share?
The configuration files for all these are independent so having other sound servers installed should matter not. The default configuration for Pipewire could vary by distro but will be the same if installed initially or later on.
I'm not actually doing anything special at all. I've tested two different machines, an older Thinkpad i5 with integrated graphics and 16 GB, and a much more powerful machine, a brand-new System76 Serval with a current i9, 32 GB RAM, and nVidia graphics. Both machines are running current PopOS. On the Thinkpad, I followed the steps outlined here: viewtopic.php?p=158807#p158807. There was some manual tweaking involved, but not much.
On the Serval, I just set the Pipewire quantum to 32 with a period of 3, and chose "Pro Audio" mode in pavucontrol. I'm using qpwgraph for routing. That's it. No disabling services, no esoteric boot options, no secret configurations.
On both machines, consumer apps play as the should, serious music apps work as expected, JACK emulation works fine, I can hotplug USB devices and switch back to the onboard sound, etc.
Now, all of this comes with the caveat that PopOS is a pretty heavily optimized distro. There are probably some settings made out of the box that make all of this easier in this distribution. I know that it employs a special scheduler that assigns real-time priority to audio apps; this is how they get around needing a low-latency kernel (although the stock kernel does have pre-empt patches installed.) I did need to add my audio apps to the file that tracks what apps get real-time permission; some of the common ones are already on the list, though.
Quick edit: I'm actually using a quantum of 64, but latency is negligible nonetheless. I did bump it up to 128 because the system seemed a little sluggish, but that turned out not to be the problem. (Issue was actually due to trying to drive a large external display in portrait mode with motherboard graphics.) I'm going to go back 64 now that I know the cause of the issue.
As I've said before, in 2023, Linux audio does not need to be an esoteric art.
Hi to all,
and thanks for your response.
This community is great!
So we will patiently wait for pipewires updates bu in the meantime we can work to find good way to low the latency.
Unfortunately i don0t find the time until now to update my OS so now here i am.
I made some test and i can confirm my interal soundcard latency (the usb keyboard attached directly to my pc) have 1s and my mic and guitard on focusrite have almost 450-500ms.
So i think best solution in my case is to follow https://wiki.archlinux.org/title/Professional_audio and trying to set realtime kernel patch set.
The only thing i can't understand is: after installing the kernel patchset how can i configure the boot priority to respect this statement? "Note: Do not forget to add the newly installed kernel to your boot loader!"
Other thing: i use qpwgraph for routing. Is awesome but there is no configuration to set sample rate and buffer size like i remember in qjackctl. Now i find pipewire have a command to set all of this and you can find thans to this post bye @Audiojunkie viewtopic.php?t=25768. But is there a gui to do so? It's the same but in some case you can be fast with a gui.
I passed six month to configure this machine. After resolving latency issues and install some DAWS and other software i'd like to share my results to the community. I don't want to distruibute yet another os for music (even if YAOM is a good name for a distro but create a base for someone who want to play music and don't lose six month of time. Yeah there many good distros for music around but i think the best you can find it's what you can update always.
Bye!
gabtram wrote: ↑Tue Oct 17, 2023 9:10 amSo i think best solution in my case is to follow https://wiki.archlinux.org/title/Professional_audio and trying to set realtime kernel patch set.
The only thing i can't understand is: after installing the kernel patchset how can i configure the boot priority to respect this statement? "Note: Do not forget to add the newly installed kernel to your boot loader!"
Usually you run something like `update-grub` or `grub-mkconfig -o /boot/grub/grub.cfg`, but that depends on your distro.
Other thing: i use qpwgraph for routing. Is awesome but there is no configuration to set sample rate and buffer size like i remember in qjackctl. Now i find pipewire have a command to set all of this and you can find thans to this post bye @Audiojunkie viewtopic.php?t=25768. But is there a gui to do so? It's the same but in some case you can be fast with a gui.
Pipewire works a little different here: Processes may request a latency target, and Pipewire applies the lowest requested target to the underlying device. For example, in Ardour you can set the latency target in the preferences and Pipewire(-JACK) will use that.
gabtram wrote: ↑Tue Oct 17, 2023 9:10 amHi to all,
and thanks for your response.
This community is great!
So we will patiently wait for pipewires updates bu in the meantime we can work to find good way to low the latency.
Unfortunately i don0t find the time until now to update my OS so now here i am.
I made some test and i can confirm my interal soundcard latency (the usb keyboard attached directly to my pc) have 1s and my mic and guitard on focusrite have almost 450-500ms.So i think best solution in my case is to follow https://wiki.archlinux.org/title/Professional_audio and trying to set realtime kernel patch set.
The only thing i can't understand is: after installing the kernel patchset how can i configure the boot priority to respect this statement? "Note: Do not forget to add the newly installed kernel to your boot loader!"Other thing: i use qpwgraph for routing. Is awesome but there is no configuration to set sample rate and buffer size like i remember in qjackctl. Now i find pipewire have a command to set all of this and you can find thans to this post bye @Audiojunkie viewtopic.php?t=25768. But is there a gui to do so? It's the same but in some case you can be fast with a gui.
I passed six month to configure this machine. After resolving latency issues and install some DAWS and other software i'd like to share my results to the community. I don't want to distruibute yet another os for music (even if YAOM is a good name for a distro but create a base for someone who want to play music and don't lose six month of time. Yeah there many good distros for music around but i think the best you can find it's what you can update always.
Bye!
There are several GUI front ends for Pipewire nowadays. The following thread just lists a few:
https://forum.cockos.com/showthread.php?t=280235
Do a search for Pipewire GUI and you should be able to find more. I've seen at least 6-8 GUIs so far, with different levels of functionality. They DO exist.
EDIT: I saw a really powerful one recently. I can't remember its name. There's also one with a name like "copper wire" or something like that. I can't find it at the moment though. There really are a lot of them though.
EDIT#2: I found some more, including the "Copper Wire" one that I couldn't remember the last name for:
https://github.com/dyegoaurelio/simple-wireplumber-gui
https://github.com/dimtpap/coppwr