On Wed, 22 Oct 2025, Rémi Denis-Courmont via ffmpeg-devel wrote:
If you want to compile AArch64 FFmpeg for use in emulated x86 processes,
then you need a FFmpeg that exposes the same ABI as the x86 FFmpeg.
That's going to require a lot of changes throughout the code base (and I
doubt people here will agree to them overall).
Can you elaborate on what changes you think would be needed?
The compilers (both MSVC and Clang) in arm64ec mode produce code that is
ABI compatible with x86_64 code - that's part of the whole point of it. It
is by default ABI compatible without us doing anything about it.
In arm64ec mode, the compiler defines __x86_64__ (or _M_X64) and does not
define __aarch64__ (or _M_ARM64). It does define __arm64ec__ (or
_M_ARM64EC) to distinguish it from regular x86_64 though.
There are a few corner cases though; e.g. the cpuflags exposed by
av_get_cpu_flags() in an arm64ec build would be arm64 flags, while they
would be x86_64 flags in an x86_64 build.
As a concrete example, I did fully stock x86_64 and arm64ec builds, with
both MSVC and mingw tools. I took ffmpeg.exe from the x86_64 build and the
DLLs from the arm64ec builds, and they ran just fine together. (ffmpeg
does warn that they are from builds with differing configure lines
though.) Mixing e.g. an x86_64 avcodec DLL with an arm64ec avutil DLL
doesn't work though.
// Martin
_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]