The application relates to a Linux PipeWire audio
noise reduction method based on CPU
instruction set optimization and a storage medium, and belongs to the field of audio
processing. The method comprises the following steps: configuring a libpipewire-module-filter-chain module in a PipeWire
multimedia server, and dynamically loading an SPA plug-in; in an initialization stage, an SPA_TYPE_INTERFACE_CPU interface is requested to obtain a CPU characteristic
mask, AVX2,
NEON or a scalar audio format
conversion function pointer is dynamically bound according to the
mask; in a high-frequency audio
processing callback, the bound
function pointer is called, a
SIMD wide register is utilized to perform
type conversion from
floating point to fixed point and saturation limiting operation in parallel, and a
double loop unrolling strategy is used to maximize the
utilization rate of an instruction emission port; and the converted data is written into Playback
Stream shared memory. The application realizes cross-platform
adaptive optimization of a single binary
package through runtime
instruction set sniffing, completely eliminates the calculation
bottleneck of F32 to S16 format conversion after neural network
noise reduction, and significantly improves the
system throughput of a PipeWire real-time audio
server while ensuring extreme compatibility.