From owner-svn-ports-head@freebsd.org Sun Sep 18 17:20:06 2016 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 411D9BE00C9; Sun, 18 Sep 2016 17:20:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1CB43177; Sun, 18 Sep 2016 17:20:06 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u8IHK5hZ016486; Sun, 18 Sep 2016 17:20:05 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u8IHK5HK016485; Sun, 18 Sep 2016 17:20:05 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201609181720.u8IHK5HK016485@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 18 Sep 2016 17:20:05 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r422400 - head/multimedia/transcode/files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Sep 2016 17:20:06 -0000 Author: dim (src committer) Date: Sun Sep 18 17:20:05 2016 New Revision: 422400 URL: https://svnweb.freebsd.org/changeset/ports/422400 Log: Add newlines to the inline assembly in calc_SAD_half_mmx(). Otherwise the .rept/.endr parsing logic in clang's inline assembler gets tripped up. Approved by: cyberbotx@cyberbotx.com (maintainer) PR: 212798 MFH: 2016Q3 Added: head/multimedia/transcode/files/patch-filter_yuvdenoise_motion.c (contents, props changed) Added: head/multimedia/transcode/files/patch-filter_yuvdenoise_motion.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/transcode/files/patch-filter_yuvdenoise_motion.c Sun Sep 18 17:20:05 2016 (r422400) @@ -0,0 +1,61 @@ +--- filter/yuvdenoise/motion.c.orig 2016-09-18 16:54:49 UTC ++++ filter/yuvdenoise/motion.c +@@ -350,32 +350,32 @@ calc_SAD_half_mmx (uint8_t * ref, uint8_ + + __asm__ __volatile__ + ( +- " pxor %%mm0 , %%mm0; /* clear mm0 */" +- " pcmpeqw %%mm6 , %%mm6; /* Build 7f7f7f7f7f7f7f in a register */" +- " psrlw $9 , %%mm6; /* */" +- " packuswb %%mm6 , %%mm6; /* */" +- " ; /* */" +- " .rept 8 ; /* */" +- " movq (%%esi), %%mm1; /* 8 Pixels from filtered frame to mm1 */" +- " movq (%%edi), %%mm2; /* 8 Pixels from filtered frame to mm2 (displaced) */" +- " movq (%%eax), %%mm3; /* reference to mm3 */" +- " psrlq $1 , %%mm1; /* average source pixels */" +- " psrlq $1 , %%mm2; /* shift right by one (divide by two) */" +- " pand %%mm6 , %%mm1; /* kill downshifted bits */" +- " pand %%mm6 , %%mm2; /* kill downshifted bits */" +- " paddusw %%mm2 , %%mm1; /* add up ... */" +- +- " movq %%mm3 , %%mm4; /* copy reference to mm4 */" +- " psubusb %%mm1 , %%mm3; /* positive differences between mm2 and mm1 */" +- " psubusb %%mm4 , %%mm1; /* positive differences between mm1 and mm3 */" +- " paddusb %%mm3 , %%mm1; /* mm1 now contains abs(mm1-mm2) */" +- " paddusw %%mm1 , %%mm0; /* add result to mm0 */" +- " addl %%ecx , %%esi; /* add framewidth to frameaddress */" +- " addl %%ecx , %%edi; /* add framewidth to frameaddress */" +- " addl %%ecx , %%ecx; /* add framewidth to frameaddress */" +- " .endr ; /* */" +- " /* */" +- " movq %%mm0 , %0 ; /* make mm0 available to gcc ... */" ++ " pxor %%mm0 , %%mm0; /* clear mm0 */\n" ++ " pcmpeqw %%mm6 , %%mm6; /* Build 7f7f7f7f7f7f7f in a register */\n" ++ " psrlw $9 , %%mm6; /* */\n" ++ " packuswb %%mm6 , %%mm6; /* */\n" ++ " ; /* */\n" ++ " .rept 8 ; /* */\n" ++ " movq (%%esi), %%mm1; /* 8 Pixels from filtered frame to mm1 */\n" ++ " movq (%%edi), %%mm2; /* 8 Pixels from filtered frame to mm2 (displaced) */\n" ++ " movq (%%eax), %%mm3; /* reference to mm3 */\n" ++ " psrlq $1 , %%mm1; /* average source pixels */\n" ++ " psrlq $1 , %%mm2; /* shift right by one (divide by two) */\n" ++ " pand %%mm6 , %%mm1; /* kill downshifted bits */\n" ++ " pand %%mm6 , %%mm2; /* kill downshifted bits */\n" ++ " paddusw %%mm2 , %%mm1; /* add up ... */\n" ++ " /* */\n" ++ " movq %%mm3 , %%mm4; /* copy reference to mm4 */\n" ++ " psubusb %%mm1 , %%mm3; /* positive differences between mm2 and mm1 */\n" ++ " psubusb %%mm4 , %%mm1; /* positive differences between mm1 and mm3 */\n" ++ " paddusb %%mm3 , %%mm1; /* mm1 now contains abs(mm1-mm2) */\n" ++ " paddusw %%mm1 , %%mm0; /* add result to mm0 */\n" ++ " addl %%ecx , %%esi; /* add framewidth to frameaddress */\n" ++ " addl %%ecx , %%edi; /* add framewidth to frameaddress */\n" ++ " addl %%ecx , %%ecx; /* add framewidth to frameaddress */\n" ++ " .endr ; /* */\n" ++ " /* */\n" ++ " movq %%mm0 , %0 ; /* make mm0 available to gcc ... */\n" + :"=g" (a) + :"S" (frm1),"D" (frm2), "a" (ref), "c" (denoiser.frame.w) + );