News: 0001539207

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

FFmpeg Lands AES-NI Optimized Implementation For Big Speed-Up

([Multimedia] 6 Hours Ago FFmpeg + AES-NI)


FFmpeg is known for carrying a lot of hand-optimized Assembly code for speeding up this widely-used multimedia library and [1]taking advantage of AVX-512 and other modern CPU ISA capabilities. Merged yesterday was support for making use of AES-NI for those relying on Advanced Encryption Standard (AES) within FFmpeg for encrypted video streams.

[2]AES-NI has been found on Intel and AMD processors for well more than a decade now... In fact, the better part of two decades. Surprisingly it's taken until 2025 for FFmpeg's libavutil code to add an AES-NI optimized code path within its AES routines.

In any event the performance results from this AES-NI optimized code are quite exciting for AMD/Intel systems if you are dealing with encrypted AES video buffers within FFmpeg. [3]The commit landing the AES-NI optimized code cites a huge speed-up:

With this now-merged code, dropping from 17 seconds with the pure C version down to 0.59 seconds with the new AES-NI path within libavutil. This AES-NI libavutil path is also comparable to gcrypt and other AES crypto implementations too.



[1] https://www.phoronix.com/news/FFmpeg-AVX-512-uyvytoyuv422

[2] https://www.phoronix.com/search/AES-NI

[3] https://github.com/FFmpeg/FFmpeg/commit/2ea3c51795414f092ae44de86ae5e3ac8ebd8b15



phoronix

Oxygen is a very toxic gas and an extreme fire hazard. It is fatal in
concentrations of as little as 0.000001 p.p.m. Humans exposed to the
oxygen concentrations die within a few minutes. Symptoms resemble very
much those of cyanide poisoning (blue face, etc.). In higher
concentrations, e.g. 20%, the toxic effect is somewhat delayed and it
takes about 2.5 billion inhalations before death takes place. The reason
for the delay is the difference in the mechanism of the toxic effect of
oxygen in 20% concentration. It apparently contributes to a complex
process called aging, of which very little is known, except that it is
always fatal.

However, the main disadvantage of the 20% oxygen concentration is in the
fact it is habit forming. The first inhalation (occurring at birth) is
sufficient to make oxygen addiction permanent. After that, any
considerable decrease in the daily oxygen doses results in death with
symptoms resembling those of cyanide poisoning.

Oxygen is an extreme fire hazard. All of the fires that were reported in
the continental U.S. for the period of the past 25 years were found to be
due to the presence of this gas in the atmosphere surrounding the buildings
in question.

Oxygen is especially dangerous because it is odorless, colorless and
tasteless, so that its presence can not be readily detected until it is
too late.
-- Chemical & Engineering News February 6, 1956