[FFmpeg-devel] [PATCH] MANGLE for labels inside asm (was: [PATCH] Move MLP's dot product to DSPContext)

Michael Niedermayer michaelni
Sat May 23 14:20:36 CEST 2009


On Fri, May 22, 2009 at 11:13:44PM -0300, Ramiro Polla wrote:
> On Fri, May 22, 2009 at 9:24 PM, Ramiro Polla <ramiro.polla at gmail.com> wrote:
> [...]
> > Applied with the #endif comment as /* !HAVE_X86_64 */
> 
> > +#if ARCH_X86_64
> > +
> > +#define MLPMUL(label, offset, offs, offc)   \
> > +    MANGLE(label)":                   \n\t" \
> > +    "movslq "offset"+"offs"(%0), %%rax\n\t" \
> > +    "movslq "offset"+"offc"(%1), %%rdx\n\t" \
> > +    "imul                 %%rdx, %%rax\n\t" \
> > +    "add                  %%rax, %%rsi\n\t"
> 
> This broke building on x86_64 with PIC. The reason is MANGLE() in that
> case appends (%%rip) to the symbol. That is not wanted for exporting a
> label from inside an asm block. The symbol must be MANGLE()d here so
> it can be picked up by the C code (or else we get undefined
> references).
> 
> So I propose:
> label_mangle.diff
> use_label_mangle.diff
> restore_x86_mlpdsp.diff

ok

[...]


-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Observe your enemies, for they first find out your faults. -- Antisthenes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090523/36840de8/attachment.pgp>



More information about the ffmpeg-devel mailing list