Re: [FFmpeg-devel] [PATCH 1/4] avutil/x86/pixelutils: Empty MMX state in ff_pixelutils_sad_8x8_mmxext

2023-11-03 Thread Andreas Rheinhardt
Andreas Rheinhardt: > We currently mostly do not empty the MMX state in our MMX > DSP functions; instead we only do so before code that might > be using x87 code. This is a violation of the System V i386 ABI > (and maybe of other ABIs, too): > "The CPU shall be in x87 mode upon entry to a

Re: [FFmpeg-devel] [PATCH 1/4] avutil/x86/pixelutils: Empty MMX state in ff_pixelutils_sad_8x8_mmxext

2023-11-01 Thread Andreas Rheinhardt
Henrik Gramner via ffmpeg-devel: > On Wed, Nov 1, 2023 at 10:44 AM Andreas Rheinhardt > wrote: >> libavutil/x86/pixelutils.asm | 1 + >> 1 file changed, 1 insertion(+) > > IIRC the emms instructions is quite slow on many systems, so if this > is the only pixelutils function using mmx it's

Re: [FFmpeg-devel] [PATCH 1/4] avutil/x86/pixelutils: Empty MMX state in ff_pixelutils_sad_8x8_mmxext

2023-11-01 Thread Henrik Gramner via ffmpeg-devel
On Wed, Nov 1, 2023 at 10:44 AM Andreas Rheinhardt wrote: > libavutil/x86/pixelutils.asm | 1 + > 1 file changed, 1 insertion(+) IIRC the emms instructions is quite slow on many systems, so if this is the only pixelutils function using mmx it's probably better to just rewrite it to use SSE2

[FFmpeg-devel] [PATCH 1/4] avutil/x86/pixelutils: Empty MMX state in ff_pixelutils_sad_8x8_mmxext

2023-11-01 Thread Andreas Rheinhardt
We currently mostly do not empty the MMX state in our MMX DSP functions; instead we only do so before code that might be using x87 code. This is a violation of the System V i386 ABI (and maybe of other ABIs, too): "The CPU shall be in x87 mode upon entry to a function. Therefore, every function