Le lauantaina 8. kesäkuuta 2024, 0.26.21 EEST Andreas Rheinhardt a écrit :
> (Also: IIRC Clang actually parses inline assembler and optimize it;

That sounds sketchy. While FFmpeg only uses inline assembler as intrinsic 
ersatz, other projects can and definitely do use them for weirder stuff. That 
will fail miserably if the compiler modifies the sequence.

The Linux kernel for instance pushes/pops sections or patches the byte 
sequence at load time or even run time. Some code also assumes exact byte 
offsets between instructions (not sure Linux specifically). So, AFAICT, the 
only 
thing the compiler can sanely do is move, and maybe eliminate/replicate, the 
entire assembler block.

-- 
レミ・デニ-クールモン
http://www.remlab.net/



_______________________________________________
ffmpeg-devel mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to