[MPlayer-dev-eng] [PATCH] mp3lib: keep stack 16-byte aligned in synth_1to1_MMX_s

Reimar Doeffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Tue May 8 10:25:06 CEST 2007


Hello,
On Tue, May 08, 2007 at 11:22:50AM +0800, Zuxy Meng wrote:
> By default gcc aligns the stack on a 16-byte boundary, and Mac OS X
> for x86 even mandates this. Hence the patch.

>  ".L02:\n\t"
>  	"emms\n\t"
> -        "pushl %0\n\t"
> +	"movl %0, %%eax\n\t"
> +	"subl $4, %%esp\n\t"
> +	"pushl %%eax\n\t"

Why do you use eax? I guess %0 breaks otherwise...
How about using mov instead of push and decrement the stack directly
before the call? Would that make the code larger?

Greetings,
Reimar Doeffinger



More information about the MPlayer-dev-eng mailing list