[MPlayer-dev-eng] [PATCH] correct illegal instruction on < armv5tE

Diego Biurrun diego at biurrun.de
Mon Jan 5 18:32:24 CET 2009


On Wed, Nov 12, 2008 at 09:37:49PM +0100, GNUtoo at no-log.org wrote:
> > On Thu, Nov 06, 2008 at 11:59:53PM +0100, GNUtoo at no-log.org wrote:
> >> > on Sunday 12 October 2008, GNUtoo at no-log.org wrote:
> >> >
> >> > Hmm, ifdefs around every instruction look extremely ugly. In
> >> > addition, they have exactly the same effect as just removing all
> >> > PLD instructions even for ARM cores that support cache prefetch
> >> > (HAVE_ARMV5TE is never defined when compiling this assembly file).
> >> I looked at the configure file of mplayer trunk and there is the
> >> following
> >> inside:
> >> if arm ; then
> >>   echocheck "ARM pld instruction"
> >>   cat > $TMPC << EOF
> >> int main(void) { __asm__ volatile ("pld [r0]"); return 0; }
> >> EOF
> >>   pld=no
> >>   cc_check && pld=yes
> >>   echores "$pld"
> >> so if I add the following to the beginning of the assembly file would it
> >> work?
> >> #ifndef HAVE_PLD
> >> .macro pld reg
> >> .endm
> >> #endif
> >> More precisely is the checks in the configure script enough or should I
> >> also add that in the configure script:
> >> enabled armv4l  && check_asm pld     '"pld [r0]"'
> >
> > What we have is enough.  It accomplishes exactly what you need.
> >
> Thanks a lot!!!
> I attached the patch for applying the following code to the
> libmpeg2/motion_comp_arm_s.S:
> --- trunk.orig/libmpeg2/motion_comp_arm_s.S
> +++ trunk/libmpeg2/motion_comp_arm_s.S
> @@ -18,6 +18,11 @@
>  @ along with mpeg2dec; if not, write to the Free Software
>  @ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
>  
> +#ifndef HAVE_PLD
> +.macro pld reg
> +.endm
> +#endif

The patch is incorrect, this file does not #include config.h, so
the preprocessor can never check the condition properly.

Diego



More information about the MPlayer-dev-eng mailing list