From patchwork Thu Jun 9 23:54:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36105 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654079pzj; Thu, 9 Jun 2022 16:55:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxg8RTrjwmK08GYpPr0eD7DtfZ0QDQUnGn5wgXWmqKLnPW9ThBzH1Rfg32eVrPFwUh2dtjY X-Received: by 2002:a05:6402:1692:b0:42d:e291:67f3 with SMTP id a18-20020a056402169200b0042de29167f3mr47043418edv.392.1654818952063; Thu, 09 Jun 2022 16:55:52 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id j39-20020a05640223a700b004315a290b9esi5194295eda.286.2022.06.09.16.55.51; Thu, 09 Jun 2022 16:55:52 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=Jsq3CYGc; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E558168B80B; Fri, 10 Jun 2022 02:55:47 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070104.outbound.protection.outlook.com [40.92.70.104]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 7766C68B6D2 for ; Fri, 10 Jun 2022 02:55:40 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cwbg/Ud/1ORdFNIhE5V7VzNCJZ7d1O/Wm6JXete3d/hpB3yVsM5TsaLDckPOJQohTqX4KYhAprAFil/+UmbI2TLDfTcOS7gF6fUQkIo7Gyubsj4woPLLl7ejCym8uDdvybqpL73KJoZTIwDAEyXtdptEv1IXeRdJuE78wCFSJINXVUU/phl2rM9AuGntMox/7PjEm+HzPSrL+Sj0eOP9xnduAIwbNOckGVO9l55A/KW65NIaEjQ7dYsAEo21w/kVwUVNh8nSx/U0smtbPXgzVWWcOna7N9xsRVPwJ1FT3bz5Y2qEr/7rquhuo7fGmW32XEOXQuQm8qVD88FeVExM+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Wk8QpUDPkTD9tA8fBU1q1m69Uf4mLiXF06tkT5Gtl30=; b=LT7AjxssEReVsfsy/g/kqGtINbatpEkUq/2uNXi4zDbA9+zsHj8OXYzMs3RoTeK61Y129Thp8lIrWpvh53tUaS5J06gJ3MPq9Q5V3FVeoJ9+IaKFapcFjRkXsPrVH3IkIM5yQAiQNurT9I4u5Rke5ltmrgxuslYBfjBVSYUP4oklAV4WAaGx1qzN8uTERYwVllWhRquvoVchbmQe0o+96GcEB0vedq1BJcorsuuHiE4PssMoDhKYgyIl30zFAUZFewtW61WeNg5OZmKzCWB20/3FhwtTfqQn4rmcGroOFRhgPtg1jg+CsExvTgZ/rS7JEKmnKl5M0zK8U4P94/vykw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Wk8QpUDPkTD9tA8fBU1q1m69Uf4mLiXF06tkT5Gtl30=; b=Jsq3CYGcujxXkFUQr/oeuDsJ7N8ePhLM5d2PdwCUW/GccGucTQJOWcGS5d9LQRzLlGcpQeSQ/132XDZ+6WBBx0/UN/an3OHhVvmVEuiC0gl4UjkehXKavKuPctHwr3YXsCMHn8+lBbDMoQKU4JcMn9ZdBuQxMfI3ZEyhF2zRhQGWeUGqBwB1EI5nprV3EfZ8YlQfht+O1ueN62Gkx9gqmug0XBpUor/Oiem/qQeUgX+gIFD9ChXAeFJqyUJs4RGyZ9scorNloKxfP4nyguIXkMvEf7QR21GBvUO9Acoe3jrD2zGdfeiCYVw1rkUga14+6ORC6HVOBPt0EanNII1G+A== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:39 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:32 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:43 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [JINL/QtlcsGkdT4Ff/gCRDY1UUu8qAy7] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-1-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6ee76ba6-3978-45c9-a6bf-08da4a7389f9 X-MS-Exchange-SLBlob-MailProps: EpEO96k6WonAGWAYIHxzt79KejfqWXcIqVT/gldKbz1FQTzZPrL7f+zMGO2xaWH5i3kkPhbMDKJ5XK75rzM0q/nVjKbPLT92pFtgLcNSf/1DRwc+8SLlXdgNtktv7YHRXW9zKp4yvXGxE78xxkTsLi+M0OYOG5n2v8DkAsHabJjDvv/zMT2DotnZUYBJ4oR+1bFfo3SL3ZJadE0/NrNDpghiINtCka9r9ZpCM04Bi3/8NkN910wHdTo7euaH5vZenHIaJVP9pPRz6ZMS31CAyRwW96D6KUPNDpISNl7CA+58xmJp5VCM7GXIHQaKBlNmejOg7ktq8IQyNKORwAaW/OLt+yZ1pwbnCCoj+lp5QXZEjzkJaO3tUsnTu9U5hJHT4Q4RVRLgreckPxEmfeVw2r3+9X2sBNGCgjuBl68LgGCmLSktKQeW6H0odsTokVTC2BQnaBhdvKWp0lo7qtFMhZo4+pkQJLXb+z1XYQU90xOQPlLc5l5x4Ct4UDbsf6CwxYaf4TVA3jwoUc/LRD58sh0kQoUR86m8pWEDfbn2bxaX10gfTYxyIuVKIfzMQCJLFCS6j/kPZDCSJFuMu3N6nmmaWAMD5ieqqRw9zpNMGwOp4a+lP9WQNkGxZWj/4W0ytDnGsNT43AtsvnHwYYUHOsH5M+wbA9W4NlxqfHAvIdplvYO8GyzyE3l0H6y39AaivUIfgx2NtLU1C08erN7/JxSj0TyIBkpzKL7F5tbhheRk8s4+c47ozdJtYTPonRX2TvOfx0/uNew= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: jFR5fveoIg9G8sraXU05AFB/Z8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Id: 6ee76ba6-3978-45c9-a6bf-08da4a7389f9 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:32.6162 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 01/41] avcodec/x86/qpeldsp: Remove unused ff_put_no_rnd_pixels16_l2_3dnow X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 3YvmkJhoYWme qpeldsp does not use 3dnow, it is MMXEXT-only. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/qpeldsp.asm | 2 -- 1 file changed, 2 deletions(-) diff --git a/libavcodec/x86/qpeldsp.asm b/libavcodec/x86/qpeldsp.asm index 282faed14f..3a6a650654 100644 --- a/libavcodec/x86/qpeldsp.asm +++ b/libavcodec/x86/qpeldsp.asm @@ -166,8 +166,6 @@ cglobal put_no_rnd_pixels16_l2, 6,6 INIT_MMX mmxext PUT_NO_RND_PIXELS16_l2 -INIT_MMX 3dnow -PUT_NO_RND_PIXELS16_l2 %macro MPEG4_QPEL16_H_LOWPASS 1 cglobal %1_mpeg4_qpel16_h_lowpass, 5, 5, 0, 16 From patchwork Thu Jun 9 23:54:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36106 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654142pzj; Thu, 9 Jun 2022 16:56:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyvjgslAkQ6jq+4qVrt1ESpcRM4IzooYX/sKfunVgmiLrHDFrZK9Mfoox4YZqOsrEIu/Wbe X-Received: by 2002:a05:6402:34cc:b0:431:67ed:96a0 with SMTP id w12-20020a05640234cc00b0043167ed96a0mr25093039edc.372.1654818961692; Thu, 09 Jun 2022 16:56:01 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id cr15-20020a170906d54f00b006f3976ed175si18293313ejc.938.2022.06.09.16.56.01; Thu, 09 Jun 2022 16:56:01 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=lma5CJZU; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0632868B81E; Fri, 10 Jun 2022 02:55:55 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id BD6C168B73B for ; Fri, 10 Jun 2022 02:55:47 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lQh2sB5u3gjMYMSfH0E1F8H3RF3UgjsNTz92Z42E5JlVIhLyTX8TFW7G/W7gNoKH26lCR5Ef41zzVqg5miEmO59ZgeEkFHhw+5VFmvM/Anc4YevbdDMUO2Qo/yh9kp8a0+qF98hY/gAkhppcFClx5TNUTy6lWp2DIhs2/GOY+mbc10Zf/FTVVm5dlk/flhg78cHyU4+u8U2qbF/AMssUAHqsUjzRr5rrcSParCEtTbGTEYX4Kz2tWGkgf5NVuJx2N1syLjtXL0Pi2QHFZOA6ybqtjYORAyGpR/0B+RlqHrIQeUHBXar5E+9J85NSUUbwkjfYby35PgXbrgN0J+jKRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=x7agMoD5QzkkX2fKHEG6XQXUaQDc5uGj2tw5kUiglB4=; b=lrIK2CJNI5fXQ/AMM5K0muiYN1vdXBSTgNVs2/VpCPC91S6m9RTc7dFS+XP7gw0tdfoiSgi8j0Ob9CXrRUXvIsR+Yb33BXOVeVVdFw+LibU9RYWVoNBIPGmINNQ8/XnrqjRoNsiBvHK6FP71oHlnhtHKYaJ1bYFv+qfMvIqToDlZSwmCOejXogyt9nNm/JAiDmC2zB7NNPf8EcD+y+5IQbpuONQMYqrCaQYEHucGW2FdSFpvoxvtvcTsAVZt+ql2zW+o8CYUoSJFwQUA1Bj+/VqwcXLuF/STCXl1AbouksPpRZovrNRtIQ+In6qPiHQklv85S9krycYU26CO02KN1g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=x7agMoD5QzkkX2fKHEG6XQXUaQDc5uGj2tw5kUiglB4=; b=lma5CJZUl+MUIfQug9pLSj5GAgEaBFfk/Xq6NvNess+QHfY9AgNPGLfVO+9tJWMy/YN4R5jsMST+nvBRyI4EaP6DiXHWdnUtdMr0MnmX3SL1O2phVfXbWzEK72D64L01OWtrHY1hXAKJ/sZ2mygwTVRaIQ/EakJ83WR76pR01tgnmICJGi0KdeNyufHaOrMzC0aesBBqp8b6b0e6D0w0ie2GpDZjmYwQHVF1Rat5b2lZGQGMQDTc6kLmevLonBbaVLG6Gz21Trllk6cJNJS3lS6k9hoP5udnsBvoE8yUQgSx4wUFBoHXbONqih7Ce+fFs/MG2MCousyyl34nKDxWvA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:46 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:46 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:44 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [5nyKt7tmVaSLSsqBSim3dPPAHsgGNgkW] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-2-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d9a8c56c-e6c9-438d-fc94-08da4a739245 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKEinvX71tfIAhdHz/mkl/FlclldUlp0ccwWPuzMMPKS+WSPqEgNs666sriO06EA1u0kNdJHMrkasyef/vTNguydE4dqmNIk7GXPvB+RQBe+gNgoYK35KFah7SjPOoEToRTDKqJeg2KEIzwEqYGbYGtiLH8k+pW/IpcOK5ZDBMAqsI+GwoosCv4u/8fJsAGARCuiKhwW1grJZIwex4iU0F/+pSgGzd+8zJhaZvY5peDB1KH0d47UgzR2Wt8bOwrXOB1JyqkoedUOwSytuPHwbxk5QwSNO5caDk0WYdhn1mj188PKEcN4Le+XREUViQA84/sdzoJGUhXN+iqlcNKGBGDcYomma5rMwY37WUjY9zwwnreU7HmP/1ljQQu/dsHrDPyhxNePk6bsK1yeNKOukLT91ogo/XspTYaRC7agfuqQGbnwN+uMsnh5h46sGfD7rDv5/zhLkFoO+fvymcQhbppH97NHfb/hAtE+WTRhXwvRYpvjVTr7Al05w9c+xJZ/gtB0v8ylZa4gSfG/IEVR7vhGe8KHmGh7crfOqfKO4SstAVIXHrzQbT+v7HHqktMeVSAsdV2j/X5/DsBWlnBJtLOc+OXbQTkTLGslf1oyezu7ZYCGfLNnExSPdXDgPZWJyBK5a42hbumhBt0+X0u52QYpq/t38BS3ZxJQgjVgJU4W9/QftbfhRm7KEqqzUID1OQLN+udg6leH7o3OkhBT3qwp5083eTeSw4ZleHBYlAaM4= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Tjed8wBuTL0VeGgAtDW0qPQYcppiJb/sSo3VaaYtlZD29YurY09fOYrIUUBuIsaifnqzGw+LaZJfwM2j4M3JZbA4v08uoLnTk4POfAbAXz+dlF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YwWBkGB0GtGqErnRSLlAkoJgDWUnsjX0Xee8mgcvd8fNwbyLIpr8c4PI22Zyfhm4E736qCVIQGblHp/B2IxjtquX1enURYw7CcApTtKZrYVVakoXCuHgM5KA7MvF5HxeA6WGgpMkUqUHmIyhusX+Sy8+EokzS9BnQSJlFXj8VyBl9i61Qh+64fTYB94MmB7BmEOrW7rV25GacCiCRRxGiA0rA/rFJpskSVZOl7/dwJPgyCMOSXThci7uGTGTTwdXb/zbkyoqRz47uSUXJHbwCpPlfStfFQkD5tisqsw0abRhEeR7qjz1bNjl1Jy3r+y5hUS7UD3SSsQExXNun/OcLlNOsZHDYeTLkMaZw9FCDP1b4wchk8gfU0ILaAooq+JL3Qtg3CGI5oeXljoTdiVHYuaWZ2uvSD2zdQNUrEXRIU7Pre4Md5o7s6pp+s7OlbdskVSEY8/+op2v0EqNtp+aR1Lggu/dRbteucxCFrM6nrzs2WMIASCYSb4lhXOX9CGkUekPMGRCczDlTF8/4OLUWESaMCnPugcJDsEIBpCSWVsrJ/uyOEFSLGHn6pAjJykArWB5Zb1HdN0PkqjORiIiSWaAMwp34yDnuj0z3YALBgTWx8IFSqYFNpr7hT1IRN17lQkOk6aacV+dYSHz3dKsz+tyNc66cqcmuONUk7oeEX9ZbExJwe+SOFK6+aSHabnjXOPFRHcZbSM+SKHWWfcsb2LTFmgPALZv4tAYvnAyzdktC3qg1nB8olOcJqfAXmXLwjg7JqPqmECY8OY1A02fk78EZR9TBr4/lqKFa0l3Wns+3Bs3kKAVofSL2ppWK119K5+9OEvAK/iRj6Xyxpv26vv8PX7gQeLvdnyFrMKSUh7qMCHxYucmibK/FLVCOw9VXBCtmGBtVUW/61T1b0GUBhaVK7VJ+mXoeHA8/i0m0T1wDBZ8JTW7cDoVIy/c4eA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: d9a8c56c-e6c9-438d-fc94-08da4a739245 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:46.4913 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 02/41] avcodec/x86/hevcdsp_init: Remove unnecessary inclusion of get_bits.h X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: Jh7O1ExRSlBO This file does not use anything from get_bits.h at all; furthermore hevcdsp.h now includes get_bits.h itself. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/hevcdsp_init.c | 1 - 1 file changed, 1 deletion(-) diff --git a/libavcodec/x86/hevcdsp_init.c b/libavcodec/x86/hevcdsp_init.c index f3061bda84..48f48a925f 100644 --- a/libavcodec/x86/hevcdsp_init.c +++ b/libavcodec/x86/hevcdsp_init.c @@ -25,7 +25,6 @@ #include "libavutil/mem_internal.h" #include "libavutil/x86/asm.h" #include "libavutil/x86/cpu.h" -#include "libavcodec/get_bits.h" /* required for hevcdsp.h GetBitContext */ #include "libavcodec/hevcdsp.h" #include "libavcodec/x86/hevcdsp.h" From patchwork Thu Jun 9 23:54:45 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36107 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654178pzj; Thu, 9 Jun 2022 16:56:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkAAN6rM8aK//8r5CepwpajQgi+D4MbBgcjGm5B86Re1WM0oUV8KhESoi84fn9ougeQtHn X-Received: by 2002:a05:6402:1857:b0:42d:bcd6:3a88 with SMTP id v23-20020a056402185700b0042dbcd63a88mr48524351edy.6.1654818970936; Thu, 09 Jun 2022 16:56:10 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id g11-20020a1709065d0b00b006f39ef3b072si19773147ejt.658.2022.06.09.16.56.10; Thu, 09 Jun 2022 16:56:10 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=JjRpmO10; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1E4FB68B82E; Fri, 10 Jun 2022 02:56:00 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id D45D568B73B for ; Fri, 10 Jun 2022 02:55:52 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=F3VFYB24CgKE8JwOnb3aOXwSm8abR/bbw0s5Lm5DbGwSBMbJFEoOdgoY/zrROYaWM8TM6n+PIflmOQH29Vikz4kO2LU5Jx30G1p78/kf3HqZLUt5f0HrfI6TH3Oxx2n32eFHJTTbB2S3XlpPBQPs4TFU4vWpnswHHQ0p5Cn7LeHzOND6lROkaV0gTzf2C4pUwsVF90TLdGz2yk3mZ/UTh160m2/x6uRUL3jVeEu3HRVfYPbwu/O70Uyh8CKrCM9tcoTk6fWWjTYCop1QNgEmKkTtAij8qEQl00aJBf0SROB2tUtou2H7mnAByqWdKh5QhavnX399bLJtJDEJGizS/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=+BFGXk5W08HN7juwPpyrCxT8bomkdnCmwCu33+CLdCw=; b=hOE2JzNEDwSKRPogA3WfdyYoSjgjnOQAxRU7JSIWjfH7jdrR3HYF179FyCLHBi07plb8tyYhGdJFU61OsrSUkOA7iC6hCq92X7e1Xhe5RjJY/61s9AdfbYwyMLe1nHZH5N87cq6gPiXiFsUOkZJrEMgZtssP30wSNi4LMDt11QuE9B3WucUBDee19LoCvANtrbaN/lKy4iW5kPIloWBFsSFclBztWgVLQAhtaXVra0lxuELroD4Ta8pMwZr40NkDr4OddRoxClnLby2LMDr2TIASZityJ8rVr9Wf8FsNQ0aHLi1AiQJdUh7e9iZGPLi+pY2dhY0/vdBoJhdRrFyaBw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+BFGXk5W08HN7juwPpyrCxT8bomkdnCmwCu33+CLdCw=; b=JjRpmO102f560FH8WB+CbfqEwBOgFbLvefrhS5246DDf6brTubwvHDPcZ7s+IZ8cK5MenPP4UjPjir4208mPW4ZP0RHwvgcLeHebDU3DlOUS0agm+V091RfnNH15E2scZ407xxja5p16dJ60I8UVpIbdiDqjI6ZwTdmRPqU9aV0380iHWvunGR9zfGnXwGYtHnR4yi8rmdhJu4wpgRMIrbI0Xcq4G+zIbofUrgqdomzXqgSk+wvxT4OY5038pC3443qWBv5lEk+CdF8ToOUJOsr1NVGL2NwsiMFnAMShy8OkyyOcBENnOzeaCqwEWam3BKqtc/AK1Rq9VMDt1/GG+Q== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:52 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:52 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:45 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [/MrRDxaFxgWI6C+XmuDprNRxEbHLCFXD] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-3-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6f8b956e-efaa-44e1-398c-08da4a7395ac X-MS-Exchange-S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YOdI+YvkTZluL/xIJNZAqyGjugpzANFZhXhKrxuST4LopenWaZqSsmkcGchRKGVFjHy7nKM9RxyBIO2dS23AU9UQmmMGZb5gii3koJRblG88+gSga87QcjfWnA1DXkp6JR9r63WiCuZ47dJ1YvCdVZYmZ3VcUSGrWJ6638klsGbRiYnxR6bOo7X+O57vxPbCZErEAB0eycW7qAHFVNFG6I8jiWSXddLSL+BLPLXJ9W8qUwByBf9T9cOna09kO/OgZCzjvvg7XRZxjdYTJKoZoR4l3LDKRGq8c8FPHTMEe0Dwt+7nNCIFyRcmLj74dLXxznPDUVDU8n6MOtabihJpKRprfSSxQyr/ItXrv/u+MBNksa4eaa3BZfNeh8Vuq3nlhtgT75Dz4yqmfQNvnY0tkPQG00o37pdyVymyknc6mfRMygp3bxKqUaaTkXOOE79wxE8zwhfPMVs3vljycvZyTSDbcvCq7hJmNijrfVlleFjQPnfywlMyGsiH9fQxB8U0ukoJaJ5VUjknNKrcy7maWb60d+Hw6gllw/aY04m5vnoCrhMslP2nscxFQp/grikw4uJA0AhJ21mOanRAVJ2n0bWv3jKJ7sHLUl3rNul+5iwKRcMfrjmwK+HUyi+iOKJYkUOQlpXD3gtC4Xm8sn6/FWIQ9ZfdS3FKFqGSjMUaQCLHu3iIXIUMif1/L6VUOCuGJc+y66kAWcsV4UR/CR6IKFl937+7lYYecDOReCMRpJLvHLdgdPNISzh8evdRAV6NS1IBLx6zNUvFQkJq3CN1SE+vrFs549W/WcKkqMK/X+Su5/eiUAZeZ7SniPB+4yQjcTAxCv5Kdd2uIQZA5fwD5gO72KggaBJKocG1cPRglT6xBqYvDKVaeIyTNq/v2S2L6/lgJUTs+RjknK/s6MENNYHhEotqQTwfTFoLiHRHdOO3Fw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6f8b956e-efaa-44e1-398c-08da4a7395ac X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:52.1633 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 03/41] avcodec/hevcdec: Make ff_hevc_pel_weight static X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: rnEklP/7GfXa Only used here. Signed-off-by: Andreas Rheinhardt --- libavcodec/hevcdec.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libavcodec/hevcdec.c b/libavcodec/hevcdec.c index f782ea6394..e84c30dd13 100644 --- a/libavcodec/hevcdec.c +++ b/libavcodec/hevcdec.c @@ -52,7 +52,7 @@ #include "thread.h" #include "threadframe.h" -const uint8_t ff_hevc_pel_weight[65] = { [2] = 0, [4] = 1, [6] = 2, [8] = 3, [12] = 4, [16] = 5, [24] = 6, [32] = 7, [48] = 8, [64] = 9 }; +static const uint8_t hevc_pel_weight[65] = { [2] = 0, [4] = 1, [6] = 2, [8] = 3, [12] = 4, [16] = 5, [24] = 6, [32] = 7, [48] = 8, [64] = 9 }; /** * NOTE: Each function hls_foo correspond to the function foo in the @@ -1509,7 +1509,7 @@ static void luma_mc_uni(HEVCContext *s, uint8_t *dst, ptrdiff_t dststride, int my = mv->y & 3; int weight_flag = (s->sh.slice_type == HEVC_SLICE_P && s->ps.pps->weighted_pred_flag) || (s->sh.slice_type == HEVC_SLICE_B && s->ps.pps->weighted_bipred_flag); - int idx = ff_hevc_pel_weight[block_w]; + int idx = hevc_pel_weight[block_w]; x_off += mv->x >> 2; y_off += mv->y >> 2; @@ -1576,7 +1576,7 @@ static void luma_mc_uni(HEVCContext *s, uint8_t *dst, ptrdiff_t dststride, int y_off0 = y_off + (mv0->y >> 2); int x_off1 = x_off + (mv1->x >> 2); int y_off1 = y_off + (mv1->y >> 2); - int idx = ff_hevc_pel_weight[block_w]; + int idx = hevc_pel_weight[block_w]; uint8_t *src0 = ref0->data[0] + y_off0 * src0stride + (int)((unsigned)x_off0 << s->ps.sps->pixel_shift); uint8_t *src1 = ref1->data[0] + y_off1 * src1stride + (int)((unsigned)x_off1 << s->ps.sps->pixel_shift); @@ -1658,7 +1658,7 @@ static void chroma_mc_uni(HEVCContext *s, uint8_t *dst0, const Mv *mv = ¤t_mv->mv[reflist]; int weight_flag = (s->sh.slice_type == HEVC_SLICE_P && s->ps.pps->weighted_pred_flag) || (s->sh.slice_type == HEVC_SLICE_B && s->ps.pps->weighted_bipred_flag); - int idx = ff_hevc_pel_weight[block_w]; + int idx = hevc_pel_weight[block_w]; int hshift = s->ps.sps->hshift[1]; int vshift = s->ps.sps->vshift[1]; intptr_t mx = av_mod_uintp2(mv->x, 2 + hshift); @@ -1743,7 +1743,7 @@ static void chroma_mc_bi(HEVCContext *s, uint8_t *dst0, ptrdiff_t dststride, AVF int y_off0 = y_off + (mv0->y >> (2 + vshift)); int x_off1 = x_off + (mv1->x >> (2 + hshift)); int y_off1 = y_off + (mv1->y >> (2 + vshift)); - int idx = ff_hevc_pel_weight[block_w]; + int idx = hevc_pel_weight[block_w]; src1 += y_off0 * src1stride + (int)((unsigned)x_off0 << s->ps.sps->pixel_shift); src2 += y_off1 * src2stride + (int)((unsigned)x_off1 << s->ps.sps->pixel_shift); From patchwork Thu Jun 9 23:54:46 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36108 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654224pzj; Thu, 9 Jun 2022 16:56:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxBqQdcIWTkimv9f3gW2z1eZB+o+CAcRS2wJQqoKVbevE2C8fBRPEtvW472Kp5bDV+OKoUI X-Received: by 2002:a17:907:1b09:b0:6d8:faa8:4a06 with SMTP id mp9-20020a1709071b0900b006d8faa84a06mr38046382ejc.701.1654818980549; Thu, 09 Jun 2022 16:56:20 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id hr38-20020a1709073fa600b00711dbfcc0aesi5872359ejc.486.2022.06.09.16.56.20; Thu, 09 Jun 2022 16:56:20 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=pKaEggl3; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1891E68B82F; Fri, 10 Jun 2022 02:56:05 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E869D68B73B for ; Fri, 10 Jun 2022 02:55:57 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fm8qa4xBgBQUkB9+3hktWqJHTStAd8S/nPht1iL2s64GfOlF8BgTBr4ADxgN3FehBSqoSR44t6y2EAnZ8e2IvxZLuJWzeOpAiPO6nTmROvraZJyOdXNG0x4dFyVxUdYUxxle+z9pkwlZqZwcn/fkgi1FXcJPhhrEB47N22X1CrFmV265nWUKYFfDc6p31dIdbsBZ6YYE0ynxATt3+ywUM+TqzVelEMtWDTBNb3MGMRYalEmXM5eItosqtAC7XMCX72HVmYDp0/tJp6Ph9Xua5Q7X877gF2SzC9jTM4g5WFqDRHLB5JUU0m6P+QwJeD2AmrPLXdVJKBGev5558tKZCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=nIxcIInCMCf+uhpxht9GI9X/AsHD0WGI4fCUeHnnVYI=; b=Dz5iLKYlG1lYw+xpnlz883IUY4n9lGigi4/N9DUao1tpw1S1pi30CXWJU/L3B3K18HATPErTEjbnHZ3jUSzrgZs7OElrFPqKxPfe7Ul0jukT52YA39qE7tmmsMYrLqKj61dZ2V90bo2wYngHEjWlJh4F3Lyu6zRC/srdSjuMyA+eImFnFJCrbKApd5pwTHg+W+8g5F8i+AsIXbFdM9Q+CrSMXazvsp4Vz/GmE7JfkpdykWg2qPfwV5AVxnMIfBfdMHRw0+0zFZOOPJUJz6GVhEnjz33f7NBqdGUXIvxVaPa/HAA8dedV5qvBQ+341SMxhW1ei0U3hp85uvA3vt7pxQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=nIxcIInCMCf+uhpxht9GI9X/AsHD0WGI4fCUeHnnVYI=; b=pKaEggl3HqRmrFvfjaWxmr30b2HbYYeQspHtlScTQLTZuRAqUCTdz6l9tD1stTfxVeo4/MkZV6f0RlxC/BoH9AfAYdvIx4fKXSn8CGIf+WINBlWQYIIs3cby7pB1JW1TwQQXvE3lbDuhaAfiOTLDv+VMkKiXmOpPJ2QmyYXOySMLFHjA0WAoLR3gyysjaW4tMoKe4RvYXuKcVnxC8+IUYAokY6O8TXoMZeD6BB9zgUktqFdyBWH45Ik6MSXn8g5MWX9QRJiOVv2R/KVN5BXx4kbuLz/DWLn6QRan4Q9rpJmx28ln8FZLkq40Jm/Ux+Zh3OFc8zv/xz1HjrWRtyFsnw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:54 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:54 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:46 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [r/F7AqtR3pzjpZe/3fWEYwF3JjIJqYe0] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-4-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 82746ea9-2e43-4fd4-ee52-08da4a739724 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKEjLrb7S2/z6HjP3g4hZPQY9YxRQF7m8hXdAkbDVJyTeoTKT1vCF4us0sh0tcYNEFOyA9INMUl630QlNyAgtxiOFMr+2SOfBMWvrluZP5FyEFQllJpfCvBfBDzM/IeCWEsf9Mteo+PcAr9E72emsCG+WFR33znHU6Lu+ctvgZKPqrUsSrFS/Pr7fY371h5yqBePTjI2G0Qg28zS7ZClkHXCXUWdP6x9XwX8DlIho8zbSKMr/C25Jpe9mqd9fIWPCsoitYLH5dXKVrz7D9c/CnNJCAqgJRRe+VCmZ/FlwrXzXmC892o4ctNlSF5kPNuATevK1ZhPSfWdpu9RY8i2macHnX9C+DWc3++wcVxBdkvXMkxAdwychH1b/nhlCX/GcDtXN5hLgshxmOB7KB2ekUQNdvx072jktsgHbGGfrttC30NRj9a/tW5oFx6YnpbGeAOdyRTu3ZpOg+3U2Srx+KQFlgyLZ1ounHBJQU7PUENVMfZVRcaIJlK49DurBAPAKDBNgwV4fD09xZ0I9a1fA+uLyc4UMeeQ0GmDzWveqQS5f8BxKFWswx9iWWDy/GfPVrJZ2RryuyKpyDsp5gHkL9YWGNQ7XFU6sYdbkWbZTEzQLTXWXOnBCCsTGwiX1qJYWH7i5aQ/+nCp/06+no1RZXDCWQ8xYd7ED1ffgBZzScZCWX1pCs+2asnWl/kEHhK4Xuor+8Z5IagDe9GPHBayMwafBTv4+upUMGerlQeG0Kewo= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: KrI/bhHe5seJDmfNJPGXxVPwCv0enDrautkpubigdtCamPUwlMSjR9V36fG9Vm4Lr3WYn1AExwry0fBttXpHJX524r5uVdzudrWwong63y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L9NGApPwWbXu/0eKZGrhfpgH/pVTNH3cSUzPs+7BKyxJZTap9cE+3mtTeAUUOgLQ2qbaaFHayjRg80JD3WEFQXnchgIzlJ0ORR9+OJ5LQg4uAsFZe4sw2glhajd7/E/Pu3rtpj6TJau5aDwHPeomgjKhU2tk3uqUCSMJEXLUYEUZEHd54WYil28itR2XM3Ats74qpCAuCgktrkzipXTmgUm72XAAHG83cFRVkUUe19Bp59N3zz+V9UKuVltKPZxBOWyebcCfRdNcxszilbxYLhB1R4CGzSgEhf3JGmjHTWXib3QN1zseGQCgfxEFkjPMWia5IBGANqElDm8EOGDa3dXph9UCz4Y/c9zIzr/ZK4UOcOslqReXnW7f3HZ2GWWzVutEDDdgluY7HLfj4RIH0M/jDrCuRSCR+AeNlNZonQd3yyzDwI74ctFOJMdGZTXey8dZaft5Tv3Joo621GoI4FyXcW3jQQKUZRvDbC0DLxJ4Bw2857wNtFjbOHn6FqGMMFfjVwnZPyRU9mlIcCj6d3QnuFLY6eVOQAr2KSu6WaWVs0AehiQlUDJYbGwg74m30I4pTOd8IIsGI9US+Ua5vnlNetNjNM3oQAIDrrgzKhYD1k53aLn7Ms2YladCYyYKNZw801AMbksjGBmnlrfLe2Fj5ZAZroJXELhTd5BeY4lZq/sAGF7EBfdmSt0aaNhTNI+z8BbbBfViGWJ59tk6u4JyADnqM+aO1I6Ep4r5By5KCOPBpgNwqzfROoA5EqUBA3unhJxsWXQHaRhl4WgLHgahnLUlIPUmDCRwGNFZ/5uJSUy1js0A3eSGe/9NnmH5IYBfcdcYuakykE4ERi4cTQbLlP2ZMcY4fYskIPx2JrLVQiiYy5a0MAULqXo59cKTCNVXL+UpYk+aX1b+kQNKOiMQOpmcMGZYpoIG6Sh2OVFkTY2MgZtrTt88ByPLisGYQLqTI2FyDhfxpItths2gXeqs74Q== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 82746ea9-2e43-4fd4-ee52-08da4a739724 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:54.6789 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 04/41] avcodec/v4l2_m2m: Remove unused ff_v4l2_m2m_codec_full_reinit X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: jJFghaj/xnxw Unused since df701ed0b582a6b5c763310b4225446089cbcfb1. Signed-off-by: Andreas Rheinhardt --- libavcodec/v4l2_m2m.c | 76 ------------------------------------------- 1 file changed, 76 deletions(-) diff --git a/libavcodec/v4l2_m2m.c b/libavcodec/v4l2_m2m.c index 3178ef06b8..51932baf84 100644 --- a/libavcodec/v4l2_m2m.c +++ b/libavcodec/v4l2_m2m.c @@ -244,82 +244,6 @@ int ff_v4l2_m2m_codec_reinit(V4L2m2mContext *s) return 0; } -int ff_v4l2_m2m_codec_full_reinit(V4L2m2mContext *s) -{ - void *log_ctx = s->avctx; - int ret; - - av_log(log_ctx, AV_LOG_DEBUG, "%s full reinit\n", s->devname); - - /* wait for pending buffer references */ - if (atomic_load(&s->refcount)) - while(sem_wait(&s->refsync) == -1 && errno == EINTR); - - ret = ff_v4l2_context_set_status(&s->output, VIDIOC_STREAMOFF); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "output VIDIOC_STREAMOFF\n"); - goto error; - } - - ret = ff_v4l2_context_set_status(&s->capture, VIDIOC_STREAMOFF); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "capture VIDIOC_STREAMOFF\n"); - goto error; - } - - /* release and unmmap the buffers */ - ff_v4l2_context_release(&s->output); - ff_v4l2_context_release(&s->capture); - - /* start again now that we know the stream dimensions */ - s->draining = 0; - s->reinit = 0; - - ret = ff_v4l2_context_get_format(&s->output, 0); - if (ret) { - av_log(log_ctx, AV_LOG_DEBUG, "v4l2 output format not supported\n"); - goto error; - } - - ret = ff_v4l2_context_get_format(&s->capture, 0); - if (ret) { - av_log(log_ctx, AV_LOG_DEBUG, "v4l2 capture format not supported\n"); - goto error; - } - - ret = ff_v4l2_context_set_format(&s->output); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "can't set v4l2 output format\n"); - goto error; - } - - ret = ff_v4l2_context_set_format(&s->capture); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "can't to set v4l2 capture format\n"); - goto error; - } - - ret = ff_v4l2_context_init(&s->output); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "no v4l2 output context's buffers\n"); - goto error; - } - - /* decoder's buffers need to be updated at a later stage */ - if (s->avctx && !av_codec_is_decoder(s->avctx->codec)) { - ret = ff_v4l2_context_init(&s->capture); - if (ret) { - av_log(log_ctx, AV_LOG_ERROR, "no v4l2 capture context's buffers\n"); - goto error; - } - } - - return 0; - -error: - return ret; -} - static void v4l2_m2m_destroy_context(void *opaque, uint8_t *context) { V4L2m2mContext *s = (V4L2m2mContext*)context; From patchwork Thu Jun 9 23:54:47 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36109 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654297pzj; Thu, 9 Jun 2022 16:56:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzGvYpsZhb9n94/0Y8Kt9F4onCmb5Y7APaQVpM0CHvdlF2Cg29oyva6Nu7Ly1+TEPGeBAQR X-Received: by 2002:a17:907:1b24:b0:6ff:235c:2ffd with SMTP id mp36-20020a1709071b2400b006ff235c2ffdmr40312040ejc.116.1654818992873; Thu, 09 Jun 2022 16:56:32 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id i7-20020a50fc07000000b00431fd4040basi5173234edr.105.2022.06.09.16.56.30; Thu, 09 Jun 2022 16:56:32 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b="Ofri/S5A"; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1E10668B85A; Fri, 10 Jun 2022 02:56:10 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 0872168B83E for ; Fri, 10 Jun 2022 02:56:03 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PdCMyqTjaPaAynHQggT7h73paF3O3zcxAkLBOXoSKmoSud7nJwdEDG30wiSOKn2OISMbJ6O9x3Ia+J2O8ws/mbl2/jZs2kfhQ7ufMxynuWSTqmYPde5KaZxbD/Gb1waWyL8VUg2/dPVc+vwseq2qTUvZG7Se/sTjW9/dnnO0ifdSBjlRMLLLFIFu1L38JL2WcmBSsYKXQgklae7Ed0W1eHkrzKQCtwWzqu6NUTFVXrapYNGyQcmtJpvE5qX56XMDO3c1Uo98If/jJ2coEzzMjI1ABUlsK7NusSoCjw2Hpv0aVGg4Np0htC8ciOCM/jXZEPfC+fgVE2+6UQkDbqzLnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=GiHZn7eMPdUpPv1ubNBJ0YoJzKWPIHLiN9PB8rF+4HU=; b=RQoteCLsSpLx7OpT4ejX9H2l1nROkY/iHWhmnw9NBky3Jij2gYm/DJYD7f8YCNK1Ibp8DPBWturqnO8AYYUlh7an/5+yPT8TnZoj17jCyWbvS6AyBErpLRaUWTFfysgPXAR4SbDetiE3yBRYwy2j26ciypu9oDXck+Gb9WDp5WF8i64B7Pt27a+RZ1wBW5uBh+xzAlcvf4UxkNI0a46CRYrECIQzrncZ2qiHguPVuOc6D0XUwoE9e5QcrlhF7kGq0nynKWGRkjkj26ZncsOJk5mix0+CBS1ZAAMjK9N+jnRS8RlEAuDGmok4xyNenujZZzZ6OGXnGTRBl34ybtsfKg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=GiHZn7eMPdUpPv1ubNBJ0YoJzKWPIHLiN9PB8rF+4HU=; b=Ofri/S5AwkVetDUpHJOp9gYnnKde65pIaDsM14UbmXCNL4WmeIQr39nHKnNOdUnJWUhc9OO9rSH8b0tI1uAf0kizs/SgWsgk9Wfgvyq4bVrMwwIvcaXDKy0dxy5J361T92trcHFFCNNiwhT2r9ywtqYtbJd0rBRBsQxW7PUSW8ynpR1r27JGof+L52dqEw0+3Afaz8AlCT9cdNEHCO+0asRO0GHsSxLDt+DOD7HieBGRN/uEzyYNvfgtecuPgKZCHsMl5nF3OZUDmFniaZzR15HnKAl13IKDjMJoP8wmWQVlqsRkTQFLwPjkivMSo29T1I7tQ4k8IfLd4lgSKMHNOQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:58 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:58 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:47 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [hyAnyqFOuxsVlvWov3GDQ+bDFCQV14Kc] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-5-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 79a1c578-3822-4a23-99a2-08da4a739976 X-MS-Exchange-SLBlob-MailProps: gjx25WM8ZNW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qog408gGKCApfGP/+h/5qKYuXs7U+6hy1zvCDF4l8pFrVwbIPP3pDFhx8pLUitB/X7oEE6Nd/+Ley2bHEuNARyOCS/IUvX8omh+0dTTHMrhCHRr4JkVsSX+/CJLirUtvWnPhhihJPhSmwRaKYtrTFAAk3UtYsIVAUw+vtxGtW0z3F3q4NlqRJ6LGSiiVZA4JM+kEG1dua7fuxCr/QSBSLMVFnz68gvn0s1BgwnfAHhQmfQkit95lYjjv5t/Q1UIYF2wlYGpuJ304r08q1G4CzTmes6QFovOc4iNChjWtUhwLU7lpRyVPjZ3OVWHDkBiVa79SmqwRjU0bLGv+8EJ+qTwQqpiIlAI/Cpzf4ZSioiAyGioNfclOH0YKJfQsX4mnSBvQQJtG+Lmuro0sn/lmkpFZvJvvFXjKO8Pqae5ZFVOtOM2cBLkEWwwWOm0+hCEChON+NbQHDCvCIW1VdWt2ZVVAGwUkou/R+d7xlf9HchKFy3bKId6jEvcNSIfDZ1yyem5D/XBBJYsvZE5h0tl4cMmr1rT0wZYBGQmMgzIue4PU9wtPDQwKbZ+JemQlDuhiqUl3FLvS1ExH4RtGSeARQLN+VqNMFuOQDgg3L/k1CnANiLDC4z75qkycuqxUAgG2HP8HAikx1sey2XmB1ii6GM7REkUqSkYJen4bn2TsZavlQ66cqen+N5PiNsXU7YYQLMRfbNIAgEdJHojbEJjsLfkvbRNDLbfESU3PRHHX6qbhPWCFHFPfzvsibon0/5RhVamYwJKe6tIUADW2746pPva62vz0S7BAG8kekA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 79a1c578-3822-4a23-99a2-08da4a739976 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:58.5071 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 05/41] avcodec/videodsp: Make ff_emulated_edge_mc_16 static X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: UoY5ijGkLD3d Only ff_emulated_edge_mc_8() is used outside of lavc/videodsp.c. Signed-off-by: Andreas Rheinhardt --- libavcodec/videodsp.c | 4 ++++ libavcodec/videodsp.h | 1 - libavcodec/videodsp_template.c | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/videodsp.c b/libavcodec/videodsp.c index 2198d46c15..02af046b81 100644 --- a/libavcodec/videodsp.c +++ b/libavcodec/videodsp.c @@ -25,11 +25,15 @@ #include "videodsp.h" #define BIT_DEPTH 8 +#define STATIC #include "videodsp_template.c" +#undef STATIC #undef BIT_DEPTH #define BIT_DEPTH 16 +#define STATIC static #include "videodsp_template.c" +#undef STATIC #undef BIT_DEPTH static void just_return(uint8_t *buf, ptrdiff_t stride, int h) diff --git a/libavcodec/videodsp.h b/libavcodec/videodsp.h index ac971dc57f..b5219d236c 100644 --- a/libavcodec/videodsp.h +++ b/libavcodec/videodsp.h @@ -36,7 +36,6 @@ void ff_emulated_edge_mc_ ## depth(uint8_t *dst, const uint8_t *src, \ int src_x, int src_y, int w, int h); EMULATED_EDGE(8) -EMULATED_EDGE(16) typedef struct VideoDSPContext { /** diff --git a/libavcodec/videodsp_template.c b/libavcodec/videodsp_template.c index 55123a5844..8bc3290248 100644 --- a/libavcodec/videodsp_template.c +++ b/libavcodec/videodsp_template.c @@ -20,6 +20,7 @@ */ #include "bit_depth_template.c" +STATIC void FUNC(ff_emulated_edge_mc)(uint8_t *buf, const uint8_t *src, ptrdiff_t buf_linesize, ptrdiff_t src_linesize, From patchwork Thu Jun 9 23:54:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36110 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654332pzj; Thu, 9 Jun 2022 16:56:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz78zxpPrRRrU3Ye34YkmQWLbzq3iNG12oNXT0xP2XP01OODfP+0AMYbkTYaNVCeCHz6flb X-Received: by 2002:a17:906:77d5:b0:712:171:d3b1 with SMTP id m21-20020a17090677d500b007120171d3b1mr6219837ejn.191.1654819001089; Thu, 09 Jun 2022 16:56:41 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id l7-20020a056402028700b0041d76e18accsi16742545edv.548.2022.06.09.16.56.40; Thu, 09 Jun 2022 16:56:41 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=KoPqOftC; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id E326768B844; Fri, 10 Jun 2022 02:56:10 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 31C4868B83E for ; Fri, 10 Jun 2022 02:56:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HEJanZY1fYSYCb3YaBe3qb9d5bn3lV93Z/N3QJJmqzAFMjS3p5xdh+7/96fs5mZq22f3ZvMQ6yfehWrhfWMZVAIinUc5BDMNTHPOnqi7FRuE3utL4QMJyeOKY/IqRh7IO1TY1nIJBal4kXBJlGnl9lNj1KRWPBFLNkVyTgo4fK9Lhhxo8YzCicz/teHTklQJU1AJdOSTed9wL1qPYp5MMsL+nMYFdilPK/ezG5tDVeyzZ9VmayR7HVrX1n0S+sSy1Iro/myUm/2r1XHzv1/EdRKn1WfH3cWGKG0JnI2795oquCrMy68yrTcpBTrDZ9sSt0ofc25p4Q/cQWfo3Q8kXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=LIfQ02v+T6pvwBx0ganOQ+V/hoe7rTBasr3r8EJrg9A=; b=PG5pivKXmhacGY+1dY/TfjgttA9zmCR66NY8/KYtBrVg3rkSOC+H86QRS7mvMR36NqGSXj7f4YaG3UONGQgCzfIpctG6fRE5EQXoXlYQ0MifsmKe9B7aQLXXZ4eXuIjaFHzif7o6VnCbO5u0sRupA5Is3Dhmhj8WVubxt9jddonihGKAZ+a4Rn4cjMjMzsulcijjDcHh4xhqhFNg7btqfpBVxivpwoMac31t8pFp14bgs68VHlpjf+brNVkfNC7n5qK5cglriU+bJgPsVHC+BqkEC4NGsbc+sO5wEjyJqnao1m+5VFd1zL8+00IRHx52wqK24LnkkbTPuEVFidFwZw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=LIfQ02v+T6pvwBx0ganOQ+V/hoe7rTBasr3r8EJrg9A=; b=KoPqOftC1JnVRukF5B+2JW9iGrei2XihjiJD3C8udHkEa3chfb8mmN4wl5gLZf4RkgC30qnKaFIck6ifSN/Og/Qe0HW58MjrXBRStJCjVzWpEU/+Qz/8594Uy4/zSCfaD7WFy/AN6cH85cT7/yA6A0m3wNX6VWvuM3PA9/69H2Sjurt/qyj5gFFc1kIIfCZ1ZwnpekzJHG+NkIVpJo+sialgmc72HsF9lEiKGbl+p6EFBx7htFqyhPod2/FB2m9DPaLf1aWKsHQLw4ZduOmNVxPPFhT5x/LSDFjx00ao255yh+K8CbZ5V/RI9KEkp0RvsUqNG2zOBCIa9mMPff+VcA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:55:59 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:55:59 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:48 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [qS+NgB/OrJf7wjMCRA9V79CiX0u4lsIS] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-6-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 046a4002-69ab-48e0-1b1e-08da4a739a3a X-MS-Exchange-SLBlob-MailProps: q+fD6XS3/UIAJF/k4bgfs75ONqEeBzm2HqtkNuNRAOoears4c+6Lq/exIfOTkl1G6yXzqdLHPr0cP3KT0LIfHMJ7Ds/Y84e0LfV5o3aumL2j+IYlia+rCfxcwazN7tYFR2s4LzAG9g+RfXkLN+FJEDX2TJfOkXkFNobn09e/bEQlsAqoHYPhniES4aRYpZ2ECAPJq3Md5kSqhpfWZG8jrctDrnCCjcR8YqBLjx6WZrLf2JYjzlHzPlxBhuEVRGbteMdPLFqh2s+MX3yhJLLF5wW3RZ5DkbH44mbIAktADs9h8v6skMNCGGZfEnLVcKNAwiSKbxjPn/sDgiWDP1ymXbVsyNZyOJsZnUn56BX4mAul7Y/glG93uUW0gvWjuTjdgJ1WReOezoUgQGc3eFbKoiSC6TJD6Zg/aeXdbVZGRDGfbZf84px5EedLYoifKcOSkus/Jxe03/n5U9yiBphu9vKKAk9gABH2hxt8u3hpB0f45K0Vg671xvhwD82r7oJ4x0fyaDIbmMk+0pbXTFBnA5biRmgh8YQDTcahm43sGHJ/Xq87tXNipBSfbSEcatiorTMv0IpGI1STKIMfkBfS4m+HcgK389Q8Idhu0lvlCFmxKdPIPtdM1hdTQ3OcKz1oCXJdyyguOjuwYtKpQ4DlinTWfz97MePoTaFvgTzadUP3H4WRiZs7VjVjW/wzw+rJyXTDd1tD2OwdZ+vx4z2aRQ== X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: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zlEGo+k12cN0LX+QUqe2/JYSzw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 046a4002-69ab-48e0-1b1e-08da4a739a3a X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:55:59.8352 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 06/41] avcodec/x86/fpel: Remove unused ff_avg_pixels4_mmx X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: eqIJZscHp8oX Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/fpel.asm | 1 - 1 file changed, 1 deletion(-) diff --git a/libavcodec/x86/fpel.asm b/libavcodec/x86/fpel.asm index 961a1587a7..d38a1b1035 100644 --- a/libavcodec/x86/fpel.asm +++ b/libavcodec/x86/fpel.asm @@ -90,7 +90,6 @@ cglobal %1_pixels%2, 4,5,4 INIT_MMX mmx OP_PIXELS put, 4 -OP_PIXELS avg, 4 OP_PIXELS put, 8 OP_PIXELS avg, 8 OP_PIXELS put, 16 From patchwork Thu Jun 9 23:54:49 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36111 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654397pzj; Thu, 9 Jun 2022 16:56:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwwtZW3bgB9SSxYd0oQ+dZsYsWKMfBDsxaPlsnOOXkpGnpSaowGIkNx4FSRBvJ1xxkS1L9O X-Received: by 2002:a05:6402:289:b0:42d:cd82:be22 with SMTP id l9-20020a056402028900b0042dcd82be22mr48003930edv.373.1654819012030; Thu, 09 Jun 2022 16:56:52 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id d3-20020a17090648c300b006fec271359asi26670130ejt.57.2022.06.09.16.56.51; Thu, 09 Jun 2022 16:56:52 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=IfaPem2R; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id BADF868B860; Fri, 10 Jun 2022 02:56:11 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 4549368B840 for ; Fri, 10 Jun 2022 02:56:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QGwSmC2QgSOyQOzhUVPGhKNL60Bol4EsQJ8Lp2sIKl1bST8OO8E4BgHH8/b9Gc7x/WiOIfvVui5c0dvT0mBD70s6QuFmwee8AfkBUw9TMX/0rCexNCYuncWmXkICmF8k2jS1K31uB709+GsOlT2Td2Y/lf8reSvymwYgnPQ1IZ9qhaCUzMxsbnKaaoBCb997qCuFOJGityRT8UpjI/QAFUa3RR5Ub2rSQSNQkCEbyzRMY18FDNpa56olWpsUswWzh+yIbOwGKbMTjeZ9fgvyZZggePkKSMjLg4+OteazEJctyKiOlDDLSkyZ6wFFxxfKlWAsXgSC5R0V9tcHpOdOcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=HoyRCEbOkiY+cAfwpRLhOwt2vz37K602yTbsOptzpr4=; b=TjNEOPVeNKaUoGrllskS3olduvkF1KUHG80lNfNfNvBpE1qDJYBYLhynAM7fETcewGs9OCfls8tSq3HS3FaURCQa9QrpvkBPN8f0XiMCHZ+/PKfrX4dAI/S3jMnDZXNlEOl58Ng1quZiySS8hkfXnaUW0TQsG/swNlmQF0QgSage3Whj4v6CM8lYJfNKpAvdlnwyPLeEaOyRKUOIfsTioy4z9FVzk+1/EwzN+83n80yZr98Z1ZY978HZR/jPEuTvQn4dGh9FvACZXokr0PYFt/ojljV7DOtG1oSDSJ30D0f5IWq7sIFAh6UZafJzlHz/r8wYgnYMVjv6Q64wdY/xTw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HoyRCEbOkiY+cAfwpRLhOwt2vz37K602yTbsOptzpr4=; b=IfaPem2RPx4YHK5/TVw4LcyLgM+JoEYdgHEba2tsdFNQhH2DFLv0biNae0xouKn5vtaUp90S8j18efLmVL9zjdsmE5r3/hhXXRZlK8vun7tO/bauglFcsN8Feoxdb4nejWVUBALBQfGGI26P6bvW2VyzyHrLtwxKRAcrnWICdRswhTdE3XKvJeII9NlyANutjrrvWvZnw9yvNhBlQYNihCPqnAXjwnUrDm9EYCtaXZthOfxIp9kFZVH63/FOM5E5f/v14MpZQjaFni5oJ/GBDlckbICo5vFggZl3LsN+RiIOGw/OEhT3QbdxOnztAYlckopkAYYj1+8IXcRComSNKQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:02 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:02 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:49 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [ypUIFqIZbaGOfHx29f4uieYE5VlW/27g] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-7-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8c0b0f48-dc1f-4aab-5692-08da4a739bfa X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKJJX5vS6LnOYVJyoTPbC1W/iBFP2mIwqjGZQq39mZbpiFIF/SxAWDoUQfiWqCaZAn4aq8O2MhsvUtr9AVeAPjApjurHkL0Foj95ptOepu9u+/1JiaAqgb0msL8NovAYJ2yNm7zmoV4shwqy2VD3yNWsb/KwxUoVW7HLY3s6T3vihthEilNbC0lZHLXquWB1wYWOnwS1Vi5QKvzRIxgrkgWNdQ8qOFwgmf82ZQfywQz/u/WEgA/uF4M37ldpgOtavXnZ1LWXQppYCu5uKL8iI38h3h+KAl+LxOo7L2KluAgelStvMT+3jSOJ6vTvofLBu6i7D2c/CB06v37U5hkog3jMbwAly6f/wX9qL53SQsr0R5jZCXKd2PyjYsHAx+xyV/BGDnj+QJaHY3BbOeBC3rxVxTiv3BHdNyqq8aAta7KVVmCulahdE9JvAXxVVFxdA4l91CqP/60ciJjmFt/LZ255MKvBuyALjp/qTywMta7btyo73z1pofFUDQtErN1CPp7Hjzky2STD5HMJ96q4QfSOywoXQEemII1yG/Dd2Px7bVl3xVx3kNOVr6IVd48CXa1wcIz/nI5wav6C1V5umQmsFkPIUsG/XnDmKoSbCDw+P3Ib1pDkB0i19Srb9xOCJf/XVzRE104q1I2VlbGDv7yRKXZcHr1JTNHaG+h1yB2ovHyPs3fjl2XTnl1+kHdra+KCv7HPEwC4iqba7LbSTGZcP4Bi9t+bxnHJG5LDnnqWA= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: NIZmVqGQlfJrdfjJxYmTqcE8PsSr7diecOmylngW8cFJiJqc1TLeyL07lvYDjnXCOpDbP2qHIFrbGnvOVRKsAznzal0bbGaX7wlJlsbouEr/MkLSURl6wNIUVWVULpC396RrVcntljMuqt8Sf/cslkmOpjoJdycSFvg6mkRuJV8zT5bvCtraq1+W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69euo+I9TPxV2iDRi40iTXE18DA1fDO6+FtAGF6/QTMPijEGSW2Jg5cUbVoLILfZLIKAapJjiB2u4mbLBLq1Ate8sa5mvXVqva7ThFG9z1r2GdUdbK+JLTexwDdIBqCb3yQcvnzykUp0CFa8rGrtK0MG1iVozpXLDOkZF0qx1o69eD+LfbSNBXOfAGTHLaFxutxZrQ8hXahoszXK+UTuhOjORA/67DI7rEkdpwxn6TfCDSdHoMvx3iG/coIZCuJljx1WrwOlXOlyNkxp2ZVjznmblklRINMomz589i2rJgiM4Icy8FTqyeomwMRbsch+L3lkHZPwfhwxE9nvNA74cwYPQV+g1zMPOpj4sG1aVLoV3Sf4wjIt9Tsy75akz7GfQf0KyCqiL86o62BN0ndCk6lxLgv3fDBRgi/eA1oNqVi3589mbaZFdkY63n4r6ozxNGGkj0d7DSSwH8oc+dGUuH9sss7VwKWTTPeeLS2jbUHmNdo9dlbTbVc3plpV9PJHRRfe7FS/TWafAvVXufDlV4iVI41kyW0E9IY0CsjGWbAyD1QTBdmO0p5UqQ046uxh7qaDHl7k3aGWgarJmFWAYoQgygjUAeVcqmLTxO3O8PUwkjIwIqerqLVtkw/cAd2GvclgBTxZe7dl+X3bTZ1WlXOQCgj0RBWZT3NZYn5eaJhyLAkGVHH+Du2dAgpv5Y7mrv62x3+9TWQEEScSBWlB5VwaLMhGfNK+dUAGRdfP6DJZCpijcjWrSql58c95iW/J+JnA9zpp5SsPjeRb1OmnS40gnSXRVClOLcbb/sLTrGE/xNbpJu//+hXmlh1UwuV8mBHIvpJxp6LCCmkpROrTUcHIVIIJISCJEDcKryD8EeFIpIz9c/o2vAsGOhHH0Xx2A== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8c0b0f48-dc1f-4aab-5692-08da4a739bfa X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:02.7571 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 07/41] avcodec/x86/rv34dsp: Remove unused ff_rv34_idct_dc_mmxext X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 3K3oE15O4uEj Forgotten in 9ba9c3402499d90e54f8aa111b62c278206d11af. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/rv34dsp.asm | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/libavcodec/x86/rv34dsp.asm b/libavcodec/x86/rv34dsp.asm index 692b4acfcd..5568ddfdf8 100644 --- a/libavcodec/x86/rv34dsp.asm +++ b/libavcodec/x86/rv34dsp.asm @@ -44,10 +44,10 @@ SECTION .text sar %1, 10 %endmacro -%macro rv34_idct 1 -cglobal rv34_idct_%1, 1, 2, 0 +INIT_MMX mmxext +cglobal rv34_idct_dc_noround, 1, 2, 0 movsx r1, word [r0] - IDCT_DC r1 + IDCT_DC_NOROUND r1 movd m0, r1d pshufw m0, m0, 0 movq [r0+ 0], m0 @@ -55,13 +55,6 @@ cglobal rv34_idct_%1, 1, 2, 0 movq [r0+16], m0 movq [r0+24], m0 REP_RET -%endmacro - -INIT_MMX mmxext -%define IDCT_DC IDCT_DC_ROUND -rv34_idct dc -%define IDCT_DC IDCT_DC_NOROUND -rv34_idct dc_noround ; ff_rv34_idct_dc_add_mmx(uint8_t *dst, int stride, int dc); %if ARCH_X86_32 From patchwork Thu Jun 9 23:54:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36112 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654440pzj; Thu, 9 Jun 2022 16:57:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyCF5ShKgL0X5NgHg6PV/CKBotez6Rd8zJG7ZUQynSlYLfWiBDZ9ONK34kwI2qmosnVLSfl X-Received: by 2002:a17:906:586:b0:70d:9052:fdf0 with SMTP id 6-20020a170906058600b0070d9052fdf0mr32982139ejn.633.1654819022314; Thu, 09 Jun 2022 16:57:02 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id hp26-20020a1709073e1a00b00710f5f817ddsi21243683ejc.462.2022.06.09.16.57.00; Thu, 09 Jun 2022 16:57:02 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=ie93K7hK; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id AB5FB68B867; Fri, 10 Jun 2022 02:56:12 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 58F6668B83E for ; Fri, 10 Jun 2022 02:56:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WX++UtcvsBDdBcspV4c+wLg3W8dFf1mobo92DqQlZE6g+hC/IztESr1byPeEp+qVqy22xXMPHmguy1P+ek6pEBizr+q88asNWy8HUuB+bhWGCKzYagYqUiS7VkzgRA5Z8TmZXjeBBQktFY6tMm9TQdzG72c2lSbOHaeWvSox3a5l0/FgfWoc0yWicNiD9T8zofg3EjpdyH+tqE3cMXWr7PLWNk4Fe4CNaa69cCc+IGphm3LGcRQFQknvr4oDfZB75mNMx8j+pACUP4lXNgd4UqlrZHcLR4T/O0CdYRwpbV9gFsvYyQbEp5ffzO3MmUvYM7IZGiCcGn1dn2a72WGVpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=XC0wIUOltvnEZ/CgAQrKmcRXa5djalpAnI0GKhlRAiM=; b=Csr0TRT8Gyz09Kej2aWaqlONdbG22QMylNL0WdsGB6XI7yDKbz2MVB3tKgO2Vt27CTTIiOkpaj1AkqYkcOjOraxNdP1JpzjbNeQVKPFV1d5dqUypphK2X3g1M6opeMDBLvY+Qka3L+wotUbgJQXYmlO+8Ts0uarBrWFcOyNuS7GV4FwekW2Rk70zDPKiShv95qIGhFjpLrdan/ehm1Z3fjpkYZOzTSCW8UbncrUArwJZGtxnd/OCgbcuQBs5Vm8Ix+INhj+C7qxXrjjr6ed0vhvqLISVcADM1yO5hOBQDEGzop20X78cKgfuOE3p4IcawSza9x5Y1313M1FmXBgiQQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XC0wIUOltvnEZ/CgAQrKmcRXa5djalpAnI0GKhlRAiM=; b=ie93K7hK4B0vIpvQJhYGS6UIV6OlHSkZX6aMXyhe2gE9PpohuyI/PBZ9DbodW7gR3E+Y6ZOWymxaBwwgDHtMfoynhaBW4Sh6KhwRPZixy72Yi4iEx395eIH1YaEGMtc+z4GsxJgt2AzU46Nx1Jv7z9o5SOf3G93ieLzM9CE4MCJp9wvQj4Co4lQ+g9SAfGFnPJn+rRQ/HfNlTxadKoe057aabvcgXmHuDpfh2DmuB/H7ljvFoKZk7hiNYHqDpqEkUao2XHRSV/sg/d89CV2f+pBoi2mngLZJa3fav7YovTCW7Ms8YYfafgYOFtbDCVTaFBvNjubb9SydXOfjndyrmA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:04 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:04 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:50 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [LY1YJqMAYzIKkqguTTXBNBJWOiPYHeaJ] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-8-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 67ad3e5d-2e78-4fd9-2631-08da4a739ccc X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKD8hn+1rXwJOC23+b70NfauSb80EFeXY7cqHAMP9b77UxPAFKWWPilXIPiIm+oDVpFOfV97dAyDucZEKxv4El4e11kT/itet63FvWscEdQuJ+rqqklSGNnMNA6r7WvBIJtLbAs6torXeeL1Qy122W5fu+VJKFk/qLFoEkaxmXdlL+k7X9vL0JzsRg1wuoj7qbVUVXUAksaAfpzYqzt43j2msUHUiulWZAmqC2tiDYOn9GXvz55r3NzZfNQxFKDL3FgzbBY88wblbJbJTNCJVP/NC8rkWwwSpk5u+2LRTnNhyY4hwRHK5AuB16UYXj0l/2PCo4ZM2tJDul9pAQPNP6H3hf3dBeM/7mtgwukW8TnIF9uYfiG82v2pOo47nsectStr1iuD8RId9pii4qI2AkioM8rdBKzSSEpmlYbLw2Q7dPH1tUWCLmg39QXZmyMLc1hBgEClMjJczb62GVJxVMkNQR8xpWDtVaLkThGDLW9ZFrcViDu1Pn5Znzjhl1+Q+p2p3D8IvLVin37Ea38J+AyoV0A1t62j7CyRqIADSDsuzsEGrf1EbPbkwyEYnLGelgoff5s7J78UpOTL7xZCBwvwWaaLf4h1OCsurCctdty6+iS7AcBm+6JcdeXQAqho/wAj2JNN4X0dqlKtGkTES/uz+HzXhJNPfJHICEGuALOwrhJpVxLpCoBisX8xAW9As8jaYoR5bOHA0zA2x/hoFclAojEw41XKSZM0Xrm6u67cE= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: mjJHO2SoPE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exchange-CrossTenant-Network-Message-Id: 67ad3e5d-2e78-4fd9-2631-08da4a739ccc X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:04.1478 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 08/41] avcodec/x86/h264_qpel_8bit: Remove unused function X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 8ffziasbP/C+ Namely ff_avg_h264_qpel8or16_hv1_lowpass_op_mmxext. It seems to exist since 610e00b3594bf0f2a75713f20e9c4edf0d03a818 (a function like this already existed before that commit, but it was static and av_always_inline and was therefore not present in the actual binaries). Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_qpel_8bit.asm | 1 - 1 file changed, 1 deletion(-) diff --git a/libavcodec/x86/h264_qpel_8bit.asm b/libavcodec/x86/h264_qpel_8bit.asm index 2d287ba443..03c7d88f8c 100644 --- a/libavcodec/x86/h264_qpel_8bit.asm +++ b/libavcodec/x86/h264_qpel_8bit.asm @@ -583,7 +583,6 @@ cglobal %1_h264_qpel8or16_hv1_lowpass_op, 4,4,8 ; src, tmp, srcStride, size INIT_MMX mmxext QPEL8OR16_HV1_LOWPASS_OP put -QPEL8OR16_HV1_LOWPASS_OP avg INIT_XMM sse2 QPEL8OR16_HV1_LOWPASS_OP put From patchwork Thu Jun 9 23:54:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36113 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654499pzj; Thu, 9 Jun 2022 16:57:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyErPE4vVCIaOCOkTAOpvLMKAiItjdLgSkz1ZDZs8FEYdPnELuTfptH1UWTN88+fKC/Z8dD X-Received: by 2002:a17:907:3ea0:b0:6ff:7d7a:480d with SMTP id hs32-20020a1709073ea000b006ff7d7a480dmr38641269ejc.750.1654819032170; Thu, 09 Jun 2022 16:57:12 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id d15-20020a056402516f00b0042b2375f906si17104459ede.327.2022.06.09.16.57.11; Thu, 09 Jun 2022 16:57:12 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=OYHqzyg0; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 9BBDF68B866; Fri, 10 Jun 2022 02:56:13 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6CEE568B840 for ; Fri, 10 Jun 2022 02:56:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=irA0bmnlWQ0yZA0pOmeBBSz8+adDE7ZV3a+9CEHdUA9rC7gDEvTahOJ2nNx9ODlKD7xMPbnqxO7jZ273oO/6YrLvXzRKus/06BwgfJFwT4tPleVxQRQv11vDm5PGKtcPYZdS9i3sJFCttuHztyX4eJmZ7dgfSsZme8B0QswXCXAPnJi6+zWTNbwrbYx+aGR4rTn7t30qduFe+bkXFkV/Dy3QD4m/zOx7KCenDiQjiOVauIKcR+9vPeAjhdD9Y0UR4/8XH1DvtLCcVME6HqnVEvcnhYjMAMeAT1wkmyQSoRxSu2ewtLm1fIUtQh8OgGLGd+57Afx4531hjg1M/nIY/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YKp14LLqSYipMKOLjsIsXgckmRdxeUMemdhaGLlKeTI=; b=MmgN3a3FssePS5ag11ypeq00Ry2dh165mnjPWbQ9E7yTh8hGXIwY5QF0BPDuBEvvC7oXH30pbcJcBIUXzRFIYfsjlHfYFrlrx0zq3mEp8NaV8fuUKaLxVkgo6XTY43zHOP1rQyx1KCb0+Y/B3yTWC3rtmuM8KdXfBry2csLU1+E7YPrtFxdnKk9cHhC2ytrORNiJx7gViDQ3jb3Sf4dkDpOpDQarSORwdcgSLAtjJCPh1u8kY1dLt2jNqhhcNognIfwpu9PR6GNAAWsyh7tMhSE9hg1CtLPgyiIVGvj6cJ9zxWXLKQdKPdiJfPuO1t3/FebOWHF1G0lfAKjeE9PIcg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YKp14LLqSYipMKOLjsIsXgckmRdxeUMemdhaGLlKeTI=; b=OYHqzyg0DYfAfTVmk4dh913t/YNT4Wb84U/+e26Cg1K6SVoVHosJTSXZKisAkEyqd9iDPCOXjp0VZqpwvCrZG+cvkhR6AIJk4+zKf5eut7R2vE0Ho3aBHHzo1IBsAZ19MDVaaS0SOjT5F2YKedjbzxBq/diC1e18s4nkZGOp4SUNBnBJFVfjoGgvnHu9mQ4+hNn/SqA1nOAYQxnzl9uIZSRBr42UrXtxDeAEaRQ4cb82zL6LmCUekINU5j3bqiobyr1Kxcy773Pg2A9zkx99fqtyVY/Ongs99ek0kp1v7S+PxS2Vs6G54cMvbJrOB3htlZCYMZXXmK67o+g8WmEL0g== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:06 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:06 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:51 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [QeX5jyDOa9Dx6LjaSKXtfMHi1bzE/eGK] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-9-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7159a712-a558-43e1-b526-08da4a739e1e X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKMY/u9/dCHeuGrjcp4sPm33RddRueCLoE3keyqQKiDzyGvUoju/10Ja4prtx4+FBWjZRc/W/siMLwBntYPFiDJU0Uer1VQXf4F2ZuucpUaqXGdsjNMSWIvl98OrlEwswmoIEekvkNHAD7Q45pDQqWpsl0e1PvdmXl2QmGJHUxAUgXGdq2xvW1WEETGyVzXKbpNBb/MVhztyTICqJjTswZpJaSZHPW0H8imh0IBL3g2iyCQQequntbDwqJmUunXgrPFTwQybEQkHsUifjVvjY/brDS+B7N3yISW9TpkUOjnmwIbfFpPi3WkPGtq/HfzSzuRZKyAaMjUNMGPhrdedBZnyvMLiwFpLSe5R9JW0GqqWOm5R4DMttngqjcWvGMgubpgaJRgOLJb9DTFdNwoeYCD5a2mWhep5wa1m/26FxA1zgSdixOmGXgCmViCoO60q3XUe0MIO57RBtmhrIbXpUvs+gBwO5JDR5MNvVql9G7UH7HGQzo1NG9PGqV5139VZMNIaAj6aOHusesFuurNJ2aN7wD+TAWxa6vlpe/JFepewsFGN1p/Tj35ERPrQCrEwpojG11+ViG+iXdKeOToREcIIdLWTZmQ+dzcSey1wynehGiKR0VPj5pVbTbZ6dAqg9PHbvxZqm0BaycCzEftwSt9dyhL4B4knyimOFBLE0VDDQKwLdRbBQU39p+iTvHkl41tqhJpfvA3eVJKftM3OJcCOBkEC/oPFECACm7WE7e0hQ= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 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com X-MS-Exchange-CrossTenant-Network-Message-Id: 7159a712-a558-43e1-b526-08da4a739e1e X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:06.3197 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 09/41] avcodec/x86/vc1dsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: YhOyO/98AzH3 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables these functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_chromamc.asm | 2 ++ libavcodec/x86/vc1dsp_init.c | 41 +++++++++++++++++++--------- libavcodec/x86/vc1dsp_loopfilter.asm | 2 ++ 3 files changed, 32 insertions(+), 13 deletions(-) diff --git a/libavcodec/x86/h264_chromamc.asm b/libavcodec/x86/h264_chromamc.asm index b5a78b537d..0421fa8695 100644 --- a/libavcodec/x86/h264_chromamc.asm +++ b/libavcodec/x86/h264_chromamc.asm @@ -448,7 +448,9 @@ chroma_mc2_mmx_func avg, h264 INIT_MMX 3dnow chroma_mc8_mmx_func avg, h264, _rnd +%if ARCH_X86_32 chroma_mc8_mmx_func avg, vc1, _nornd +%endif chroma_mc8_mmx_func avg, rv40 chroma_mc4_mmx_func avg, h264 chroma_mc4_mmx_func avg, rv40 diff --git a/libavcodec/x86/vc1dsp_init.c b/libavcodec/x86/vc1dsp_init.c index 2fbf0b3a74..66d894061c 100644 --- a/libavcodec/x86/vc1dsp_init.c +++ b/libavcodec/x86/vc1dsp_init.c @@ -33,9 +33,10 @@ #include "vc1dsp.h" #include "config.h" -#define LOOP_FILTER(EXT) \ +#define LOOP_FILTER4(EXT) \ void ff_vc1_v_loop_filter4_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq); \ -void ff_vc1_h_loop_filter4_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq); \ +void ff_vc1_h_loop_filter4_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq); +#define LOOP_FILTER816(EXT) \ void ff_vc1_v_loop_filter8_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq); \ void ff_vc1_h_loop_filter8_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq); \ \ @@ -52,9 +53,13 @@ static void vc1_h_loop_filter16_ ## EXT(uint8_t *src, ptrdiff_t stride, int pq) } #if HAVE_X86ASM -LOOP_FILTER(mmxext) -LOOP_FILTER(sse2) -LOOP_FILTER(ssse3) +LOOP_FILTER4(mmxext) +#if ARCH_X86_32 +LOOP_FILTER816(mmxext) +#endif +LOOP_FILTER816(sse2) +LOOP_FILTER4(ssse3) +LOOP_FILTER816(ssse3) void ff_vc1_h_loop_filter8_sse4(uint8_t *src, ptrdiff_t stride, int pq); @@ -71,12 +76,14 @@ static void vc1_h_loop_filter16_sse4(uint8_t *src, ptrdiff_t stride, int pq) ff_ ## OP ## pixels ## DEPTH ## INSN(dst, src, stride, DEPTH); \ } -DECLARE_FUNCTION(put_, 8, _mmx) +#if ARCH_X86_32 DECLARE_FUNCTION(put_, 16, _mmx) DECLARE_FUNCTION(avg_, 8, _mmx) DECLARE_FUNCTION(avg_, 16, _mmx) -DECLARE_FUNCTION(avg_, 8, _mmxext) DECLARE_FUNCTION(avg_, 16, _mmxext) +#endif +DECLARE_FUNCTION(put_, 8, _mmx) +DECLARE_FUNCTION(avg_, 8, _mmxext) DECLARE_FUNCTION(put_, 16, _sse2) DECLARE_FUNCTION(avg_, 16, _sse2) @@ -114,9 +121,10 @@ av_cold void ff_vc1dsp_init_x86(VC1DSPContext *dsp) if (EXTERNAL_MMXEXT(cpu_flags)) ff_vc1dsp_init_mmxext(dsp); -#define ASSIGN_LF(EXT) \ +#define ASSIGN_LF4(EXT) \ dsp->vc1_v_loop_filter4 = ff_vc1_v_loop_filter4_ ## EXT; \ - dsp->vc1_h_loop_filter4 = ff_vc1_h_loop_filter4_ ## EXT; \ + dsp->vc1_h_loop_filter4 = ff_vc1_h_loop_filter4_ ## EXT +#define ASSIGN_LF816(EXT) \ dsp->vc1_v_loop_filter8 = ff_vc1_v_loop_filter8_ ## EXT; \ dsp->vc1_h_loop_filter8 = ff_vc1_h_loop_filter8_ ## EXT; \ dsp->vc1_v_loop_filter16 = vc1_v_loop_filter16_ ## EXT; \ @@ -127,19 +135,25 @@ av_cold void ff_vc1dsp_init_x86(VC1DSPContext *dsp) dsp->put_no_rnd_vc1_chroma_pixels_tab[0] = ff_put_vc1_chroma_mc8_nornd_mmx; dsp->put_vc1_mspel_pixels_tab[1][0] = put_vc1_mspel_mc00_8_mmx; +#if ARCH_X86_32 dsp->put_vc1_mspel_pixels_tab[0][0] = put_vc1_mspel_mc00_16_mmx; dsp->avg_vc1_mspel_pixels_tab[1][0] = avg_vc1_mspel_mc00_8_mmx; dsp->avg_vc1_mspel_pixels_tab[0][0] = avg_vc1_mspel_mc00_16_mmx; } if (EXTERNAL_AMD3DNOW(cpu_flags)) { dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_3dnow; +#endif } if (EXTERNAL_MMXEXT(cpu_flags)) { - ASSIGN_LF(mmxext); - dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_mmxext; + ASSIGN_LF4(mmxext); +#if ARCH_X86_32 + ASSIGN_LF816(mmxext); - dsp->avg_vc1_mspel_pixels_tab[1][0] = avg_vc1_mspel_mc00_8_mmxext; dsp->avg_vc1_mspel_pixels_tab[0][0] = avg_vc1_mspel_mc00_16_mmxext; +#endif + dsp->avg_vc1_mspel_pixels_tab[1][0] = avg_vc1_mspel_mc00_8_mmxext; + + dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_mmxext; dsp->vc1_inv_trans_8x8_dc = ff_vc1_inv_trans_8x8_dc_mmxext; dsp->vc1_inv_trans_4x8_dc = ff_vc1_inv_trans_4x8_dc_mmxext; @@ -156,7 +170,8 @@ av_cold void ff_vc1dsp_init_x86(VC1DSPContext *dsp) dsp->avg_vc1_mspel_pixels_tab[0][0] = avg_vc1_mspel_mc00_16_sse2; } if (EXTERNAL_SSSE3(cpu_flags)) { - ASSIGN_LF(ssse3); + ASSIGN_LF4(ssse3); + ASSIGN_LF816(ssse3); dsp->put_no_rnd_vc1_chroma_pixels_tab[0] = ff_put_vc1_chroma_mc8_nornd_ssse3; dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_ssse3; } diff --git a/libavcodec/x86/vc1dsp_loopfilter.asm b/libavcodec/x86/vc1dsp_loopfilter.asm index 74360949dc..3475a682b3 100644 --- a/libavcodec/x86/vc1dsp_loopfilter.asm +++ b/libavcodec/x86/vc1dsp_loopfilter.asm @@ -249,6 +249,7 @@ cglobal vc1_h_loop_filter4, 3,5,0 call vc1_h_loop_filter_internal RET +%if ARCH_X86_32 ; void ff_vc1_v_loop_filter8_mmxext(uint8_t *src, ptrdiff_t stride, int pq) cglobal vc1_v_loop_filter8, 3,5,0 START_V_FILTER @@ -265,6 +266,7 @@ cglobal vc1_h_loop_filter8, 3,5,0 lea r0, [r0+4*r1] call vc1_h_loop_filter_internal RET +%endif %endmacro INIT_MMX mmxext From patchwork Thu Jun 9 23:54:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36114 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654549pzj; Thu, 9 Jun 2022 16:57:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyXPhpfY2BT4ny+Y6CuIraFRbM1y4Fz42Vq21Caxy9hM/Fhznqf7iv+oiWtF2H4aHlKQ0a+ X-Received: by 2002:a17:907:7282:b0:6fa:9365:f922 with SMTP id dt2-20020a170907728200b006fa9365f922mr37680712ejc.262.1654819042936; Thu, 09 Jun 2022 16:57:22 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id sd9-20020a1709076e0900b006feeea7fe6esi7633151ejc.632.2022.06.09.16.57.22; Thu, 09 Jun 2022 16:57:22 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=ZXm5hTMZ; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A9CC268B871; Fri, 10 Jun 2022 02:56:14 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070085.outbound.protection.outlook.com [40.92.70.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 81BB668B83E for ; Fri, 10 Jun 2022 02:56:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aMWHP6Wqi6JurStixFTHkrjWHa9HTY8Ny3euSePVpXG4FaVwpn6U6j+J5qM6Mikyps5DgfISLVWlTPLl+xpX9a+h7DF8BDBUI7n0FwYasPUe4QbBIwNQMriwSqDmZ40IozYy4e9pkbXNYYsaGjkAVgn8lF0z7Alilz492pSHjFTv/GDxvtZjdj5tVnu0GLvxYsaVnFeS3BSSnvhoe5MiEW3ZQ9crUsrLMZ6nWT9Ki1Je8MYWqkJeY7UltPxP36AXlrzbdtz2s/5n88Xz86lks5h+gdukvzUx12qur/SCKcEY/i3ubkb911jTcBHBAFpeDH3X1rtHAniZZlA3S9fOUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=df9t1ZjBsBgL5Ej2pbyOVQuvEsLAlQQ27Cd2Smup8tg=; b=PDGZJe51qXaHE4PXIbbd54sxmupNXPjiw+CPvZFJ35//QVUMzhkwv2tKwq+juiuQBmGc9NUQW+jmHJ90By0I2nvB3ip50s8Jb5aGw57QW28nJhugiAAPJkXC+xqQVaynyaJLMEkZm6ef70a3CgCmkQzG1s+E0hByA6YDAg312y0WJgyFwjpVE14m2ch6whour8f5MbVSt2UL1tFVFTzj8akGNkkXJp5y1qrigtB6BldJ+Ko/jAJBHcH1iaoZE4qv6KFrW4+HyWYANs33eWLQwBjyMItN5S1FDB/3GZaxse41q39VR8sHR0yLmRAdRl0CZ7WeLRSe+hxzLlbyuuKlGg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=df9t1ZjBsBgL5Ej2pbyOVQuvEsLAlQQ27Cd2Smup8tg=; b=ZXm5hTMZIBmNQodSZegKdVhO8D6XCMBOTMSzqxEdZlZZff0THuFT1vFCI41Ogv4MVi8VieE8ytgIo6exOrjmxxorY9YtLmiqkJIGUO7DXraFNDAqvurN98qztYRrNj5xjrDUXREwE9XLS5uhjBuFtGezIopfSP/bq+knVJAFv6pRARC5fNu/vmaHUic/vKEig2YhCRe3Vf1lKIBG9hFsbIuPk51q8qZ9umPwS/XPaiHDS96DuaUJRg2rhTYKfaSzhjYBOtUfCfn2feQ9iDWpANxc+4J59riCuCxWEJv7mi/X+heLEr/ycE04Vf9Bp7mhBHunMjxLGfMzKI3+tJPcXA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:08 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:08 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:52 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [+/ATqcvKbm/0ntSKHJBnOaPPBE3zRO9y] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-10-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: a50be5e9-1a74-4b6c-6f35-08da4a739f1b X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yph1Ez1nKEl6ioi44PeM6/lMoplXpEt0KJ0x+przxYAitFhWqApYpi9HEW/7+M70RdKdwvPixrAf7MlqDrUKpfKvNY9k2AXD6cDEOu1OMHaGw3/AryP7VUiBPW6ZnupmQ6S+SVUltLR39B6DO+L9tVKZqfpryQr9g3hkjxA4oSkeGlcM7rkhz1w0AMktSAM2Ez3Ksfm0qXAi9U92HniT/euzM/X3Hg/l8qIyPwxfPmqstzFLssePOyEGzoAslwoULIOGDo4GL1yhB7ol0bZM0xtUaCvgOyVDfe4f/FMXVF5yfaJ6GG0AwnowCM0j+yl38BcdEK2/YjwPLy6aBoFTNYkKEYvGiwUZIbopLyfZW6NDcr/4+lir4DrckmNrKgfuFoWeil1f9ZR4E5V1DrlsdalOpvkW2janXllw3DmcLHInrMc4dxlWMwJ/xEAwHE+h4ZDSRMXvLg8afz4taa6BNEOQZJrGbmH3xAZoAD/MkIY2rW/k/DzZprAsAj7JUvw9Snf00Z+Tk6Gei9LSWxpMhDbo/Fccu0kAVR+L+XB/mD/GsHfv6olCAsoGyIxcMCYoJAULBxscJ+ph7HG0lY+2RmFuDXR9Hias3R0Fp8+iPxkoaNDarOzRbqDqwAP/Eh+SowZMjKQP7MNtbHwgZheYh5+tIpMzsfhkJP1hlY6/nKkJrKCzZg9l+ikHrvjs3SDYSBGzP7WztdqNNecHLcE1tMUIm0WFmYqPMI= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft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RHntNH+A== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: a50be5e9-1a74-4b6c-6f35-08da4a739f1b X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:07.9760 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 10/41] avcodec/x86/ac3dsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: Qi/hMArWRQ2W x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such AC-3 functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/ac3dsp.asm | 5 +++++ libavcodec/x86/ac3dsp_init.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/libavcodec/x86/ac3dsp.asm b/libavcodec/x86/ac3dsp.asm index 4ddaa94320..050cbfe06a 100644 --- a/libavcodec/x86/ac3dsp.asm +++ b/libavcodec/x86/ac3dsp.asm @@ -64,6 +64,7 @@ cglobal ac3_exponent_min, 3, 4, 2, exp, reuse_blks, expn, offset %endmacro %define LOOP_ALIGN +%if ARCH_X86_32 INIT_MMX mmx AC3_EXPONENT_MIN %if HAVE_MMXEXT_EXTERNAL @@ -71,7 +72,9 @@ AC3_EXPONENT_MIN INIT_MMX mmxext AC3_EXPONENT_MIN %endif +%endif %if HAVE_SSE2_EXTERNAL +%define LOOP_ALIGN ALIGN 16 INIT_XMM sse2 AC3_EXPONENT_MIN %endif @@ -81,6 +84,7 @@ AC3_EXPONENT_MIN ; void ff_float_to_fixed24(int32_t *dst, const float *src, unsigned int len) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 ; The 3DNow! version is not bit-identical because pf2id uses truncation rather ; than round-to-nearest. INIT_MMX 3dnow @@ -134,6 +138,7 @@ cglobal float_to_fixed24, 3, 3, 3, dst, src, len ja .loop emms RET +%endif INIT_XMM sse2 cglobal float_to_fixed24, 3, 3, 9, dst, src, len diff --git a/libavcodec/x86/ac3dsp_init.c b/libavcodec/x86/ac3dsp_init.c index 5f20e6dc31..47ec5d8070 100644 --- a/libavcodec/x86/ac3dsp_init.c +++ b/libavcodec/x86/ac3dsp_init.c @@ -41,6 +41,7 @@ av_cold void ff_ac3dsp_init_x86(AC3DSPContext *c, int bit_exact) { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { c->ac3_exponent_min = ff_ac3_exponent_min_mmx; } @@ -55,6 +56,7 @@ av_cold void ff_ac3dsp_init_x86(AC3DSPContext *c, int bit_exact) if (EXTERNAL_SSE(cpu_flags)) { c->float_to_fixed24 = ff_float_to_fixed24_sse; } +#endif if (EXTERNAL_SSE2(cpu_flags)) { c->ac3_exponent_min = ff_ac3_exponent_min_sse2; c->float_to_fixed24 = ff_float_to_fixed24_sse2; From patchwork Thu Jun 9 23:54:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36115 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654608pzj; Thu, 9 Jun 2022 16:57:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz9UF3WOX+NZjgP0spNgYZWzknmGTriDhbjItgvxLai+ZGeVdNBkiLSdqMWCJLg+spsL4wa X-Received: by 2002:a05:6402:4411:b0:42b:a773:4800 with SMTP id y17-20020a056402441100b0042ba7734800mr48819332eda.37.1654819053034; Thu, 09 Jun 2022 16:57:33 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id mp37-20020a1709071b2500b006e88579e94fsi5550216ejc.798.2022.06.09.16.57.32; Thu, 09 Jun 2022 16:57:33 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b="k/AepTUA"; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B036A68B842; Fri, 10 Jun 2022 02:56:15 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070100.outbound.protection.outlook.com [40.92.70.100]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 1CA3168B86F for ; Fri, 10 Jun 2022 02:56:13 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=my1E6rbLOoWqO7j6MaNEmtHl5eAnhFydrm7ZLr4RIloL+N9uAD8CZjVWRx2XxN7k2hBeRiSeVDc80RRpUu3j0xJtNrf0o87r0HtBXdpa3Xnjfv7DOuW5NclwUVPU6uS0GoMibNP8o1gX1NBh3aJRj76GsFuKPaZLVDW8n3H4zFvSSq5Y5Nvml8jb9docFYmR6HgqST1SqkQnNQXIg20ysO+rQ8NzcOi74mc4zaXwjsy+S35eiKd59YSy8+SMLC/exo5E3/AmZmlkenDCb9nr9sNBbRyqGW0tWEfdDN4hbkGWZ7JQrkEU2lBE+TiSpa6+3SQpWLVjepTgSACvbGAJDg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=kyE0kuv0RgVZkw54HSIOgOkFBghZz7tSragUmBt//oE=; b=mHqmsG3Ao3RsfEi5BBrW955g+mw4MCT570V49Ykq2BahBkFUkRfX5S/8Bd5vkcSWYVCWklMFke5GMb5CuZa4bjry48WLyqTD+2jyW7nxaxlHFhQ0PGvfbDk5dJYCgBj/XuTGJE4yf/MeYNQwryu8DySX7SagWjEoOLFcRDrGmQnTeXvZ7OepwD2A47FxL509gsjWKMuZ5grsnWbCrTavgem8iooDijzh41tlizDZoaD+FliZWvpEF5l5t8vES9y3npJ+6htTz5zYkvmJAk08/v+ABTHgZheJpPNXnZg8BMibI9M0+aQXcm1x/0fcMfTXbyl6Q+Fs9aCouvWCvcvK9Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=kyE0kuv0RgVZkw54HSIOgOkFBghZz7tSragUmBt//oE=; b=k/AepTUAXzeKMGgf1cU3O24Y2AbXQzhBhTkGAlvvYXiSO0CmwJNcj5LK3n4jcA1PeSNFQfuz1++f3z+p0KPONqNOHhmaUjg+hEcHpniLRF/sTI0SGa+pR/Q9za4VQR7ckAB2AU7i8OL4ouoyHxUJBF1K24/wyHol/R8ZAImirzfMji8h6wuXvDrNwlXiQ47FrfucfQh+ijlUh8yMaS0WjxU19WXA2J3wrz4DFX4k+sASo++eGc2Z+9RGPd6EDXSQ+mQcPEyq0yC0LMH/VJwxTIswFNaqrUUj2xGbdJW6i2+F0r2HRHWqBFSqV4hB9nZMPHShQmv5KtfCtW8Rbhm7Gg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:12 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:12 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:53 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [kNu6c0y1l7pdwCExUqlJBfRy7DeVGlI2] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-11-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 97723fbb-52aa-4a70-68be-08da4a73a17b X-MS-Exchange-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yFbLGz5A7KaQoL0blaQGI05hMGULAZKv7uJ2wlKkYvrEVQwk6F8eKSgnmJnK8HyKtqDISJl4yGo1MM4FJoWqKOeck9ybK9Z5EPjeoO4VRGVcSYpjPtWWItS4PAZMrAqTW2KBTind7toL9kud8z+rsHSj14mX6Vv3GPeKRhAH+SFv/Ggy6SNvYLkxqhRkRXUMdT7MrDSUqpEEmdHf0RgHQmRAwezRQhvkp1Qahh5fYHSJ9usQTkCyv2yDAYSQDPcpAxyYtmzunSUbk56fRMv0lddXZ4FrfnUzU0jHKyTE447VIONo2XZSQJoVMnycbPIHZI5/HkxTahNzjrwcWqq8JWxQ19nnFJ8NRWGQV+gmMo5PiAonI01CciNo7by7jj3YdlpP/+UfGYM4NZy8EFnKBYesLlKVrZAN+sUXkdZN0DeqNdePWZL3L0JOvH53JZmMFRcv//TJsYnvRlpqjBp4JNcVNklJytVoN0UMQTlckgbZa5XazaLGGreA8S9ba0itFN8Lu4QSfCv16hAF2WsKyiZXHknMKkFBDRca+8HeJj5yx1fOAltGOqJgRq3GqufXOKgV2X8GYTng+zOMTbXJVSrc1KK8pMJmCoXGpM6A1yxCtDNkoDZ9rOKBkyS5Mp/CySP5yOcQ6C74suuTny2Qm6hUev+d+bK3BEn+b5sB+UGbVRSrH9erWXVezRHzK2+UUA2QGV7m1uCqKKL7FgYruZ4g7O5Tb9nXQYnurnt2JlJTtPf8BPzftAmaqQzRGfM4fjdMMVY5FjIzvbEgNj4Dyh0xXYAIZFQXnlGpgmUTrqt3n2GwoRQrwlao41Hio6HTwqRGUiiQwdTV7MqhlBgfJRm2dTKHA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 97723fbb-52aa-4a70-68be-08da4a73a17b X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:11.9604 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 11/41] avcodec/x86/audiodsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: BG7UVz0qWmLO x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such audiodsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/audiodsp.asm | 4 ++++ libavcodec/x86/audiodsp_init.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/libavcodec/x86/audiodsp.asm b/libavcodec/x86/audiodsp.asm index de395e5fa8..e4a498b516 100644 --- a/libavcodec/x86/audiodsp.asm +++ b/libavcodec/x86/audiodsp.asm @@ -48,8 +48,10 @@ cglobal scalarproduct_int16, 3,3,3, v1, v2, order RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext SCALARPRODUCT +%endif INIT_XMM sse2 SCALARPRODUCT @@ -117,8 +119,10 @@ cglobal vector_clip_int32%5, 5,5,%1, dst, src, min, max, len REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx VECTOR_CLIP_INT32 0, 1, 0, 0 +%endif INIT_XMM sse2 VECTOR_CLIP_INT32 6, 1, 0, 0, _int VECTOR_CLIP_INT32 6, 2, 0, 1 diff --git a/libavcodec/x86/audiodsp_init.c b/libavcodec/x86/audiodsp_init.c index 98e296c264..ebb28ece78 100644 --- a/libavcodec/x86/audiodsp_init.c +++ b/libavcodec/x86/audiodsp_init.c @@ -44,11 +44,13 @@ av_cold void ff_audiodsp_init_x86(AudioDSPContext *c) { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) c->vector_clip_int32 = ff_vector_clip_int32_mmx; if (EXTERNAL_MMXEXT(cpu_flags)) c->scalarproduct_int16 = ff_scalarproduct_int16_mmxext; +#endif if (EXTERNAL_SSE(cpu_flags)) c->vector_clipf = ff_vector_clipf_sse; From patchwork Thu Jun 9 23:54:54 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36116 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654655pzj; Thu, 9 Jun 2022 16:57:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJChUkfiyg57JALF4qRZ8RIdo7uv7NqaQmVTqrQ+8A5PnZErDCFvb8OP7jjzaZxY8wNvxg X-Received: by 2002:a05:6402:542:b0:42d:c7d6:4121 with SMTP id i2-20020a056402054200b0042dc7d64121mr47214005edx.302.1654819063518; Thu, 09 Jun 2022 16:57:43 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id b5-20020aa7d485000000b00418c2b5bdaesi25812695edr.144.2022.06.09.16.57.43; Thu, 09 Jun 2022 16:57:43 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=eKL1JSF8; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id BD9B468B87D; Fri, 10 Jun 2022 02:56:18 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070065.outbound.protection.outlook.com [40.92.70.65]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id F393668B86C for ; Fri, 10 Jun 2022 02:56:16 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aFLyVXMIpg/nkPDv6diWiXrx/BfrWqQo3WOA1rKtVbRhZaD4l2aSU8u3iK0PU8A8Ox1q+ShxBA/XpL0hbQqGu8oy3yVyGayEo48gEPVU0j972a1ow1bXkPGj5OBYikddCpFIku92eBE5/lhZVww2jbdtQHZDWpa7RxJG6U4+PWVzyYwntdiFL0OmbOSbU7gjzPYWn4WovL8BhlfdZw8VuxuvKH5ooDFZkizFbZNhHv5kHOfWVrv5xiFFojhc4nA5QsZYZgJLD0NK6dQjlvFQy+Zbhgjykl86v6HDKlxAUQYxP03tuHexYIRUvcJyzeImmK086n63chg1fXjhQHenpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=EwMWeE0iI4bbi4jTutmWicgpVeLEb9TEVFYjaSsUHhc=; b=gXFze+1aT/dKKp7uIQQS9hyJcX8cYAnLHPjXUacjLfGhlvAJAvqzPDEs9nubDfe/IHo/FuOa/DSWjdCBdQb/JQLuHQdLm7fHnV3jxGbAFY8qlvNHsG0EBZwwmgtOdRzHaoiHy2Vd1gKJxqGsEiHjy1ZwLZgO8LlICzzZDsVa42S6qX3hUOElFuKg+CNMpdfDLIwjKLx6K8siOu3ngcHW+DRxfZ8uM5jVK+yGn/scyq2k/bf09ZbS3DxAPI5ddmr7kzXFcE4CbmNFHtlPUrk/gqDvquWQ3tcqHGpHajbCoV+TYi/JWlf/p8ND73bnDaOgPtI9/UyfP6DibBr3XkCkMA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EwMWeE0iI4bbi4jTutmWicgpVeLEb9TEVFYjaSsUHhc=; b=eKL1JSF8D4s6j5meujYcAT7SA42GTVX93tg+DSiaCr2NytTx3OUP6MZsDmiuzRLDAqP+71kqwvtnQftekc8vW9n7R3AP92CmzwdGcCgwY4yQAQVDJKNvphm5lpLpsofRF4SMHy+sSCom4x5raxm3t1FkxRtN99+5s+5rUs76/TtQaV3ydDrzT9yYct+JDHuneDePik/NmId05D4MRkpaf5y1s01SLq6vbpPcxoMPScPpUYNV7s5qTWcyPhdeFnimqIa8iYRkDWt2mGfcgbl1E5nJr+pszx0MYLiAPVUnugMDggjdxByLhzs0gRvJoLpZVsiqNTQZBq/yda6lUkOuxA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:15 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:15 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:54 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [c2r8TMiQUlf970DN7CMTdhtUBLjoRGkk] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-12-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 4041be3a-e42a-4816-77ca-08da4a73a3b0 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvO5zT0ngXti8FeD2zRVkqUa2eddzL7lVAtSSOkMH0O+C0+wc78WyO2TIUhuleXAlcS4NH04/5ZHN6r+00c/bgpkGeuPk0aPq770iRqz3MrW67AN9LUqerSW5cmTmrsO2rrnQlxhaT7Rn9w5QpfRCyB9K65lFB0G2nUuR2M6k51Nsf48CTzEBXgez+TMC+fYvueLNaz/g6WgkkllhuWAWmK/ZjSFVoaqBVof6N9tfP2Ok8C5BTCOJJq2BM/k6fs2aI/wTzMaU76XA/58YJ8vW5ubaod73nuoTWZii+W9AbE+v73ouVnxmyUSI7/H0xzulpBeJCMQA11X94Sf9BavwNqb98PmDXxIgHxFNFqJKJUv92yAWgLKQ75qAToc1ecj4E/dPECAzGl+KkxD8Zl40c4MyjoiMekgj2js+vdRc63LMRLFmAy2xl2aJxM0nxFrUBvl1rcfU+GlyXLnpu6YCkhF1YEdS/ZEavR1c9Xbh/kck59KVhXYFe8Ciq5vzlROmDFJm0vmY9lPX+H34Y3jA0CBHitce2ZqUL6MH/t5bk9cQZouK6laSbOq7Tmf3ZvMRnQkZI0Y5pnqOkDUzJbIzBhFdFsRGeMWYewymgDxjTatRX2mCdHH9Sf+G/2lKcCQVorg2XaJCCuN//l5bFAacw5jQGV8zbiUWH/7GcttkVY1VC+nMDu0yQYP5M/B35yKta95fZjz1F5+uRs3Ceupyp2w= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gbuINXaXq1wQuBX9hkX/6jO9BlwA7HSlAiHTbEtIz0QNgU9+SKPg22WO05ijrjbzsDqfkvSj8kViq63vI3h7uRseW8+La48yaO2FYwzSM/PjKgKeS3zGs5M7IGXiKyCf5u3lo8xE5VQT+GZyn4/8XmraKGZGtRlych8zZz2jN0tbd0M0hthG9EtFnCJTXi+ZwRqjYTyLqqSjRavF8CAw/kbqWDEA8iL9EI1ACdOVFQJit999d92hBFpA3XdT2S8mKyklrppNuucfQeThUYJtnQ2Pp7P0xk6Tc1W520CnNTBtacuDwQJgZuvY8cueyeoj17Qy4DJu7Q0dtyBz0zAyousr0qFKkxaZg56Svvq7OXiCZDyjEqWRnHsztfBWfkXh4H4Ltk08H92EUXRRAQMOB6JsyRrYm7xiqRuoNC0/l1ixt6BIsB/iCyFp++4C0rMbNkxBrsdpKH7yRmttaavCakSObS2qoghTcGWOE6N0e09LEYDACFSUgQF0ROAQzAljF5HZ1+dEgYf/rj2Ru/taH2lXwpcb7PMjgmaHC1frNKgn7SGsSCMHFhIuSv7BOv9pL9jLfkJmdy31hh0SXPHinw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: cIspuwrH/hIdhYwKHddlwwqC5olk5eLZFAeedfeNQ0CLSGD0ZNSPiQWKmiuEd6w82crSVcb0zKX9iTDDwHprsoii3DT/RpPzhBDwCiXCeLT11bLNVPiLmImYmSuOQ0ltc1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ux/KBNkkQX31VrISwptu8AnXZtkfcsVN2DnJzIIuqesYrnTFK0l23TgloKF0mkV98QnNw/jei1Wa43kxzJ2Dq4QdUOTFylVHJYpytgDTiGkewurPk9XicT7rdtnIsZd9tqZsFsFIKno51oGSKwQ5zHzFdSBPoPtWdbskKDI8VhkdzmBBCDdlwDPNs4pADV+vSEXihmY6D7kkAg20poH62kRR0B1XChj4H7gN0wh0H6dYmBnaQAWqCzvAagyXroqMPzuz1RYQmRiSiWwt4utG684lMmh4GEQKyg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4041be3a-e42a-4816-77ca-08da4a73a3b0 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:15.7260 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 12/41] avcodec/x86/diracdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: zVBBTglfkZNr x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such diracdsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/diracdsp_init.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavcodec/x86/diracdsp_init.c b/libavcodec/x86/diracdsp_init.c index 8baacf3129..c9dca58f1b 100644 --- a/libavcodec/x86/diracdsp_init.c +++ b/libavcodec/x86/diracdsp_init.c @@ -87,9 +87,11 @@ static void OPNAME ## _dirac_pixels32_ ## EXT(uint8_t *dst, const uint8_t *src[5 }\ } +#if !ARCH_X86_64 DIRAC_PIXOP(put, mmx) DIRAC_PIXOP(avg, mmx) DIRAC_PIXOP(avg, mmxext) +#endif DIRAC_PIXOP(put, sse2) DIRAC_PIXOP(avg, sse2) @@ -114,13 +116,13 @@ void ff_diracdsp_init_x86(DiracDSPContext* c) c->dirac_hpel_filter = dirac_hpel_filter_mmx; c->add_rect_clamped = ff_add_rect_clamped_mmx; c->put_signed_rect_clamped[0] = (void *)ff_put_signed_rect_clamped_mmx; -#endif PIXFUNC(put, 0, mmx); PIXFUNC(avg, 0, mmx); } if (EXTERNAL_MMXEXT(mm_flags)) { PIXFUNC(avg, 0, mmxext); +#endif } if (EXTERNAL_SSE2(mm_flags)) { From patchwork Thu Jun 9 23:54:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36117 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654696pzj; Thu, 9 Jun 2022 16:57:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy5mD6or9sdO0qsXwEtCIm7ZHVzwR8B9z6UiwSpJcqqsUcy3cbVfTkPmpCJKqjlH3TAceWq X-Received: by 2002:a17:907:6e0f:b0:706:9a4f:2f3d with SMTP id sd15-20020a1709076e0f00b007069a4f2f3dmr39218772ejc.413.1654819073499; Thu, 09 Jun 2022 16:57:53 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ds14-20020a170907724e00b0070f31a190e5si22996360ejc.436.2022.06.09.16.57.53; Thu, 09 Jun 2022 16:57:53 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=UWVgQDrM; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id C47EA68B83F; Fri, 10 Jun 2022 02:56:21 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070045.outbound.protection.outlook.com [40.92.70.45]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id DA1E868B84A for ; Fri, 10 Jun 2022 02:56:19 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LxjL1qS2GZuUBMm7GfUutuw4CDussOMozBYxO7jj/Nq/GYGxSrgXT3WycdsrN9Pgcgk30kAd7Pm9Yoeu/MCvqIQ434nGYQL1Z53UBrWyB9G0luf5hPrDn4w7Gj583jHVbH0UBHs67uNsCYaiXOq52kHEde0ec+MasLtGN2OxWO6wq6pgHCnucWwCa/6ftdCJc9syqqyy2UA8YelxTmAJt9iS4wm4K2OTDYl90e/rImkGXI0xpt5MbZSLAfga7YqrqJj4d3eB81PLqhOCTmm2gZ6DfVaaVTmUEXOGxrnus/sR2eJKI1GpT0DhnSDuOuELynImR84QJSLRv7HqKXBNAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zTBTY8UELZY24n/b0cGoH/HLCxYOQxbWSY1z5JHjOjI=; b=a69r5gMGQux3Ub/xkjlNjkm1SbLul7mUXjv+G+BjCTilrTKHbkSQGkU9W91w5X5HjjL/rfXPoW+/yRsgy9JwlsvRmp/xMydG34vYl9LHYAbTcIglc9FcRXpaLvxTruOtJdCifBwXdjuNrguriWeYESoVfRxhlsJ8AAgftfVJjGI8KDCHXUESmYpF4b6udPLyfkHCKp00VNj34W5XbQzhgA+wyzruhprwwjofxqtZZgGx77XN+xtEpXZF7gishfzYxu+Mhum2Ifo1B8bcSaOZ15Ua1t+iRx5iZy/b4wsiwktf1GrxExm7471o0+EWhs75zREA1slgl8nl6+zDSZ2Img== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zTBTY8UELZY24n/b0cGoH/HLCxYOQxbWSY1z5JHjOjI=; b=UWVgQDrMvos0rBc0z78WfXDT2hm4jY1FRrMUsZ0MnqRQ3f+irDqUIN4A6/JiNi3m1cv3d5/cfAFGTi6cIP+XWpwvWTlfn0L75i8QmdhmQRfm/WOhKVYLeZoFODVXY3dyKOFc3JUBeNYpSkDr1CMFcYbjZjTKsGKP0aTF9DZgX+zEaxt6Gpb4JFoPPlNq/QUW3rjCVTFaCJBAIOZGa5f5wM8u0rlu7GeMyH/mLJMzUIVDH0jK7Gt1lK4Tk+zNcKQY/K0fF/j5CxOX3aMtTCBohlDYWmcBtd9L8ia5nG2e8jBwm/5s/g/2KKUm12OorwZIbp1YP/VkG+Y8U/sOzt3RUQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:18 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:18 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:55 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [7snq1LROpzyYBr68lxxLKQUnbPk6XioG] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-13-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0d92ae2a-9575-4e2f-7805-08da4a73a575 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKZUEsqnalwNSYM5G7njFZZnSZ2ovhokaoSm9EbfPh7oz+zl/yolkbCEqtn3kdsUUqeCdTtVnsYNZCA+t0iuuJO8Ce0s3XPXyBWGSSSJV1t7imod35rTJ9klDelqa+wqYqBnw/7WBYeWwgzX8iUQS3uT5bvBgozRJrhxGNMBnEE0DADCrGAB93NgcRtqkZMNOF08PJj5fS63hmCj5ePBoOA2Napz9rDyupyysOsxAs+1F3GXRr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TE+Fba2NQTTO+dQhJFwc5FyLg5T5ZUwVIvhpnoU6wkhaMU/x6FzvrFsguOi6onVenGrzmD4K9lUUo7f2LiyC+ndZeEyYhYDI+2S9a7baOVektg3kGg2FcaKTZmGxwx6zuxO4v+sgo95K7kATTc24HEjUrNWMrP8qzMsRvd45zleks+HoZtgzFCgW93hMYAMlRdsAIKCuvys9eaAE+1uNRLHphOQyoZkD1vo7igTYxPuUD2g4h6ORmOX27CI+Z9DnbARXfuNT9w8b6SJ4sdq1ELCh3XYjolG0DYK9GQLC2CrOJV22UOWXhq+wxtJJp0ui9pHZiZjyJO3AmG0xNQ6dzb0f0cHMsvHAzsepTChvWYVBOOIZwg+leNa7iJFzgptWbRAAJxG0qkCqTvSPo/3E599AheEyR9YkKgzFQ54NEzEg4yMzz+oe64zDwnUcKQ1JmOLN0GEHCqM3d2JYw1JNWP6B/Q5j9bpwAzN9UdoZeTdGLWmbC8OV82EHH1F8FQeGsPQMdChXoRC0oDr9YBVX4QOGpHJCQfA4naEegfQM9IBZLYj6yMoeoCy5Q== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0d92ae2a-9575-4e2f-7805-08da4a73a575 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:18.6323 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 13/41] avcodec/x86/mpegvideoenc: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: ksw95ClulArp x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such mpegvideoenc functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/mpegvideoenc.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/libavcodec/x86/mpegvideoenc.c b/libavcodec/x86/mpegvideoenc.c index 3691cce26c..d9c89d568b 100644 --- a/libavcodec/x86/mpegvideoenc.c +++ b/libavcodec/x86/mpegvideoenc.c @@ -42,6 +42,7 @@ DECLARE_ALIGNED(16, static const uint16_t, inv_zigzag_direct16)[64] = { #if HAVE_6REGS +#if ARCH_X86_32 #if HAVE_MMX_INLINE #define COMPILE_TEMPLATE_MMXEXT 0 #define COMPILE_TEMPLATE_SSE2 0 @@ -64,6 +65,7 @@ DECLARE_ALIGNED(16, static const uint16_t, inv_zigzag_direct16)[64] = { #define RENAME_FDCT(a) a ## _mmxext #include "mpegvideoenc_template.c" #endif /* HAVE_MMXEXT_INLINE */ +#endif /* ARCH_X86_32 */ #if HAVE_SSE2_INLINE #undef COMPILE_TEMPLATE_MMXEXT @@ -96,7 +98,7 @@ DECLARE_ALIGNED(16, static const uint16_t, inv_zigzag_direct16)[64] = { #endif /* HAVE_6REGS */ #if HAVE_INLINE_ASM -#if HAVE_MMX_INLINE +#if HAVE_MMX_INLINE && ARCH_X86_32 static void denoise_dct_mmx(MpegEncContext *s, int16_t *block){ const int intra= s->mb_intra; int *sum= s->dct_error_sum[intra]; @@ -218,17 +220,18 @@ av_cold void ff_dct_encode_init_x86(MpegEncContext *s) if (dct_algo == FF_DCT_AUTO || dct_algo == FF_DCT_MMX) { #if HAVE_MMX_INLINE int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (INLINE_MMX(cpu_flags)) { #if HAVE_6REGS s->dct_quantize = dct_quantize_mmx; #endif s->denoise_dct = denoise_dct_mmx; } -#endif #if HAVE_6REGS && HAVE_MMXEXT_INLINE if (INLINE_MMXEXT(cpu_flags)) s->dct_quantize = dct_quantize_mmxext; #endif +#endif #if HAVE_SSE2_INLINE if (INLINE_SSE2(cpu_flags)) { #if HAVE_6REGS @@ -240,6 +243,7 @@ av_cold void ff_dct_encode_init_x86(MpegEncContext *s) #if HAVE_6REGS && HAVE_SSSE3_INLINE if (INLINE_SSSE3(cpu_flags)) s->dct_quantize = dct_quantize_ssse3; +#endif #endif } } From patchwork Thu Jun 9 23:54:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36118 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654724pzj; Thu, 9 Jun 2022 16:58:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzWqme8BGaV0SquyWO7UaVYzFciBsriM0S+Oe0ihYLbp4sqlgM/D7mN9Fv6f2nMwWYqS1tz X-Received: by 2002:a17:906:6a07:b0:6fe:ec47:b64d with SMTP id qw7-20020a1709066a0700b006feec47b64dmr37893497ejc.765.1654819083707; Thu, 09 Jun 2022 16:58:03 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id ht12-20020a170907608c00b0071191fb96eesi17287485ejc.459.2022.06.09.16.58.03; Thu, 09 Jun 2022 16:58:03 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=hT3HrtFX; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id CC37168B883; Fri, 10 Jun 2022 02:56:28 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070066.outbound.protection.outlook.com [40.92.70.66]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 5045968B882 for ; Fri, 10 Jun 2022 02:56:21 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=j0VSS0TpNyd3VfuaeqlYYTGo3VN999PCRUFTJ5ByzhnObfpiwiifoDlElpZnC+wq90UjQv6jmEI53qw6UjZcgvu5pcXC4hNgVk9uxFRm3IxodDaPvs5fWEu/nDKau6aTBxrmHzZVAcNVF4rBx0xDk4fbsIx7f7rBKf2hxh8hAgK1ba8knVQYQ1NXuxeWHueQgOqmhi/MNOx/9o8ZMTsHfKCTNmbme0tOJn4+hvr5hDtop76SJSSFVFx/RoxOw4CS2eayqET1JHgvJ9IJFZOtV4bMUV/jiqdYXLmowoIz70b6tIDxbCMciMkp5jl/vwTJzSMWWUYTLCFqrBOPBGqKyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=NpVtCwI7zmpKF9yYpofvvs9OUUl9Fma2aYfK2HXWIrY=; b=Ti8TOlCDY4ro3Tkhv1vdQbydBSK2O0RuOrK5KzFal73MtHQOFzsyF0nRzJN+I/VhlCznkHhoFzwSmiX9kfaL/IrWc1SK0aCu5jUTEtKfrtDH3OdcqBk8mEPN5aNLb5XclD9zHJbET+qMADka7xYnqjziH+gXmlWwhrOu61YFcUa4bJNER4EMAAEGhFLl3zWwUYltyuuPv5b+UUrXaj0wNzYG96eiqVsBN2aaJJpiulAPO8nvaA/IGNvWdgD3BduvLiBFKmScOKD8n9dQ9COEM8lqTlp66noORG1Le4/7d3DV3FJO9AFySV1pog5LJHhvlLMoazGZjP7WOyQY6xP4XQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NpVtCwI7zmpKF9yYpofvvs9OUUl9Fma2aYfK2HXWIrY=; b=hT3HrtFXbgjk7BqC7Xtn0VNX7QawjnBdihNYhshV8vEzPrlo/jpSXdhFZQgD3eGoDK6sXToYNwehpClADPr8uaHoRhLFEbjByf8fPw8h6Pm/XvKOtHpXbkXtil/PgnfrKk2pHSldHFPL3Lj+/KjmLEYvQHw16kAvnClNmE9xMo4mdgOMVYC9Mn5ZAJHDxWk4wIGmHsQR5Bxxz5EZDNUFhT3UdBM4gO9g2p9xw8bFzp7SHfnc67vWxaFvhi9gG8wlzU/jUVkluUl+K4GGBky1EYg/pvYlYFt3elXaUr7xG64oNsghaCbHzN69rKja3AwWeksL4itUHYfjBgXbY8brLA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:20 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:20 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:56 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [rbqe8YvSJfjqmeKRevsqpeWitPGT/LD1] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-14-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7e0a1342-389d-4101-cfb0-08da4a73a66f X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKFxj+c9sj9FOuEXVGNB3DxFXMxoM1wWmD3+JPZqM6AxZn4Dx2vqtLuhRbAjBKXVDd/rkhaTQHr6Lo4/+Zen2ZaIgkHx4PKXz0U5+ftiMeLiOrLOzrRF0OyeHWM6ka8SeZwctI5aeWhuqIBgd5EsVSMu39stXdLmE5wrq/c15G7nXyFqCRlqg1lAjIFXtebvnE8i3/8iZShyW9QEbOcXq+VAcUwMYV8XYAe7ieMuKDRPkf4Hn3l6bOzNGZ+hmQOKmGL5xof4B3mhZvEuXFWuOwuxc6gTJ3Q2YCebGfK/ssJmHs5bmM0U1QKMFSjNm+6o0B1W3XvvFsBhFhHfTraYqIsC4KF2FD6SJB8njVt1njl/wWSyoxtoGocNOkGNixHcrLFh2kiiicu7SiKNZUA1sSOZn7J+X3J6jilI9os6jO+OfepuRToTNlTMvIpgAZiXnB3rmXGguk4Woz4+MiQtUfSk82eOFLDS41rXWsQgDTxt5TeZNpwrsgPG9xphUR9blkEoEpLdTx/6DCv9UCuacWRd57NfVmLeZg6BDv9iXRCDI5oQ4pLVZptsAG5nN0TNqjk6jhB6ohLh7iPF673jxIwaTGWcLgupwlbkvh+6IGVcMWGga1BMAr3wZt5XJ4Qha+MQCfXtGtc3npswKg5/qSYgSbTYKlicn5O2SHxCpvBaXg4soM+JXBBiFKvO5hypT4/ZCHQAg3Yr1y4Cl7HAZKyctJvlTQJZezy33j6rLOzrk= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gCNTLfnhKab6PbUrwoSXfbcwAi9+LwrNp72mX5uJa+/J6e1OoXY8L3Y4pec+kd6DBg1bks9T6/UEir08cWsFFnkZ0/xFSU2a7FmUga+mrvawQ9TgIZGOqRAwSi5cTjyEVvAS6bbGhqg6BwToYL2wGScJYLFDGSGF8+Yopa5RywnVzRkj0yU/eaObbOB5eS5zlMwSMJJ1ojkYqZE5xRnAKken6rCbcQ3fp3J+qK2My2xxPBcbKKFg9sNeigaNSCIAZ2GF62z+/nn8PUbdUEjoh0PRxzAx6DqY6UkMvjF1jLfZr2c/Orqs+X6tl8oVsAdz8QFhs2JFEJ2LBaja55iwk/10GaUDRL37bTuSHsjYNOnzn5ixmj4AX4DVl7JOaKqFOYb7W7pq1TTt9EwaJttmYAw0O5zl3KCjvZsJO5D2iDHR+IrK5a9FoMaFokr0qCWP3ptwQBd8dMsYrMyX4/+TQ0rXdWYC++Qsmcc96Itjrrw1Yr//+6QPDNsxMFdIw+vJVjxvJgw8Ezst56i3yAEaesrYeqzCzNeqF9DDO/xRShl9s5mPMXsPVgJU7IKVeO1b5xDcb4iserbB9s3OlDQQ8g== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: DOEiMVPcbh+CoExbjvXW0rln43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wx+Uzhx5aZHDxTU0OPm9RdC7IFUo7vIkAm+KCp0LPIhUNJumxUnZSh6I5RprEm3OaFwja6Oh08pux1Jggb5IN3TsQxLqGmZnejm7X3vlCqlkGuEsOiwq1C9oPoTFaRLI5u5mKXdgpuXtvmi3mtG2hAM+Z6+PtN48VRTD/gFVJtyuU1D+PJPRegM1CmcSMihkyTKl1EMyOGAhtnm1H0t9CICYY+FALkH7LBEnRg7FDKRCnG0/rWWm/ZSxdKkQLf40aXfw6Ynk/N+K2riHnFk0ftz5q58tsO6u0+xZYjijPkXLh5rlfJAuPrTNSxAzV8MgPJs2yxHf+nFETsszJLFI10AlWM1i9BLgHt0hTgPJ1Catnw+An4LBd28qwn6p4c8U8TLjEqQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7e0a1342-389d-4101-cfb0-08da4a73a66f X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:20.3511 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 14/41] avcodec/x86/fdct: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: M8zQ7J8Qwspy x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such mpegvideoenc functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/tests/x86/dct.c | 2 ++ libavcodec/x86/fdct.c | 12 ++++++++---- libavcodec/x86/fdctdsp_init.c | 2 ++ 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/libavcodec/tests/x86/dct.c b/libavcodec/tests/x86/dct.c index b332c9642d..1eb9400567 100644 --- a/libavcodec/tests/x86/dct.c +++ b/libavcodec/tests/x86/dct.c @@ -58,12 +58,14 @@ PR_WRAP(avx) #endif static const struct algo fdct_tab_arch[] = { +#if ARCH_X86_32 #if HAVE_MMX_INLINE { "MMX", ff_fdct_mmx, FF_IDCT_PERM_NONE, AV_CPU_FLAG_MMX }, #endif #if HAVE_MMXEXT_INLINE { "MMXEXT", ff_fdct_mmxext, FF_IDCT_PERM_NONE, AV_CPU_FLAG_MMXEXT }, #endif +#endif #if HAVE_SSE2_INLINE { "SSE2", ff_fdct_sse2, FF_IDCT_PERM_NONE, AV_CPU_FLAG_SSE2 }, #endif diff --git a/libavcodec/x86/fdct.c b/libavcodec/x86/fdct.c index 835fcc2b28..5e00287764 100644 --- a/libavcodec/x86/fdct.c +++ b/libavcodec/x86/fdct.c @@ -71,8 +71,6 @@ DECLARE_ALIGNED(16, static const int16_t, ocos_4_16)[8] = { DECLARE_ALIGNED(16, static const int16_t, fdct_one_corr)[8] = { X8(1) }; -DECLARE_ALIGNED(8, static const int32_t, fdct_r_row)[2] = {RND_FRW_ROW, RND_FRW_ROW }; - static const struct { DECLARE_ALIGNED(16, const int32_t, fdct_r_row_sse2)[4]; @@ -375,7 +373,6 @@ static av_always_inline void fdct_col_##cpu(const int16_t *in, int16_t *out, int "r" (out + offset), "r" (ocos_4_16)); \ } -FDCT_COL(mmx, mm, movq) FDCT_COL(sse2, xmm, movdqa) static av_always_inline void fdct_row_sse2(const int16_t *in, int16_t *out) @@ -443,6 +440,12 @@ static av_always_inline void fdct_row_sse2(const int16_t *in, int16_t *out) ); } +#if ARCH_X86_32 + +DECLARE_ALIGNED(8, static const int32_t, fdct_r_row)[2] = { RND_FRW_ROW, RND_FRW_ROW }; + +FDCT_COL(mmx, mm, movq) + static av_always_inline void fdct_row_mmxext(const int16_t *in, int16_t *out, const int16_t *table) { @@ -559,9 +562,10 @@ void ff_fdct_mmx(int16_t *block) } } +#endif /* ARCH_X86_32 */ #endif /* HAVE_MMX_INLINE */ -#if HAVE_MMXEXT_INLINE +#if HAVE_MMXEXT_INLINE && ARCH_X86_32 void ff_fdct_mmxext(int16_t *block) { diff --git a/libavcodec/x86/fdctdsp_init.c b/libavcodec/x86/fdctdsp_init.c index 0cb5fd625b..b801e57701 100644 --- a/libavcodec/x86/fdctdsp_init.c +++ b/libavcodec/x86/fdctdsp_init.c @@ -31,11 +31,13 @@ av_cold void ff_fdctdsp_init_x86(FDCTDSPContext *c, AVCodecContext *avctx, if (!high_bit_depth) { if ((dct_algo == FF_DCT_AUTO || dct_algo == FF_DCT_MMX)) { +#if ARCH_X86_32 if (INLINE_MMX(cpu_flags)) c->fdct = ff_fdct_mmx; if (INLINE_MMXEXT(cpu_flags)) c->fdct = ff_fdct_mmxext; +#endif if (INLINE_SSE2(cpu_flags)) c->fdct = ff_fdct_sse2; From patchwork Thu Jun 9 23:54:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36119 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654753pzj; Thu, 9 Jun 2022 16:58:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxEocn6OSJYCrLIodTHI4AWhntaBVt9tfT0bz053cjajBsyShNl3aR86ZePHsmMbemQSc2F X-Received: by 2002:a17:906:2001:b0:6f3:bd7f:d878 with SMTP id 1-20020a170906200100b006f3bd7fd878mr39076133ejo.133.1654819093907; Thu, 09 Jun 2022 16:58:13 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id d5-20020a50fb05000000b0042888eee944si3644660edq.471.2022.06.09.16.58.13; Thu, 09 Jun 2022 16:58:13 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=lHS7n1fe; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id C14DF68B89B; Fri, 10 Jun 2022 02:56:29 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070066.outbound.protection.outlook.com [40.92.70.66]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id ABDF868B88C for ; Fri, 10 Jun 2022 02:56:26 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JAFa//d3lhm5OCWLv19TFGQrv13yOKYADocmUgRGD8k7+zwANCARMtIdCqBY3ogAKBtNkWdnTm7PcyU9ibsR6rwLQvs7gBMs8OuAsTjlfUUmI/1XfkE+VOZ60x3qjVF8JH8iZaQeWAJrPMf/r30g7o7Ij2aE/bjytHFxb7BWcYVomswhO17iJ0W2TUasKYyL39z6mXjKyJy9RSoQ86dJJAeageFbzXP5X+pCk3KKxWXmUlUh5gK1Zz4WevQybEg2KgOp/gBAxPWzTWOqKEi6FV7MNCBb0dvB76DDHSW7hHrLwWsMrGobpOc9++pvjz8TQ6dRuoX+bpiGaxf29EiE8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=/ugtXHDGTR9ADKuM7ds13wZrlHn1kKGdCjpahljopjE=; b=QUNJEdIdHjC3u1aPJGY2sqHJqgcrZJsnoi70lmWHNUQ8NLIFg92Q6R2zzI7PIztVRDZVRmkzk9q1bY9O1bSKAv0gi0y1c+nMInKRxxmryYNqHrJeb8RUigWrXy0EL1FUeX0fajYP2El1ctXtD3zblPSdK2+3nXjz4/jWMO01NowtUtkWR6Phb8AwP789jFOQg/EydT/HCSiorKJMxatWO74C4U+zmpkgVN20cdOQWeiT06+WzJKYuRSjCGBJTYtBC7f1+JqXWmlEB0DhlqXQUJLhJYmYc5Y+ODnqRhpHAII5Uyo+mtFCCQy4clWUSJ4PU0lE22XaXMUVmCB+xYwQZg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/ugtXHDGTR9ADKuM7ds13wZrlHn1kKGdCjpahljopjE=; b=lHS7n1fejOmEYwJVcZOFn6/0uOL/MasyupdHleSsQuueRyzYq68MR21di2BXLD9blQaadzHUNMLgS0M4W1Mhpb7Yts9QbSDZ/X+4nyICxdrFxeWX3r8ehhUCllWVlnlrtJ73mAW9TctlooPrEpZzJSLMGJ6LuCsfUCAJHurHzgStf0IXs+SfDjNTERXdRzBITkT3hZ6xpJfJpDYKhlGvcw48I1m7CqQ6YC2AstpBKdmO34Nxs5uLJdJJREXQDr7TcKdjkpqeLMBRy76ezDrkdDMBc6KMLIWTwfTP0GUO4w5thpk4WI7FeId3tloq8Gvudkj3NwCHPcD45siHhrPwMQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:22 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:22 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:57 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [6c8ZM9xfRPseNWRWpVJcgngvAjTvL9Qn] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-15-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9276af93-38cd-4bdd-38f1-08da4a73a79c X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvMFM3UeT0D3FXynBXrSZWz0X33sTpy/d6aLakPyzKL3C/5da6kTwwo8WVMMcXppyYK6wmS9uWMezYI4qGXHc5nGWvLikO1J0yCd4aIGSXbuQkf0uD8eFE8qgu6J1CLWr/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2AjjtdoCA7Lxk37UBhlGL7T8qGBIvV2hjN3Vuks0IE7MQrG4RnfavIapHysqyTt1/QfBAVWTPOK2Tv+8YdQmEn9zgOEINrZD9jx5de8LIKWWEgsh3Ov6O42bbg7w3AkyWZpUqui62P6MtAnY7MtbVuTyYggbXJi5/fzIEO8Z3EYUsIaYVkR5qRAu84WotFXviUR9hefn/omlHOzL7gpe4HMtHzINWd4wwZQiuTtXUs5sfTyi/DAgrQvW4Q8GGL4RnDm0/tNI9gwp9I/Mryme/N9GSzrzyp4S/kw+5jriGiQXKKdpYiA6ZpFZmbcyLBx751Z6RYbtgWbi2WwHseRtNoC+IQZX3eO7kOC0CrbDdQrrNrjXv6RfxTkT7+eW6sGhbNJQ0ne7JzuEsys2yEM5Hru7NpLTbGxR4Gk+002ghJySwXoTh4IsAEdBTjmdTZCLJ0DB/zIujXz18x6sJCsQdaVVIA5Wf9H3qaed7lVEPkP4n/cslzoJaj6Dwnkk/IAYyGoSInj2OgmRsFiTh9BUxXSGlqAFYA3srnOp+D6bljDRqq76j78ML4tS9bQYKKp8XC3dEqOoINzfosBn/QcSxxz6aSFidGC5MY5XyrdXEOvgsiNNQL+JpQZgZgevV9EK/tnCzKdOfS6STE0+MnXe+AfpcbzLh6Srx3S0zJuElA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9276af93-38cd-4bdd-38f1-08da4a73a79c X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:22.2418 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 15/41] avcodec/x86/hevcdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: UKJ9SvzYI93T x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such hevcdsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- FYI: There is a pre-existing stride/alignment bug in this code: If one configures with --disable-sse3, one gets STRIDE_ALIGN 16. Then the test fate-hevc-conformance-DBLK_A_MAIN10_VIXS_3 fails when using SSE2; more exactly, if one comments out both SAO_BAND_INIT(10, sse2); and SAO_EDGE_INIT(10, sse2); in x86/hevcdsp_init.c, the test passes. It also passes if one hardcodes STRIDE_ALIGN to 32 in avcodec_align_dimensions2(). libavcodec/x86/hevc_idct.asm | 2 ++ libavcodec/x86/hevcdsp_init.c | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/libavcodec/x86/hevc_idct.asm b/libavcodec/x86/hevc_idct.asm index 1eb1973f27..eb44e06123 100644 --- a/libavcodec/x86/hevc_idct.asm +++ b/libavcodec/x86/hevc_idct.asm @@ -811,7 +811,9 @@ cglobal hevc_idct_32x32_%1, 1, 6, 16, 256, coeffs %macro INIT_IDCT_DC 1 INIT_MMX mmxext IDCT_DC_NL 4, %1 +%if ARCH_X86_32 IDCT_DC 8, 2, %1 +%endif INIT_XMM sse2 IDCT_DC_NL 8, %1 diff --git a/libavcodec/x86/hevcdsp_init.c b/libavcodec/x86/hevcdsp_init.c index 48f48a925f..b48661fe35 100644 --- a/libavcodec/x86/hevcdsp_init.c +++ b/libavcodec/x86/hevcdsp_init.c @@ -712,7 +712,9 @@ void ff_hevc_dsp_init_x86(HEVCDSPContext *c, const int bit_depth) if (bit_depth == 8) { if (EXTERNAL_MMXEXT(cpu_flags)) { c->idct_dc[0] = ff_hevc_idct_4x4_dc_8_mmxext; +#if ARCH_X86_32 c->idct_dc[1] = ff_hevc_idct_8x8_dc_8_mmxext; +#endif c->add_residual[0] = ff_hevc_add_residual_4_8_mmxext; } @@ -889,7 +891,9 @@ void ff_hevc_dsp_init_x86(HEVCDSPContext *c, const int bit_depth) if (EXTERNAL_MMXEXT(cpu_flags)) { c->add_residual[0] = ff_hevc_add_residual_4_10_mmxext; c->idct_dc[0] = ff_hevc_idct_4x4_dc_10_mmxext; +#if ARCH_X86_32 c->idct_dc[1] = ff_hevc_idct_8x8_dc_10_mmxext; +#endif } if (EXTERNAL_SSE2(cpu_flags)) { c->hevc_v_loop_filter_chroma = ff_hevc_v_loop_filter_chroma_10_sse2; @@ -1105,7 +1109,9 @@ void ff_hevc_dsp_init_x86(HEVCDSPContext *c, const int bit_depth) } else if (bit_depth == 12) { if (EXTERNAL_MMXEXT(cpu_flags)) { c->idct_dc[0] = ff_hevc_idct_4x4_dc_12_mmxext; +#if ARCH_X86_32 c->idct_dc[1] = ff_hevc_idct_8x8_dc_12_mmxext; +#endif } if (EXTERNAL_SSE2(cpu_flags)) { c->hevc_v_loop_filter_chroma = ff_hevc_v_loop_filter_chroma_12_sse2; From patchwork Thu Jun 9 23:54:58 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36120 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654797pzj; Thu, 9 Jun 2022 16:58:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxpMPGUxOyeUaptWahIyl9emT5vnR4bnMW9ha+KsVLfuGk2VAsNSdsUTfVWqbgO/QqEi/hf X-Received: by 2002:a05:6402:3293:b0:42e:18a:d6eb with SMTP id f19-20020a056402329300b0042e018ad6ebmr47851533eda.293.1654819103610; Thu, 09 Jun 2022 16:58:23 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id k4-20020a1709062a4400b006e844990dcdsi5173657eje.334.2022.06.09.16.58.23; Thu, 09 Jun 2022 16:58:23 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=B44nLMYX; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id ED57768B8A3; Fri, 10 Jun 2022 02:56:30 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR03-AM5-obe.outbound.protection.outlook.com (mail-oln040092070066.outbound.protection.outlook.com [40.92.70.66]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id BFA1568B882 for ; Fri, 10 Jun 2022 02:56:26 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iCMCgESq9fm0PXWvfCBJVD96gFxiEGMkW1+Qbj6VwSczg2tCGI1aR7jgbi1THYr1hA92XnI6i8bl/MNjTemslBSciM8/BCwRrVCdreX1ha41kp34f4bS0R++1wTGcodQi0X8Y+zqRWi1/Aklo7L99wY3UZceKF4IIjnvQ0bCNwB1GWiyB5eHHcdT/Luu5haobeZgET52e6Jj2FSYeHpMCrpKrzMH278Yn8q4U9maYkNuE6Prk5/L10PCI6o4jFKy3RfJo0JElXRWl87HHrHNohQrQsfq1gSCCnBQMyFGMVAHpFzoePlZekJRsjXeXm0xY+NDObkLSzPxt7pgAGXB8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=uX0KlbFFGURU3ScwIdqjpD7wjbDDonh78aQJoj3m1Ak=; b=lZtCiYLmm7JHuGQY/ONtlEPaLcHPltcDIXUYVTWsUGTuzh0r85PIMd8nfXL22cQe92gqDlfHUcTDSk2DpR+mkpvFkLTqNkDlrf0PjvUhCeOnbYbmDuyoU3InMCSumC+G7xXn9ahBJlxEDf5YmUI7yPzI6zU3kBZx1YX7U+7z4Him0jVJtP7gAXhVhjc/xnoE3WxvF3Mw8zLU1o6vE50C2LxrzVyIcWkvBQc+yX2ZfUfxWcQHJ/bJC9BU8qC9DJpLPj5gV1OjZuxqE5c2XzYTBuFFQw5RA62CMDs+xX/KKZZ1jlZw23uiz20GV/6Da+9JdaYsbw6nkwzFzc+sQkdDrg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=uX0KlbFFGURU3ScwIdqjpD7wjbDDonh78aQJoj3m1Ak=; b=B44nLMYXj+uqlwAwRXx4wApIvCwkL4kHGaTn1nGCl5AI86xPuWdmVqlS1OxyzVUgtVkSq9Z8Ixr1dti/Qt96hWMcYsCh45luO/JuqEIThHa12BSn11eAPHVuXPXzpnk2f6KHyOkbD26QWO9O/4euPAlTrGb2Cb+exF+F1Q0gHiN5O5MpF+W0QZ6EHLQwrol2RloNOfLnMYrpE0v5HOUIJSg0T8IjSuK5svNUXTvF1HsAIIMqJOyRnFAuvjdrpzr7mJJuqcoDs2mIBNSsMI7m3uAbVPZc8iuvlqioyRSkOhp/mYH4e5N5p1p5kmvZ2DMmqklVVRrB4OUhcLIZ1wxXKg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:23 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:23 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:58 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [ycDNlvEcOF31TcRuAzDyXo5iUmvMYwds] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-16-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 45eb1ffe-a969-46e3-ce96-08da4a73a853 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKMY/u9/dCHeuGrjcp4sPm30bBzK6iL9NRH3pv2T48t5UtlSMmn3RS56xP/ZLBwOAOQ9na7FHO5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/oqWnvpGgBD+hNi5bO5WVU+aTJZZEOTVdT+vFJdKYGE/nLth5MCd2jyvzsRWcY255IWXxz+XAJ/YX+AzMavYnNPhEaz34H+Jy1WOiNg5fWQvP8uURC6u/+MXnPtfEq0ANzOy4Hib/YZIboisC3ZcP+iKCc9wfo9kD2Wu7rrF0VXlioMvBKBAGb4dFxGYW2JTuEfcBA9e08ZFNi0RxqXhFPlydhrWQiRgQob4hOl/HhSSK1lQi+VkNoWNGcd7E47XosLonH1rMMlrbAn2vUkzscve3VACTJjXll56eYovmKgXB6xk2lwO3x18QX2Qk56Kj0Mp2ekKAVBHIOj/MIy7X5AUriPppFREGX1oGbT76ky4RYD8tZNea24/uYtXSTAgA+y6Gu0j4NpK545UShIxO90mew8IyvLNx+5Sl+ChAhmieidTY6AeRBMucjuMug7oe2h9gzXSC5gpFbOotZYFsFvVh75dtZ3iVUbjVdxpOLkLQ8iMaA0F6uxbSNUGduwgSvnwzNTi1gVZ2JnZAOZ06w/51c16OClZOXRAZcVEsmFgIOoShZeS/l4qWRt8hshGBHF5lJ8BWARdgv85/AmNschoG/KErMEbqYiYhSZYA0ZQXlhryC7e50TAgcTCY+tvFx9d8RWkjEhugy3Y+92T9TGtPq99oE8o9qm5TiZ0dODV32mUKNDHuXBsnElvpaiXsGu7jDAyJBc6bnQ+4KW/VjSdkdj47qiaiU2PG/Xz8Iuew== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 45eb1ffe-a969-46e3-ce96-08da4a73a853 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:23.4449 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 16/41] avcodec/x86/rv40dsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: fOv0Y0fFyEPl x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such RV40-dsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_chromamc.asm | 4 ++-- libavcodec/x86/rv40dsp.asm | 2 ++ libavcodec/x86/rv40dsp_init.c | 10 ++++++---- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/libavcodec/x86/h264_chromamc.asm b/libavcodec/x86/h264_chromamc.asm index 0421fa8695..d59c183371 100644 --- a/libavcodec/x86/h264_chromamc.asm +++ b/libavcodec/x86/h264_chromamc.asm @@ -450,10 +450,10 @@ INIT_MMX 3dnow chroma_mc8_mmx_func avg, h264, _rnd %if ARCH_X86_32 chroma_mc8_mmx_func avg, vc1, _nornd -%endif chroma_mc8_mmx_func avg, rv40 -chroma_mc4_mmx_func avg, h264 chroma_mc4_mmx_func avg, rv40 +%endif +chroma_mc4_mmx_func avg, h264 %macro chroma_mc8_ssse3_func 2-3 cglobal %1_%2_chroma_mc8%3, 6, 7, 8 diff --git a/libavcodec/x86/rv40dsp.asm b/libavcodec/x86/rv40dsp.asm index bcad1aee80..7fa271a5d5 100644 --- a/libavcodec/x86/rv40dsp.asm +++ b/libavcodec/x86/rv40dsp.asm @@ -481,11 +481,13 @@ cglobal rv40_weight_func_%1_%2, 6, 7, 8 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext RV40_WEIGHT rnd, 8, 3 RV40_WEIGHT rnd, 16, 4 RV40_WEIGHT nornd, 8, 3 RV40_WEIGHT nornd, 16, 4 +%endif INIT_XMM sse2 RV40_WEIGHT rnd, 8, 3 diff --git a/libavcodec/x86/rv40dsp_init.c b/libavcodec/x86/rv40dsp_init.c index 7a05ab14ad..7a60a30295 100644 --- a/libavcodec/x86/rv40dsp_init.c +++ b/libavcodec/x86/rv40dsp_init.c @@ -207,10 +207,12 @@ DEFINE_FN(avg, 16, ssse3) #if HAVE_MMX_INLINE DEFINE_FN(put, 8, mmx) +#if ARCH_X86_32 DEFINE_FN(avg, 8, mmx) DEFINE_FN(put, 16, mmx) DEFINE_FN(avg, 16, mmx) #endif +#endif av_cold void ff_rv40dsp_init_x86(RV34DSPContext *c) { @@ -218,10 +220,12 @@ av_cold void ff_rv40dsp_init_x86(RV34DSPContext *c) #if HAVE_MMX_INLINE if (INLINE_MMX(cpu_flags)) { - c->put_pixels_tab[0][15] = put_rv40_qpel16_mc33_mmx; c->put_pixels_tab[1][15] = put_rv40_qpel8_mc33_mmx; +#if ARCH_X86_32 + c->put_pixels_tab[0][15] = put_rv40_qpel16_mc33_mmx; c->avg_pixels_tab[0][15] = avg_rv40_qpel16_mc33_mmx; c->avg_pixels_tab[1][15] = avg_rv40_qpel8_mc33_mmx; +#endif } #endif /* HAVE_MMX_INLINE */ @@ -231,12 +235,10 @@ av_cold void ff_rv40dsp_init_x86(RV34DSPContext *c) c->put_chroma_pixels_tab[1] = ff_put_rv40_chroma_mc4_mmx; #if ARCH_X86_32 QPEL_MC_SET(put_, _mmx) -#endif } if (EXTERNAL_AMD3DNOW(cpu_flags)) { c->avg_chroma_pixels_tab[0] = ff_avg_rv40_chroma_mc8_3dnow; c->avg_chroma_pixels_tab[1] = ff_avg_rv40_chroma_mc4_3dnow; -#if ARCH_X86_32 QPEL_MC_SET(avg_, _3dnow) #endif } @@ -244,11 +246,11 @@ av_cold void ff_rv40dsp_init_x86(RV34DSPContext *c) c->avg_pixels_tab[1][15] = avg_rv40_qpel8_mc33_mmxext; c->avg_chroma_pixels_tab[0] = ff_avg_rv40_chroma_mc8_mmxext; c->avg_chroma_pixels_tab[1] = ff_avg_rv40_chroma_mc4_mmxext; +#if ARCH_X86_32 c->rv40_weight_pixels_tab[0][0] = ff_rv40_weight_func_rnd_16_mmxext; c->rv40_weight_pixels_tab[0][1] = ff_rv40_weight_func_rnd_8_mmxext; c->rv40_weight_pixels_tab[1][0] = ff_rv40_weight_func_nornd_16_mmxext; c->rv40_weight_pixels_tab[1][1] = ff_rv40_weight_func_nornd_8_mmxext; -#if ARCH_X86_32 QPEL_MC_SET(avg_, _mmxext) #endif } From patchwork Thu Jun 9 23:54:59 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36121 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp654848pzj; Thu, 9 Jun 2022 16:58:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxxN2PyoKf/qSZ/+Xw4B0NE58Lrz7CwHUGX0lkKTmRH63DvI3icpQC0vE9LcDTdPnM0nkp8 X-Received: by 2002:a05:6402:27cc:b0:42d:de10:4b6c with SMTP id c12-20020a05640227cc00b0042dde104b6cmr49206914ede.424.1654819113749; Thu, 09 Jun 2022 16:58:33 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id r26-20020a056402035a00b00425e843eda1si4807842edw.72.2022.06.09.16.58.33; Thu, 09 Jun 2022 16:58:33 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=dWWF+96A; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 17AA568B8A5; Fri, 10 Jun 2022 02:56:32 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-oln040092074079.outbound.protection.outlook.com [40.92.74.79]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id DD07168B88C for ; Fri, 10 Jun 2022 02:56:27 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iN2lPsZjxrwixiOI1dhw1XvUAyS+qD+vCJak4UawdYzoBrrEo3g7ldo+HD+lmKnED71y3i1RC7Il+c/yOOfleX9GSqa+MdgPk23G4HAIQk3Hvc3Pg1rotOYn8rjLVEE9kmcdDCMXEpfo1nfbOFzxNesqWkAIfowcExiEA5OQKVUHxgjHOB3ROU1CuOhdlRdGXlqE5kNYYo4MtP9PlySubn9g96dwAczuKLG00N/CqfgWUz54i0pNovQ6j3i11iWKViuiBWpi5EkZGSQBbJgodCEH43GHADSBuuC5CCU/QF9B2NZjvs4OT7TkENGLgjSgHT0mHbmBtawHrHC+VJshVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=5OKoMskQ0PooSlYvANJ9iNKyYNQj39j6x93H9AylMmY=; b=WJ1PGlryQ8aHpKq1qf8zEUBxwlLit3vFmnwHz/oWRJbZFpfwk0k8EaxOyQqrpWkVt6uIdKbiyrYOlVFafA65+oo2WTjdt1aZA5IoX4s9NmBk/2fkkDBY5wfZKdUV9/sCNbeYHQugjpy9J4xWiUbcFmeJc97wPzFdysJTzEiVqzWHwGYAI9MSgYoJ0st99YI1Gz7ATIQxPRM9SyekGjangeFywMe9E/e6UIlczxyIUpkSEQHNJe/HUyqPxL5mA6Ez+MngMoD1QbSo7Faeg2/nY1QWnGlplSBbP3NWnsaJSHdmUbUAiBXxOtEk7wYU9qvev8IBemIMSW0/0arGuvBNRg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5OKoMskQ0PooSlYvANJ9iNKyYNQj39j6x93H9AylMmY=; b=dWWF+96AfrAfeCBG9qkAx05i6ujgCHzP6f295OmgazHTcmtHpHDwbe7dnwCblXGXrOdC2jLolNCFWwbhB+XcMoJFLacBbVs6MKUpMVmyHGbiRvDW1j2T6Y6OlAwHllTNuv96sW+aACMaX7VSPnzroARg5tfLYngVb+ZcSX8Jq4/00coPwWaOl9T+LHquBckOI7fLIQCszUE2RxjI18pT9xB5N0aVKnqDoMxZpuZA1YJ3n0Bzc4KQICkMuoRtzhCEOiGoCZY6KxT1ReHn+HFIv4aPQ+eIFEIsgvqCFivsN4tbuKsRaPZIk/E443ZqhAYSGC/VFypUUin7KJJVz34Ejw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:24 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:24 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:54:59 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [lQ4KbAcs3K1tD/WVg3iYWXKxzHdE5sPy] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-17-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 15b55fcb-fd4b-42b6-6434-08da4a73a90b X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKlUyWZ3/UssyWmvZ/CrdyhrXXz3rGuXXs3I1udnvHifyindXIh18K8vyiZ+36mSdYWUvdyY7pTfgcFc4P0zI/YqGA3VdMeZu4A+8gONftvNs8sRwchFbm4I+oosy5YSIzgMmD4MmOw45328mwdK+3MJE97yW/WdedzAYyqOrUXPq0hE/kh5YC1H05aY+yqgbTqMTk0/nh6vCTqxZKDnouoOZ2kULsZLpCUNilJ2ZzyGThf/xfxBtzSBdD+03TteCt+YYGwD5RBWgmc2Dushwl13nnRY0MIBEpY5zOjGUHiRbxfyuJBoRc3m75UJKe2CNbjfc26JZWrcfpm/vA/ixinMTCjYo8P5wE3JB/UdtkxeZD6NwfBcpwfLHoHWQv9/fwp2KNk4WA6SvQ9srH3nCs/u5Jp4lnNLHWuiYeIvOKFTu0irgShZyf12toQbOIIebp4XatG3MlUY6ikk8mUURa4cmkbKvLLuQvKrqrcKmFRe2CTntjXF8hKGDrtEAqgbF9dqnu2JWfNroL1HjVbjUee0kiqy86OIZ7nNqkrrmL8S+bznP/i6k9C7vMME4SXjQYgxDO84JxkefvcBh+DApFvyR8kBfMug4tosV2m/3AOf8Z8wJFFsLuCYI2i9xfvLgHPYz/huvnaWkBPgxIaECKW4txD2RM5OQY5tTYQt2D9rNhY32BLHrxKJvipCTda1NiCea1Sp9neL7BFtjLL989wNfApZYB1c/FwwnYSSoKuvw= X-MS-TrafficTypeDiagnostic: AM0PR01MB5809:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Spkp81vRFPkfQvMUlYhxDap8ez7Hd+hYEkE0IJGNkm4+x/vv/WW/x5Bw3fN+hLQAVafGC45CuuHCgvZI2SHrRNSUNBJ96GkqUwOo1uQDeOUXKsmaLd77YzBybfQeeCt26nh22DyTlV7XYe5yRB3ojw+432ZG7lMoPAPD/2/Q1eJEgS5DPdCl838QTSnxZtY+JEUFhfUTNInqoxDZjAeyqegPzBm1Xv7uN51MThkYdHtCg+DklgrJqUP8Rh4KGiTYtTjLPZGDFMzx/ogBUyvMvv4ksULbvRX+d7lCKawGFPwSAOMqmKatMboJXu6uRG5vPx168t1qZKUl5AKQcEke1xSFNYMkkQL66wSrxXr0R8A6u0JvnR10be8G3dkrZxu7sNqFMElcIJ6XYh3ZGdoOXvo2RPqoZ42AFTkNF1Tld2Qa/ZW+rCYsDRc0L+G25KT3Ru+H4eaTvAY2HaZSz6iuL+cPw4BJWigIYBQmTGa7szsJZEatsea4frN8DB30mAsoSQsFz2LR2A0MxoNqe8OTKya+Y6HO+yWSZTKW2oyOI0gVyYG6pw6oGdRbh7qUezMvbUDiWl21DqK7cwp0mDtWYw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 1oywmggsrYQsMwP2aMVc9pJBOU8rAka3RigFy8h7rPyzi+z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pLQcrPcvK90+6GA8nAg0+NmWVwjS/Hq323EUp2xIbMP38hSHVbwWUvwd8OYvWA8LhBjivdmRwtCs/iNmH8JPLfTj/5Xq8Xnp9VWyDlXVhlJsDHFigqjo8MiGUXVadvIVsp+ew7sYaR6mWOzSwBDDXp/EhOf6H+XVqNRRpFo+GxA4hwgVbzKggKmyYFszQObXTJyFsNE+tH6/m73UpXTTY/kP8bAyv9UzNmNw7jJ9r1jLCAJxnepTpP84WVr2ZWQoNbpQAU3bVROtQR268As4E8+b+ssKlD+FZhpj96ChMVz6D5ch5iDsw1Zfjpa7Of6hVh+rXbg6BZmLFxQ6tVD0WRDl63T8tepdp9+9g8FBtkMLBg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 15b55fcb-fd4b-42b6-6434-08da4a73a90b X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:24.6480 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 17/41] avcodec/x86/cavsdsp: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: m2IP1XDWzLxe x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such CAVS-dsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/cavsdsp.c | 20 +++++++++++++++----- libavcodec/x86/cavsidct.asm | 2 ++ 2 files changed, 17 insertions(+), 5 deletions(-) diff --git a/libavcodec/x86/cavsdsp.c b/libavcodec/x86/cavsdsp.c index f974f93fc0..fea9daa0ff 100644 --- a/libavcodec/x86/cavsdsp.c +++ b/libavcodec/x86/cavsdsp.c @@ -38,6 +38,7 @@ #if HAVE_MMX_EXTERNAL +#if ARCH_X86_32 void ff_cavs_idct8_mmx(int16_t *out, const int16_t *in); static void cavs_idct8_add_mmx(uint8_t *dst, int16_t *block, ptrdiff_t stride) @@ -46,6 +47,7 @@ static void cavs_idct8_add_mmx(uint8_t *dst, int16_t *block, ptrdiff_t stride) ff_cavs_idct8_mmx(b2, block); ff_add_pixels_clamped_mmx(b2, dst, stride); } +#endif /* ARCH_X86_32 */ void ff_cavs_idct8_sse2(int16_t *out, const int16_t *in); @@ -335,11 +337,13 @@ static void put_cavs_qpel8_mc00_mmx(uint8_t *dst, const uint8_t *src, ff_put_pixels8_mmx(dst, src, stride, 8); } +#if ARCH_X86_32 static void avg_cavs_qpel8_mc00_mmx(uint8_t *dst, const uint8_t *src, ptrdiff_t stride) { ff_avg_pixels8_mmx(dst, src, stride, 8); } +#endif static void avg_cavs_qpel8_mc00_mmxext(uint8_t *dst, const uint8_t *src, ptrdiff_t stride) @@ -347,6 +351,7 @@ static void avg_cavs_qpel8_mc00_mmxext(uint8_t *dst, const uint8_t *src, ff_avg_pixels8_mmxext(dst, src, stride, 8); } +#if ARCH_X86_32 static void put_cavs_qpel16_mc00_mmx(uint8_t *dst, const uint8_t *src, ptrdiff_t stride) { @@ -364,6 +369,7 @@ static void avg_cavs_qpel16_mc00_mmxext(uint8_t *dst, const uint8_t *src, { ff_avg_pixels16_mmxext(dst, src, stride, 16); } +#endif static void put_cavs_qpel16_mc00_sse2(uint8_t *dst, const uint8_t *src, ptrdiff_t stride) @@ -382,13 +388,15 @@ static av_cold void cavsdsp_init_mmx(CAVSDSPContext *c, AVCodecContext *avctx) { #if HAVE_MMX_EXTERNAL - c->put_cavs_qpel_pixels_tab[0][0] = put_cavs_qpel16_mc00_mmx; c->put_cavs_qpel_pixels_tab[1][0] = put_cavs_qpel8_mc00_mmx; +#if ARCH_X86_32 + c->put_cavs_qpel_pixels_tab[0][0] = put_cavs_qpel16_mc00_mmx; c->avg_cavs_qpel_pixels_tab[0][0] = avg_cavs_qpel16_mc00_mmx; c->avg_cavs_qpel_pixels_tab[1][0] = avg_cavs_qpel8_mc00_mmx; c->cavs_idct8_add = cavs_idct8_add_mmx; c->idct_perm = FF_IDCT_PERM_TRANSPOSE; +#endif /* ARCH_X86_32 */ #endif /* HAVE_MMX_EXTERNAL */ } @@ -408,7 +416,7 @@ CAVS_MC(avg_, 8, mmxext) CAVS_MC(avg_, 16, mmxext) #endif /* HAVE_MMXEXT_INLINE */ -#if HAVE_AMD3DNOW_INLINE +#if ARCH_X86_32 && HAVE_AMD3DNOW_INLINE QPEL_CAVS(put_, PUT_OP, 3dnow) QPEL_CAVS(avg_, AVG_3DNOW_OP, 3dnow) @@ -425,7 +433,7 @@ static av_cold void cavsdsp_init_3dnow(CAVSDSPContext *c, DSPFUNC(avg, 0, 16, 3dnow); DSPFUNC(avg, 1, 8, 3dnow); } -#endif /* HAVE_AMD3DNOW_INLINE */ +#endif /* ARCH_X86_32 && HAVE_AMD3DNOW_INLINE */ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c, AVCodecContext *avctx) { @@ -434,10 +442,10 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c, AVCodecContext *avctx) if (X86_MMX(cpu_flags)) cavsdsp_init_mmx(c, avctx); -#if HAVE_AMD3DNOW_INLINE +#if ARCH_X86_32 && HAVE_AMD3DNOW_INLINE if (INLINE_AMD3DNOW(cpu_flags)) cavsdsp_init_3dnow(c, avctx); -#endif /* HAVE_AMD3DNOW_INLINE */ +#endif /* ARCH_X86_32 && HAVE_AMD3DNOW_INLINE */ #if HAVE_MMXEXT_INLINE if (INLINE_MMXEXT(cpu_flags)) { DSPFUNC(put, 0, 16, mmxext); @@ -448,7 +456,9 @@ av_cold void ff_cavsdsp_init_x86(CAVSDSPContext *c, AVCodecContext *avctx) #endif #if HAVE_MMX_EXTERNAL if (EXTERNAL_MMXEXT(cpu_flags)) { +#if ARCH_X86_32 c->avg_cavs_qpel_pixels_tab[0][0] = avg_cavs_qpel16_mc00_mmxext; +#endif c->avg_cavs_qpel_pixels_tab[1][0] = avg_cavs_qpel8_mc00_mmxext; } #endif diff --git a/libavcodec/x86/cavsidct.asm b/libavcodec/x86/cavsidct.asm index 6c768c2646..070b46a6cc 100644 --- a/libavcodec/x86/cavsidct.asm +++ b/libavcodec/x86/cavsidct.asm @@ -107,6 +107,7 @@ SECTION .text SUMSUB_BA w, 1, 0 ; m1 = dst3, m0 = dst4 %endmacro +%if ARCH_X86_32 INIT_MMX mmx cglobal cavs_idct8, 2, 4, 8, 8 * 16, out, in, cnt, tmp mov cntd, 2 @@ -168,6 +169,7 @@ cglobal cavs_idct8, 2, 4, 8, 8 * 16, out, in, cnt, tmp jg .loop_2 RET +%endif INIT_XMM sse2 cglobal cavs_idct8, 2, 2, 8 + ARCH_X86_64, 0 - 8 * 16, out, in From patchwork Thu Jun 9 23:55:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36154 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp888813ybk; Thu, 9 Jun 2022 16:58:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwnc7GAtS3X5PX0LA1WUZaPT7QcBTK7oze1LaIf3SdDZRoFd3wBZpoBRuNteNX93AeDb0hN X-Received: by 2002:a17:906:519c:b0:712:1c90:1c39 with SMTP id y28-20020a170906519c00b007121c901c39mr1525096ejk.620.1654819123451; Thu, 09 Jun 2022 16:58:43 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id fj2-20020a1709069c8200b006fea2b8ed8dsi4735881ejc.297.2022.06.09.16.58.43; Thu, 09 Jun 2022 16:58:43 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=pDTyN9x8; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 69E8068B8AF; Fri, 10 Jun 2022 02:56:33 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-oln040092074013.outbound.protection.outlook.com [40.92.74.13]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 06E6668B8A4 for ; Fri, 10 Jun 2022 02:56:30 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Cz6XaD8Uzg7d+6CY6eEF754M6edKTBBRiRc8KKvxzaV4kqKHN8CRKvTXeLHfvGHCTDJLC+TGzYjORlcEpifVpTlM5tEWnJLWM53GsXC0ZEEXp9Oie2HYLnELfi+0Qr1xlTHdbZX0M7ZdBfYyT92YmSoWRr1F+ijTyvhB3zc5okvBV2fBhuSRLDPPp/2ygtSnAEvPBfGZFV/8LhK0+CgBzrlYAD4LpAAtx39nOtEtj/yqb1/9zJl+9WowWt35bVLe4hUpgUcXbBBRmZA38z2UKii0u8pBoR8xH8yaCxumOH/HMUnelpXgvkvo69uTHBWVWcv7vuyvNDNCXylj78AFRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=7HAJou86PfcOCZi51pIHhzqMVMlnh2d6hwmhIQ7wX/M=; b=c5YSYiMojL70F+bx39vXI0kPc9hU0vG4UmRfHBYzHcy1haDCzDW/qMukQ8V1KaTmWtDtzuAW5JEBUuZDOv+dawsq38q4zPNEE/ltcEkEOtwdmw0rccDruju8tlS+75IEg9ouXiLKOQaKtQIwqTTyfvOQV3PqnDvBkOfMrRbJhFdtxo4liLFB+Et/Lz+3Y8kPcl15JWflMOVGQUVDUPXrzzLYKRc9Xp8L5sxf8/KKrSyTQAQ1WpgXZCnT/scosgkD+DfnII0cyN3tCXt0QVbEVLGBBHr+ieFouQkTXp+yKKYlY6f1tUleb7TZqY6CBTmyMgO9AtL6xdNP9IkFOyhZhg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=7HAJou86PfcOCZi51pIHhzqMVMlnh2d6hwmhIQ7wX/M=; b=pDTyN9x8Rg0KDOkOUF75+3v4fvNr4CCu7AwoIyLysf3kOPYkMXwIl3ksYK/TG71iS93qKuSIl+ECutOqL7CkbHd9xY0pc8nYJ1GYpziJlZE4jSBLG0NeKv4eVBy/X+CQWOjjBazrwnSJkuQ7lnB2ySHuZ/4Yb9kv72lucwpxoy0sTZ82VaLgnvxYz1i3j3I2WgOff8GEknRLn5o60YlFQJZvJxEaLmUf5rMMTVqo6cCo7pRs7F+LpcyoNm1T36azyEl3MzlWuC32U03VE7uN/N8ftkye1MpkFOIa7B9GAArgn2IqMHmrYJbGuga93DLtQDqPsrr0wUgt2tQbdYc8+w== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:29 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:29 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:00 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [Iwnm73pTvoNPKUeKd46ZsmE+azB4PAlh] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-18-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 574f34b2-1010-4c1e-f756-08da4a73abc5 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKf1z/Z0tSEnyEsnFmWbZzSf6aSOVFT5cWNazzZWxWQPa2haeXIt8Ng2l7yc9d6jblHJZQrSpjBz0hP4SZd21tuSIU1122iZEt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LISbREje6SYIjNFF0VnqHMLwNr2QobTI0YYoA5K4AIQ/solKr2hX07inyaqiQjqOIn/sy0NUr7SjfWTvSV+qtbuMLegxwLx+r9MrkuUIeu/qmXlJTCtXm6XKXFxkEUSiC8pct0ymH7/FkiD8/zYQP6LjIFe4bVEK15roldkZdCUPjKVs9jv1lJ1h6+QIbA79VU3/tcvq1b25HJz3TgNvkpWkl04anh0dqy073Ui9IINMM0N3l+w5M59Sz2gqDhXFJCz+hzIMO8Hab/64ifBiyvG4kQycdwO8tF9EUR2Dqjgpx2MOBAhA4nFkdcZ0Uayti+U497zaLlFjD3V9jazYOVVRXBcrB0uNQxj9wvE6xcvpuJKD/MBzw6LhQfvwpkHCj20LiTG/esF1zDW/W6nzpaltLqe2t8sa/WBHnhlrJ3BA9m37fh+DmOKJZokWIOTFWa81aEXu/rNU700HR88R+Z1saq55g4Af7zta1LCPgZhEvgLP3eaoRYCkw3ESUJidYHCFM4Gdt2uWsbgOmdqU4/J3j53p4eH0xMiwg4PlGphmCGL+/PG7+aIKMSgqqTZXHxL6eqzVqcMwOESC0h6AIoorjVCTAT91rSzGEDTXgbbPqYAEriKMpuLTpCnFPkSCvggJXb9+0GoBwkUnFX2bZN4y7opx3Ou0YRjSVk8rA4blGrAjhJnxbkKM0kiids7wtDoixOI5hTPpThDiDVnaJjW6KeBtrJUG0rFw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 574f34b2-1010-4c1e-f756-08da4a73abc5 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:29.2418 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 18/41] avcodec/x86/h264_intrapred_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: U5L6sRx+PFdn Content-Length: 11954 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such H.264-intrapred-dsp functions at compile-time. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_intrapred.asm | 26 +++++++++++++++++++++++++ libavcodec/x86/h264_intrapred_10bit.asm | 16 +++++++++++++++ libavcodec/x86/h264_intrapred_init.c | 20 +++++++++++++++---- 3 files changed, 58 insertions(+), 4 deletions(-) diff --git a/libavcodec/x86/h264_intrapred.asm b/libavcodec/x86/h264_intrapred.asm index b36c198fbb..9426598a63 100644 --- a/libavcodec/x86/h264_intrapred.asm +++ b/libavcodec/x86/h264_intrapred.asm @@ -48,6 +48,7 @@ cextern pw_8 ; void ff_pred16x16_vertical_8(uint8_t *src, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 INIT_MMX mmx cglobal pred16x16_vertical_8, 2,3 sub r0, r1 @@ -63,6 +64,7 @@ cglobal pred16x16_vertical_8, 2,3 dec r2 jg .loop REP_RET +%endif INIT_XMM sse cglobal pred16x16_vertical_8, 2,3 @@ -114,8 +116,10 @@ cglobal pred16x16_horizontal_8, 2,3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PRED16x16_H +%endif INIT_MMX mmxext PRED16x16_H INIT_XMM ssse3 @@ -176,8 +180,10 @@ cglobal pred16x16_dc_8, 2,7 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_DC +%endif INIT_XMM sse2 PRED16x16_DC INIT_XMM ssse3 @@ -187,6 +193,7 @@ PRED16x16_DC ; void ff_pred16x16_tm_vp8_8(uint8_t *src, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 %macro PRED16x16_TM 0 cglobal pred16x16_tm_vp8_8, 2,5 sub r0, r1 @@ -227,6 +234,7 @@ INIT_MMX mmx PRED16x16_TM INIT_MMX mmxext PRED16x16_TM +%endif INIT_XMM sse2 cglobal pred16x16_tm_vp8_8, 2,6,6 @@ -565,6 +573,7 @@ cglobal pred16x16_plane_%1_8, 2,9,7 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx H264_PRED16x16_PLANE h264 H264_PRED16x16_PLANE rv40 @@ -573,6 +582,7 @@ INIT_MMX mmxext H264_PRED16x16_PLANE h264 H264_PRED16x16_PLANE rv40 H264_PRED16x16_PLANE svq3 +%endif INIT_XMM sse2 H264_PRED16x16_PLANE h264 H264_PRED16x16_PLANE rv40 @@ -747,10 +757,12 @@ ALIGN 16 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx H264_PRED8x8_PLANE INIT_MMX mmxext H264_PRED8x8_PLANE +%endif INIT_XMM sse2 H264_PRED8x8_PLANE INIT_XMM ssse3 @@ -794,8 +806,10 @@ cglobal pred8x8_horizontal_8, 2,3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PRED8x8_H +%endif INIT_MMX mmxext PRED8x8_H INIT_MMX ssse3 @@ -937,6 +951,7 @@ cglobal pred8x8_dc_rv40_8, 2,7 ; void ff_pred8x8_tm_vp8_8(uint8_t *src, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 %macro PRED8x8_TM 0 cglobal pred8x8_tm_vp8_8, 2,6 sub r0, r1 @@ -976,6 +991,7 @@ INIT_MMX mmx PRED8x8_TM INIT_MMX mmxext PRED8x8_TM +%endif INIT_XMM sse2 cglobal pred8x8_tm_vp8_8, 2,6,4 @@ -1333,6 +1349,7 @@ PRED8x8L_VERTICAL ; int has_topright, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 INIT_MMX mmxext cglobal pred8x8l_down_left_8, 4,5 sub r0, r3 @@ -1440,6 +1457,7 @@ cglobal pred8x8l_down_left_8, 4,5 por mm1, mm0 movq [r0+r3*1], mm1 RET +%endif %macro PRED8x8L_DOWN_LEFT 0 cglobal pred8x8l_down_left_8, 4,4 @@ -1534,6 +1552,7 @@ PRED8x8L_DOWN_LEFT ; int has_topright, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 INIT_MMX mmxext cglobal pred8x8l_down_right_8, 4,5 sub r0, r3 @@ -1665,6 +1684,7 @@ cglobal pred8x8l_down_right_8, 4,5 por mm0, mm1 movq [r0+r3*1], mm0 RET +%endif %macro PRED8x8L_DOWN_RIGHT 0 cglobal pred8x8l_down_right_8, 4,5 @@ -1786,6 +1806,7 @@ PRED8x8L_DOWN_RIGHT ; int has_topright, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 INIT_MMX mmxext cglobal pred8x8l_vertical_right_8, 4,5 sub r0, r3 @@ -1892,6 +1913,7 @@ cglobal pred8x8l_vertical_right_8, 4,5 PALIGNR mm5, mm0, 7, mm1 movq [r4+r3*2], mm5 RET +%endif %macro PRED8x8L_VERTICAL_RIGHT 0 cglobal pred8x8l_vertical_right_8, 4,5,7 @@ -2192,6 +2214,7 @@ PRED8x8L_HORIZONTAL_UP ; int has_topright, ptrdiff_t stride) ;----------------------------------------------------------------------------- +%if ARCH_X86_32 INIT_MMX mmxext cglobal pred8x8l_horizontal_down_8, 4,5 sub r0, r3 @@ -2306,6 +2329,7 @@ cglobal pred8x8l_horizontal_down_8, 4,5 PALIGNR mm3, mm4, 6, mm4 movq [r0+r3*1], mm3 RET +%endif %macro PRED8x8L_HORIZONTAL_DOWN 0 cglobal pred8x8l_horizontal_down_8, 4,5 @@ -2508,8 +2532,10 @@ cglobal pred4x4_tm_vp8_8, 3,6 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PRED4x4_TM +%endif INIT_MMX mmxext PRED4x4_TM diff --git a/libavcodec/x86/h264_intrapred_10bit.asm b/libavcodec/x86/h264_intrapred_10bit.asm index 629e0a72e3..e978d91ff1 100644 --- a/libavcodec/x86/h264_intrapred_10bit.asm +++ b/libavcodec/x86/h264_intrapred_10bit.asm @@ -411,8 +411,10 @@ cglobal pred8x8_dc_10, 2, 6 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED8x8_DC pshufw +%endif INIT_XMM sse2 PRED8x8_DC pshuflw @@ -526,8 +528,10 @@ cglobal pred8x8l_128_dc_10, 4, 4 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED8x8L_128_DC +%endif INIT_XMM sse2 PRED8x8L_128_DC @@ -1033,8 +1037,10 @@ cglobal pred16x16_vertical_10, 2, 3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_VERTICAL +%endif INIT_XMM sse2 PRED16x16_VERTICAL @@ -1057,8 +1063,10 @@ cglobal pred16x16_horizontal_10, 2, 3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_HORIZONTAL +%endif INIT_XMM sse2 PRED16x16_HORIZONTAL @@ -1103,8 +1111,10 @@ cglobal pred16x16_dc_10, 2, 6 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_DC +%endif INIT_XMM sse2 PRED16x16_DC @@ -1135,8 +1145,10 @@ cglobal pred16x16_top_dc_10, 2, 3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_TOP_DC +%endif INIT_XMM sse2 PRED16x16_TOP_DC @@ -1172,8 +1184,10 @@ cglobal pred16x16_left_dc_10, 2, 6 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_LEFT_DC +%endif INIT_XMM sse2 PRED16x16_LEFT_DC @@ -1193,7 +1207,9 @@ cglobal pred16x16_128_dc_10, 2,3 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PRED16x16_128_DC +%endif INIT_XMM sse2 PRED16x16_128_DC diff --git a/libavcodec/x86/h264_intrapred_init.c b/libavcodec/x86/h264_intrapred_init.c index a95cfbca55..b4b04beff5 100644 --- a/libavcodec/x86/h264_intrapred_init.c +++ b/libavcodec/x86/h264_intrapred_init.c @@ -193,10 +193,13 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, if (bit_depth == 8) { if (EXTERNAL_MMX(cpu_flags)) { +#if ARCH_X86_32 h->pred16x16[VERT_PRED8x8 ] = ff_pred16x16_vertical_8_mmx; h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_8_mmx; +#endif if (chroma_format_idc <= 1) { h->pred8x8 [VERT_PRED8x8 ] = ff_pred8x8_vertical_8_mmx; +#if ARCH_X86_32 h->pred8x8 [HOR_PRED8x8 ] = ff_pred8x8_horizontal_8_mmx; } if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) { @@ -214,23 +217,28 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, } else { h->pred16x16[PLANE_PRED8x8] = ff_pred16x16_plane_h264_8_mmx; } +#endif } } if (EXTERNAL_MMXEXT(cpu_flags)) { h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_8_mmxext; +#if ARCH_X86_32 h->pred16x16[DC_PRED8x8 ] = ff_pred16x16_dc_8_mmxext; +#endif if (chroma_format_idc <= 1) h->pred8x8[HOR_PRED8x8 ] = ff_pred8x8_horizontal_8_mmxext; h->pred8x8l [TOP_DC_PRED ] = ff_pred8x8l_top_dc_8_mmxext; h->pred8x8l [DC_PRED ] = ff_pred8x8l_dc_8_mmxext; h->pred8x8l [HOR_PRED ] = ff_pred8x8l_horizontal_8_mmxext; h->pred8x8l [VERT_PRED ] = ff_pred8x8l_vertical_8_mmxext; - h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_mmxext; - h->pred8x8l [VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_8_mmxext; h->pred8x8l [HOR_UP_PRED ] = ff_pred8x8l_horizontal_up_8_mmxext; +#if ARCH_X86_32 h->pred8x8l [DIAG_DOWN_LEFT_PRED ] = ff_pred8x8l_down_left_8_mmxext; + h->pred8x8l [DIAG_DOWN_RIGHT_PRED ] = ff_pred8x8l_down_right_8_mmxext; + h->pred8x8l [VERT_RIGHT_PRED ] = ff_pred8x8l_vertical_right_8_mmxext; h->pred8x8l [HOR_DOWN_PRED ] = ff_pred8x8l_horizontal_down_8_mmxext; +#endif h->pred4x4 [DIAG_DOWN_RIGHT_PRED ] = ff_pred4x4_down_right_8_mmxext; h->pred4x4 [VERT_RIGHT_PRED ] = ff_pred4x4_vertical_right_8_mmxext; h->pred4x4 [HOR_DOWN_PRED ] = ff_pred4x4_horizontal_down_8_mmxext; @@ -252,11 +260,12 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, } } if (codec_id == AV_CODEC_ID_VP7 || codec_id == AV_CODEC_ID_VP8) { - h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_mmxext; h->pred8x8 [DC_PRED8x8 ] = ff_pred8x8_dc_rv40_8_mmxext; - h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_mmxext; h->pred4x4 [TM_VP8_PRED ] = ff_pred4x4_tm_vp8_8_mmxext; h->pred4x4 [VERT_PRED ] = ff_pred4x4_vertical_vp8_8_mmxext; +#if ARCH_X86_32 + h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_tm_vp8_8_mmxext; + h->pred8x8 [PLANE_PRED8x8 ] = ff_pred8x8_tm_vp8_8_mmxext; } else { if (chroma_format_idc <= 1) h->pred8x8 [PLANE_PRED8x8] = ff_pred8x8_plane_8_mmxext; @@ -267,6 +276,7 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, } else { h->pred16x16[PLANE_PRED8x8 ] = ff_pred16x16_plane_h264_8_mmxext; } +#endif } } @@ -338,6 +348,7 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, h->pred4x4[DC_PRED ] = ff_pred4x4_dc_10_mmxext; h->pred4x4[HOR_UP_PRED ] = ff_pred4x4_horizontal_up_10_mmxext; +#if ARCH_X86_32 if (chroma_format_idc <= 1) h->pred8x8[DC_PRED8x8 ] = ff_pred8x8_dc_10_mmxext; @@ -349,6 +360,7 @@ av_cold void ff_h264_pred_init_x86(H264PredContext *h, int codec_id, h->pred16x16[LEFT_DC_PRED8x8 ] = ff_pred16x16_left_dc_10_mmxext; h->pred16x16[VERT_PRED8x8 ] = ff_pred16x16_vertical_10_mmxext; h->pred16x16[HOR_PRED8x8 ] = ff_pred16x16_horizontal_10_mmxext; +#endif } if (EXTERNAL_SSE2(cpu_flags)) { h->pred4x4[DIAG_DOWN_LEFT_PRED ] = ff_pred4x4_down_left_10_sse2; From patchwork Thu Jun 9 23:55:01 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36157 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp888917ybk; Thu, 9 Jun 2022 16:58:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwkOaHTR4C1yLPcC5FZ5xfZtrInplcSXPOh3M8rwg7SVQwPkPafVPfErZwGI5jtNE/vay+8 X-Received: by 2002:a17:906:6985:b0:6fe:988b:d248 with SMTP id i5-20020a170906698500b006fe988bd248mr38566252ejr.226.1654819133905; Thu, 09 Jun 2022 16:58:53 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id sg44-20020a170907a42c00b007120074c1d4si4985665ejc.747.2022.06.09.16.58.53; Thu, 09 Jun 2022 16:58:53 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b="E0rgML/8"; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 7BACA68B88F; Fri, 10 Jun 2022 02:56:41 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-oln040092074058.outbound.protection.outlook.com [40.92.74.58]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id B020368B7AD for ; Fri, 10 Jun 2022 02:56:33 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Z5RAP05VMvWZN0KPMb41xVRqvMPvr617mdIAAe/Fy7iNrs4YAZXbPUyCrwv66SQqfTIJlOque4Ab9kMC6fKzxpzjJWS0hXG8x2pmyyiBSdQoWD4G2icQBfB8oGhjLsOAkrjEvT7qgWs7BWVX2Bp8i28LxRBjAAXC84XK9c7h9y85MCwCKwZk2uqhZQ5K3gH0kaFCUWk47twaH4qXYw3Yx58AQntSBLPk7XHoPO00sHyIxrH2s75nC1BDOpbj6WeMv4AiUqEndolvQ9T+D3MMdE9baI1jVT/zqJMG25gZ8Zy/1sZtZgkFkebXymfdaSh2ul6sIzYORZomIxuoXLWLzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=pbTGxb/RPNgubUIAZVqiJL78uBpp7gsr3XHcvoVn0Lg=; b=IQYZ0XtNK630UAMPOjADN6Hle3In+7XnYmFIkKSpX67SNB2aKwUptF/iWDDrVODGYJZR0yTTA06iq8pZpdx03H9dolCLMfKaPDKesfUXUXW56P8Hq/AF/4ntDIoLn2hwN7w90rDE41nxtCjuOoa36kebTEZGhDCT+G+XgX0ur+6IUAnIN9qbHQzY7crD7DlbYEn+zepdFyZXHgtdi5Lpmqn1TJcJUGZtooc0NnEfcohZT+Blp1w/Nju4Rrhb4p0lDWjsEOX8/UU7LuZL/dfs7uUvlVRIQtAslrWR6cauWbiTMEE/cFtw/zd+8Lwqy+/PetH+eYOt6p6fdXy6AQAtRA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pbTGxb/RPNgubUIAZVqiJL78uBpp7gsr3XHcvoVn0Lg=; b=E0rgML/8HMEy3TzhyTQPE6pDZE20Dy9+Wq5r05/3EAaBOHe4T4PkZIVo1qhGQidmjvCBTMZ71/28LeVlYitka/gK1o93z8pJbl9h7YYMCHTrdBuvgPNeAhylQvs879TEzJFL+0u6lZAUWkCJi5s42Mc2jCbh3ic4BjTjDkqBw3+/v4h8IR4rRxrmhakRLsys92lhgiRAlibV5wTO3HThbMABc54J8wyhFvnmd4sk28u9ILkXJXfza2Te1AdnHyp9K8Jt8gagaQJFHXET2dFG7Vr8z48Vh2BsmKydzBVnZd5jkl1s6CoCxJa51vNoYIjJci+pFkMHjVw4hL8CK9SW1A== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:32 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:32 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:01 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [y1egpJ7sOT+EE6OAZv6JTjoWraCnbh2Q] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-19-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 391cd6ce-29b6-41d3-f4ec-08da4a73adc8 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvMM96q35HTFzQcKwIZn77ThFeMtcOunjVco8CqsfS2Ydk2auu/YGIUWglr4DmnDS55LPdfau4eEaJkoSWBLrSaRWlz8R/+JWzkeAGDqsk/cDPZrgthmlYFEy01q9vRbbWHafeJfUVBq43chUd2BtM5anH1aphjnzPUY3rQHURKg1Yl2kQ93zMjohBO7vQIageyVfOV9v/rK7tU7rnNSZSeJBidNWVZgNgTwJX6wcuPsr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2n8pahcLFFBMazmeJCWT31nuWVdIOga3sP1RDZMLBN5S9ubNWF94bMjERUKzEgfQi0zKHyP3FdRzsAhekngLx5D76VN5WPR7fw/htqrR4WKiTBE+3a0bK82lrDH677xgSwy2f6R1cPz5wmijs6K7VB/T/O5ZbSImILwxlRhUe6QlxFcKViknL4RSKFxVnQ5SvkWYmJ2I3lPZGDs4P5Rh2m0PaMPxOBGFZKu1SVV0azhQP119wq+C3ntlqnwo2MsfinBeLxOQ6kIc75uqra41Qg5kGfLZoMmHa7oXPaN4iMh6HqAZdp03jiSu/2/F01c5VIJqedu7+xmpNeu0LZxzzGQQQR6hlhWMVWO29QRN4cSUNhORoGwwR5RUhC+PNREQjM7shRR2NgM2qyO7jmTY8VtVDeDULqYkIVLf7UeoHoDlF0jM6owRW0HazUNO0Ioa/9QNCyJiCNJdcSQgHZSlxlmlE4UOtZhF2VYq5XMxG1y50Q93suxN/MEnV/gLwMqgbdNCf18sMYHeBRuy8deybkAGOKXvuodlLGWnRtwg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 391cd6ce-29b6-41d3-f4ec-08da4a73adc8 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:32.6325 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 19/41] avfilter/x86/vf_noise: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 7Kwp/8RYfutp Content-Length: 1637 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables line_noise_mmx at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavfilter/x86/vf_noise.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavfilter/x86/vf_noise.c b/libavfilter/x86/vf_noise.c index f7a4d00336..ce7260e94f 100644 --- a/libavfilter/x86/vf_noise.c +++ b/libavfilter/x86/vf_noise.c @@ -25,6 +25,7 @@ #include "libavfilter/vf_noise.h" #if HAVE_INLINE_ASM +#if ARCH_X86_32 static void line_noise_mmx(uint8_t *dst, const uint8_t *src, const int8_t *noise, int len, int shift) { @@ -52,6 +53,7 @@ static void line_noise_mmx(uint8_t *dst, const uint8_t *src, if (mmx_len != len) ff_line_noise_c(dst+mmx_len, src+mmx_len, noise+mmx_len, len-mmx_len, 0); } +#endif #if HAVE_6REGS static void line_noise_avg_mmx(uint8_t *dst, const uint8_t *src, @@ -132,7 +134,9 @@ av_cold void ff_noise_init_x86(NoiseContext *n) int cpu_flags = av_get_cpu_flags(); if (INLINE_MMX(cpu_flags)) { +#if ARCH_X86_32 n->line_noise = line_noise_mmx; +#endif #if HAVE_6REGS n->line_noise_avg = line_noise_avg_mmx; #endif From patchwork Thu Jun 9 23:55:02 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36156 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp888976ybk; Thu, 9 Jun 2022 16:59:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz+6G97tODg4drFJswfaMhSDWozwDGfntjPp4uSoLZLLCfhwnf1rncaBhVCEeKrvAiGdu6Q X-Received: by 2002:a17:907:7f8d:b0:711:d8db:2714 with SMTP id qk13-20020a1709077f8d00b00711d8db2714mr18060748ejc.63.1654819140505; Thu, 09 Jun 2022 16:59:00 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id v17-20020a056402175100b0042839620d77si19171791edx.631.2022.06.09.16.59.00; Thu, 09 Jun 2022 16:59:00 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=JbgNehbB; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 05F9968B8BA; Fri, 10 Jun 2022 02:56:42 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-oln040092074058.outbound.protection.outlook.com [40.92.74.58]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E436A68B7AD for ; Fri, 10 Jun 2022 02:56:38 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GAc6cco/GrFjsseCKOuWhK2pH8gM6/j/tnd6EfTwqfVbGPeVWe2eX/jsuvjJMYGVkKxvJ2iN+q7LguUnJTxzEpGisakQO1MpH78Wa/s7/USFz4KyTZ07+KqzvSgbn1cPgSm+RAx4wJGKaUGUOXcXRhMGs1FZgaTfHkKXVrD3iAxrg95zfuTATFTaeTAr9rt1I45Rokls9p7V1DZCxBjz/J1/udeHHWWTHrcZptNT6O1z0q2chZJGtZf83XmtgYBxRj3Cud6TnozpsTPq6SyOOrRX1MMoAIiaaGdjIPde9M57IhhnZCsDx+pnRgm4aCCZiTzIM70Kqr9nmxuwCbfP7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=lgTtglDe8rJxlnp1Xz9BNiVN13NiRcNR2hFYp9ZTBkU=; b=nMWc6zBZ+oEeliziNkRmCmheJvpE3pdS2EoqfKF1uaj6ytW413SmknQjrPZBYVwWC5T3nt3i4zZyqXztkoyu3Thkt2D9bI9A8VkncITQVVmtP7sMzjGydPHm65xrkPpfUiMbFoZVQIEQQc76LMXim+UT5YWj8e21tdTgHmBDMafp/19xg0cKqQFIqSF77oVOJIZtgrlQcsG2NH/vGsZr/k8x03GCdb+yfu2fcWWdu6sa/q4YM//xxlP3MoKnDUEwSYhoPA4byRHz62CjIqajfGXHsuwVFPXvL7j3Iv9+3hHvK+tFGP0GEg8DQfGCtO7+ciVkdbp4TPhjENnNjbiYgw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=lgTtglDe8rJxlnp1Xz9BNiVN13NiRcNR2hFYp9ZTBkU=; b=JbgNehbB9XXMCLP6I8I6csvN2MHzjSbo81IsUmGRJHxHyjm9KN3v2mNj+EoHS2I6jRNvyrwidRD+2vCn8hOUFgZQ8ir2eDw9WHnwHWZgJ2Ni1XSvM3PJVOYqzylqvzcTiPmRI4RXTfU7pcxXkIwBKA1+q68B0ZDlHZDAMRxUFpnCFSq0oXfCsOJZ9DfANOC6zRlys68UOVdTuHoVNT2MucGJHpn+cowQxdL39ut0Dh62yFYMY2JCTSv8CDflCEtmKd6YANoTTDzdDF55kB5O50s29ltcQF4+C0DDePZjs5WzW5aaB1K6vZJm5oLrgKIFfI7SKhT0ZYJVm9G/K5CPvQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5809.eurprd01.prod.exchangelabs.com (2603:10a6:208:16f::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:56:35 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:34 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:02 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [HqsAFVTg6KL/zPipHncAbiCf+SeK9mow] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-20-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0cb350b1-5d61-44b7-5e1a-08da4a73aef5 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKzLqQpsDZYwaNtD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dg+SiIFfRkKFDMxD5L7t1zODOFbxKRdxL9oQ+dMl8Z4ojOm0HTPDaSz/ZxTypYAZXAZWDRfcHI9gwLUwq0cIBXgJktANPi2VSLwqGy/ZkxmaUITT/9eSzm87yPQIJcsdxnwCdAheU8H2tu9Z3KeDNmlfIh5iZCLq9EYvv6aNqT5/JDEDWHIFE2jdXOaPyqGtB382oEGQugwSCwMzDd4g4tgqvKSVgs6iA0nrbUELs8PDYR4VrqgOlghfQ1rUPGQZ2xfmkur3b12JDJ4LXxAVtzCj31fSW7qblBsUfVSBjxohXIlbJunWASNmRQ6eL4J+TqBUi7TdIwFjkER3BuwNtIZhz4xf011hNowMwD2ubSvfmlOlG3BNvyJ3wP58ebwZ5hIPsz1BCffci6uI0AhUdZznVds6mg940/tB/Dh1asjf4Xgqqwotxc03/8KN3WkeZmp6S/MFh4aVBP3sNBK1rqGJRDp+LL7slxlcUH/1yXEOw2fhUxk8jgmg8zJMixUh0VPNqtB7SQ5yq9xIqYxEDdi5X3zHtMaHuNzGMRioQQ8IMzLrmF5Q1iMzeEF8Xxs4i9rFeJQ2Q4RJxpZBvQtYeegR4QKhYLo1n08OgF6KQGl3H0bgnTRpw2dFk1NzGnQddWbZubFxqP6xlH18QJiRH9iHlj/iQeaAidOTHHjjDmg7UoSC9vahNsaQ74WE5COW4iMOrOBF86HM0a50Yw7pK7yC8udO0JhG7ZOm6L+TrTB/NQ6LCE9JPHUP1XH1NuqkItZRy3GPxHBcf4Fuzxl94/gMWkcARHmKh4dQC1BC+pg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0cb350b1-5d61-44b7-5e1a-08da4a73aef5 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:34.5700 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5809 Subject: [FFmpeg-devel] [PATCH 20/41] avcodec/x86/me_cmp: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: h4wwZ2rI9hAN Content-Length: 7683 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such me_cmp functions at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/me_cmp.asm | 6 ++++ libavcodec/x86/me_cmp_init.c | 61 +++++++++++++++++++++--------------- 2 files changed, 42 insertions(+), 25 deletions(-) diff --git a/libavcodec/x86/me_cmp.asm b/libavcodec/x86/me_cmp.asm index ad06d485ab..05e521cb08 100644 --- a/libavcodec/x86/me_cmp.asm +++ b/libavcodec/x86/me_cmp.asm @@ -261,11 +261,15 @@ hadamard8_16_wrapper 0, 14 %endif %endmacro +%if ARCH_X86_32 INIT_MMX mmx HADAMARD8_DIFF +%endif +%if ARCH_X86_32 || HAVE_ALIGNED_STACK == 0 INIT_MMX mmxext HADAMARD8_DIFF +%endif INIT_XMM sse2 %if ARCH_X86_64 @@ -385,10 +389,12 @@ cglobal sum_abs_dctelem, 1, 1, %1, block RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx SUM_ABS_DCTELEM 0, 4 INIT_MMX mmxext SUM_ABS_DCTELEM 0, 4 +%endif INIT_XMM sse2 SUM_ABS_DCTELEM 7, 2 INIT_XMM ssse3 diff --git a/libavcodec/x86/me_cmp_init.c b/libavcodec/x86/me_cmp_init.c index 9af911bb88..6144bb9496 100644 --- a/libavcodec/x86/me_cmp_init.c +++ b/libavcodec/x86/me_cmp_init.c @@ -126,6 +126,7 @@ static int nsse8_mmx(MpegEncContext *c, uint8_t *pix1, uint8_t *pix2, #if HAVE_INLINE_ASM +#if ARCH_X86_32 static int vsad_intra16_mmx(MpegEncContext *v, uint8_t *pix, uint8_t *dummy, ptrdiff_t stride, int h) { @@ -270,6 +271,7 @@ static int vsad16_mmx(MpegEncContext *v, uint8_t *pix1, uint8_t *pix2, return tmp & 0x7FFF; } #undef SUM +#endif DECLARE_ASM_CONST(8, uint64_t, round_tab)[3] = { 0x0000000000000000ULL, @@ -478,20 +480,6 @@ static int sad8_y2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ return sum_ ## suf(); \ } \ \ -static int sad8_xy2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ - uint8_t *blk1, ptrdiff_t stride, int h) \ -{ \ - av_assert2(h == 8); \ - __asm__ volatile ( \ - "pxor %%mm7, %%mm7 \n\t" \ - "pxor %%mm6, %%mm6 \n\t" \ - ::); \ - \ - sad8_4_ ## suf(blk1, blk2, stride, 8); \ - \ - return sum_ ## suf(); \ -} \ - \ static int sad16_ ## suf(MpegEncContext *v, uint8_t *blk2, \ uint8_t *blk1, ptrdiff_t stride, int h) \ { \ @@ -535,7 +523,8 @@ static int sad16_y2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ \ return sum_ ## suf(); \ } \ - \ + +#define PIX_SADXY(suf) \ static int sad16_xy2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ uint8_t *blk1, ptrdiff_t stride, int h) \ { \ @@ -549,8 +538,25 @@ static int sad16_xy2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ \ return sum_ ## suf(); \ } \ + \ +static int sad8_xy2_ ## suf(MpegEncContext *v, uint8_t *blk2, \ + uint8_t *blk1, ptrdiff_t stride, int h) \ +{ \ + av_assert2(h == 8); \ + __asm__ volatile ( \ + "pxor %%mm7, %%mm7 \n\t" \ + "pxor %%mm6, %%mm6 \n\t" \ + ::); \ + \ + sad8_4_ ## suf(blk1, blk2, stride, 8); \ + \ + return sum_ ## suf(); \ +} \ +#if ARCH_X86_32 PIX_SAD(mmx) +#endif +PIX_SADXY(mmx) #endif /* HAVE_INLINE_ASM */ @@ -560,32 +566,35 @@ av_cold void ff_me_cmp_init_x86(MECmpContext *c, AVCodecContext *avctx) #if HAVE_INLINE_ASM if (INLINE_MMX(cpu_flags)) { +#if ARCH_X86_32 + c->sad[0] = sad16_mmx; + c->sad[1] = sad8_mmx; + + if (!(avctx->flags & AV_CODEC_FLAG_BITEXACT)) { + c->vsad[0] = vsad16_mmx; + } + c->vsad[4] = vsad_intra16_mmx; + c->pix_abs[0][0] = sad16_mmx; c->pix_abs[0][1] = sad16_x2_mmx; c->pix_abs[0][2] = sad16_y2_mmx; - c->pix_abs[0][3] = sad16_xy2_mmx; c->pix_abs[1][0] = sad8_mmx; c->pix_abs[1][1] = sad8_x2_mmx; c->pix_abs[1][2] = sad8_y2_mmx; +#endif + c->pix_abs[0][3] = sad16_xy2_mmx; c->pix_abs[1][3] = sad8_xy2_mmx; - - c->sad[0] = sad16_mmx; - c->sad[1] = sad8_mmx; - - c->vsad[4] = vsad_intra16_mmx; - - if (!(avctx->flags & AV_CODEC_FLAG_BITEXACT)) { - c->vsad[0] = vsad16_mmx; - } } #endif /* HAVE_INLINE_ASM */ if (EXTERNAL_MMX(cpu_flags)) { +#if ARCH_X86_32 c->hadamard8_diff[0] = ff_hadamard8_diff16_mmx; c->hadamard8_diff[1] = ff_hadamard8_diff_mmx; c->sum_abs_dctelem = ff_sum_abs_dctelem_mmx; c->sse[0] = ff_sse16_mmx; +#endif c->sse[1] = ff_sse8_mmx; #if HAVE_X86ASM c->nsse[0] = nsse16_mmx; @@ -594,9 +603,11 @@ av_cold void ff_me_cmp_init_x86(MECmpContext *c, AVCodecContext *avctx) } if (EXTERNAL_MMXEXT(cpu_flags)) { +#if ARCH_X86_32 || !HAVE_ALIGNED_STACK c->hadamard8_diff[0] = ff_hadamard8_diff16_mmxext; c->hadamard8_diff[1] = ff_hadamard8_diff_mmxext; c->sum_abs_dctelem = ff_sum_abs_dctelem_mmxext; +#endif c->sad[0] = ff_sad16_mmxext; c->sad[1] = ff_sad8_mmxext; From patchwork Thu Jun 9 23:55:03 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36152 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp889128ybk; Thu, 9 Jun 2022 16:59:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzDhthiNzp9DYEBB/DNT1gLsf3NW1Uxh8sigxirx4F36fpmHkJNGx76bJbEquUAOBvkXO4L X-Received: by 2002:a17:907:8330:b0:711:cfc4:3a3e with SMTP id mq48-20020a170907833000b00711cfc43a3emr21424671ejc.483.1654819155770; Thu, 09 Jun 2022 16:59:15 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id o24-20020a17090611d800b006febef95910si22956307eja.332.2022.06.09.16.59.15; Thu, 09 Jun 2022 16:59:15 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=dmMoCXBN; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 85D6568B8C3; Fri, 10 Jun 2022 02:56:43 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073093.outbound.protection.outlook.com [40.92.73.93]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 48D5E68B7AD for ; Fri, 10 Jun 2022 02:56:38 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=G3xyCH2hCoOs6++YfPd62bGtTkFIv9RdxeUsdeqAtBLF6Cs8kLxgDC7AuNHwb/GW0y0VeeS9Sy4caN5HtpqoicQtw2wyr2lgGUyu1fQDtA5r0dVz+vXsR+Ns61cO5M1btwNUIqoo0WcXZ6xrB/HE7xqsVljmVTWAZOhoWNK7fFpD5LncTigVfDTqUu2aDgo2AEBYUv6ilzUaqtwVTIjIyHviHi/crNRDQebbfUrGUhgwS/PjQwVKDtDo8VV03Ei7HH2mNF6x1ZbCeFIjBdKtLKhDknfHQBFvzPXe4D4txSzNdRlUdFvbQJK0hsfUFLo1IBtII8V5nE4dPVi+xsshQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=qA7DgIuN4uIjkV9FCsUP2f2kMcgZNLDoQXaHA42XZgk=; b=JQ+eNNmmWqrTNYP+Nsm9QmxiXsGP7JeqIhK5ceRmJiWzWagtl1cSyFMh0dkdjNj3dseEP+nZguDUKZVE+U1Bu3S24KCUChoQ9vlhilxaBrw9JSBcgzM2G9JPD9n9XWfV9SJn8Y1rNrI9xii9thpNnVs7lU4Z80xo1s/U2eYh43YleqRljCEfs13479zz+yo26Y8ocDJY05fXU9kUB6+uR9K+GUwBr2irC4HyWCcRgn25/HvmYSxpiprnYxbLHckC9uy+z3mfra44McQHPAGexP5mU+RkaPNprGME54seeZsVfBurd+6s5V2OxkR8HSAHUBsEZjI8im5FmNe6u1X/og== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qA7DgIuN4uIjkV9FCsUP2f2kMcgZNLDoQXaHA42XZgk=; b=dmMoCXBNLQQthwnQjOXHeO29Nl8/e9HqUQw6Tx0hiYberDC/r4rZvIsP2r3KBHYOYMp7la1w6rWnQQ8kxIBopvaGmEQdUF88kTUN6UbwbDUsGifrpNfN2HsllEhOcRckAiOu3NVhdTboXqMU1SB0iYJono6X2ERuk3J5POI5UvYF4FU4vXI40W0vg4M/Z6cm30wIrKvPPm86xNpoNxJ7fa07oMd4z58jUBDCmadVjoo0hvyn7pc7shYS/HVUm1R1WpIS0KkcYBvknK8Z/qcOWurq3flZ+n70O9gelRhRRvX7LzjQYh2EmhQWDXky/z+POL+b36etJ3G5VF7zxSuh1Q== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:37 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:37 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:03 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [vkn+iywXM5OT11/zWejugIvld12laMsY] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-21-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 70a6325b-b66d-4185-86b6-08da4a73b0a2 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKG7m+VkvX9kuWsmRNv2G06jXggYTaRPEeMiSCHcOJeXBx1290cU8rSgv/YtHmMR+aEZMaOmjDp/bBs0qYHkMdTXOqWWDT/uniozqakt39xamK3vtWvXiQnGn9AeWrrX1mXmn2cgHlVJuYVuZLCwRYQofJsLedjr/+qL8Y38Zj+C+r6l6F3KjBoNNeUOy57wnSX5FFIlPEV51Ve09PdUE8dbytUHT07W581eazeNvA7qLXYyuKVjv0dA8ybVitGeqCLEbzUPTgsKe/gvsCU8XejOSoeC2XgGdHZ0z4vG15sHnrBCXAAIgRCJZWXKofh4vEXEqjiD5iQgkxm8JHIBDQ2YxGO1JFWRyc9mbVujfhY6XKVKUkhSLqw1S6NHvOmvvAmevrFa9jxM3Uw1ie9tRqndfWbzXZrRNMGBSrYFVX0DM1LdfZ3g9OIrIv33lszwopkDDC5IXRt7wqesq3B+/5X5/YJ7sVtktWohrRjAGOt9qTH7iDgjo3p/Wr0BmCr/TyaTBr69QKk2q3MvR/udv9968EqDrqcFN8lz4i502YP1Hs7OHSyDdInzzjOBlS7jO6uTWjdxfK0CKrDzWmVB/YwhwfKulROi+tdH8svQuOFSD7CGJPBZzyz3N5US5u3wMghwayAyhGt/ZPL5t+3sewD1tiffozIzZEhe4BAHx/nynwyGMJzaWYVQ0e1JQZ0h4/cWd33B8o2yF7VKV+JxZ3cLlHziJ1NiuAX0NZBaqPGTU= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 0xp6VvlzPYjuEl+czV0AhDRreHoIbBP2pGunB8OZBwY5CB6AvaLp5kkzGc3QcgzmMVTFKkX4IW0BW+ISFh2prYr3SPPoHJwERanTlS8VSE9Pfy/0DmQCdD5wNOz8rjXJK0TsZKHlvd6fJJEmJrId/Iz7vEZver4DcNe4V1CZdl4ckbq9D9IOY7QgRyVuHkuu7InenIU8i5kC9qDd5fJfrrF1AAVVhhl+dX5r50aZyOR7gCFzfLRCAvPXgUPpFRJmpNOgPDsXmkvA+Nr0NnUXpWxc4zapp8zSVqq+xyJZ+NKt/oW9GyjtpbaFcki+2Xf4P6oPT2vqcwrRVRCm89QVpHb34FmtGRVh8diFUyNc0pYLU8f/rJaOocVkghHVSYuUQ7uKE9TfKKF9js2/kh87Azv3gUoWNqzNlUYy7wyDR2N51eJWWecHjKUqGqLoDiQF7I2byD6gKiz5TtiLjpFrhZkoebJZ1lfFnAnFwxgifaAfTMgmt9SYgtUBU9koobhtYuP1FjbZje1XOL4+LjhM0VOUsf75545ZgyExGMJNbvYAz9adsFP3uy/fXv2H+SlJx6CURY02L7KY4EcPl+OaWg== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: glcyTsU8yHl6wphMRG4rUVP2ihgxxFJcS+GFm46WqDhENCUCzNC+AMoVt0TLTkz+JvmD60MKPKKYT0QBnme9FsSe6ksShwI063L+njL2y0JpNt1Kg7yT272hTbzMtfJI3zlVD3OXklN33pyr58V5Hg2SOe0fvy18J2sreuUPe6C3Bg93bbu9ARcMcAn2plPyiAoUm7JF/2P/uVDh6PXVXCglDN8O+kB9oCwNrlznsR2v3fn+OhVOQyh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TTrS7AkyW3l344pDh7DpMeUooEejgWlAajdaLFFlMRmInn1ihxzZJCNE2dPYGGCeeOUDk5vm/OOO2ScZoM3RuXiNIu8kdeQWTHJdb1Lu5gQJKdZP5f1Jc+fJ4AX/EqDCEfhiERJ59XVmqbfNDPHk+Xq2tc70BTfDN+TZ/h8Py9CyKM1g== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 70a6325b-b66d-4185-86b6-08da4a73b0a2 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:37.4138 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 21/41] avcodec/x86/mpegvideoencdsp: Disable ff_pix_norm1_mmx on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: nQAkXtmkMdA5 Content-Length: 830 Forgotten in acebff8e5dc0789c228b10ffcae2f2eb6c30a91d. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/mpegvideoencdsp.asm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavcodec/x86/mpegvideoencdsp.asm b/libavcodec/x86/mpegvideoencdsp.asm index aec73f82dc..639abc429d 100644 --- a/libavcodec/x86/mpegvideoencdsp.asm +++ b/libavcodec/x86/mpegvideoencdsp.asm @@ -147,8 +147,10 @@ cglobal pix_norm1, 2, 3, %1 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PIX_NORM1 0, 16 +%endif INIT_XMM sse2 PIX_NORM1 6, 8 From patchwork Thu Jun 9 23:55:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36153 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp889194ybk; Thu, 9 Jun 2022 16:59:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw2MzQ1iy2EM7RVo5JTvRK1HHXc53NR/Ffup9SfjCoCp3E0taodfIFyJyT840nrx0CIFduK X-Received: by 2002:a17:906:d550:b0:704:7ba6:9854 with SMTP id cr16-20020a170906d55000b007047ba69854mr37714639ejc.579.1654819165069; Thu, 09 Jun 2022 16:59:25 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id e16-20020a056402089000b0042dd608eb5fsi5482932edy.630.2022.06.09.16.59.24; Thu, 09 Jun 2022 16:59:25 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=WFy27xPP; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6436E68B81D; Fri, 10 Jun 2022 02:56:49 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073020.outbound.protection.outlook.com [40.92.73.20]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id DC82B68B89C for ; Fri, 10 Jun 2022 02:56:41 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=I+Zoa7eVBs3yAkn0/ONsEGvPUCRTqVOBh8GeWgdOwwe1+sZE2yNhsI+HBnrdukmcBp9Rrgn+l5+ppr4dNzw2fM2m7QUT03abM4UPKw71FSCUiVprvAnI0w+XRGcJ+XDu1o2XXfZ9M7SzfF30LBIiaYiO67kiREEQFfsOIDkTvJ/4ye1xn7IafDwOL8ywuNXn4Odh2sw0DssjFLyT0BIDcLYVtom/RunyWKk70fSY+GitHSiA/bJdCY/o0DIti158pMhsFnSINrpxkt8jedHBoQ/ufFOvtnlWBrdsOK7JPv8Chr2BLbd0YddrOu88pLYdLuf4UexEtz1M9FdPVKvs1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=j9IFP5ptWbe2uMdpd2j2AJvrmYcSkjqD1nxCTlSHc4g=; b=cDVRsQH7MRSB9UQNSnwQ0U9r/DL4ROnhPJbG0ZJmIMqMe+SAxu0wL/U+zQ8+n/DS2gB2aHo0DNbc+pImtotNW3aP0lHP1Hbhgn6klqmxNvYTOPY82UJnXyE45vGpi2SZGACXbUvS3wXjGO5RgB6QZuQkzeM700mNjzF8Pif3BnKwaVmsJKSDChmCh+YGtRekwtTOF+LIS0f3aaOlqdTgIlyMqFG8r05UoFpr8/zew8W1eLhnIdYWzaWT23cvicVHdPEhFjtFBqclZws1XdenszmXdjBT+GuF5xfTYH5uNBLpj5z8nW27dPjlNvr36DJqf8b79RmnPw+tWyIpFr4Xxg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=j9IFP5ptWbe2uMdpd2j2AJvrmYcSkjqD1nxCTlSHc4g=; b=WFy27xPPcUrJiWBUfyd1SfqOPzlyh5h7OppZWFyesgjZPLkCLjKmAHJp0qBEce//+wJ7zCyEI5RDc0Du6K3XmG8UVkTf5cr1RAFrCw+zw1FZVenJSyR8ifX2ba8As3gkXQzPrxr/RaAnEJ/MRdl5zaKfdaB+2f5dKBlp2iyiIlCYz4+5lgtAM6VbfgN9ZITB2Za836YkfeSl1ssvUJ5lOJtzKaPvaJtSMrGDP6445Y9zu84uZgxGW1f8fJBfnT1eitgPRPQpRuQ9WeEiZ9NdTdLNTyZGSK6r/LyWf393F0vddHaXszRAfu8ooWy9yXaBtW7YCu8C9fjBPgNJl2pPKA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:40 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:40 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:04 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [p9hnxAw1SCv8m0Xy9AcQ2UtIpfdyPbXc] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-22-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 27b99c67-e174-4f8d-24a2-08da4a73b265 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lK5ICh3LxIb9p5Ukhtv6lASHxqGeC/yQoVhbaVEAOvE21XmiwAozB+ZdiFsUtvFPydBM+XxGTSEcaykNVdRNnbnFt0OzBDC3YB/Kbvzd6tLhH/l7xw3uM+OqH4BwAYsBIw2hBub6kYuOiWyngTn61srTNRVlNzfRxtGtG7hv80BccM8okxIUGKR9vjtQWDOSZuAjHPEIXAnPbnzwi/GFTd/U7D+5ty2IPG6YvMMnmQYeumnVikvpALl0u6ZLvRAz8qyyTAW3rERKTL8XeudYL1D8I5YDZlBqUiUuRNaArE+Cu7AmsjicTJ2div0jFT8fyo5y4p8NwnRKLMQQ6eTlWq50EUvmZLsCXRB6R957Y70MAqT0zK8LDj4iZvXTOhU5LliLhQ3fIQGE5a+mt6oc+IATEiVUsTgeypC9zTQYQ0Dj6Xmh1oLqXDUOopCpp2GzGdjUEEZzyCBPEjmaEvpppzqLBsfMdRWMHsw03MujDlew/Pckr2c/4I7aWSHdV9OJZGQbLAW8CoDogkq03gQYnIgbn33+ukUoMZoKghRs6CbdTDAJbZIMrKj1Bre4AKAFcLMTDXLcHOZi+c0CFK/sqYGCqDUoO9gQGFAKEqqIRoqifHv018F3e8srF4dHumV7k5bfqE3rxwlnQpI6bZAEPZ+/gIplSjmof/HeQ4u/j16lgpAM9HiOwUqKMTxIp3j6nBbiyRiTFiziufwzS3bEucVA5awccXeFN5yi2G9JX88f4= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: DwT3MU5GT6qd6fclewbDEDIp6986pK89jnUzDlm2eY2TSqyTkK+7zI1Ng6B3K4p9nqGQIYI27PevCvkD49N+s79pSw80BniFKZScgDjYKmHtoUJ2orcQA0o+9VAKC4ZgnMib0ssU39HmWvqDwXcxbVDcjg1qvJDOuFMBlv4tZrDAzPsf94PuI0r+fFppFkqxhP8JfNe5DL4ksxxyh9C4J9sZw5FF9OyhXalK/NZLCsTPxViMdE3vI72EQPHmQ7s2uRSp8URxigDBH8y4PuEa3adTmPVm5gWVog2wrn7ZA8Z2rlHZ2H+nFp4ToqP6io3ZLfToDqFJWRhBk7wxIU9w8448D8hK8ob6mYxsHrW2029OV6ltMNy1X4SLzAm4YyIcptg4bTBxvv/kE9HiA3JJLofvRgW577UTb6OUSF4S+lhZ9PMG+54ja00O7C00uWTE9zR4N3UUa+MmsgqP74E28pulWEWOJw0+7wFR+qEqpzLDst2TKvw4U1Z7Z5aCIEBfnojfTKPsVCpU4F89rUPV7/l+UxAX6jDBBHd/waqgNCw79rIlhrHL39qhyc3yWH08/9u2zimLS19tejayrByYjw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 3xxTJlchw55ux0lg8NDXqIbTEHcQynW4V7mDStjVl6dleQv6U8i2ThTfakQz9f/WqLfnZROuYd9d3nJomFpBuincTqHe0FaNctI6JMhtgDXIIZHAcskPk3J719dElI1gWfZgaU+Ft+Lq63N7+jvqi9f480/f9v1hKK3v8bVVr+qirYx4weKwFlW3SXTQfGpE4jxSk+7g1B1CVnwIcjOEHPKB+QitIzsU4hJvHX5xs8PrD05W1ov3b9HDhvMBWMhevZYbKWtTwEbiWUiz2JuQNtkZYJ5/Z81tmduJ0pD/FtFDtI2IvF84+ttU0VyhRg9KoPntEP6HIXUC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7SLKD40dKeOQ8Aqqkuo4fQBnNF1QMb6jtv1i8efM+wIJKi59j43nEjylDGl4SDqgyRvg== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 27b99c67-e174-4f8d-24a2-08da4a73b265 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:40.3513 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 22/41] avcodec/x86/h264dsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: cXoSGc8/EVg+ Content-Length: 13430 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables such h264dsp functions at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_deblock.asm | 24 +++----------- libavcodec/x86/h264_idct.asm | 57 +++++++-------------------------- libavcodec/x86/h264_weight.asm | 8 +++++ libavcodec/x86/h264dsp_init.c | 21 ++++++++---- 4 files changed, 38 insertions(+), 72 deletions(-) diff --git a/libavcodec/x86/h264_deblock.asm b/libavcodec/x86/h264_deblock.asm index a2e745cd8e..9e671af45c 100644 --- a/libavcodec/x86/h264_deblock.asm +++ b/libavcodec/x86/h264_deblock.asm @@ -867,7 +867,6 @@ DEBLOCK_LUMA_INTRA v %if ARCH_X86_64 == 0 INIT_MMX mmxext DEBLOCK_LUMA_INTRA v8 -%endif INIT_MMX mmxext @@ -911,17 +910,8 @@ cglobal deblock_v_chroma_8, 5,6 ; int8_t *tc0) ;----------------------------------------------------------------------------- cglobal deblock_h_chroma_8, 5,7 -%if ARCH_X86_64 - ; This could use the red zone on 64 bit unix to avoid the stack pointer - ; readjustment, but valgrind assumes the red zone is clobbered on - ; function calls and returns. - sub rsp, 16 - %define buf0 [rsp] - %define buf1 [rsp+8] -%else %define buf0 r0m %define buf1 r2m -%endif CHROMA_H_START TRANSPOSE4x8_LOAD bw, wd, dq, PASS8ROWS(t5, r0, r1, t6) movq buf0, m0 @@ -934,9 +924,6 @@ cglobal deblock_h_chroma_8, 5,7 movq m0, buf0 movq m3, buf1 TRANSPOSE8x4B_STORE PASS8ROWS(t5, r0, r1, t6) -%if ARCH_X86_64 - add rsp, 16 -%endif RET ALIGN 16 @@ -953,13 +940,8 @@ ff_chroma_inter_body_mmxext: cglobal deblock_h_chroma422_8, 5, 6 SUB rsp, (1+ARCH_X86_64*2)*mmsize - %if ARCH_X86_64 - %define buf0 [rsp+16] - %define buf1 [rsp+8] - %else - %define buf0 r0m - %define buf1 r2m - %endif + %define buf0 r0m + %define buf1 r2m movd m6, [r4] punpcklbw m6, m6 @@ -1059,6 +1041,8 @@ ff_chroma_intra_body_mmxext: paddb m2, m6 ret +%endif ; ARCH_X86_64 == 0 + %macro LOAD_8_ROWS 8 movd m0, %1 movd m1, %2 diff --git a/libavcodec/x86/h264_idct.asm b/libavcodec/x86/h264_idct.asm index c54f9f1a68..17c7af388c 100644 --- a/libavcodec/x86/h264_idct.asm +++ b/libavcodec/x86/h264_idct.asm @@ -87,12 +87,14 @@ SECTION .text STORE_DIFFx2 m2, m3, m4, m5, m7, 6, %1, %3 %endmacro +%if ARCH_X86_32 INIT_MMX mmx ; void ff_h264_idct_add_8_mmx(uint8_t *dst, int16_t *block, int stride) cglobal h264_idct_add_8, 3, 3, 0 movsxdifnidn r2, r2d IDCT4_ADD r0, r1, r2 RET +%endif %macro IDCT8_1D 2 psraw m0, m1, 1 @@ -207,6 +209,7 @@ cglobal h264_idct_add_8, 3, 3, 0 STORE_DIFFx2 m1, m2, m5, m6, m7, 6, %1, %3 %endmacro +%if ARCH_X86_32 INIT_MMX mmx ; void ff_h264_idct8_add_8_mmx(uint8_t *dst, int16_t *block, int stride) cglobal h264_idct8_add_8, 3, 4, 0 @@ -223,6 +226,7 @@ cglobal h264_idct8_add_8, 3, 4, 0 ADD rsp, pad RET +%endif ; %1=uint8_t *dst, %2=int16_t *block, %3=int stride %macro IDCT8_ADD_SSE 4 @@ -315,16 +319,7 @@ cglobal h264_idct8_add_8, 3, 4, 10 %endmacro INIT_MMX mmxext -; void ff_h264_idct_dc_add_8_mmxext(uint8_t *dst, int16_t *block, int stride) %if ARCH_X86_64 -cglobal h264_idct_dc_add_8, 3, 4, 0 - movsxd r2, r2d - movsx r3, word [r1] - mov dword [r1], 0 - DC_ADD_MMXEXT_INIT r3, r2 - DC_ADD_MMXEXT_OP movh, r0, r2, r3 - RET - ; void ff_h264_idct8_dc_add_8_mmxext(uint8_t *dst, int16_t *block, int stride) cglobal h264_idct8_dc_add_8, 3, 4, 0 movsxd r2, r2d @@ -358,6 +353,7 @@ cglobal h264_idct8_dc_add_8, 2, 3, 0 %endif INIT_MMX mmx +%if ARCH_X86_32 ; void ff_h264_idct_add16_8_mmx(uint8_t *dst, const int *block_offset, ; int16_t *block, int stride, ; const uint8_t nnzc[6 * 8]) @@ -438,16 +434,12 @@ cglobal h264_idct_add16_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride jz .no_dc mov word [r2], 0 DC_ADD_MMXEXT_INIT r6, r3 -%if ARCH_X86_64 == 0 %define dst2q r1 %define dst2d r1d -%endif mov dst2d, dword [r1+r5*4] lea dst2q, [r0+dst2q] DC_ADD_MMXEXT_OP movh, dst2q, r3, r6 -%if ARCH_X86_64 == 0 mov r1, r1m -%endif inc r5 add r2, 32 cmp r5, 16 @@ -519,16 +511,12 @@ cglobal h264_idct_add16intra_8, 5, 8 + npicregs, 0, dst1, block_offset, block, s jz .skipblock mov word [r2], 0 DC_ADD_MMXEXT_INIT r6, r3 -%if ARCH_X86_64 == 0 %define dst2q r1 %define dst2d r1d -%endif mov dst2d, dword [r1+r5*4] add dst2q, r0 DC_ADD_MMXEXT_OP movh, dst2q, r3, r6 -%if ARCH_X86_64 == 0 mov r1, r1m -%endif .skipblock: inc r5 add r2, 32 @@ -560,18 +548,14 @@ cglobal h264_idct8_add4_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride jz .no_dc mov word [r2], 0 DC_ADD_MMXEXT_INIT r6, r3 -%if ARCH_X86_64 == 0 %define dst2q r1 %define dst2d r1d -%endif mov dst2d, dword [r1+r5*4] lea dst2q, [r0+dst2q] DC_ADD_MMXEXT_OP mova, dst2q, r3, r6 lea dst2q, [dst2q+r3*4] DC_ADD_MMXEXT_OP mova, dst2q, r3, r6 -%if ARCH_X86_64 == 0 mov r1, r1m -%endif add r5, 4 add r2, 128 cmp r5, 16 @@ -597,6 +581,7 @@ cglobal h264_idct8_add4_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride ADD rsp, pad RET +%endif INIT_XMM sse2 ; void ff_h264_idct8_add4_8_sse2(uint8_t *dst, const int *block_offset, @@ -678,6 +663,7 @@ h264_idct_add8_mmx_plane: jnz .nextblock rep ret +%if ARCH_X86_32 ; void ff_h264_idct_add8_8_mmx(uint8_t **dest, const int *block_offset, ; int16_t *block, int stride, ; const uint8_t nnzc[6 * 8]) @@ -687,20 +673,14 @@ cglobal h264_idct_add8_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride, add r2, 512 %ifdef PIC lea picregq, [scan8_mem] -%endif -%if ARCH_X86_64 - mov dst2q, r0 %endif call h264_idct_add8_mmx_plane mov r5, 32 add r2, 384 -%if ARCH_X86_64 - add dst2q, gprsize -%else add r0mp, gprsize -%endif call h264_idct_add8_mmx_plane RET ; TODO: check rep ret after a function call +%endif cglobal h264_idct_add8_422_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride, nnzc, cntr, coeff, dst2, picreg ; dst1, block_offset, block, stride, nnzc, cntr, coeff, dst2, picreg @@ -734,6 +714,7 @@ cglobal h264_idct_add8_422_8, 5, 8 + npicregs, 0, dst1, block_offset, block, str RET ; TODO: check rep ret after a function call +%if ARCH_X86_32 h264_idct_add8_mmxext_plane: movsxdifnidn r3, r3d .nextblock: @@ -741,14 +722,9 @@ h264_idct_add8_mmxext_plane: movzx r6, byte [r4+r6] test r6, r6 jz .try_dc -%if ARCH_X86_64 - mov r0d, dword [r1+r5*4] - add r0, [dst2q] -%else mov r0, r1m ; XXX r1m here is actually r0m of the calling func mov r0, [r0] add r0, dword [r1+r5*4] -%endif IDCT4_ADD r0, r2, r3 inc r5 add r2, 32 @@ -761,14 +737,9 @@ h264_idct_add8_mmxext_plane: jz .skipblock mov word [r2], 0 DC_ADD_MMXEXT_INIT r6, r3 -%if ARCH_X86_64 - mov r0d, dword [r1+r5*4] - add r0, [dst2q] -%else mov r0, r1m ; XXX r1m here is actually r0m of the calling func mov r0, [r0] add r0, dword [r1+r5*4] -%endif DC_ADD_MMXEXT_OP movh, r0, r3, r6 .skipblock: inc r5 @@ -785,22 +756,16 @@ cglobal h264_idct_add8_8, 5, 8 + npicregs, 0, dst1, block_offset, block, stride, movsxdifnidn r3, r3d mov r5, 16 add r2, 512 -%if ARCH_X86_64 - mov dst2q, r0 -%endif %ifdef PIC lea picregq, [scan8_mem] %endif call h264_idct_add8_mmxext_plane mov r5, 32 add r2, 384 -%if ARCH_X86_64 - add dst2q, gprsize -%else add r0mp, gprsize -%endif call h264_idct_add8_mmxext_plane RET ; TODO: check rep ret after a function call +%endif ; r0 = uint8_t *dst, r2 = int16_t *block, r3 = int stride, r6=clobbered h264_idct_dc_add8_mmxext: @@ -1139,8 +1104,10 @@ cglobal h264_luma_dc_dequant_idct, 3, 4, %1 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx IDCT_DC_DEQUANT 0 +%endif INIT_MMX sse2 IDCT_DC_DEQUANT 7 diff --git a/libavcodec/x86/h264_weight.asm b/libavcodec/x86/h264_weight.asm index 0975d74fcf..086616e633 100644 --- a/libavcodec/x86/h264_weight.asm +++ b/libavcodec/x86/h264_weight.asm @@ -70,6 +70,7 @@ SECTION .text packuswb m0, m1 %endmacro +%if ARCH_X86_32 INIT_MMX mmxext cglobal h264_weight_16, 6, 6, 0 WEIGHT_SETUP @@ -82,6 +83,7 @@ cglobal h264_weight_16, 6, 6, 0 dec r2d jnz .nextrow REP_RET +%endif %macro WEIGHT_FUNC_MM 2 cglobal h264_weight_%1, 6, 6, %2 @@ -95,8 +97,10 @@ cglobal h264_weight_%1, 6, 6, %2 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext WEIGHT_FUNC_MM 8, 0 +%endif INIT_XMM sse2 WEIGHT_FUNC_MM 16, 8 @@ -198,6 +202,7 @@ WEIGHT_FUNC_HALF_MM 8, 8 packuswb m0, m1 %endmacro +%if ARCH_X86_32 INIT_MMX mmxext cglobal h264_biweight_16, 7, 8, 0 BIWEIGHT_SETUP @@ -216,6 +221,7 @@ cglobal h264_biweight_16, 7, 8, 0 dec r3d jnz .nextrow REP_RET +%endif %macro BIWEIGHT_FUNC_MM 2 cglobal h264_biweight_%1, 7, 8, %2 @@ -233,8 +239,10 @@ cglobal h264_biweight_%1, 7, 8, %2 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext BIWEIGHT_FUNC_MM 8, 0 +%endif INIT_XMM sse2 BIWEIGHT_FUNC_MM 16, 8 diff --git a/libavcodec/x86/h264dsp_init.c b/libavcodec/x86/h264dsp_init.c index c9a96c7dca..9ef6c6bb53 100644 --- a/libavcodec/x86/h264dsp_init.c +++ b/libavcodec/x86/h264dsp_init.c @@ -236,6 +236,10 @@ av_cold void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, if (bit_depth == 8) { if (EXTERNAL_MMX(cpu_flags)) { +#if ARCH_X86_32 + if (cpu_flags & AV_CPU_FLAG_CMOV) + c->h264_luma_dc_dequant_idct = ff_h264_luma_dc_dequant_idct_mmx; + c->h264_idct_dc_add = c->h264_idct_add = ff_h264_idct_add_8_mmx; c->h264_idct8_dc_add = @@ -243,18 +247,21 @@ av_cold void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, c->h264_idct_add16 = ff_h264_idct_add16_8_mmx; c->h264_idct8_add4 = ff_h264_idct8_add4_8_mmx; + + c->h264_idct_add16intra = ff_h264_idct_add16intra_8_mmx; +#endif if (chroma_format_idc <= 1) { +#if ARCH_X86_32 c->h264_idct_add8 = ff_h264_idct_add8_8_mmx; +#endif } else { c->h264_idct_add8 = ff_h264_idct_add8_422_8_mmx; } - c->h264_idct_add16intra = ff_h264_idct_add16intra_8_mmx; - if (cpu_flags & AV_CPU_FLAG_CMOV) - c->h264_luma_dc_dequant_idct = ff_h264_luma_dc_dequant_idct_mmx; } if (EXTERNAL_MMXEXT(cpu_flags)) { - c->h264_idct_dc_add = ff_h264_idct_dc_add_8_mmxext; c->h264_idct8_dc_add = ff_h264_idct8_dc_add_8_mmxext; +#if ARCH_X86_32 && HAVE_MMXEXT_EXTERNAL + c->h264_idct_dc_add = ff_h264_idct_dc_add_8_mmxext; c->h264_idct_add16 = ff_h264_idct_add16_8_mmxext; c->h264_idct8_add4 = ff_h264_idct8_add4_8_mmxext; if (chroma_format_idc <= 1) @@ -270,18 +277,18 @@ av_cold void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, c->h264_h_loop_filter_chroma = ff_deblock_h_chroma422_8_mmxext; c->h264_h_loop_filter_chroma_intra = ff_deblock_h_chroma422_intra_8_mmxext; } -#if ARCH_X86_32 && HAVE_MMXEXT_EXTERNAL c->h264_v_loop_filter_luma = deblock_v_luma_8_mmxext; c->h264_h_loop_filter_luma = ff_deblock_h_luma_8_mmxext; c->h264_v_loop_filter_luma_intra = deblock_v_luma_intra_8_mmxext; c->h264_h_loop_filter_luma_intra = ff_deblock_h_luma_intra_8_mmxext; -#endif /* ARCH_X86_32 && HAVE_MMXEXT_EXTERNAL */ + c->weight_h264_pixels_tab[0] = ff_h264_weight_16_mmxext; c->weight_h264_pixels_tab[1] = ff_h264_weight_8_mmxext; - c->weight_h264_pixels_tab[2] = ff_h264_weight_4_mmxext; c->biweight_h264_pixels_tab[0] = ff_h264_biweight_16_mmxext; c->biweight_h264_pixels_tab[1] = ff_h264_biweight_8_mmxext; +#endif /* ARCH_X86_32 && HAVE_MMXEXT_EXTERNAL */ + c->weight_h264_pixels_tab[2] = ff_h264_weight_4_mmxext; c->biweight_h264_pixels_tab[2] = ff_h264_biweight_4_mmxext; } if (EXTERNAL_SSE2(cpu_flags)) { From patchwork Thu Jun 9 23:55:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36155 Delivered-To: andriy.gelman@gmail.com Received: by 2002:a25:bb42:0:0:0:0:0 with SMTP id b2csp889245ybk; Thu, 9 Jun 2022 16:59:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwQ/9PR+rgeHnTTzm1RsmvoltWw6a3r4y7srAJ1Ofhxo6xChT4plLrgaPEhKqHT5FwLGIqp X-Received: by 2002:a05:6402:190d:b0:431:4e5d:d780 with SMTP id e13-20020a056402190d00b004314e5dd780mr29935656edz.279.1654819171789; Thu, 09 Jun 2022 16:59:31 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id b15-20020aa7d48f000000b0042dc59e4ac9si17493582edr.440.2022.06.09.16.59.31; Thu, 09 Jun 2022 16:59:31 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=oxXT1HPo; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id B888868B8CC; Fri, 10 Jun 2022 02:56:49 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073020.outbound.protection.outlook.com [40.92.73.20]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 35C4668B89C for ; Fri, 10 Jun 2022 02:56:47 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mtIaE0w3pgSnOUg0ZNnQ8S6af9xT9F+uxttn2poWJss3WbISWn1HxbO8lmDF1sUJJuGC1o2/JefvROyOngosSM9dKGiBlgA+fSePMJulBZXdaeMEJYCvsOjqSS6JPS9qoxXhGRzFzekv7JrQqRIODlWcLs1sQA6Qjh/PE4noT6w2glgl2Z6zmkoHoPwMLuP/anGzkF0lcH02Scypiac1qR+LNQH/EW9wF1V6eVEobRibG71F0TXM0aguis3w2Z/CWuL8/Oc60KOUQX4Fyks+lNY42GkG6qILEJ4QDuUkbCJirQsrNauRioU0ylzhsRQtpIy5yozLojA1fy+ODeMfIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=1YZHJ65jDgmO0Dfs8IM3s+FaBR0xMT7zfFfz9SbHaes=; b=T0qni9SkqtTmDuf83MNH7LwZ2Am7kDiRNx/4S0RpDhPxOz4ItsGq2QqupZ8fpsahE9LCgdC8vlxz86HPMX4BKrLkuUeXzJa5X85LLbO2rHkLoEjQlrqSbksJWgnUiVLXcV9wQfZG+oSh8faoyK5pAgxcu4pV+NbrO7CAhtfu/a+4hq+RldJmt3Fchu2yTzRyfnrp90eid7Lr6yR2dAtLVRIX/FXsDlYGW4mrbU1yLarjUZcp4W1zYRHUfd62nE4c174QZyHM0AWdv6FToEY31LQlVi24cUAySWzi6obHTwZc8vX3eSNLe+9h/QNuh3VFDkz7dr9MVgn6pUvCM5EWdA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1YZHJ65jDgmO0Dfs8IM3s+FaBR0xMT7zfFfz9SbHaes=; b=oxXT1HPolG3YB46E86aQ2O/5ksH5trxlKITqTw43l++Tmr3AHWH4Vfxn69BhaEGI4mDku+et04pyBqrpQfqwMLw8KEO0RO/guZlxLb43IZLxzwDsLYYT7n9xrIw7tOZoYKQkH43obWKFKRlmMNo4b7YhWt8bkuMQnFFmfXy38x44CICFdilD8OjnEMVL2YCNYc8pGrUs8ZDTKILIZ7PgK0kXdW3wokWCK31lhpnThG/1j7nxXpIZFCj+FRpiGwGJUctw/VvC5vIzB1jjXF7h1TIBxd7lJHF30WZ8d+rIvHzZQBsImnwM1NOeWHR2vRHXTzMF1wBmewcTqaF9mn6shg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:42 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:42 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:05 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [7p+Noxxu3/iZXIu7X9NPDjON/Cjtfk6C] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-23-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 79a64231-4e15-49f4-045d-08da4a73b388 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvJNAlAr0aD9v7vxl0C0r78+Lo9EeUSupjG9CVPqS2KO8TXP9EFrWaYk72m9xMZI+95qkzK4s/vusTqGROGzQUoZAxJP/lV4DtpLmwjprymnMi6H0vLuQFeHJ34M9YwZ1FhB4RSmHb1mx3oHEa3t7OrO+07tODduvT1FeV9EvNO0EdJ8Fir8O3pTYdNf4t71w9m9X+WiW5YqUFXXNlsVMQTodKQJahmYbIVSNPnmeRyBMUuCs4lLRhBIBml4/O4U3B0GLNY5Dx4kMTaVsby3GCw4zPPXR0CGVzpXHl/GHnU8tDLc3MriaTu8uHtYKCd2b+elTpZ3glkvUkuINewC8LB+7KGH4Z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y351wUBdml5z6/OLBfg+b54eI3t27tc0kG53Bvd86B3B8pmhW5izjoB53F8v6nF4yDwu+0+L6SP3BCgYD6k4ZltSLQBrH75b7vXUfivqcuc5VjGt3gPWrboSIJtQUosHfHiGjrjms82mi+FwBIon5Q+s+8AyUEZ6PSK1FWTp4SwfhgazuaSOi8yPYrs1LMwPAIoDIofYHbqCih3+s2EvoBOmNve2Yo439bPsOgkyw3RsgRa8fkUOL6IKEm9U6597PLv784TABHUNi/OLSLHsehwGmQ40OY0VDtDkEe/3e4SZVWxZpASU+nu7eznp7SX88+/ChdcAY+uX+Afy+xwM873k9mPD7ox1NVC43KwKcNjJy/6EJEq+R8FisJmMA7pEp9wwUxH5YQ8bqKFl0F0MZ2DK5jwk3O9snnJFUUBXflbD/htaJ39/WhPwQZbmbHDodUQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 79a64231-4e15-49f4-045d-08da4a73b388 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:42.2420 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 23/41] avcodec/x86/sbrdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: FBfk0MFdi3DW Content-Length: 1726 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables ff_sbr_qmf_deint_bfly_sse (which is overridden by an SSE2 function) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/sbrdsp.asm | 2 ++ libavcodec/x86/sbrdsp_init.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/libavcodec/x86/sbrdsp.asm b/libavcodec/x86/sbrdsp.asm index 62bbe512ec..ea5099a5d1 100644 --- a/libavcodec/x86/sbrdsp.asm +++ b/libavcodec/x86/sbrdsp.asm @@ -286,8 +286,10 @@ cglobal sbr_qmf_deint_bfly, 3,5,8, v,src0,src1,vrev,c REP_RET %endmacro +%if ARCH_X86_32 INIT_XMM sse SBR_QMF_DEINT_BFLY +%endif INIT_XMM sse2 SBR_QMF_DEINT_BFLY diff --git a/libavcodec/x86/sbrdsp_init.c b/libavcodec/x86/sbrdsp_init.c index 6911a1a515..a710f10dc1 100644 --- a/libavcodec/x86/sbrdsp_init.c +++ b/libavcodec/x86/sbrdsp_init.c @@ -67,7 +67,9 @@ av_cold void ff_sbrdsp_init_x86(SBRDSPContext *s) s->hf_g_filt = ff_sbr_hf_g_filt_sse; s->hf_gen = ff_sbr_hf_gen_sse; s->qmf_post_shuffle = ff_sbr_qmf_post_shuffle_sse; +#if ARCH_X86_32 s->qmf_deint_bfly = ff_sbr_qmf_deint_bfly_sse; +#endif s->qmf_deint_neg = ff_sbr_qmf_deint_neg_sse; s->autocorrelate = ff_sbr_autocorrelate_sse; } From patchwork Thu Jun 9 23:55:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36122 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655277pzj; Thu, 9 Jun 2022 16:59:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyRh/G+6FaffCfwdQ7dFiMfGu/JV3N75d9X0pNOJzhW4qe0l7fHfeIAxeS/SfUZSyr+12V7 X-Received: by 2002:a17:906:9254:b0:708:cf8e:25a5 with SMTP id c20-20020a170906925400b00708cf8e25a5mr37698337ejx.119.1654819184475; Thu, 09 Jun 2022 16:59:44 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id c3-20020a17090620c300b00711f6238bb1si7222438ejc.606.2022.06.09.16.59.44; Thu, 09 Jun 2022 16:59:44 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=mOMNcvfi; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 9266B68B8D4; Fri, 10 Jun 2022 02:56:50 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073020.outbound.protection.outlook.com [40.92.73.20]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 66F4168B8C5 for ; Fri, 10 Jun 2022 02:56:47 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MHaDqLIpsgiaXPtckpI5dhS1nileQcrVh5knsrGOton7ar9Kv0EKGNyfh84wGhQl0v1uCtAttVS8vjzkddws+/uu3Fsp52I1VZAldVOprwC3AEQA8nau+XzirtJ8UOys72GjQ6co7aO2YeVEBRrlstI5zZ3gWMezylG6M9DAb37HlHEnOKWY52VRY3s0TXQnuJWyRL8Ch/o7s0U9Kfp7tHxSVCOshxU+mxYdgG5hzveCp4UHLW4clIUOxpDBo7/upDmyUhryzzW9dXVNBMWLH8DRr+d2gK9awVBGfiocWN7FpnDgJj/8ixkXthe7aBmlZzvtNCefSIPvy7jDjLvnMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=e4Rnv1n3oHpwiKNfpqBxkHACVxxKkTdFnsBBaj+D830=; b=YclsQ9a4hwH4E2cDEItsFrWEYCqaPa2aOYKaUJvULs7cOUA7XTdy8xzPVDL7wLm9q10wZn8OyX2BDuZtnOqaXcohBtFzS50Fs3kcEHbD3PrVeHyRzD5qjwbzpB5xFybU+MYDTfYCqpzERGdWTZRJ1fU6mS2NR9qF4GGMkPUnPnoc1s35EmnWajWeGAdHLCuKW8kNLk48hmCigLUYbsn2IMcBsL42p82IXEOKkQBa5aLw82ppS1g8PshwUT45u1rSeuL3CfWRxMTwJxFF3YtMWYtGbhb6JP/R0JzXpInZjyvqkDRRm1umUg7cVAVbAU0B7Fk2zzIfGiE5l4G2V8dFGA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=e4Rnv1n3oHpwiKNfpqBxkHACVxxKkTdFnsBBaj+D830=; b=mOMNcvfiTKxT5jCnuT7KuEIwYtPXc49mGGA/CUbruTOoMTfLuMzi2FX32vx6XN2t6YuV+UEjSWImc0FsXScb2nKau1XmEfB4O1QRWjT6Nza4okji0A6bfk0073u1GR/8SHe+aY60ZMtpImZ+Kj0MkjXIkO6pL+kMqzs7RjicXEZsXHAXfmcniBEiY+fU+X6QRzxhUZkNHgW33VS6kyBPyAZTwYihMbBdd3Ogts/AdxOfS2Pxoum9ONoYmRQOM38M7xRhfklg88W7cqn52P7v6+aSpvP6Dmj/FEGSd8yDcyxNkywoqYbHGHRhNaNqRkt7a3YRgoGTdB3EFNuEtGPWAw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:44 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:44 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:06 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [G8Z65jLJRJl70m7Zcd6qDxu+C8qYyE+C] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-24-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b84c58a8-560b-4663-a8df-08da4a73b4af X-MS-Exchange-SLB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6ukINqJ07ad39QnIDyNxfqAiP4YPE4EHV529dOUb8TPmfvs9RgdBqzJm22scg+uEOPeFKTaRHGJTmS779njTvCKt7NrlG9GBRDJa/XJZ62npzMZLp9G//ETTAmsgLJff/JbjeYXiuMKQQMmkGYDlFDBRxwBfJ8pYb9m1ECO2+8q/ysVUUNIoT+6kkJ/CcpibqaY9oJNL5xBkp6UCrYuebh29EifSYVVZnS23xE2X6TPZ5s0Wa0EaWwnvR7LMSHDWMzoeEc/YxzQxoNmfHPSiWp+DkUsCjHrOfQKMJxKrxFhshyLDXYo8Z3TywwYDcwOuiqosirx3u4DdGZ2MTiAmihBnxkMBy6uADYAD4FqUBEQbzQ9fnJTLpUQGvubALh0fyOTMZYJzAdQxXxFCUDqpR8D8qCsz0qBOmO1sWpXUI1FIDCseynTSAYmiYfzIUwTIbLLGWw1eYXG22b9Vu7WoPJP6phABPsT8uEuMr5AROzADRS7YmCLmRck+u7eqHPiLtbGtVz5s9vwnsCZTu0/pTzKnakYab1PLSHPrrGwJQEGNjaorfGaGlTDyg4Sn3b++5qmjXFrf/iSaupypdygAo5H1mhjEWRLU52Ggu4X7Z6imS79Klz5gPBH3fLfAPLIclp5atg3mMQYwbdvh+tdY4JRjW9aw4qQVqltba2diP7EGX7TOShGaRTah0PR5CPJdAKBVEwMIfW6C8eW0BnYzqnh2QdGWqWMKmovjKcBS1Uf4xcxPhdiGGVR8E686K/u8q6g+PFm/43fUTR7Tzu7tHkEi0rVV27AkOSJLE2c7hgY/DvdUEUHkZyovSZgxVOpGllJGy7y7VfXpVXQdjqTs7F86BLFXzZrksw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: b84c58a8-560b-4663-a8df-08da4a73b4af X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:44.1795 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 24/41] avcodec/x86/idctdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 9wCOkM3Xb6Sw x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX as well as the non-64 bit (which are overridden by the 64bit specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/tests/x86/dct.c | 2 +- libavcodec/x86/idctdsp.asm | 6 ++++++ libavcodec/x86/idctdsp_init.c | 4 ++++ libavcodec/x86/simple_idct.asm | 2 ++ 4 files changed, 13 insertions(+), 1 deletion(-) diff --git a/libavcodec/tests/x86/dct.c b/libavcodec/tests/x86/dct.c index 1eb9400567..144d055cff 100644 --- a/libavcodec/tests/x86/dct.c +++ b/libavcodec/tests/x86/dct.c @@ -73,7 +73,7 @@ static const struct algo fdct_tab_arch[] = { }; static const struct algo idct_tab_arch[] = { -#if HAVE_MMX_EXTERNAL +#if ARCH_X86_32 && HAVE_MMX_EXTERNAL { "SIMPLE-MMX", ff_simple_idct_mmx, FF_IDCT_PERM_SIMPLE, AV_CPU_FLAG_MMX }, #endif #if CONFIG_MPEG4_DECODER && HAVE_X86ASM diff --git a/libavcodec/x86/idctdsp.asm b/libavcodec/x86/idctdsp.asm index 089425a9ab..701a8c5a43 100644 --- a/libavcodec/x86/idctdsp.asm +++ b/libavcodec/x86/idctdsp.asm @@ -74,8 +74,10 @@ cglobal put_signed_pixels_clamped, 3, 4, %1, block, pixels, lsize, lsize3 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PUT_SIGNED_PIXELS_CLAMPED 0 +%endif INIT_XMM sse2 PUT_SIGNED_PIXELS_CLAMPED 3 @@ -117,8 +119,10 @@ cglobal put_pixels_clamped, 3, 4, 2, block, pixels, lsize, lsize3 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx PUT_PIXELS_CLAMPED +%endif INIT_XMM sse2 PUT_PIXELS_CLAMPED @@ -177,7 +181,9 @@ cglobal add_pixels_clamped, 3, 3, 5, block, pixels, lsize RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx ADD_PIXELS_CLAMPED +%endif INIT_XMM sse2 ADD_PIXELS_CLAMPED diff --git a/libavcodec/x86/idctdsp_init.c b/libavcodec/x86/idctdsp_init.c index 9103b92ce7..41ba9d68cb 100644 --- a/libavcodec/x86/idctdsp_init.c +++ b/libavcodec/x86/idctdsp_init.c @@ -63,6 +63,7 @@ av_cold void ff_idctdsp_init_x86(IDCTDSPContext *c, AVCodecContext *avctx, { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { c->put_signed_pixels_clamped = ff_put_signed_pixels_clamped_mmx; c->put_pixels_clamped = ff_put_pixels_clamped_mmx; @@ -79,12 +80,14 @@ av_cold void ff_idctdsp_init_x86(IDCTDSPContext *c, AVCodecContext *avctx, c->perm_type = FF_IDCT_PERM_SIMPLE; } } +#endif if (EXTERNAL_SSE2(cpu_flags)) { c->put_signed_pixels_clamped = ff_put_signed_pixels_clamped_sse2; c->put_pixels_clamped = ff_put_pixels_clamped_sse2; c->add_pixels_clamped = ff_add_pixels_clamped_sse2; +#if ARCH_X86_32 if (!high_bit_depth && avctx->lowres == 0 && (avctx->idct_algo == FF_IDCT_AUTO || @@ -94,6 +97,7 @@ av_cold void ff_idctdsp_init_x86(IDCTDSPContext *c, AVCodecContext *avctx, c->idct_add = ff_simple_idct_add_sse2; c->perm_type = FF_IDCT_PERM_SIMPLE; } +#endif if (ARCH_X86_64 && !high_bit_depth && diff --git a/libavcodec/x86/simple_idct.asm b/libavcodec/x86/simple_idct.asm index 6fedbb5784..002fdede90 100644 --- a/libavcodec/x86/simple_idct.asm +++ b/libavcodec/x86/simple_idct.asm @@ -25,6 +25,7 @@ %include "libavutil/x86/x86util.asm" +%if ARCH_X86_32 SECTION_RODATA cextern pb_80 @@ -887,3 +888,4 @@ cglobal simple_idct_add, 3, 4, 8, 128, pixels, lsize, block, t0 lea pixelsq, [pixelsq+lsizeq*2] ADD_PIXELS_CLAMPED 96 RET +%endif From patchwork Thu Jun 9 23:55:07 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36123 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655329pzj; Thu, 9 Jun 2022 16:59:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy5LRrRn59hHVvWsLuFrRdJsg1LkasyAg3OiDmtZLPb1e+mVXxodVJ8kjVobVhzeOlHbijj X-Received: by 2002:a17:906:824a:b0:70f:4c58:6ec6 with SMTP id f10-20020a170906824a00b0070f4c586ec6mr31158508ejx.648.1654819194514; Thu, 09 Jun 2022 16:59:54 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id e1-20020a17090681c100b006fee9ca7540si8775835ejx.244.2022.06.09.16.59.54; Thu, 09 Jun 2022 16:59:54 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=jeQWbEZj; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 8FAFE68B872; Fri, 10 Jun 2022 02:56:59 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073045.outbound.protection.outlook.com [40.92.73.45]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 0478768B872 for ; Fri, 10 Jun 2022 02:56:56 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=VQ8TKZquIZ0OpH5FX3K3D+KJ+Xoo1LLJvuMpsruc+prKmCYoLwjKBmhp9TvID/va5bsf98vmtXKbdsjR0DGF+63vnQrBVc8Fld/7QKKaMZAzEsDtkxfy3qm1AUYhfTYX9a5fZ434C/3FqoxaibvTDwBDDJwwwFQcWDKHY4MkrcD4OMELt5QW5ctM3AaPMnDiQyUKEeLoFdPl4YYOKuZxlfdbHMqeKIKC+bCogxviWqYE3Nsq/UivYWkIFX7ufME4JvHQABXLq09Ry3VUgKBQLsyfyPJALsDPIh5S9xHABFrnbGVJL0LcARCFefz5WWbPjiUCvO4Z37Q5MPfi1St75g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=wn9HQJElAJYHaIbvyBaq0t5pV9dsk70uyXkk+fGZmJA=; b=jkjQfz7NVJfxXdxjXX0DGpd6llW1o1NBCHN7tMDGgFMzfhvmCySyttD+6Rqicb4Srg5jVn32DRQ1j7bw2kYAqaveI5v6Oo9vYt1c1SAxEXx7ojg4urB69INf0A+l5MjaIVbOHwiYqzmGw/MRmM0NqNUA/QyGV9zZLdtb/yar5YCEO3+JqkhbN2bgmg5EqT/uYi6Bm83gly26BMDG/EQRN1TvkAeZDlKYEM+b7EOEQsoiqXdGfdIdyqlKwAq6pBsLAXw/j311WrBKH0gjv+juZxW4pVlQ1MlsS0al72jzbOQQO4HGBG8YJvEwu+4a5YDKBQhLPh0T35RBeEPY+q0H7w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=wn9HQJElAJYHaIbvyBaq0t5pV9dsk70uyXkk+fGZmJA=; b=jeQWbEZjEUqfNJl90y7LywDsAqPch0jhuWfRFqZI8x+A7eWpgB99tVLpWMWM+pjnuS4/thDelcBVA8l/PzBPSnkfAHr8bwC8a7HhLBZ3pp3a3ibzX8N5XTxRHG/Zz8yTH3tvs2dosBPTRz7eX7VSn8csRpiqYgCP1/ncWdLZ9gIHEpHjZJnRitCFh6WStxo/IYHCIDN5WOYaiF6mlNvrwzZNxCnihaEmx0VcjtRTFGSDNNbeP/cV+KK32x7Kgg9NFBHv5sPMHaOcdH2sSHxDYANGrs2PX34fHK+CFpR3WsTvfII8UWfzUhDSon2GeOxkRh3HWiYhhrKw/jz10saxHg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:55 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:55 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:07 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [9pL19JNlBSLiYAQWzBtpSxTTawguILqK] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-25-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 470c0dde-f08e-4047-d4c8-08da4a73bb6d X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvLPWlq5XGOSNv47REEvgFpWaNYXgC8B/V3/RmugEYzPlbC43okKQ3tawO91w64scF/T+SItCl36DLSRKOXmoWG3LHWZH9Of3SOFUEC/auVJmR6z6s4wGmNCQ2onboeGI4jrtZRiy5RHqkal6om9IlEdRjOsQ/1jpvl40lfFFolfd8S85ivzQ+70ZwEws3mGRj7pJqemaQZ1q8RDY23lHq/B7MOs7ZP2u8zw+swIw2nmZ/0jtvQITFkAgKuaQi+18u0HnIDvXhIE7wlFIBtXXvyu0OmtNsiIsmqMzrFlLtgt9RnJBqD6tq4rofEHVc/QHu/9b/qdJDSsMZ3vtxs4lEI9uPtjAvHzHpp4ajj1zLTh+eS2EFFZuil8VOwg7Ez9R9uxfSBnZgb8wE9m1/nUNopq1EtbMhihT0MkY26neceAOo36lXLo7RSGDXUxQMXmdiHAruEHg8dl4h0zEwd8lJcXRCJPE6ND1F7vtbEDvqbDxkb9FxIqwi30Ww9LKeRJTSC7eC5Cujfwk6SpmemfZe95MrE3MPnIyYGnT0Vw92jXsFrK4i9O1QPJFa6o8yCZII9BK0ycjA/uOWrRS7vuT940W9TMxm0brS42Mx5OxEc4Hcn77b+12K2hqiKBopp8uKJk9Wm3o3jxpHZU1RxSDtR+7JnOLW+9Rtfznv3oj+j/zw4KsdcfGCh1vQVS5ojplmPY5nkwXD2ompkpT0tQ3qj8= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: pWRu1fz7LU9lKzhicanshs7vRt0dp89HjK5/ej70xpuYhh7RuuAHtbRCU26U6DSGw5uKH+RChyiWnP5iP3aUKh+VpedApQ7u4icRU2pyDv3bdKfZIhnJOXMjXqrdW1DYIEtcbnlIbffS/lD7tPas7EatCIWT7qUqsyzW8Df+a5Z6NUI1gXFoGXzV280AJ7AAW1zd0oCaXMbhijK0hrreQxa/SM/qkU5tkJQowCQLueHmHVIBNOzL8Y5JKcD75z1SPCRcygGxVwUQvJ2GMsOo+48eaNIX8wN6e1keMG7PXWJdLiAlZ+DszSJW4UdMhm1ImxdyXhlTNKwPZiOSD0QrSqpKsUguM/E8bJS4fOihoHfZMW1ytZzjwLePkLw3CUNkSXym+zdzCnhLy4IdWdL8mbv6Pu7ZkRw9a2K2liRmdboaGejitDdn+X1LiUFJ7Fb/AMLHe0PArQhWVwVN7WGnJiMD+MC1gWpZarZlq4pYPIU9comow3ZoCLFlgH+aS1kYbACRWSqmd2EvgBv9feyoD1xAs9zdUFYmcAGtcTK1N2eafCd3g7pq3/haIK/bzKNS8ZuAV22brZek3rLTO4goNA== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: p/x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7QajjsB8m7fA1/IW1XT/W+9Wc6flknavvogRttrClDsKfQ8uEhFWCMIJ6e93klKnn+dkSQhrD2ceZfMDarVwYKHTrmbkzpLI2DYH+CLa9Wfppwv+3DgRd7vggtOBI6/2c8N2hNS9JpcUs97prJ3o3eh9WXYrjBqkDZNDtc5Y1EVMima8IW+cBJ6hHoDP1TN8hXvATQCV8yZO630aP05K1FBKrU79qO73Fa/g35LvPFO4sMO938LLlTmvC+Bck0LAGONlfdaKv4AAGnStIR/UHhkI/P/GzAS9zLO0+Wj4IOM4rSj60GMbnDsmgPa2LbGpDNSupsJUl62jmAJThGlkK8r57BD/rbfJEVU9URww5qD8BnR9MaPNb+cib9B1dchKyert7GGwk6a2P98wjqhjw8USyKZ5g== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 470c0dde-f08e-4047-d4c8-08da4a73bb6d X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:55.4765 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 25/41] avcodec/x86/blockdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: HTqWvAqpa9/8 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/blockdsp.asm | 4 ++++ libavcodec/x86/blockdsp_init.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/libavcodec/x86/blockdsp.asm b/libavcodec/x86/blockdsp.asm index 9d203df8f5..dfa38f1d3d 100644 --- a/libavcodec/x86/blockdsp.asm +++ b/libavcodec/x86/blockdsp.asm @@ -46,9 +46,11 @@ cglobal clear_block, 1, 1, %1, blocks RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx %define ZERO pxor CLEAR_BLOCK 0, 4 +%endif INIT_XMM sse %define ZERO xorps CLEAR_BLOCK 1, 2 @@ -78,9 +80,11 @@ cglobal clear_blocks, 1, 2, %1, blocks, len RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx %define ZERO pxor CLEAR_BLOCKS 0 +%endif INIT_XMM sse %define ZERO xorps CLEAR_BLOCKS 1 diff --git a/libavcodec/x86/blockdsp_init.c b/libavcodec/x86/blockdsp_init.c index d7f8a8e508..3b857a51b6 100644 --- a/libavcodec/x86/blockdsp_init.c +++ b/libavcodec/x86/blockdsp_init.c @@ -37,10 +37,12 @@ av_cold void ff_blockdsp_init_x86(BlockDSPContext *c, #if HAVE_X86ASM int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { c->clear_block = ff_clear_block_mmx; c->clear_blocks = ff_clear_blocks_mmx; } +#endif if (EXTERNAL_SSE(cpu_flags)) { c->clear_block = ff_clear_block_sse; From patchwork Thu Jun 9 23:55:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36124 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655393pzj; Thu, 9 Jun 2022 17:00:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx7wY7qHLbLbKKLSLKqyvswUxvRVP7bF6oh1xV/GqNbsutlNjsmO2teo2rw4mLbrWA90avt X-Received: by 2002:a05:6402:120b:b0:42f:aa44:4d85 with SMTP id c11-20020a056402120b00b0042faa444d85mr38776705edw.338.1654819205150; Thu, 09 Jun 2022 17:00:05 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id t17-20020a1709066bd100b007035ad9a503si9565708ejs.325.2022.06.09.17.00.04; Thu, 09 Jun 2022 17:00:05 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=QvcfzQjB; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 834E468B8F4; Fri, 10 Jun 2022 02:57:00 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073013.outbound.protection.outlook.com [40.92.73.13]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 213F568B8C7 for ; Fri, 10 Jun 2022 02:56:58 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UPn6Fd041OMJ/WGmycwDrWrmOaSIGB5PvvBR+KE0lXr0Ilz30vEUqjqo71X5zfstUAd9fxEHv/cJa4+jHDpE1CtA7TTlf//gAu6cBCsES2SOWnt1MBDra0bTBy4WltP7uoLjGjBk0GlskUwGlMteO/KGAHC4KL7/6iGSW5Yc/RXeyCn20RDrVVhhXDVjQ2GG2lhL3t1oYnrJ7hsgX1CGy5b2S8IHbF/bXO2E6I2hoHhagVl5c8r6YSwxwXyfT7XyJgwds5T8GZB0PNoArLWgK8Vz0hefJ5e8gE8RxxUb0HBRTNl6moY8ksjmTABa2pJRYp1BNCROPn/HOrXc+bZ0Sg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=WJ3w6OLhcPqAiobD7hx4cnQp5DvOFpjG8X4P6junb9k=; b=jdK6vnVNXb2L0ButjUCGNQwU7a4GuwkrSJ7Nb0v+UakDdNKuHlla7Sy+pZ4n3L8zhRGbhICOleVTDTU3PR6PB9sPJUitvqZd8CEwb6SA2wMo26Wskf/fYK8bw89cigditDBtdqU68ph4LyI7QlspjdopJ7KaKwGN2S2cH9R8tuHFe+upH6bZBGhIcVlgFsd6hRlWe3FBZlrbcWazKFWyD1zVz6VJtDlkEQF9bccqfq/dJ5Y4BcuTDY6oMonoPLyDt3ee6r7FOs8zb9S+H7NXS4qTfXGvDC6PaSlUQW7ZpKtocqKDX33jN+JkPM4wKRfa5nTEFtx6Xd+xLCXpJYeCGw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WJ3w6OLhcPqAiobD7hx4cnQp5DvOFpjG8X4P6junb9k=; b=QvcfzQjBRILwrg+ADySqS4m2zjrj7xMDWzoIZCPrt0ymm3PfCaIQVlmhebN/ymsjrCSwG+Znj8nR8UcfEs/MJbbNF8f8tNGSv19lJP9d0VA/ELBLmZCiHE2vzO1PPG72IZKEay/f/EzldIckR8IzMosL25JKrdrp1kC2dkFPZiTpSPP28SmXXfPThpml6ar8TJugy4ez3zZUoRVly/LaLTT5KluYYaZfFidHH6IUD/9TnL7aoDpJ4Lt0u6pTKLywHCIQ7gJdkyBbPkbRFOJpzDqKBwTdAcXNbflBSs2GIw/l56tjoD22ADCa+kUY18g/1AE+ngXhZ+Wrmjq84JrguA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:57 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:57 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:08 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [Y+UHDfXVE7hbMShLHK6aYX6Xir6dQO6X] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-26-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 47e0ba63-b9d6-4521-16f3-08da4a73bc93 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKLkAYCmHAduXdaKWs31JD+0jDYp8N73WvD1chXvPwZoi7eAyHul819mqIOSQQV3rSG91QPtOlV+4Ps4AHuS/afGTPFcNxO6zkJMmvySjWeDWJctdpiQ6K0cpE3/wbwIZQfKhUxZUxqIMRQG1OhH0rF0jwMn0ALIMXF4e9/p+vKtlKLzAOkZgm4yf0KELv59phiVGyl2e/77T7/wt/wyKYDQJlNRZ5x77HxrL1nedVcIVhSvm2o8peGmDim21Dpnhe1fXkNZ81y1zu4SxptMXpHyt+OptAE6RztQx+ev2eJr/iOpifpIV1pmbtzoOR9tKSbLhaDvxkjmYARUYwijki3BBgJ8LYO1AcB7k9ikbGKfT8L5j4IK9errwzyVBEX3Jx8LHjbInqEKcyMT12g+5Ku3v1qqfiNhGzLiYHeG18CM7+WtAHsKEI3qZzfoLRMthVUUGJBaRTXteAfNaIzkEwAcmwkAzMQRZAVQmFqzXs2Is1zwiEc5Vcnmb5ULd0TEoQPwY0K9saZsmLvfXBnQ80kPfrF16FFsrSNtjBuhdygqeIMxkmi6ikwVgsEuP20/TBRuCgHHYZ5ylMKSNQNOVTxUh4znfJ90vI0Au20Mp9MDhsqOdJ0Tp6uk1+iHYroP9T/OizD9hYNSPeknzFziTmX492bBUGCk9Eo8E65h9CQBiMDtGGisSjcZIFftXHTiCt3oayC6G0sHhcned/gg5iy3r9Fs3lgBVcxq0M9dhWmlg= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Nb/mzMER+uvVV9LPCLW8k0w8t64W2BMJQb6wkXPLWiOKFRWOUzy12Ap9rgml66fsipxcsYc25aM17Z8Wt6DWuHqIeaODXOXNilhkuEk/q9/lCAyg1OsfyYX2FXphR/i4foGZzE8xS9b9I5TPhQFoITElkBbptjasIyJ5/yBPmDr7mHzC0HtfG9x20YepAz/igDNcRI2O6M64/IR2AD2fPSqkd4mv11sAG/Sq+dfWz6/H4F9n9ma7vjyoFNjIl2/+2yFZL17SLJml6KJQ8wjaSsGNkaYhBox8hBurnAD5A/bpLkzLP2H34kPLcnSbi5kcB0z05MRxOC8yRE1qUHvU/w11C3opej3qau2bIFDtyQMRKxkWiNV+xXs2atPKrz3VCGNXHEam0zo+7SOK1LRRNkX4IxuWzj2ToFDaRremmM5tvVHMoBb7hErUb9l/fqWJGNurQiBhp1qNgXyWeiMJgip5rHc+jJfU2t7bVIbgtdLLDkFbZyKydCzVZTctU7rxxjogmEcYELWn5tDf16woWRGdp8RulyR8xUaiHnWQUaeqJquKz9YSyHTDNWEKXXYRfvY6J3ifJ45DmOyBoXvUxg== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: hQK+OWWqEnVtNTABoSgKbxnZ98DeyvvbasxkQhPTLU0pMazBaHzWJK1pnFVc6NM+Yoe8VILOQ3kYOmELJGq69ZyKR9sYamh0s1Xw/95B5tI0sZpvn+WsuMY4v88k/8Ywgf5Eb9b6zAX5800YAzRi8/7sN+cNYLqPENPoE5s06rgfykkttlLiguh54pCpU2yLihkGtYzaHW0C3I4qDcSzI7im/p1s8wIFt1HLu6PKLvI8nDfJDCXpL59zZfTwYL+cjvveokTKEHPXp+BK3auYHXmdxnhzNTlFqbK7X84ad9eQLtHP53EXY+z1b9ekKoKtMb+MbdtIGz1ntxhcTNirBOVrYWuAW1y5/5JRezcPQ78iEUZieqmWNUgY1edET6HZSRBuKWDis3HfVvfB88iGSbQnUPyQOi6khk7EuqPgcmX11aGvz8FfOPaLTRqJu7E2Z08IfZWBF8SBwxKxpekUioMSyFhHl+kfgESecUsxCy8C4Hq0Szj8wTxs9iTSi/9rvN6J3UqEmYrARMstwMveaw8nELKIZzQLWqDu62p2aissK56fkamUgqkbxurcjN4fRSBsdHdJ4md9XpL+udNLJq81fVMSBikTpqaJrITUiM0dDyMgXumdSWxXpFVlCgLdLfT/hGH5QssoMewCd/hXBtQR50fewFGqk5sXIB2g7xcP9xEOTOcG3DBijyQCBj+HndQdnEOLSz9yJQGbG0M97DQnNb+MTPV7bFcbtf+7rW8P5/ylMAurY4/wTqGgyobcyDozZMz3tmQcJV9wKYErw6887zuopvEb+c/X9VRU23fSVdrj9nDlke3FQTPSjvjmlHc4eZV+AQFwDY3tuh6zw9Z1MLhfJEE6kGCA/PYjcla6LRVqRcAAwBCqPEaorsk6t0skhjyGjCHUh11vzz2BFB1r5SYeCgzemQX2BpV1N1ZVz2dMFDRM0DR6zy98a4naT4Yy3kWz6ygWK6F0z81rZtv4CB806GO60i5ts2iFAtvwQpMqUXhSAYiKJqpdLMVTvnOBdAH0ny8pNIz7mT14G5EfgUTarlmDjtCBUDl5eCEHcjWALh/KII4zOyj0v/KXX3dAFZuEB4/1t6fggby7TrAGZc87Eyb3/wGm8iVQGoXMoNUo25R2fIFE0KVcTGhip2y7kgRtiwxRR6gTri2eH3u2R0Elp2I9V69EAbZkHFjqv0ohp+IV10QzmKb+8FN32gqM1BDycRCNNO+JWP9Kxo1WZ2aJd/QWAhcCX3Md4dtBi/nQvA3+Xnrm0ZaKX9YjF6unnFJbmsKVwtrabcUJgA1cUPj2hvd/fr9SYws5Rtv1eu9XUk0wPjL+UCVCcJKjT50eLDhZwesVn4LjZIjNWV7PZrRVkV4l4q0femTsgHVHuHLAq/xHPXtGrNeavcb87Ku6clZjfcRnljVOa+2W6evhz5jqAlJr6Nw5AQ1chCTUCK2kAL5CV1Hjy0BOxjKLISHNJWyxhT4p62apL6NHqw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 47e0ba63-b9d6-4521-16f3-08da4a73bc93 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:57.5859 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 26/41] avcodec/x86/pixblockdsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: QNl1GiyiorfR x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/pixblockdsp.asm | 4 ++++ libavcodec/x86/pixblockdsp_init.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/libavcodec/x86/pixblockdsp.asm b/libavcodec/x86/pixblockdsp.asm index 440fe29bcc..4a6369d7da 100644 --- a/libavcodec/x86/pixblockdsp.asm +++ b/libavcodec/x86/pixblockdsp.asm @@ -25,6 +25,7 @@ SECTION .text +%if ARCH_X86_32 INIT_MMX mmx ; void ff_get_pixels_mmx(int16_t *block, const uint8_t *pixels, ptrdiff_t stride) cglobal get_pixels, 3,4 @@ -48,6 +49,7 @@ cglobal get_pixels, 3,4 add r3, 32 js .loop REP_RET +%endif INIT_XMM sse2 cglobal get_pixels, 3, 4, 5 @@ -121,8 +123,10 @@ cglobal diff_pixels, 4,5,5 RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx DIFF_PIXELS +%endif INIT_XMM sse2 DIFF_PIXELS diff --git a/libavcodec/x86/pixblockdsp_init.c b/libavcodec/x86/pixblockdsp_init.c index 3a5eb6959c..684879598e 100644 --- a/libavcodec/x86/pixblockdsp_init.c +++ b/libavcodec/x86/pixblockdsp_init.c @@ -36,6 +36,7 @@ av_cold void ff_pixblockdsp_init_x86(PixblockDSPContext *c, { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { if (!high_bit_depth) { c->get_pixels_unaligned = @@ -44,6 +45,7 @@ av_cold void ff_pixblockdsp_init_x86(PixblockDSPContext *c, c->diff_pixels_unaligned = c->diff_pixels = ff_diff_pixels_mmx; } +#endif if (EXTERNAL_SSE2(cpu_flags)) { if (!high_bit_depth) { From patchwork Thu Jun 9 23:55:09 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36125 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655458pzj; Thu, 9 Jun 2022 17:00:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwH1pDV7S0OXWGmZtqlXLghuZ0uSmaiNXl3gXxjHQp8rd+L3GEg3NROgfyBW5uP2J8N+f8W X-Received: by 2002:a17:906:1f07:b0:710:2911:378c with SMTP id w7-20020a1709061f0700b007102911378cmr30449248ejj.8.1654819216164; Thu, 09 Jun 2022 17:00:16 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id hr35-20020a1709073fa300b006fcad948d58si18893209ejc.822.2022.06.09.17.00.15; Thu, 09 Jun 2022 17:00:16 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=RykoJFSy; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6A1BF68B8FC; Fri, 10 Jun 2022 02:57:01 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073036.outbound.protection.outlook.com [40.92.73.36]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id ADB2F68B8F6 for ; Fri, 10 Jun 2022 02:57:00 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fIbHeqqPELwtog2LYd+JYXUoEmss4iy2qK4+q5mK/DbtQ9EAi8Wc5w+sK8m1ARBJvxkEaViy9d5YRQ/wxPRuZ0l9A9eKLjjLUB80eEdG3z80xCwA/kcVV5A5uuM7w22S92LTDIArJ45QTMO8XTkswgG3iiCqAFYuzUS/u7pnx0gvjqYYFq2Tz/E26WIteU9hqFB6fvJMuw4ZV7dkSNatMj7e8JIlbmJcwIgqJCeW+O5KIxJTA2PXJU7dohxl/3KALEC50P204SCDgiDExoPIc8zr1WTStjVqfR3a98mdzuubyx9n6X0tIReKBzUMqiFZXob2K75QF9PHqxlSP/2Baw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=E8zxnKGD+6EIPmHJc6txSd3F1DlfJkZkBoUq6f4J9W8=; b=EDzdthpvyhzR+nYzklqQRRQZ4kEViayGz8FZOpnlhrVTaaxb/uconD0iRQ6qhaYMVfwGBvhZ/oJqCO8FB2WRntIdKSWgF1pi5MT7te95J25QInEvdgVgwdaywcnx5u4qVkbHz3RPv09TSjl3+aK7r5B8iludI/yHqgviPQsC957brykvvosi0V2ZiTKFJ+eboP2Km8k3IdsMV64drmMFHU74/1oIJmstRomo4m56emq0Ui6gQ76mrGfIKrDZfaXpkZtr0rOYF+Va6eeNtmLWUWR61Ik5BA5x13fi2X4v6K+2YF/l08m438BG2VdP1dM/YKcRVaN2nrdWXLemYtcXkQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=E8zxnKGD+6EIPmHJc6txSd3F1DlfJkZkBoUq6f4J9W8=; b=RykoJFSyBMD1t+YEAmN3r69YK2gVX2iUreXiLIp5JAWwLNUUy725oqoj3rkl0/nRfCFAXWL4hwkx9xCfjNBGyA4V5nDI6kRF53J1Zpwr2qYcCZguyWpGwOWh3KiaYbd9O5fPsTy3eIAUwmEzqk8hzZ6FVGPKDJj5dYIrCQSESo68JpUw6k/aNitOZPMKyouHBDLJGGfA1Vu/ech1O/P5jUa46lBVQOl6qs0JpOw7YkZg7DH96udxL33QsLEabHYyN6fCdpweRFUvqoFLdxdiOcgWYhQ22jLmtDSwTyuaXWeSNl27GSpU9T+Ud4l11x9DMtd31KOz+SlX8G9Nu0SNHg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:56:59 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:56:59 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:09 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [J8CIGmwUFvWWYCw/k/MjyqURX12RT9X+] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-27-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 715393bb-2234-401e-463a-08da4a73bda5 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKoG+8R97yWywWP82rv3sd0Tp8WY2AHLWcv8RxYlxlXpbnYNGLYxWZz4iPJBtSm9/Bo/Oj+JThySg9yamSskZU9edcSeDxYNwWxujg0wfrXAFh5cPpuOouSxz4zKU5WNwejxrtuiwH6TLXU/fwdI+8y678OGBACRiozNSM3NU0t+OxmEw2mSNyk5JTPqP8U0iWVLUZKJeszDdAzPG/XVDJOAeln3ZFwPiaJru2zlr03tlJyZoP+mBHdWKarN2Z4r7kzlkY5jkNRckd4IkJdnpq3Ppr3HmPKKI898m1OPugAvG/TrDcCwP8WKbB1qhCitBOUqbWryMDTEi3Fxk4Klhz2AqBCp3OnOO8JPmS15U7Ks8jMHDk+ztJN+Nv3GY5QkQYGt51QxXghYN24nSpkndt7oTucCdFsgJdfFZsS4RNzgQSrqrxj1ksST9Kff3j1T5RIrPnRcVbEbusLgfMyqy7NNYjetrb2psuUuCKhhNc/pqQLvTvUMsLqm55MDEPmu9dfiQJ2BQpwsryrV1kExVRv2sgNptun4Y5dCAFydUC3wpKk/O1JXOJFgmn/HCsuDuhaKlnxU+DjJthLDFXzUYx2Gr4QYpLKA7xy2kYUFdpAg1NhUgFbBvwY4zf0g6/kzzOGS51wlDg6PZSEAXPGuehLV//f90AhGX1Tl6gYrlRI5qWDZyXwYB359xJa3m5Hm/YGBvuJ64QwUwN8vF8zLpuKcwPgmA0RvaOMlAbIMmd8Po= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: qbIL9liU+e/1t5ndz9kjUPh6p1KCeVWzpPsnflptx6+bbL54p5R2LZMz7AJVK6lifKbH7AVXEVllv3RS+ZFh4dNiJ7bO17DbnIqhSS8RBvR55qoSgcpJ0Y55aM1vpbGPRhhw0+SKmxTK6pYrbS8XxTZlFAPPFiMLK2xnzAwqCjZ37RZ1WHEmQH+oLQhGz4+NlyVXAiC0Ui24iLWFGc5EQ8Q19PTRMhpue49sShGcFQ6ied3TG2JL6YwvunWP+lMeqFUtKNBctUIh+ErWlVRuS0+ck527JTyHlPhnuldvROmR16tzusRTOhh9Dxb2LHn9HVnbuhzdf6vcjXZGqR2uQKTSQi9ZMjANGXXuT9COnmcF/tWIltW/J/L1PGVN+OjPI5UZCV+bwwiNN3KJ4P8ts9kpq8226YCInkpDClbBbXYG+4i3nwe/7PmOJQBJYeb9lfWedU/IOPE68E5YYhBMMjHx7JbbwTyOpF5rHHj1qWmRCFKetfXcyMk57nbykLv+QZYNp8ufWimBzVauaY0ZUuW61BRKJtKorrbYBvH4CkFH+z2+GiJEZMYu8zidk1/5Z0P5tU6sVStq6PgXJhOJrw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: spPhAtqUtmfOU/jrZZuV8teC80RwXC18ChMIPrZFJo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B7/nQLDsZ4qetAST5ezjd0Hex5QMW7/vIi4OKNd2EY85jJRbCwffAXX4XHkJNsjy5kYkCxUXtHGDnIqFkhzRz09+bKGNiCtKkcYcjrylx42hZhrr8XvgB3YdehrB5tEbXDFASr9h2QPI4sxMYjUITBB2uThmVePth4/BMMDvxtTSqPnvavDOp6SJhf9wA1MJhOBzvwOy3bCsfHfSu1/hE5LsE3LZYVdljoFKNCPKjbf84n9Rs5GcyBwSMMnI2/bMjAHSoYJVu7J+J58lOLV6sZUYNnbZ0507jkUbUOGHF0TxGdi0NQxNIMhhZ7G5U6PXqt3DJyGFjuKfbTlhibDS7k+csxWtKhqr X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 715393bb-2234-401e-463a-08da4a73bda5 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:56:59.2109 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 27/41] avcodec/x86/lossless_audiodsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: DlSUlDyeZ4gF x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/lossless_audiodsp.asm | 2 ++ libavcodec/x86/lossless_audiodsp_init.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/libavcodec/x86/lossless_audiodsp.asm b/libavcodec/x86/lossless_audiodsp.asm index 063d7b41af..ad8a34531a 100644 --- a/libavcodec/x86/lossless_audiodsp.asm +++ b/libavcodec/x86/lossless_audiodsp.asm @@ -63,8 +63,10 @@ cglobal scalarproduct_and_madd_int16, 4,4,8, v1, v2, v3, order, mul RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext SCALARPRODUCT +%endif INIT_XMM sse2 SCALARPRODUCT diff --git a/libavcodec/x86/lossless_audiodsp_init.c b/libavcodec/x86/lossless_audiodsp_init.c index f74c7e4361..f90cab55d3 100644 --- a/libavcodec/x86/lossless_audiodsp_init.c +++ b/libavcodec/x86/lossless_audiodsp_init.c @@ -40,8 +40,10 @@ av_cold void ff_llauddsp_init_x86(LLAudDSPContext *c) #if HAVE_X86ASM int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMXEXT(cpu_flags)) c->scalarproduct_and_madd_int16 = ff_scalarproduct_and_madd_int16_mmxext; +#endif if (EXTERNAL_SSE2(cpu_flags)) c->scalarproduct_and_madd_int16 = ff_scalarproduct_and_madd_int16_sse2; From patchwork Thu Jun 9 23:55:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36126 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655543pzj; Thu, 9 Jun 2022 17:00:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy4nykvfPXTaZiaV6MwM3r4iJ6hmRCICsCttmyzc+3EKoVjE5XiKr1PY0swBxcsW/uIFg5K X-Received: by 2002:a17:906:84b:b0:70c:d506:7817 with SMTP id f11-20020a170906084b00b0070cd5067817mr35422648ejd.206.1654819227149; Thu, 09 Jun 2022 17:00:27 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id qk44-20020a1709077fac00b006e8baf14cc8si24837518ejc.927.2022.06.09.17.00.26; Thu, 09 Jun 2022 17:00:27 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=kPvWhSVD; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 6022268B8F9; Fri, 10 Jun 2022 02:57:09 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073108.outbound.protection.outlook.com [40.92.73.108]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 00B4368B86F for ; Fri, 10 Jun 2022 02:57:02 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UEXUNp2T14hBvjSr7GwQvTklKwM7qlVdkCx5aV2Fxbuei0Zjxu8Pw+5IEc4ee9r2Dd3phrcbP88JK3bFNdWirl9CLcJoT/+/JhsDM3xwFAh5TaEHVqW8A+rKTCLnWRes+9lPM1UzthOGp9cpbrENn0kOVji4fJzQCibW8TMsvjNjkKjG+Pl4gJpuNpIEfiLfewkbrS0qj7kgwPVrKaLzGWsdiHT4t+psbxQA28W8kHYCLIpbgLynfOI6Eh3ELuwtG23kM89a0sITNdk5PkMSgxiCaai1egpyRnFy92qIG4mZASvjb9xZEJ++Rul4LfCpfofH/qTMqnhedWdwTUsaVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=8Q/kQuAY4LLL0yjPc4M6jZC4DDJ1kp5JuPYtGQepfr0=; b=drjI5hx5ZJWAQNJoYVTo7y0EA2448CYELlT4fAvLLQMENo2KkJAQzppmkQiAqJj+w3A1BZfEFqLhiJzRtBjedoMmvc5vBbgbSovfv//c/1DXEYAvK7fqg1JuOTUFxPB6vlSfkRKxGcou+/TvzcVyg2uFd9NYURHpcQgJLg7hqd/oyzXDs7Un/M0Hrra5vKRO+JPuh+phO0tsQ7NV13gnskB/W8UtGv9PW+8RuTTlOOzqcwaeYCfirxxx220lA0CLxhOrkHZnNTndjSrOifkJzmLCrHuGI1ll6wc6GVHq1lFRkZuHeB334eDSpWWMMcCbUCPXU/ayJ068027FgAVfvA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=8Q/kQuAY4LLL0yjPc4M6jZC4DDJ1kp5JuPYtGQepfr0=; b=kPvWhSVDMKpce6GhccwPEm6x1QjHoynBNTHlAl7Hw7NQDVOgYL11tp50VTL3e/Oo+VhmqRdela7cKc9RGbG/px0FtV2gNX4HpfY7/LxLzQwVTTAejBawFSePf3O/yGqgpbEksT0G079oppwA2p83gMpwD1QJBkW5IhMhGPkRf0ZP0aTTolqV4NMF5HTcyuyBfG/28IxLatJmAeISX0TFzUvRM961CqVRR3unQ/eTMGutuWHsIofNxAC9mrViIYTGZhGOxaWA7UuyjoJKaqF/W2xkOWODCYBidcgYV57YSr8RG90Df7TbUu6VEqdb8GpNlL9JlVITYXYuuulDfC0U7Q== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:01 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:01 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:10 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [vu4b9CWpFYnKb6RQK05YHOSqmSCrtpxi] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-28-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 670aa999-b180-48af-d3d9-08da4a73bf16 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvOeZ1w4qHksJ4pVb7E9znD8Ya5oVPlZyYo70WR538sjT9QERSMSUpC2h3DN7j8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D5PUL7w7oN/GBHEqDV9jvv8Xe6BU8zIuT3mgQG1mwxhTD4msDfdWkQ7tRdm1U+Ljy7Ht6V6lpbRAn8visJX4YCqFkmMLIvin4bcwjq5Y+4yEPwjMEKYKa4AE/N25W18kaEI4UUCurYdBrvNw+PT8SWlVlvoalQ0n947ohDpa5adkrHYHtgRRFUvrDAOKTF90LIDRlMgKVvfMfxE7lsF/qZXFGJQc5M+zPN1zvd6ANf/3H77pGah77pmVGhny2u+MB0yfyTkLIf9HzmrMdLdUbzOqzjWemXBdk2iPSYISRe26pJ9UEKaAVIPzot0Y8eQO+QkiO5arCM4ZHoiQmZGziiy296fbz1Gvurqp3ToXekokFMePWBV27Mq1QFhdTdYD/toplz+pg6mYn++JG6hKTI5mydvnerk8KFvppa7z659ZzCjIaIojGvJkCnjUOBlo82YtuP7m3ItCZ/HKhhiTDKZa4Qsvm6/6ZMBFvKAW46fMfIXPmJnnqmMDxE9fE4h9+ljGADM71nkeZJv/QSU8cIMdbg8IG6bZ4wFu8YHH0HIxM9eQAMVEvBAC0Qh0CtsfvsNqbxSpcoHauKlPV3XObj0fsLQ/H40aTA7BAo1tI7XLGASwtp5QwyFQm2PlwaLesjJirrawAwzsR0XbuCQdMDJPyfuJbq6LgcV9s4x1+FlM1ZtUwe0fzzxOVNIPyNnINKlhgkEl4 X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 670aa999-b180-48af-d3d9-08da4a73bf16 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:01.6172 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 28/41] avcodec/x86/svq1enc_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: ZIP16rRKggem x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/svq1enc.asm | 2 ++ libavcodec/x86/svq1enc_init.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/libavcodec/x86/svq1enc.asm b/libavcodec/x86/svq1enc.asm index a87632836d..a43d3b4029 100644 --- a/libavcodec/x86/svq1enc.asm +++ b/libavcodec/x86/svq1enc.asm @@ -55,7 +55,9 @@ cglobal ssd_int8_vs_int16, 3, 3, 3, pix1, pix2, size RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx SSD_INT8_VS_INT16 +%endif INIT_XMM sse2 SSD_INT8_VS_INT16 diff --git a/libavcodec/x86/svq1enc_init.c b/libavcodec/x86/svq1enc_init.c index 40b4b0e183..aaebbb92cc 100644 --- a/libavcodec/x86/svq1enc_init.c +++ b/libavcodec/x86/svq1enc_init.c @@ -33,9 +33,11 @@ av_cold void ff_svq1enc_init_x86(SVQ1EncContext *c) { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { c->ssd_int8_vs_int16 = ff_ssd_int8_vs_int16_mmx; } +#endif if (EXTERNAL_SSE2(cpu_flags)) { c->ssd_int8_vs_int16 = ff_ssd_int8_vs_int16_sse2; } From patchwork Thu Jun 9 23:55:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36127 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655644pzj; Thu, 9 Jun 2022 17:00:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwZGJmwLnm/4KU/xZLsTauyS8gF1lYULStpEpKii+l74m4aw9VqzQ9jEG070bIV8PM/qOsw X-Received: by 2002:a17:907:1628:b0:711:e3fe:50a9 with SMTP id hb40-20020a170907162800b00711e3fe50a9mr13751832ejc.746.1654819239287; Thu, 09 Jun 2022 17:00:39 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id l4-20020a50cbc4000000b0042dc3b66e0dsi7070466edi.357.2022.06.09.17.00.38; Thu, 09 Jun 2022 17:00:39 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=sjR9dAUf; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4CBB468B903; Fri, 10 Jun 2022 02:57:10 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073108.outbound.protection.outlook.com [40.92.73.108]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 430B568B86F for ; Fri, 10 Jun 2022 02:57:08 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=klkSejXQxNtxS4RA3prThBYvjT6Mum8YH73nW45v/VSY7HJKtc0B4tTQ2CXET/nZARRUiWr1t+WSBDx3Zfy9pHUgZUjxsibiftRSc5xr9hqAw6BaYSYNvYjLfO56HJhw6G9VWYw68vCDlzCEzQIFk7wEDXAXAKGSA9Xn49p4kzkmf0jszfMibZ3qZpn/41uy3zs1nNOJXQJ6hn2AeTviTew3DPmHYOFSvy2K8kEqlBARnjmOD5KIGfQaq42jsdhGU2A9cYRQ4A/5hj7xQf2+oNZkBRkqhzW9zIjr9LKNDAE3wAcRIKKsFq+yhqhDLlft72iStiip5YGfe+HFQwu6bQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=7aCg53R6HwUsT/IAB8gWcPkdLhHNgff6RSsqPllImp0=; b=mLU3ypGTyTAwQ+5w/JtZp/Bor4De/h1q1ChatOvShqVLkKlqrGdNRMVLFHnwC2L6T5RzRZV42FzvZJGxaMolubNwO7oKc6ogJVzb/0sR2raCaP0h/y5lubR8a+5M+eDb0AeAE5AZOCFXOTqRdlP1zrbJTaBUd141cSzfiL7pVXSDDs2lVjOxsHsDvsqfOUDusqNI3qh6iUQS5yUenJ5XVHhxMuq0Kkjq+V0xvqNU1SSh0R7FWwfBjMg6yKLVVFnqVXtS/w4enSJV4BYI4pIlvt+Rwz9bF6NQ7VN9YktqxYSKYWU4j1h7tsiwzZjaL7488W6YpiHQKtviUysGUiArYw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=7aCg53R6HwUsT/IAB8gWcPkdLhHNgff6RSsqPllImp0=; b=sjR9dAUf0OudBLPy4z58wf8wIK+OU0o99X+i3mcvhqVLAY+B+TvZy612YZgoFtRX5cQsR0VXMvhbLQajjOC/TyYuvK2Wv876cgiYmkAk5DNNur/ygZSlYxvus8RSZ6z6eCwv8KFH0qt74cWOLo75+2CTOfW/Ejk0cdiSVvc+4REx7951Q3+gPSMahXh+7AZnEA+g6OLk3DBOmJFFjYTNVT/1WTvHe932F6KuutZYbHbSXemud2jOwxyJzMnt5rPrcjAmB5h/QUrc5bEOFFpoqGKXluN7tV/8GRo8rN3FC/l3e0Il7VBy2CP0j/US68a01H0VJZjuqyAT7zUd8StwHw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:04 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:04 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:11 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [dG45TJniPegwDCH7Id66xFg3k4Zxp2pL] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-29-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f92326c0-f114-4ca1-be87-08da4a73c106 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKLkAYCmHAduXdaKWs31JD+yskJEDZACCulrzUZPAXEA5kIzdwcxZUIUpRg0v/xAr0My3IaBTHYdLTL8P5Wa2KkvSfdDZZq3uJ0fJULjX9wLOIcxoyE2zMCZTP9p0t7bDuMGbNpnXZYRfqsOGhatCZMsaT4Mzmw4H7jtvKtYGxKIEeLCKL77O2o9odAHQBT4y9R695qYkD1lG72taHcrH2QARuBvZyEmq3XUDLoEhOqdSpzoidoAqTX9HrYRdfuTMg5ZtJQWcq0ONruIBj+oE5uMS5VQcFz75/4QJjEsayCyFtCKE2LnHOPyePjdKO0PbncQdBgKZF7XR7RPeBIqyqEbp05Lsvq+aVInqhnGNKkPgfV3C42sUkjbDjO/yZSqHEwheBNSbb3+JsitQ8cisdjf8RAkyvhXZ53gg8/Y8TE/Oi6WMdUsfRKT29obDRx5HIbbQhl3PqJhYxVkCBjR3Y5+MVzeU19Umhju9Pk8BgbkuO7sYYzdqM/GI+qsk5vGtfhjOM7hzxRNCFEMp3hcQjndpAntYyevGP/kDUFeZxGKxOg1FGdC2d8w4JY1705m6KUfMk4SsTcXnSrNMPoMb37+EXoR0LOZ27ebcO54+v+enH+IASHI3ZEtcmh6fXTL14/cslPnCT1zHTjBNiac76aq/UM7mSk8BuMTGzLV7F1rlyw26WPOaW6svr3HyXoYdzS9Fxprddy2/Mvjyr6Bv5788vOzJIoSF/gunGaycTaw4= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: jDX1lCSfRrjptINkMpcdQy4nZfAdRkpz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0OXEPxD2bzUtndj+pheBZst0UJskvdKq8JrJa3tkk+XBf4kUN2KYabirQFl9IxuK+WS6i76eMQcGUPsBn5TuwYpfiiO12GBIrm/yvjzWjMqDu6YtREZy74a39HHkfjqrxNvilD82peZLH7x+Adsr9uvQAOMId/nhSQVxI67NzfH1UTKxfw6nqipfoUY2Nga5dgF43ojVF+CvoWGSLRY/3LGzXGTaJDWnTujL6RY+uORI4y5dYxUUrksR9mXP/sW9WxsmZY+VlUQ0wKZzCxou916ow7xb5mHgiQ9zbtUrC+77XUAY0Cg7hZSfASao2VsKcjNOA7CgPkDqbd77rDi94P3A1bcxmwXuZF8eW5EeiyhxCCDtLrg7sKSuuFRjMM84XqwwBRr+pQFcqI0BrRmrdPR+hj41Y8gTxxifY/z2iMUeEV8nQc5G1Mpd7+25gHCoz9WmVwU/UjbT/BURmiowc0ePiOnBMjOiCYUskOzlvRJKsrWCgTZEOcxeqAPlNpefdMSEFw9KndULClJSGf2saJaqtxrp6ob8NuKg9fUSZA6dAnYSl6npHtVYmcAQ74emRu8fJaQDNlFzuL5lPTE8yDvasoCftPaybmhcXP97DgN29CSFo8DecZEYBGNBNfCSEq3z7zLcMYigtH36f7t3eGfTpq+UyRvM5yCvVNE4mm/moI9Z0mDFVqNZ25KYYn8+WHbP+imb+SW/3uWUDh+u9SAZqLey7A3h//6cU1AMrKmorswCyV1d5mfiMe8Df3kOrMdYRU7CKLk7vTeux90fAlNn320GOku+yHGg7lldFGfEi25BFKfBPppTH55aehDW/brCWMpNejCw7wAKS8XA2Z8N69bzdx4bP9aw+cf9UpIuZVS3axYeHlUFgFwTPybFT2HS85A9znMdZeMZt6nPzL6/D9fyUEW82mdE/vFCz9zHjTbZXrY+LPPKZ53gWuvtpfiHVLUKQVDYVDWKLxm8B9xmcO/eTZCdvOkZF+bbw7RskQ4z9lkyhFpFz2YyuxbgBwYOv7EXiU7yWaekoww== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f92326c0-f114-4ca1-be87-08da4a73c106 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:04.8985 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 29/41] avcodec/x86/fmtconvert_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: KFTAyhNUB5dt x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the SSE implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/fmtconvert.asm | 4 ++++ libavcodec/x86/fmtconvert_init.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/libavcodec/x86/fmtconvert.asm b/libavcodec/x86/fmtconvert.asm index 8f62a0a093..5b7578825a 100644 --- a/libavcodec/x86/fmtconvert.asm +++ b/libavcodec/x86/fmtconvert.asm @@ -71,8 +71,10 @@ cglobal int32_to_float_fmul_scalar, 4, 4, %1, dst, src, mul, len RET %endmacro +%if ARCH_X86_32 INIT_XMM sse INT32_TO_FLOAT_FMUL_SCALAR 5 +%endif INIT_XMM sse2 INT32_TO_FLOAT_FMUL_SCALAR 3 @@ -117,8 +119,10 @@ cglobal int32_to_float_fmul_array8, 5, 5, 5, c, dst, src, mul, len RET %endmacro +%if ARCH_X86_32 INIT_XMM sse INT32_TO_FLOAT_FMUL_ARRAY8 +%endif INIT_XMM sse2 INT32_TO_FLOAT_FMUL_ARRAY8 diff --git a/libavcodec/x86/fmtconvert_init.c b/libavcodec/x86/fmtconvert_init.c index df097054e4..0883cd8a56 100644 --- a/libavcodec/x86/fmtconvert_init.c +++ b/libavcodec/x86/fmtconvert_init.c @@ -43,10 +43,12 @@ av_cold void ff_fmt_convert_init_x86(FmtConvertContext *c, AVCodecContext *avctx #if HAVE_X86ASM int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_SSE(cpu_flags)) { c->int32_to_float_fmul_scalar = ff_int32_to_float_fmul_scalar_sse; c->int32_to_float_fmul_array8 = ff_int32_to_float_fmul_array8_sse; } +#endif if (EXTERNAL_SSE2(cpu_flags)) { c->int32_to_float_fmul_scalar = ff_int32_to_float_fmul_scalar_sse2; c->int32_to_float_fmul_array8 = ff_int32_to_float_fmul_array8_sse2; From patchwork Thu Jun 9 23:55:12 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36128 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655727pzj; Thu, 9 Jun 2022 17:00:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzheIwBth1Ak/4w1N9ywmh4/9sO/Qf5rpSLFljaaxzbt6W0cgPhkCpq7cPMv8crkP9GSIPA X-Received: by 2002:a05:6402:139a:b0:431:6b50:11a2 with SMTP id b26-20020a056402139a00b004316b5011a2mr25381537edv.72.1654819251041; Thu, 09 Jun 2022 17:00:51 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id n6-20020aa7d046000000b0042b4ee1bb64si24494713edo.542.2022.06.09.17.00.50; Thu, 09 Jun 2022 17:00:51 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=Spfsc5xJ; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 504FB68B90D; Fri, 10 Jun 2022 02:57:11 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073010.outbound.protection.outlook.com [40.92.73.10]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id C00BA68B8E7 for ; Fri, 10 Jun 2022 02:57:09 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ylq1X4cynu6nRFhLrdaJllWECRlFK0aEXbPZdVzzA0vqIM8r27HjhOzoepnudKZXSUJA96yRnnxWcx481Z/T4kMC21zvyIxtMz3WvOj7Ys57l3D3WpuTRw0B0S/O+YN8341k+Vu5YD2IgYGP9wORWxDHUhcr5YXsNVuXcNluFGCcQ86RM+9xuRqXvJGkwMzwXtbMT9cprWZg7914S6zgR9XFDgqZy4wTtEdu3RnP3Gfjk6xTy6kL43N7gR0MesNvFHC1VO5t9KYGUEYIqh/yQXpSkj6T5ots+UUE0jA+DTy+EuquheyqzPUSFYp93RShyP66nW0ySNctvYb2BkfwyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=HPW9oyXyefPHDnD6R6zQ7b6fhySKoXxfIL47Kqzby+k=; b=dcElteUP2sA/wgacPGmo9UpdggMe+NgObD5uFqpEUY63lvI4Kaz1vUIGZXDbx51GVhXuTanglT2RhDJTgdxIVsrcr9mvnyCikmccAaSPRw9GR0nzBy/+VzgGh7AT+JgWUg2LWzSXk2gfLRikog1s4CChzswxJ0ls4WPRkOnTSEcw14+nA3mrJB12g1Ek9J+ThTJr7y/jiBhygx8rzuZhZ8bncCx8DB2RlJ/0mXid1jcd2mEu3sWfblKOvl6KthaC/oFxt0Wabzt4W4bC0E2vhcliCHKgDAGuuKfQ8iizIQm7r0m09PJO+XZaa7go6M+4AvD2rwrLl8JMZ23ZpG1XlA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HPW9oyXyefPHDnD6R6zQ7b6fhySKoXxfIL47Kqzby+k=; b=Spfsc5xJcJgYQKEoZwut/FL2jYS0lt0ankrIfBbs6FrRA5034MjsmV6KNHRIjz+UDkpIU5lbLJSa9fVkPXkH77MOkrLi8Lk7hPxFP15ERjim92ZRBQxc/DPR9FduGcDHp/u+yEk6ly85Unc0TTGIcbKNmPOy3v4tubx1OAc0rq01oMiLase2jNXBJ9QYQI706et/JgmZksdlt8V5hLqKSiYqSXfTKCu5PyivZBtchkigUho+oTAl34zJHwZDopDE5EnLaatZDaejmmnDOxoXMG5cPklraMzaBKIZl4GXjsidLDqvvJniK31GSrDbOYxWbAlDYvDCLx6ldGZ1wwOWRQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:07 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:07 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:12 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [sBwF9U4uyzJeGqiUXm3KWBfWyQboO337] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-30-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: bcd0dfb1-7bb6-404d-d2eb-08da4a73c2bf X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lK/K0mVwNAsvs8WUtpenCE7biljDV2vL5bsIqsgRx5KLjjXNx1Dfb9SfWXXihSfIIVk21xMk8Z/u5EZzFPSz7ncGd38VwPXZduFvDTLrMJ3lwJHYT7cDiDoPHF1Q6Yulp0eXarW5NHroMva4QmbTCX3DVcxJPIDn9QyWCGW/zFbr8iSSjEGuf4xuUhYHoTx5tzYcO0imIpnGAJDKZTii/T8cMJmhfs0cvH4EyGT9FeVvaTLmjX3XmueAXy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Hp/hSFMZ93/862EcADJHyMLrZm6tWbPkjcSovircQR/J79oJPu18kgpETD71+rqXyDO6LGBGNNZkuY5sJFSBFcIPTYWGYaI1DluT5odPdZqScxFnczazQwDt4/BXgVhTkzr1SR2aPfU+WzJsb2QFlv9A14d2cEu6/YVyXjwEFNx9Ucz9efx6vhZd1Q38PNxoVy1RIyM/sDy9mroJNdtCxmFR6nIO4zBvCUzNrsPkVWE3IwErACWJegSNffDWNfx/iPr3D2o32D4PYJVT67v1ObxzAR8HSHpqER2V9njDGUrAoJSzGpQNidDISCcorMoBbO/ZGXJkGR9/BHaGpy1Apkd2EQY7i1CVREgRjAkZiQDVcPKev5kcp9KRLt+NeQcxBVrYHWzaboHnCO4SfM3eePEGmjXEnJ2FG8QHN7roF4r02a3xdlfiSCV6uA3DR0XH590W5sSFH0tKpUyC6KQgcLK+YiKIDDSBWegorFI3qBO4iAph1CYqu0SJY7rrdbVbSPd9qsWvDOhYcApy5rEVYw1OmwMjF9DjhuwqLFhCyZC9ce3+trWrw5f3hn1LyjZWLBsaooA+8FQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: bcd0dfb1-7bb6-404d-d2eb-08da4a73c2bf X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:07.7736 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 30/41] avcodec/x86/hpeldsp_vp3_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: /Nx2SoIpEMFl x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the 3dnow implementation (which is overridden by the MMXEXT specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/hpeldsp_vp3.asm | 4 ++++ libavcodec/x86/hpeldsp_vp3_init.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/libavcodec/x86/hpeldsp_vp3.asm b/libavcodec/x86/hpeldsp_vp3.asm index cba96d06cb..284babfd70 100644 --- a/libavcodec/x86/hpeldsp_vp3.asm +++ b/libavcodec/x86/hpeldsp_vp3.asm @@ -65,8 +65,10 @@ cglobal put_no_rnd_pixels8_x2_exact, 4,5 INIT_MMX mmxext PUT_NO_RND_PIXELS8_X2_EXACT +%if ARCH_X86_32 INIT_MMX 3dnow PUT_NO_RND_PIXELS8_X2_EXACT +%endif ; void ff_put_no_rnd_pixels8_y2_exact(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -107,5 +109,7 @@ cglobal put_no_rnd_pixels8_y2_exact, 4,5 INIT_MMX mmxext PUT_NO_RND_PIXELS8_Y2_EXACT +%if ARCH_X86_32 INIT_MMX 3dnow PUT_NO_RND_PIXELS8_Y2_EXACT +%endif diff --git a/libavcodec/x86/hpeldsp_vp3_init.c b/libavcodec/x86/hpeldsp_vp3_init.c index 5979f4123c..3c52f9d6f4 100644 --- a/libavcodec/x86/hpeldsp_vp3_init.c +++ b/libavcodec/x86/hpeldsp_vp3_init.c @@ -40,12 +40,14 @@ void ff_put_no_rnd_pixels8_y2_exact_3dnow(uint8_t *block, av_cold void ff_hpeldsp_vp3_init_x86(HpelDSPContext *c, int cpu_flags, int flags) { +#if ARCH_X86_32 if (EXTERNAL_AMD3DNOW(cpu_flags)) { if (flags & AV_CODEC_FLAG_BITEXACT) { c->put_no_rnd_pixels_tab[1][1] = ff_put_no_rnd_pixels8_x2_exact_3dnow; c->put_no_rnd_pixels_tab[1][2] = ff_put_no_rnd_pixels8_y2_exact_3dnow; } } +#endif if (EXTERNAL_MMXEXT(cpu_flags)) { if (flags & AV_CODEC_FLAG_BITEXACT) { From patchwork Thu Jun 9 23:55:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36129 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655837pzj; Thu, 9 Jun 2022 17:01:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxdIXm5gKq19hYnWeNY9a2mf3Q2H5xaFm828SJ1HRgDbZ0sdsoZfkbTXYZXO6d6Gwn8OgNV X-Received: by 2002:a17:907:2d8d:b0:711:d1bd:d738 with SMTP id gt13-20020a1709072d8d00b00711d1bdd738mr20693660ejc.658.1654819264332; Thu, 09 Jun 2022 17:01:04 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id nd22-20020a170907629600b006e81dd29c00si19329895ejc.569.2022.06.09.17.01.03; Thu, 09 Jun 2022 17:01:04 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=uouQvwkK; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 4254468B8F6; Fri, 10 Jun 2022 02:57:13 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073059.outbound.protection.outlook.com [40.92.73.59]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 76FE668B912 for ; Fri, 10 Jun 2022 02:57:11 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cXrjcevvafRqIzw0c3ftL87Zyjh58Jcwrd69bVJ2ASvAE/pvT2ck/CbdZmWa4hE1KsZSmfqiaofM0wxNhSIui/1VAAxpNOF8y4cljZ6ZYntryoEswiGX1RKn0X/J+stz0vQYvUpmAxfzW7DjOCW9pzwI02CRmtsvq2rvAgdlZ3JRWFsMy+2qvz74dU5MZXlo7dAUV388rt49xRXRpDPe6DY68gCoJ9o1Ukhe0isGEBzIsPSolcR8Idcx1gdUvMRNFSUoZgqtQN7emqE2MGJz2knSgpRa6P16ZO/stsigb0nr0bRYxRk3PYYpYyMMrQA8jMQ/flNcYS7QDjm9pxRL4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2n2GXm9dXbSoaHHNYHo9ii5bfP9DoycGmopXorJH6BI=; b=nAFugs0G1BWOGnDRKNdge1Gq0rEpThuFasjAPVQyGeOtx7WjYXm2JndIKXGMr1EC6KG53TfrklNiJ0pliX+YJ6IkJ2FkddqWbsbUnyDvoWGPfFoieOmK7rjZuFzVvAaf+a66igWxLJrk7DE4diGGybjwUK6SDG5t7qVtydCG7nU5aF/+hRBIow/NZgj7UdLt9zyKioDAA5HuzNPhutgrYK4YESsZ8scl3ADpIDQBXOaLYtA3kkeRc4EBiXegpXGJz77QilBS6YFBkcN8LedEJs9NKoZxLLITTqdvp59cbPf4SP1D0XdyBD36Wy/syn5KWBogNiNQNE3ci8imBg+xaQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2n2GXm9dXbSoaHHNYHo9ii5bfP9DoycGmopXorJH6BI=; b=uouQvwkKPvyj8fQcOv8P7n1SZQ8EzRiJaYTy0PPB89X8Up4uHMuLIlHdPM9HdYMDQc1Jlx/qNR5K2VcC6vM2MtY99YdoQcr4is02mEdZwVC9MA2+qszG/Qh7EBJfz7aT6hETGwrPn9zKm3ZRoT/TLNPVyMcX7nxyNZUVkKd0gyAZjf6MGZryVpeYLNTGSYKLta8HT5yfLu+AwHl38pTdiq/lyqLjZ6wrTy01z1QepUkewy8Hr0E2PVdy9b11fM2UnJY+RQXkMAo+MF8/0p2XK6p7vRkPUJa090dgt3ZXQoYMPbdXXr5qThGASrsLFSGqaS5Zw2f/246uvgMoGUGa3A== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:09 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:09 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:13 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [ZWmy/01KC9mgzJ8onQY3gy6Vhnr53tFi] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-31-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5aa33db3-8420-4427-ecab-08da4a73c3fc X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKMY/u9/dCHeuGrjcp4sPm30bBzK6iL9NRH3pv2T48t5UtlSMmn3RS56xP/ZLBwOAOQ9na7FHO5ZiOMSwIlLs/8c9wWgpQyDz2MeEX/8160ZRqHU6ynH0dvMIOlf+cmciA2u0hF70XTGWnyaBancRA/rlMrdwenFzOcfniwsXyeLUec21ialpBT/bZ+nLTxCsQ2q4jFVFpMJ5+k9hTIIFl7NtOnPqig5mg8Sycrh4JoAJ6iUhPVTpoHzpFP28tZCqTzMP0dXD+79iqZ1BANVn2uaeq2vTnPvYN94SeF3nbRbcUKvqG9qGR0xaRzgnH4rwnB97R37W0mioHM61bnPFkGkJsBLOn0XQdfJx5gJN8i+8rOc4edez9fTjkSEK1EsAQuzEutNTo6YeWyzXshDAopS4GffrGuKftKG8cpFXWe8c7bduhYcGG7cBqhK/xenBRk3FzXIDFvtA19jPXzVnCUE2Zf91/R53uEjUe/6/ZI9UINERuIrMbyCapMM7qT19akbNxsdn1M4+2BDL3DgGYQ2tIdPdDw+N32aw1QqbXfe3T33Ho7YWWNH2tgVUkJH4D2TSIE9nwtizRmRYT61/YNrdNGT2O6VV2LHGg5E8+rB9BNnkTHsDV5NmrsEE/oNwd5ofu8qsadhy/yWogyC83qeYJCxv84Gt2wqMczMO6lz+6vUEE9Qb9sTgb8O1yjF4Hy4xzkiSQwP7IKLPmkhKjj2cHoi3+SdTnpJb2xqobPvs= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: hSQMsN+g3+X+cMhLkyM2gc5h6ZZBaBBp4BgkElpndGwPCaGHPP/Oeh0nd8TM4dbUiZntq4zlrlUmZM5eD+RThb2vRNL5ZzK/jJh7OvhtvDCCZbSAQbOO5shIbPoNw2p54XoLQGk5tVr7p3GYCRyQWandwo1aMaferZdriO0aXFna7KKK2XFap7Q0vDciuYuKcJx9ohRv+MhEvAUT+0P/6V5le95Jf7IW+VK3ufpzys3AI5Z0jU7YXVPBNLgWgI72BJ7Jf7tJ7F+cYMseV1BplsKUE0srOZC9+M9L3LmSSv7dRz133wyDVA/KrNZtFf7lzfsR/ICM5GSCoA/9jIQ7pceoe8eEDssrQBQ7LOdGcu0Dzj6hlORbEGLQpQqBNk7lqlJzuePyN3KCix/mD/gOxkta40crJu8NasIxyftpSaklDToKy6TiyMawFuTOte79c+a2MHGv3zltUnSivRJocXWoErjunCsl+O5qqcxH+AsVI3TLx9cPArPXyd5B7BEY5pSbsZtWMkkxvn98KjjisXk01z9CMJzT39YGb2iF+eSYTwWKKbnR9+mLyWvKPVuP+zgul0uAskATvTw26CBWig== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: jy2W4R78y8xsfs0vaM5hib6SMFwBlsoZFbsa7IFr/2C5dlxhUZxyeAEa7YnsTuP+0STEM1YKh1owhCePx9SVb7KT1chxxcTrU8fsJCbr3tzS2adoRhqChOcaudvajkZ79Pln0eV9AVG9sRj6kUdDXwTkWifkPlUY8BBGFGvLevLmnI/8zE6/LGf9L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Q/V8/ET/CigyasymwG3QbSIn8IGz2cJ9vHLdkzUwB0cVx1cFYERTQoFzFDrL5Feph47JFZRTKmI/i+kAqnN6W4YV7XfsXi8dLszYb24eH18v1ZslA4lfYIo7KteyGKYb/ySCLaWyKfhDxA7wnIlkE2QVYax2tTHTa75R3sOwWWHIy7EQtegtCPATj9vor62mbl7eGQJsUE8bFZjAlGA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5aa33db3-8420-4427-ecab-08da4a73c3fc X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:09.9142 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 31/41] avcodec/x86/hpeldsp_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 5P5zCPxBlpOY x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the 3dnow implementation (which is overridden by the MMXEXT specific implementation) as well as some MMX functions at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/fpel.asm | 2 ++ libavcodec/x86/hpeldsp.asm | 22 +++++++++++++++++++ libavcodec/x86/hpeldsp_init.c | 40 +++++++++++++++++++++++++---------- libavcodec/x86/rnd_template.c | 2 ++ 4 files changed, 55 insertions(+), 11 deletions(-) diff --git a/libavcodec/x86/fpel.asm b/libavcodec/x86/fpel.asm index d38a1b1035..8c810265c3 100644 --- a/libavcodec/x86/fpel.asm +++ b/libavcodec/x86/fpel.asm @@ -91,7 +91,9 @@ cglobal %1_pixels%2, 4,5,4 INIT_MMX mmx OP_PIXELS put, 4 OP_PIXELS put, 8 +%if ARCH_X86_32 OP_PIXELS avg, 8 +%endif OP_PIXELS put, 16 OP_PIXELS avg, 16 diff --git a/libavcodec/x86/hpeldsp.asm b/libavcodec/x86/hpeldsp.asm index ce5d7a4e28..97f9f06539 100644 --- a/libavcodec/x86/hpeldsp.asm +++ b/libavcodec/x86/hpeldsp.asm @@ -83,8 +83,10 @@ cglobal put_pixels8_x2, 4,5 INIT_MMX mmxext PUT_PIXELS8_X2 +%if ARCH_X86_32 INIT_MMX 3dnow PUT_PIXELS8_X2 +%endif ; void ff_put_pixels16_x2(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -127,8 +129,10 @@ cglobal put_pixels16_x2, 4,5 INIT_MMX mmxext PUT_PIXELS_16 +%if ARCH_X86_32 INIT_MMX 3dnow PUT_PIXELS_16 +%endif ; The 8_X2 macro can easily be used here INIT_XMM sse2 PUT_PIXELS8_X2 @@ -171,8 +175,10 @@ cglobal put_no_rnd_pixels8_x2, 4,5 INIT_MMX mmxext PUT_NO_RND_PIXELS8_X2 +%if ARCH_X86_32 INIT_MMX 3dnow PUT_NO_RND_PIXELS8_X2 +%endif ; void ff_put_pixels8_y2(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -209,8 +215,10 @@ cglobal put_pixels8_y2, 4,5 INIT_MMX mmxext PUT_PIXELS8_Y2 +%if ARCH_X86_32 INIT_MMX 3dnow PUT_PIXELS8_Y2 +%endif ; actually, put_pixels16_y2_sse2 INIT_XMM sse2 PUT_PIXELS8_Y2 @@ -249,8 +257,10 @@ cglobal put_no_rnd_pixels8_y2, 4,5 INIT_MMX mmxext PUT_NO_RND_PIXELS8_Y2 +%if ARCH_X86_32 INIT_MMX 3dnow PUT_NO_RND_PIXELS8_Y2 +%endif ; void ff_avg_pixels8(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -279,8 +289,10 @@ cglobal avg_pixels8, 4,5 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX 3dnow AVG_PIXELS8 +%endif ; void ff_avg_pixels8_x2(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -335,12 +347,16 @@ cglobal avg_pixels8_x2, 4,5 REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmx AVG_PIXELS8_X2 +%endif INIT_MMX mmxext AVG_PIXELS8_X2 +%if ARCH_X86_32 INIT_MMX 3dnow AVG_PIXELS8_X2 +%endif ; actually avg_pixels16_x2 INIT_XMM sse2 AVG_PIXELS8_X2 @@ -384,8 +400,10 @@ cglobal avg_pixels8_y2, 4,5 INIT_MMX mmxext AVG_PIXELS8_Y2 +%if ARCH_X86_32 INIT_MMX 3dnow AVG_PIXELS8_Y2 +%endif ; actually avg_pixels16_y2 INIT_XMM sse2 AVG_PIXELS8_Y2 @@ -433,8 +451,10 @@ cglobal avg_approx_pixels8_xy2, 4,5 INIT_MMX mmxext AVG_APPROX_PIXELS8_XY2 +%if ARCH_X86_32 INIT_MMX 3dnow AVG_APPROX_PIXELS8_XY2 +%endif ; void ff_avg_pixels16_xy2(uint8_t *block, const uint8_t *pixels, ptrdiff_t line_size, int h) @@ -517,8 +537,10 @@ cglobal %1_pixels8_xy2, 4,5 INIT_MMX mmxext SET_PIXELS_XY2 avg +%if ARCH_X86_32 INIT_MMX 3dnow SET_PIXELS_XY2 avg +%endif INIT_XMM sse2 SET_PIXELS_XY2 put SET_PIXELS_XY2 avg diff --git a/libavcodec/x86/hpeldsp_init.c b/libavcodec/x86/hpeldsp_init.c index 6336587281..06ba5390d7 100644 --- a/libavcodec/x86/hpeldsp_init.c +++ b/libavcodec/x86/hpeldsp_init.c @@ -131,19 +131,25 @@ CALL_2X_PIXELS(put_no_rnd_pixels16_xy2_mmx, put_no_rnd_pixels8_xy2_mmx, 8) #undef DEF #define DEF(x, y) ff_ ## x ## _ ## y ## _mmx #define STATIC +#if ARCH_X86_64 +#define NO_AVG +#endif #include "rnd_template.c" +#undef NO_AVG #undef DEF #undef SET_RND #undef PAVGBP #undef PAVGB #if HAVE_MMX +#if ARCH_X86_32 CALL_2X_PIXELS(avg_pixels16_y2_mmx, avg_pixels8_y2_mmx, 8) CALL_2X_PIXELS(put_pixels16_y2_mmx, put_pixels8_y2_mmx, 8) CALL_2X_PIXELS_EXPORT(ff_avg_pixels16_xy2_mmx, ff_avg_pixels8_xy2_mmx, 8) +#endif CALL_2X_PIXELS_EXPORT(ff_put_pixels16_xy2_mmx, ff_put_pixels8_xy2_mmx, 8) #endif @@ -162,38 +168,49 @@ CALL_2X_PIXELS_EXPORT(ff_put_pixels16_xy2_mmx, ff_put_pixels8_xy2_mmx, 8) CALL_2X_PIXELS(avg_pixels16_xy2 ## CPUEXT, ff_avg_pixels8_xy2 ## CPUEXT, 8) \ CALL_2X_PIXELS(avg_approx_pixels16_xy2## CPUEXT, ff_avg_approx_pixels8_xy2## CPUEXT, 8) +#if ARCH_X86_32 HPELDSP_AVG_PIXELS16(_3dnow) +#endif HPELDSP_AVG_PIXELS16(_mmxext) #endif /* HAVE_X86ASM */ #define SET_HPEL_FUNCS_EXT(PFX, IDX, SIZE, CPU) \ if (HAVE_MMX_EXTERNAL) \ - c->PFX ## _pixels_tab IDX [0] = PFX ## _pixels ## SIZE ## _ ## CPU; + c->PFX ## _pixels_tab IDX [0] = PFX ## _pixels ## SIZE ## _ ## CPU #if HAVE_MMX_INLINE -#define SET_HPEL_FUNCS(PFX, IDX, SIZE, CPU) \ +#define SET_HPEL_FUNCS03(PFX, IDX, SIZE, CPU) \ + do { \ + SET_HPEL_FUNCS_EXT(PFX, IDX, SIZE, CPU); \ + c->PFX ## _pixels_tab IDX [3] = PFX ## _pixels ## SIZE ## _xy2_ ## CPU; \ + } while (0) +#define SET_HPEL_FUNCS12(PFX, IDX, SIZE, CPU) \ do { \ - SET_HPEL_FUNCS_EXT(PFX, IDX, SIZE, CPU) \ c->PFX ## _pixels_tab IDX [1] = PFX ## _pixels ## SIZE ## _x2_ ## CPU; \ c->PFX ## _pixels_tab IDX [2] = PFX ## _pixels ## SIZE ## _y2_ ## CPU; \ - c->PFX ## _pixels_tab IDX [3] = PFX ## _pixels ## SIZE ## _xy2_ ## CPU; \ } while (0) #else +#define SET_HPEL_FUNCS03(PFX, IDX, SIZE, CPU) SET_HPEL_FUNCS_EXT(PFX, IDX, SIZE, CPU) +#define SET_HPEL_FUNCS12(PFX, IDX, SIZE, CPU) ((void)0) +#endif #define SET_HPEL_FUNCS(PFX, IDX, SIZE, CPU) \ do { \ - SET_HPEL_FUNCS_EXT(PFX, IDX, SIZE, CPU) \ + SET_HPEL_FUNCS03(PFX, IDX, SIZE, CPU); \ + SET_HPEL_FUNCS12(PFX, IDX, SIZE, CPU); \ } while (0) -#endif static void hpeldsp_init_mmx(HpelDSPContext *c, int flags) { - SET_HPEL_FUNCS(put, [0], 16, mmx); + SET_HPEL_FUNCS03(put, [0], 16, mmx); SET_HPEL_FUNCS(put_no_rnd, [0], 16, mmx); - SET_HPEL_FUNCS(avg, [0], 16, mmx); SET_HPEL_FUNCS(avg_no_rnd, , 16, mmx); - SET_HPEL_FUNCS(put, [1], 8, mmx); + SET_HPEL_FUNCS03(put, [1], 8, mmx); SET_HPEL_FUNCS(put_no_rnd, [1], 8, mmx); +#if ARCH_X86_32 + SET_HPEL_FUNCS12(put, [0], 16, mmx); + SET_HPEL_FUNCS12(put, [1], 8, mmx); + SET_HPEL_FUNCS(avg, [0], 16, mmx); if (HAVE_MMX_EXTERNAL) { c->avg_pixels_tab[1][0] = ff_avg_pixels8_mmx; c->avg_pixels_tab[1][1] = ff_avg_pixels8_x2_mmx; @@ -202,6 +219,7 @@ static void hpeldsp_init_mmx(HpelDSPContext *c, int flags) c->avg_pixels_tab[1][2] = avg_pixels8_y2_mmx; c->avg_pixels_tab[1][3] = ff_avg_pixels8_xy2_mmx; #endif +#endif } static void hpeldsp_init_mmxext(HpelDSPContext *c, int flags) @@ -237,7 +255,7 @@ static void hpeldsp_init_mmxext(HpelDSPContext *c, int flags) static void hpeldsp_init_3dnow(HpelDSPContext *c, int flags) { -#if HAVE_AMD3DNOW_EXTERNAL +#if HAVE_AMD3DNOW_EXTERNAL && ARCH_X86_32 c->put_pixels_tab[0][1] = ff_put_pixels16_x2_3dnow; c->put_pixels_tab[0][2] = put_pixels16_y2_3dnow; @@ -263,7 +281,7 @@ static void hpeldsp_init_3dnow(HpelDSPContext *c, int flags) c->avg_pixels_tab[0][3] = avg_approx_pixels16_xy2_3dnow; c->avg_pixels_tab[1][3] = ff_avg_approx_pixels8_xy2_3dnow; } -#endif /* HAVE_AMD3DNOW_EXTERNAL */ +#endif /* HAVE_AMD3DNOW_EXTERNAL && ARCH_X86_32 */ } static void hpeldsp_init_sse2_fast(HpelDSPContext *c, int flags) diff --git a/libavcodec/x86/rnd_template.c b/libavcodec/x86/rnd_template.c index 09946bd23f..b825eeba6e 100644 --- a/libavcodec/x86/rnd_template.c +++ b/libavcodec/x86/rnd_template.c @@ -97,6 +97,7 @@ av_unused STATIC void DEF(put, pixels8_xy2)(uint8_t *block, const uint8_t *pixel :FF_REG_a, "memory"); } +#ifndef NO_AVG // avg_pixels // this routine is 'slightly' suboptimal but mostly unused av_unused STATIC void DEF(avg, pixels8_xy2)(uint8_t *block, const uint8_t *pixels, @@ -173,3 +174,4 @@ av_unused STATIC void DEF(avg, pixels8_xy2)(uint8_t *block, const uint8_t *pixel :"D"(block), "r"((x86_reg)line_size) :FF_REG_a, "memory"); } +#endif From patchwork Thu Jun 9 23:55:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36130 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp655916pzj; Thu, 9 Jun 2022 17:01:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyVgacYD/UvOsUo/fslx1mU//d9SZuPfy4ohovdZwYAX3GAHHcncjQwVfszbOgnIJy5Lh3K X-Received: by 2002:a17:907:d05:b0:6f4:3729:8e36 with SMTP id gn5-20020a1709070d0500b006f437298e36mr37360146ejc.475.1654819276736; Thu, 09 Jun 2022 17:01:16 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id jg35-20020a170907972300b006f40efd4b88si7791869ejc.812.2022.06.09.17.01.16; Thu, 09 Jun 2022 17:01:16 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=rLjtxZLW; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 41E6868B91A; Fri, 10 Jun 2022 02:57:15 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073085.outbound.protection.outlook.com [40.92.73.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id CE65668B8F6 for ; Fri, 10 Jun 2022 02:57:12 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UWbnhT4y9r5ikg7C0rUlz7DWCj7rmhSXers0EVPQOtnjk0WlMvCELIGqrTmlCSgkQY1SxBPpqlG0wwzuEdLAK6z0WjLE3EIoHeB2d/P7FKgRLhsVsvasIEr1Qmi98j0655GkyEvrxq0oBqER0ejz3U0mr++MmsdpOuzcxMsF1qsZH7RYhI1qoXmqr//i3eyOFwk6WgPBBLVbu9Smp3pymPg0Ar3AiMZ2TfUL1DIsEo9hOMtO+mBWXdVf9UYXs83tBLrBw/XolHQe63m9k7y2TEaiscqb6C2Ibns0BgVE5+rJa2VR5aXUHNDZu9qms09Cp6/8zuxnjV1U0FcnKg7Qng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=3ucyKEhwG7jgVdKd4PbuGcga9UnmRPXcoLl+vsKacZ8=; b=kw5XEjAh0H/12NtQZrMW91kHPSK7lCT64nPiNEMOcXVzct/HfXVKkjw+CJFX667FbpKDIW9VYWczZSTtLBqYTUsIxy+GX8xQYaI5sx/r9cv2SwOtcz15KNa42y3FG/+4u7f+jGBHxZKRFSKQbr7OZKmXxBq4mVQAQ/SUGlQnaHRfjs3FucfH+Pn1zqRTFcMuF1s8trkZmtw+hVoo2ipm0e4M0AsstpAOzTKFdnaAGXr9ZnhPOyL6Sw37+Ohi8ZRGbykv09gsjaf8bkltCrJX07HkkgDk+kF1bjiSbfsfPrGk/O7Dy50P+bXsMqIMhxOQoVlfBiXb1tW5pUIrLfcgYQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=3ucyKEhwG7jgVdKd4PbuGcga9UnmRPXcoLl+vsKacZ8=; b=rLjtxZLWxl10p8WSmfmBUI8/RvvVkeazBXj96rKsJsgZKIegCNQi7pGm/yVL3I1jY5BGWpWtJBQyjspDruRXqern0PaXWOB1b03hMTyG4tNbS/L0Iihs5jbc3DKML2XEoxFTcUcNChmNat204AffSIqUuLleMLEWYZDAKBGUMFLZP9Vq1DLl0r116l8m62kgaFY8YIFkTPjJuoEK3yer/3viQeF/Rb3+Gw8kvpmV7WIZZxnw+xH4ZED2bqFW+SreLsS3jwjQJaP96DLOPK9HgRSPP/Dx0+KqBl0pAsD2YUF4JAILZZNL0glziiy0swZtYffkYoSpp75BE7YU9HhPiA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:11 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:11 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:14 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [z+eUzdQdzX59/LmGBL96SinJIcnMtfdv] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-32-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: a8559324-ea86-49a1-cf21-08da4a73c4e1 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKtZ7ZnKz1Moez84Nz9n+Fdhj7YbqHuMC2KID9QWPXTsoQPMIMUXEche/U9EY2gFiLP/DTqB980A7adRjWXZNd0s4MDNChALUzTdaJcvw2Qs5TcpU5PKtVmu5dj5DmzuwB6U2nzKVLtdhg5xkH3tK+6ahPwwhgZWAcTb5a/z7yQZC1R9kzrIDmv9YqsEX5eWeiGHjjBORCP45pbSHUrPY80lV6S+Ki/kA5zyxX34TErRr3s88aBOAR4hzMMD7L13A/7OzAuxIIjMXc7nnNTlRtUfa5dqKHiDTz5n4ABIx6rcUyzcJUNVsy0F2q+kZWNc+Junf7C1oSDXXzvisHWYf78QnRWD89i+8O+9ToadXqSNQIMaUOiaRIIwUqc+YwULr+zspwJCp3USggM30H0S8bY5nuJKHjelTe03gdrX0LKzIeE1fuXD9ZhgnUaWVmlvaDgPxZARrqWfxE0n0tz+/BYQvPdZ/Nc6n4/MnZ3yw4E88Mi5LPqGcp1odzNRO/ezZEAIxpaF7Bx+sYLgW0vGw7LELB6fnOST1TQW/ONSeqe0t4Xei0Ow/PrRUkUvPinHLR3ibur5bg5p59+nsy5VOV8PIYiw7OfXbgEMpcSwUEKzlsN/TKPqK1xYoxqUCW048f5jVs322b+cFv4TzgTBAUweV9jUIGnkFi265xdTOn2IPrTMC/nwAu54DPI/L3WpelosKCNqyUMMNvtPxFlfpC5jWLSKmXJj5m389cL3vabwY= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: dClUSKX8Vx9hXpGT27xDzI4KncQ30CZy+drKmIePFUjkNk9YKZLQzN/joMxiI//j+9o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08da4a73c4e1 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:11.3673 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 32/41] avcodec/x86/h264_qpel: Make functions only used here static X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: aBiM4nfl3Bn6 Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_qpel.c | 44 ++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/libavcodec/x86/h264_qpel.c b/libavcodec/x86/h264_qpel.c index dda50ded89..fd1070247b 100644 --- a/libavcodec/x86/h264_qpel.c +++ b/libavcodec/x86/h264_qpel.c @@ -409,13 +409,11 @@ H264_MC_816(H264_MC_HV, ssse3) void ff_ ## OP ## _h264_qpel ## NUM ## _ ## TYPE ## _ ## DEPTH ## _ ## OPT \ (uint8_t *dst, const uint8_t *src, ptrdiff_t stride); -#define LUMA_MC_ALL(DEPTH, TYPE, OPT) \ +#define LUMA_MC_48(DEPTH, TYPE, OPT) \ LUMA_MC_OP(put, 4, DEPTH, TYPE, OPT) \ LUMA_MC_OP(avg, 4, DEPTH, TYPE, OPT) \ LUMA_MC_OP(put, 8, DEPTH, TYPE, OPT) \ - LUMA_MC_OP(avg, 8, DEPTH, TYPE, OPT) \ - LUMA_MC_OP(put, 16, DEPTH, TYPE, OPT) \ - LUMA_MC_OP(avg, 16, DEPTH, TYPE, OPT) + LUMA_MC_OP(avg, 8, DEPTH, TYPE, OPT) #define LUMA_MC_816(DEPTH, TYPE, OPT) \ LUMA_MC_OP(put, 8, DEPTH, TYPE, OPT) \ @@ -423,22 +421,22 @@ void ff_ ## OP ## _h264_qpel ## NUM ## _ ## TYPE ## _ ## DEPTH ## _ ## OPT \ LUMA_MC_OP(put, 16, DEPTH, TYPE, OPT) \ LUMA_MC_OP(avg, 16, DEPTH, TYPE, OPT) -LUMA_MC_ALL(10, mc00, mmxext) -LUMA_MC_ALL(10, mc10, mmxext) -LUMA_MC_ALL(10, mc20, mmxext) -LUMA_MC_ALL(10, mc30, mmxext) -LUMA_MC_ALL(10, mc01, mmxext) -LUMA_MC_ALL(10, mc11, mmxext) -LUMA_MC_ALL(10, mc21, mmxext) -LUMA_MC_ALL(10, mc31, mmxext) -LUMA_MC_ALL(10, mc02, mmxext) -LUMA_MC_ALL(10, mc12, mmxext) -LUMA_MC_ALL(10, mc22, mmxext) -LUMA_MC_ALL(10, mc32, mmxext) -LUMA_MC_ALL(10, mc03, mmxext) -LUMA_MC_ALL(10, mc13, mmxext) -LUMA_MC_ALL(10, mc23, mmxext) -LUMA_MC_ALL(10, mc33, mmxext) +LUMA_MC_48(10, mc00, mmxext) +LUMA_MC_48(10, mc10, mmxext) +LUMA_MC_48(10, mc20, mmxext) +LUMA_MC_48(10, mc30, mmxext) +LUMA_MC_48(10, mc01, mmxext) +LUMA_MC_48(10, mc11, mmxext) +LUMA_MC_48(10, mc21, mmxext) +LUMA_MC_48(10, mc31, mmxext) +LUMA_MC_48(10, mc02, mmxext) +LUMA_MC_48(10, mc12, mmxext) +LUMA_MC_48(10, mc22, mmxext) +LUMA_MC_48(10, mc32, mmxext) +LUMA_MC_48(10, mc03, mmxext) +LUMA_MC_48(10, mc13, mmxext) +LUMA_MC_48(10, mc23, mmxext) +LUMA_MC_48(10, mc33, mmxext) LUMA_MC_816(10, mc00, sse2) LUMA_MC_816(10, mc10, sse2) @@ -464,7 +462,7 @@ LUMA_MC_816(10, mc23, sse2) LUMA_MC_816(10, mc33, sse2) #define QPEL16_OPMC(OP, MC, MMX)\ -void ff_ ## OP ## _h264_qpel16_ ## MC ## _10_ ## MMX(uint8_t *dst, const uint8_t *src, ptrdiff_t stride){\ +static void OP ## _h264_qpel16_ ## MC ## _10_ ## MMX(uint8_t *dst, const uint8_t *src, ptrdiff_t stride){\ ff_ ## OP ## _h264_qpel8_ ## MC ## _10_ ## MMX(dst , src , stride);\ ff_ ## OP ## _h264_qpel8_ ## MC ## _10_ ## MMX(dst+16, src+16, stride);\ src += 8*stride;\ @@ -553,8 +551,8 @@ av_cold void ff_h264qpel_init_x86(H264QpelContext *c, int bit_depth) SET_QPEL_FUNCS(avg_h264_qpel, 2, 4, mmxext, ); } else if (bit_depth == 10) { #if ARCH_X86_32 - SET_QPEL_FUNCS(avg_h264_qpel, 0, 16, 10_mmxext, ff_); - SET_QPEL_FUNCS(put_h264_qpel, 0, 16, 10_mmxext, ff_); + SET_QPEL_FUNCS(avg_h264_qpel, 0, 16, 10_mmxext, ); + SET_QPEL_FUNCS(put_h264_qpel, 0, 16, 10_mmxext, ); SET_QPEL_FUNCS(put_h264_qpel, 1, 8, 10_mmxext, ff_); SET_QPEL_FUNCS(avg_h264_qpel, 1, 8, 10_mmxext, ff_); #endif From patchwork Thu Jun 9 23:55:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36131 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656016pzj; Thu, 9 Jun 2022 17:01:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJztd8rYxYYKlMvM8HaIqTni0WGkV3x6Uy5L8/xtsOwFFBhzbaSj5q1ShexzQnS0Jmq1rpfy X-Received: by 2002:aa7:d058:0:b0:42d:f33f:ad21 with SMTP id n24-20020aa7d058000000b0042df33fad21mr47919658edo.388.1654819289506; Thu, 09 Jun 2022 17:01:29 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id mp37-20020a1709071b2500b006feb04902a8si5297810ejc.824.2022.06.09.17.01.28; Thu, 09 Jun 2022 17:01:29 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=QzM0XiJp; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 3706368B926; Fri, 10 Jun 2022 02:57:22 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073083.outbound.protection.outlook.com [40.92.73.83]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id DA99968B918 for ; Fri, 10 Jun 2022 02:57:20 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=X+N3wU0ayNdWjiDtvw8AEMkxdgrPbhynLLPSmIR1IDGR18IfmA4cBI5JbfXKyMafm82G0ThZSSNKsjtdVC4FEa6u702ib9FctOeXPVDLPaK3KzEo7V2fGBt2Q7C4pGuUjm848Eo4jho+NMTy/97AAKfQopni0f6GvLXcYmWJEYi8N+GAKOTM2TcHngshgws4ZBXb5pi7ovapk6zl0uq7DRWf+MfHecdPnB5zmx7y+3n+QAxyXY6MRHj51eD4oA4P82XODsSpyzq2LAQfe1DxPOSVrYfwKGtjkvedt73khxvMpFNyjUJ/qzv2Wz3riIUA+FVNM7KQ36nwdonqgnzPKA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=va4Nk39vhctx231QYDHz2inDcteFwM+2+mfcx+GiTpk=; b=ByHWvF00RGYHiD6MIzVSasXOrhJksFCwdyQpr7w8LrqvugWUor+bSrGQZ8tdqH3RHp3gXBdcRoO9YewQnfNl8gFGe6dnzBonVCVImj1g0l7yuW0sWnbg9oMVAE3Hxprj4CzMpvD3TeZI48zDIbkgL8wAXKl+tTZOyzGRu/6mYU+C7wtY9eIBNoiC0ojWkzMkqVItqQ2BGGYb71b6+fb6u2qdpFXnKgKMk7Ow/V7EARSq7hs1MSfhrfaIiI8YYEyO/lInR2QOt5vSPrSNSbV9lDIDaT60vl01nM29nTydcz2Fe2HtOP8XUb2kMIopGWGCpYczP3LPbgHfFxYbQrpOvg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=va4Nk39vhctx231QYDHz2inDcteFwM+2+mfcx+GiTpk=; b=QzM0XiJp97Q4AjkQR/7LAHwETjwE2QKCSFsRMkppMwScJBUG7Y7yrUdmH4LWQVCxZa0xmb92TSIXrPViKUz5TVtPl7tSr1MHnVq2anyfG3oC7ViPFjs7XzS02HtuZz7MntY0i0GwIkxunmEvzzsbqh9ktSshiKGg4l7FiJNJyl89UawFHaWCwWAclnCQ4e2vqqEOjmaopor1QZE1GMXQDQ6xXkAHZf6jF4zLUQqZ2cDFOYHUBc0noB7IRkHyI9/SqO54di+YtNisrnuXdR37N3WGncsmItTbYNVZO/yxNO8xmguvUvPdH7AxgUkEIFmVIqzDf6HkTDvf9HoHK+SBOQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:19 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:19 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:15 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [kWR1sGgpDfHoDZHESZJhKrOcSFLtLZV+] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-33-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 08cbb10e-d1cc-48d9-25df-08da4a73c985 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKMY/u9/dCHeuGrjcp4sPm3/48ClZ85alLW4s34KqJoBpECgFDZ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WWdhokRMNXnAXM1dGPhAtpucHHqiscLG9kgXVe0VTOPGI4+X0jWdwCMF2MrQsG+ITKBcqG9rDqvk39eDy42GZyk55vZeUh4MM2KaOiWhgUlSJ52tDnGUOBw8x1F4Ldy6n3Ra18EN1AQc3t/1PRgLdhaP0IJJdxJda22zFz2DlMEbijQvL3T5GlB5Ah7HfH9ShFD0inzI5QJS8tfsudW88SD4uo57nYYomEK2YLUpOEyc96nzuTlUUTMY8jbBa+sCkxvKRO5/P50xYBmt1ukJUQM8fhQl2bp1UJm796+JuFF+f6Z5h8tUzbIVNYMRZRWAM4p46q9uAQz9GG9LoKsY0lKzaPCURpFs7NlI1xc4p2lw0SN57Rq/m2YpJr/TK/1Yh2xy3SW++Rs4APRjPr+9PIWaID3V6cejz5XtDNEBjHjE4s4GxZF5fql4siKkKNOY3pJmsQ0VG7tVyi2YkXN2uwuq9B6gyX5Kk4HTODB77gA2CWxLowS7sHZJLn7vvpftIizuHFmo0tRkWM02j6v78buvZ1emWmaGbT4bC8rckenM1rnjPVGd4No9rl2srF6VGEZv8CXQs2OqK0yHZSiiCPYJ5Opd85SnIyKx5wAFlH4cZ6ZwbvE9L7zFK7wvCoHVKAYmkb27ZKm5k8YHEKkGS7qEigPAYg0DyCp5A3ZFWsTFyeokm3tK61ZL+vRxzEBPI0TMRwwop8z38Uc/GdLXltD8c+T5MIr+IQ3kCsrbQRrkhSh1kdGA== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 08cbb10e-d1cc-48d9-25df-08da4a73c985 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:19.1487 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 33/41] avcodec/x86/h264_qpel: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: lrfevL4blv50 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables several MMXEXT functions (that are overridden by SSE2 functions) at compile-time for x64. Notice that some 10-bit SSE2 functions are overridden by sse2_cache64 functions in the same code block. This is suboptimal and the functions that are overridden should either be removed or the sse2_cache64 functions be put behind suitable checks. This commit does neither. Signed-off-by: Andreas Rheinhardt --- I would love to get input on what to do with these sse2_cache64 functions. If no one says anything, I will send a patch that retains the current behaviour and removes the functions overridden by the sse2_cache64 functions. libavcodec/x86/h264_qpel.c | 44 +++++++++++++++++++++---------- libavcodec/x86/h264_qpel_8bit.asm | 4 +++ 2 files changed, 34 insertions(+), 14 deletions(-) diff --git a/libavcodec/x86/h264_qpel.c b/libavcodec/x86/h264_qpel.c index fd1070247b..cb5f8a126c 100644 --- a/libavcodec/x86/h264_qpel.c +++ b/libavcodec/x86/h264_qpel.c @@ -236,7 +236,11 @@ static av_always_inline void ff_ ## OPNAME ## h264_qpel16_hv_lowpass_ ## MMX(uin #define ff_put_h264_qpel8or16_hv2_lowpass_sse2 ff_put_h264_qpel8or16_hv2_lowpass_mmxext #define ff_avg_h264_qpel8or16_hv2_lowpass_sse2 ff_avg_h264_qpel8or16_hv2_lowpass_mmxext -#define H264_MC(OPNAME, SIZE, MMX, ALIGN) \ +#define H264_MC_C_H(OPNAME, SIZE, MMX, ALIGN) \ +H264_MC_C(OPNAME, SIZE, MMX, ALIGN)\ +H264_MC_H(OPNAME, SIZE, MMX, ALIGN)\ + +#define H264_MC_C_V_H_HV(OPNAME, SIZE, MMX, ALIGN) \ H264_MC_C(OPNAME, SIZE, MMX, ALIGN)\ H264_MC_V(OPNAME, SIZE, MMX, ALIGN)\ H264_MC_H(OPNAME, SIZE, MMX, ALIGN)\ @@ -372,13 +376,9 @@ static void OPNAME ## h264_qpel ## SIZE ## _mc32_ ## MMX(uint8_t *dst, const uin ff_ ## OPNAME ## pixels ## SIZE ## _l2_shift5_mmxext(dst, halfV+3, halfHV, stride, SIZE, SIZE);\ }\ -#define H264_MC_4816(MMX)\ -H264_MC(put_, 4, MMX, 8)\ -H264_MC(put_, 8, MMX, 8)\ -H264_MC(put_, 16,MMX, 8)\ -H264_MC(avg_, 4, MMX, 8)\ -H264_MC(avg_, 8, MMX, 8)\ -H264_MC(avg_, 16,MMX, 8)\ +#define H264_MC(QPEL, SIZE, MMX, ALIGN)\ +QPEL(put_, SIZE, MMX, ALIGN) \ +QPEL(avg_, SIZE, MMX, ALIGN) \ #define H264_MC_816(QPEL, XMM)\ QPEL(put_, 8, XMM, 16)\ @@ -397,7 +397,14 @@ QPEL_H264_H_XMM(avg_,AVG_MMXEXT_OP, ssse3) QPEL_H264_HV_XMM(put_, PUT_OP, ssse3) QPEL_H264_HV_XMM(avg_,AVG_MMXEXT_OP, ssse3) -H264_MC_4816(mmxext) +H264_MC(H264_MC_C_V_H_HV, 4, mmxext, 8) +#if ARCH_X86_32 +H264_MC(H264_MC_C_V_H_HV, 8, mmxext, 8) +H264_MC(H264_MC_C_V_H_HV, 16, mmxext, 8) +#else +H264_MC(H264_MC_C_H, 8, mmxext, 8) +H264_MC(H264_MC_C_H, 16, mmxext, 8) +#endif H264_MC_816(H264_MC_V, sse2) H264_MC_816(H264_MC_HV, sse2) H264_MC_816(H264_MC_H, ssse3) @@ -499,12 +506,16 @@ QPEL16(mmxext) #endif /* HAVE_X86ASM */ -#define SET_QPEL_FUNCS(PFX, IDX, SIZE, CPU, PREFIX) \ +#define SET_QPEL_FUNCS0123(PFX, IDX, SIZE, CPU, PREFIX) \ do { \ c->PFX ## _pixels_tab[IDX][ 0] = PREFIX ## PFX ## SIZE ## _mc00_ ## CPU; \ c->PFX ## _pixels_tab[IDX][ 1] = PREFIX ## PFX ## SIZE ## _mc10_ ## CPU; \ c->PFX ## _pixels_tab[IDX][ 2] = PREFIX ## PFX ## SIZE ## _mc20_ ## CPU; \ c->PFX ## _pixels_tab[IDX][ 3] = PREFIX ## PFX ## SIZE ## _mc30_ ## CPU; \ + } while (0) +#define SET_QPEL_FUNCS(PFX, IDX, SIZE, CPU, PREFIX) \ + do { \ + SET_QPEL_FUNCS0123(PFX, IDX, SIZE, CPU, PREFIX); \ c->PFX ## _pixels_tab[IDX][ 4] = PREFIX ## PFX ## SIZE ## _mc01_ ## CPU; \ c->PFX ## _pixels_tab[IDX][ 5] = PREFIX ## PFX ## SIZE ## _mc11_ ## CPU; \ c->PFX ## _pixels_tab[IDX][ 6] = PREFIX ## PFX ## SIZE ## _mc21_ ## CPU; \ @@ -543,11 +554,16 @@ av_cold void ff_h264qpel_init_x86(H264QpelContext *c, int bit_depth) if (EXTERNAL_MMXEXT(cpu_flags)) { if (!high_bit_depth) { - SET_QPEL_FUNCS(put_h264_qpel, 0, 16, mmxext, ); - SET_QPEL_FUNCS(put_h264_qpel, 1, 8, mmxext, ); +#if ARCH_X86_32 +#define SET_MMXEXT_QPEL_FUNCS(PFX, IDX, SIZE, CPU, PREFIX) SET_QPEL_FUNCS(PFX, IDX, SIZE, CPU, PREFIX) +#else +#define SET_MMXEXT_QPEL_FUNCS(PFX, IDX, SIZE, CPU, PREFIX) SET_QPEL_FUNCS0123(PFX, IDX, SIZE, CPU, PREFIX) +#endif + SET_MMXEXT_QPEL_FUNCS(put_h264_qpel, 0, 16, mmxext, ); + SET_MMXEXT_QPEL_FUNCS(put_h264_qpel, 1, 8, mmxext, ); SET_QPEL_FUNCS(put_h264_qpel, 2, 4, mmxext, ); - SET_QPEL_FUNCS(avg_h264_qpel, 0, 16, mmxext, ); - SET_QPEL_FUNCS(avg_h264_qpel, 1, 8, mmxext, ); + SET_MMXEXT_QPEL_FUNCS(avg_h264_qpel, 0, 16, mmxext, ); + SET_MMXEXT_QPEL_FUNCS(avg_h264_qpel, 1, 8, mmxext, ); SET_QPEL_FUNCS(avg_h264_qpel, 2, 4, mmxext, ); } else if (bit_depth == 10) { #if ARCH_X86_32 diff --git a/libavcodec/x86/h264_qpel_8bit.asm b/libavcodec/x86/h264_qpel_8bit.asm index 03c7d88f8c..72e98248d8 100644 --- a/libavcodec/x86/h264_qpel_8bit.asm +++ b/libavcodec/x86/h264_qpel_8bit.asm @@ -461,9 +461,11 @@ cglobal %1_h264_qpel8or16_v_lowpass_op, 5,5,8 ; dst, src, dstStride, srcStride, REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext QPEL8OR16_V_LOWPASS_OP put QPEL8OR16_V_LOWPASS_OP avg +%endif INIT_XMM sse2 QPEL8OR16_V_LOWPASS_OP put @@ -581,8 +583,10 @@ cglobal %1_h264_qpel8or16_hv1_lowpass_op, 4,4,8 ; src, tmp, srcStride, size REP_RET %endmacro +%if ARCH_X86_32 INIT_MMX mmxext QPEL8OR16_HV1_LOWPASS_OP put +%endif INIT_XMM sse2 QPEL8OR16_HV1_LOWPASS_OP put From patchwork Thu Jun 9 23:55:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36132 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656103pzj; Thu, 9 Jun 2022 17:01:41 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwF6GwMT6osiWksYf3e0b2AmXYqDh42cXhOwEWjytEJSAfUHw7SqoF3mVgS7C6ulXcdkuaV X-Received: by 2002:a17:907:3d8a:b0:70e:6b1:b004 with SMTP id he10-20020a1709073d8a00b0070e06b1b004mr33762728ejc.61.1654819301180; Thu, 09 Jun 2022 17:01:41 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id di8-20020a170906730800b007120a60b38csi315400ejc.568.2022.06.09.17.01.40; Thu, 09 Jun 2022 17:01:41 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=EDaP293R; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 3CC0468B929; Fri, 10 Jun 2022 02:57:24 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073052.outbound.protection.outlook.com [40.92.73.52]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 96EBE68B927 for ; Fri, 10 Jun 2022 02:57:22 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JuLFqvFnIVi1hTV9dPvGITDV2wTkzKD3mlpGgWBJjhEACb6yyxFw5U8FRzUE97ZlpCM06v2TMxE9r3iaEAInQsfnmO3LYzmLPbakiChfXY85k98ToPIvsUf1fHUOJ1NvA0osmwfjZ5y1np1vagKnkBZgpM70aemNZ/UuOlckVH2wyHao59PVzzifOk5Uk3YGxj0vAjhE7CBsFtZbSMYfruEUAVvXAM12rL6avr5Llb3BY0usZu6YJJFknKmF6h9+eEwF32rqUALm72t7q6hR9gwU/8znWelTlWctpPYbW2gyHwv1y3Jfm47aK5Yh6sJewRHpLKl/p2/Tv28K+snrRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=s40nEzTx8PSZ/WcMsXNLsXYTJJxK9UuljFjCwQ01/i4=; b=nSr4n1ycc81XPpVPd2NQKh8PRIXJM68yDVpO4jtk1SNdrLDLV5GAnZh6Xlo9hhbIQfOrxWomxDD43zCceN9oiemjoQa1db+ahjfkm9bI57Bu1OYW0uz1nLvFqd31XzvFMyWYZxYHTRcdE4dKCcmGdz699LicmNXe2W+o/ahxLV+8QiC+MR8XFdN45VfUqyVOZV0hO9ag6d+forbLTSDJpkqCmLbe/JpBuR705LU+ZV0f88TXfmR7MlPvovvXKTbkQrpcDO29BR/A1asy/KpKhU6gT6bUtxu9TZjGthvYCqzywXpIRYyrCfLj7KU4oSc2rWbczC2eAHlGm8q+OV4T5g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=s40nEzTx8PSZ/WcMsXNLsXYTJJxK9UuljFjCwQ01/i4=; b=EDaP293RTupX0kxy/27Vx6vAqGC90eN8uFpxdeQYWD6zZPnSu7xjSxWU0W8gQgVzbVGu2amrd8CsoIizYWybT6HfEkHIkVxK1osio3aIOXxFXPvJyvXPHXLA9lwAgaVTxtVe6qOiuHjiopjMtOv6RavMbY1X0UpcOnNKdPx+XcYiyVMs8lZNk4s78sm7L8V3DyfQfcMHloaaATCupjjZlzfj5iAM/KpTFMPTIuFYi49lUhZseb5tYpgxMc9dCoyihFd+wNhsKJ7YEPbqbkHA0qLHv2AnoiMv0vBNj+wTQKDHzn01AwdgqLbhXkYFuGjqRrjuR86lzfHCo/Jss4IHJQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:20 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:20 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:16 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [64Nrs4oH4TRu40F0hLFgzZK+KB9we5yl] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-34-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 29e1c6a9-ee64-40c2-2e1e-08da4a73ca90 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKLkAYCmHAduU3v4IIh4OQCHCavelasmOMjKdbR0S9nCd1bbZNbQQaDy1vqti8ey8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+Kl74PTLYpbJkzGn/Oa0tXLmvzQ1Q1hvXYyAVw3yLwpFSq75FBCYhVyAuGDy/xTCF4YK5m8v9/z2FPRs1NDjaaAyvSf+u7vtd9EUiShLUSEUwU9sGGfNfzhwkeg6AgfjFNeB1lGNsrEMvNN7e/7DoP7X2+5kpzAeaCQYA0kiK8Cr4tUL5j0v68zakFx4wqToY8i18lFE2sGlhstQZXple+iCg5TbuOdJ0bs6vfmjbV83+tXih8ZDewuT8/zGxyuS7YE+Urtdl7Wm3kY4bAYR8LreEzSvmBZa/JZXeD0PPnhAkkMEX+IdXAXJsxcf91y9uk1cnzlYtN77l/kqgTh7t1KN94OiKPE1qCKl1WR7pcifUJeuyPx5xjfCyUV9tW2+YEzC2nIo+o2YIaupg1GYUoGEsb5YVEriExq0n/+FAubsVHr7fZVNSH4KEkyn1oS4TLDA9jUn3LOL0ei7OtDEh8ZDcrrXxA5MACWoU2ebKe6/njFDQJsAudIP0fF2+odUyl2kwHmUkNLaHxee4JiP60HASa4zq7JJYhJm9SMg5c9NUPoKA4Prr7Jsrh+j7mW8AALip6LUNB7/uo9bw3ozQKqTPey77vDoFtMJz955+jnndNqYKxcRgOdp2DJ3uljtlDeFmVjRnVyc5yrZwv9vTN0ligaKDVUG+qo4tZAQcj4IC6yR86ln83+89W5XY0PKxRIUu53FBAUb2hQVgHXdhDAWCb/9lKqzkBBzUvdxMl4NJoWhykxVQrw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 29e1c6a9-ee64-40c2-2e1e-08da4a73ca90 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:20.8675 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 34/41] avcodec/x86/h264chroma_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: bw8dM5683ONk x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the 3dnow implementation (which is overridden by the MMXEXT specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavcodec/x86/h264_chromamc.asm | 4 ++-- libavcodec/x86/h264chroma_init.c | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/libavcodec/x86/h264_chromamc.asm b/libavcodec/x86/h264_chromamc.asm index d59c183371..5704deed1c 100644 --- a/libavcodec/x86/h264_chromamc.asm +++ b/libavcodec/x86/h264_chromamc.asm @@ -446,14 +446,14 @@ chroma_mc4_mmx_func avg, h264 chroma_mc4_mmx_func avg, rv40 chroma_mc2_mmx_func avg, h264 +%if ARCH_X86_32 INIT_MMX 3dnow chroma_mc8_mmx_func avg, h264, _rnd -%if ARCH_X86_32 chroma_mc8_mmx_func avg, vc1, _nornd chroma_mc8_mmx_func avg, rv40 chroma_mc4_mmx_func avg, rv40 -%endif chroma_mc4_mmx_func avg, h264 +%endif %macro chroma_mc8_ssse3_func 2-3 cglobal %1_%2_chroma_mc8%3, 6, 7, 8 diff --git a/libavcodec/x86/h264chroma_init.c b/libavcodec/x86/h264chroma_init.c index 36bf29df02..26883d57e9 100644 --- a/libavcodec/x86/h264chroma_init.c +++ b/libavcodec/x86/h264chroma_init.c @@ -77,10 +77,12 @@ av_cold void ff_h264chroma_init_x86(H264ChromaContext *c, int bit_depth) c->put_h264_chroma_pixels_tab[1] = ff_put_h264_chroma_mc4_mmx; } +#if ARCH_X86_32 if (EXTERNAL_AMD3DNOW(cpu_flags) && !high_bit_depth) { c->avg_h264_chroma_pixels_tab[0] = ff_avg_h264_chroma_mc8_rnd_3dnow; c->avg_h264_chroma_pixels_tab[1] = ff_avg_h264_chroma_mc4_3dnow; } +#endif if (EXTERNAL_MMXEXT(cpu_flags) && !high_bit_depth) { c->avg_h264_chroma_pixels_tab[0] = ff_avg_h264_chroma_mc8_rnd_mmxext; From patchwork Thu Jun 9 23:55:17 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36133 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656164pzj; Thu, 9 Jun 2022 17:01:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxb5OGW2dD3ZxKzEgSrL/C1ShDfr/HYBc5+sTdx6DzwoHBUrONVjN5zqJtMiBF4rbsfvheh X-Received: by 2002:aa7:ce96:0:b0:42d:e1ae:6815 with SMTP id y22-20020aa7ce96000000b0042de1ae6815mr47939147edv.109.1654819312812; Thu, 09 Jun 2022 17:01:52 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id du14-20020a17090772ce00b00707e0e3cd7csi28291105ejc.359.2022.06.09.17.01.52; Thu, 09 Jun 2022 17:01:52 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=UmYbAplx; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 28C1268B92A; Fri, 10 Jun 2022 02:57:25 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073025.outbound.protection.outlook.com [40.92.73.25]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3A7C368B83C for ; Fri, 10 Jun 2022 02:57:23 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=BgU7KjfM+azWHqhgNuoFeOg9vGGgk5fI1jdI/q+ek7CF6HkRBU4Bl7oPN0zA8Gjhzo87WDdT9sqgt6h1GbWoextvaG4HVjuTNwYckaMg8xa/l0eJAoJf7yv1U7DW6RfBdNjpzaS03OhhRrtV7CmUspNPUR6yjZ+pGFXvzb+vqvgIEYG2mQwiHu6cZVrfpXnVkz/ishaGU3uwqW8sC1ySwLG60iu7e5caXYDtjjwvFvSSae9RJD/tOnUqzcq8SW99cnL/nN5dFNAQJGwSRuZ9pWvCgL+/DmkR9UyY+4PyJU5SGCd33FTdYrYbAQew5uNn6gHaAVJQXyvLOFWd3V5PlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2MFknlYTAnsXE1XeYKgstMLf8pnSf/q86Sc4FpA0uqs=; b=huqu/Oom3TkzJUCd/7zc4KDFOwWe+QgkFvDBlrm8slKBXArKERa2JeoQQvIsojr60yOpxuEDEq/G1D8dusyvUz3T91mYhzzRgP2mPbpyrxWM6hBaNAzprXkKpXbeo+HJDm8b+ERnUn029ssVx+N+E7KdZSOUOolFq59BFWP63WmPnvXpCjqAOwRfuEeVhV/7ZVqeJZ4KIP5X1Z6uopBgH8cjHMpucQnA8AUqS9r32FgQ/So5p/l7enYJFrrw6e1ye+FR4gNSWOF4xv/3oche/S6zOQkANPy/Cjt5RMZwX3j4r16nSLPu+YZreWTNK71xuj5k6eZj+uSrypNv+5KtSw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2MFknlYTAnsXE1XeYKgstMLf8pnSf/q86Sc4FpA0uqs=; b=UmYbAplxl1iZHzAd7ZhJ368L5PHUxr08ynhmvkdVvC3+VD2rMOt5zRs7oPehbUvh9NpIl/1eDBpBcDgjz5eZXJVFOwz6TEYHbjWsPgfkMKvQiMF0fHSU2ww9XcnNUSv5nBY9ma3+DloKbHW2nVXeCnymf49ILpGnuJEzIjmV5ts4hKG++7OLYaoNcwI2TDJcjS4YXfWik0qXWy5351CLM15TTKN3xT5n1dqs4+wvlr1QtExTUmsvQuZASX/s4z6nMhXqvjtPwD5vM3Aw7HgTNaRB61+wAvqhASnw/e631M4AObaS/URrm0GV9zgKVsBMrtYVBjPa45LvAJfmYfBqig== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:22 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:22 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:17 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [229aARcGDWCqKRy9lp9zbGQLeMYaJ27O] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-35-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5d4d3d66-7cf2-4e8e-3642-08da4a73cb9b X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKoG+8R97yWywWP82rv3sd0TcZk9hIJ84VGxT44JwbcY2YaUjDUzek7ig6LPMZTMfkxuEIj/LqClZTAudcs1nxrdaSSRPnlR8ZP/7qDkfwzBABKKHWz6fVUXKL7yKqNPj0Z5k//Hdqoionro8N7pGsBxTMTvXGereKgCyt3Nn6iqqgSB21/yVpqWy7cUPsIbtsilmeleF7RIjwF/YWKxBGzpcwc0BuSy+B7NWQKbSuoj3xbvCsezQZdYOa+3xwJd/Fsvkp/XT+6UTCex9fU0qK6FJxluAnqoUrbNatgJQIwDViVEfn4gGISM8Y1slZGaeXbN42h+cjb/SEc1Y1xkgaZ88AGXtT9539G1KyqhcjiLEiLPrJcNJEab5ixXPMuZ90ltBRUA6isj8hFZyWXelqeI0Bz9cV8Fs4ZciRmAy2X32M+qSxHZsmUvlWPyHuDwDLzknIaTuS2xn8bLtyM6kKQFMnN0DQJnVDWbObjMy0RY+IyC4MEO8kWpNWx1nJqauY9Sw2XhMUUVLE+2TK+NmVDvP7ayRVR6ucmsefB+krEf0NKzZYbbaJ+Tv+vpz2kh3Fh9lzW6dOr03xIStREZ7uig1ubE9Z14a5zO943Dg6HpR3WnfRcQDbKU+MKEdtiRwhF6mZX17bBCW8PpaFA/Ym7Dtjr70XkFkMhLycmKw4PB4z5eeae0SJ419AcG2nLLQ5cJmNxFppbsIHJ7IbaWchvcFuq3YuoTX1mBkh6QHVeak= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 7UY/bOL3RpjVY/U7xs9Nwok5xLYyx0R/AgBnfyx+PWpFelTR30Oyp262XV/U+EN6Fu8BtIRoyHj1vOjYB77l7OAPYSzkIgO2MAGyN48ow25eCOQKXb/Gha7kEibg/7ofknK3FpEo8GuEDIyyQIdOE0RJxRtCSEr2O0VmELX1uc73Lj4yLM3NorU23sej4Oxrs4XJKNf1OW7uUadwGcRpUQ9w0okOqBCPEmr5fDOdG4j39C9Z5IhttvedwL8+sfN77/hd/KEnqI4BVQ0F6pcvW+nE42+tHB9sNDQqPQjC7X0l63ShwLvTdv3eOd7tKUsIIzaKWytZI+JMTXOqUHXvgRb7c7raDjeKOHMDH8fxy/hq4ShnXCzHakq2Cz2+FyeKWO4qMKbOP5mssCnPiUDvCbDfzhfRzHFD30RSUV/TURY6USnP5aUJmTfFLycuZJJhMxk9LLqnOJdU5Fc5Gai/arKlvUckTGmEVAXsHql4C9Kvo/f/3hUnIcYDEBf5XYG+AygkoTBBuPkF2ylJsvqZqk0zauVPQZ4JpCA+5QzGR7C0kokxKKUz0Eb6Z2hYvrOUn4bZTAf2E1/H+mGkG+6P0w== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: SdxUW9nc0uhE3Yoe9+RiIymGybucq6PCFhyLeRT+cBM55KP2X3Kg08IJ1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trl7W7kCVDNMjD+8hCfTFZu8YnBgODO6YdmXllFQ+EQYJpKGQdo+AwNZQfC69tEAqxDzAvxQvaYhSHuDmOvtTXm7E81LoI1+akyUlssRLI2yXqHnv9K82qTi5PT6iS2WwdPV0APOSmADXSf/7S7BLu22Ce8IOZhmMypeM2h96vexqIb8yhSpFKPw/VGKyUd3peb1PEfkdvQ6tcAbhQ/QqSfjy/Ath4LWwGOaSFve2aLb6oODMTo4BjV27y2y00xyCw6iqOkCjXbhohoUSqnG5PFivgZNAVgF0io8utxWRWvGMWuvgm5VJ1Lhax/e7R6p2qMtPG X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5d4d3d66-7cf2-4e8e-3642-08da4a73cb9b X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:22.6331 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 35/41] swresample/x86/audio_convert_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 4xwB62vSU2aa x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libswresample/x86/audio_convert.asm | 2 ++ libswresample/x86/audio_convert_init.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/libswresample/x86/audio_convert.asm b/libswresample/x86/audio_convert.asm index d441636d3c..d2413f9f04 100644 --- a/libswresample/x86/audio_convert.asm +++ b/libswresample/x86/audio_convert.asm @@ -608,6 +608,7 @@ pack_8ch_%2_to_%1_u_int %+ SUFFIX: %macro NOP_N 0-6 %endmacro +%if ARCH_X86_32 INIT_MMX mmx CONV int32, int16, u, 2, 1, INT16_TO_INT32_N, NOP_N CONV int32, int16, a, 2, 1, INT16_TO_INT32_N, NOP_N @@ -616,6 +617,7 @@ CONV int16, int32, a, 1, 2, INT32_TO_INT16_N, NOP_N PACK_6CH float, float, u, 2, 2, 0, NOP_N, NOP_N PACK_6CH float, float, a, 2, 2, 0, NOP_N, NOP_N +%endif INIT_XMM sse PACK_6CH float, float, u, 2, 2, 7, NOP_N, NOP_N diff --git a/libswresample/x86/audio_convert_init.c b/libswresample/x86/audio_convert_init.c index a7d5ab89f8..7728c9ae00 100644 --- a/libswresample/x86/audio_convert_init.c +++ b/libswresample/x86/audio_convert_init.c @@ -52,15 +52,19 @@ av_cold void swri_audio_convert_init_x86(struct AudioConvert *ac, ac->simd_f = ff_int32_to_int16_a_ ## cap;\ } +#if ARCH_X86_32 MULTI_CAPS_FUNC(MMX, mmx) +#endif MULTI_CAPS_FUNC(SSE2, sse2) +#if ARCH_X86_32 if(EXTERNAL_MMX(mm_flags)) { if(channels == 6) { if( out_fmt == AV_SAMPLE_FMT_FLT && in_fmt == AV_SAMPLE_FMT_FLTP || out_fmt == AV_SAMPLE_FMT_S32 && in_fmt == AV_SAMPLE_FMT_S32P) ac->simd_f = ff_pack_6ch_float_to_float_a_mmx; } } +#endif if(EXTERNAL_SSE(mm_flags)) { if(channels == 6) { if( out_fmt == AV_SAMPLE_FMT_FLT && in_fmt == AV_SAMPLE_FMT_FLTP || out_fmt == AV_SAMPLE_FMT_S32 && in_fmt == AV_SAMPLE_FMT_S32P) From patchwork Thu Jun 9 23:55:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36134 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656246pzj; Thu, 9 Jun 2022 17:02:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzE47E/W14hoVRMRuaQdCnoZAJ6NNYNe+HDElHOWfrFHvgs7GACd4nqo1F5GyqokfuBpgAZ X-Received: by 2002:a17:906:58d2:b0:6fd:daa7:3a6e with SMTP id e18-20020a17090658d200b006fddaa73a6emr38103692ejs.0.1654819324613; Thu, 09 Jun 2022 17:02:04 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id s1-20020a17090699c100b0070b60b92455si6758896ejn.240.2022.06.09.17.02.03; Thu, 09 Jun 2022 17:02:04 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=QpPyTdJ7; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2293568B92F; Fri, 10 Jun 2022 02:57:39 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073052.outbound.protection.outlook.com [40.92.73.52]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 869AE68B937 for ; Fri, 10 Jun 2022 02:57:32 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KLRfLZvfRHs02seBnKok0qs5yjTEXEx/jKN5vV5GSABTUbpkPkb2axoillbEXdF5sr5ZxiMSuVdaICKt7NuepneUDIkJc9R27xjJiqF4U1IOrQH+Ssxro7yekGWVTxcZYqYtLbOTaKNzuuWQIGBPqAGx4bmLKGx4dG7vjooXCZ3WmxmZL4K2v6ZTKibXcSNDomjlvLX/tUkV9nc9WE7HZsU9BXIcolX2Z6yksNwkziBfqk5MBdZEul50uOkZhuqkdelBANKure7POwYOWpN8qpQlLveJp0n3hV6aZi1vWsahcoOpfV5eIrZSBQcX1X2xlmP1+avxqeVrwSRpkE2OlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=xHVEnHzjzqMUacivAbnh39H58n/KLfJsRKRtqTLIRDs=; b=e4B35iKLxx6ygSI/cwjLkzNxxtpBbt83Pr1WCdBQ15+JQJIpTVRseFKH5CjBOMdMTXIaBN/obKbvS/IDuh13ZV3Gyc22ybIlm8MUOdlAW7oieujQOn5lFkWhMgCsFli1dkrK2W6IVJv7a+QUbDOlo0VFEmYmO8Mk3KpVwIKEJYyGdGvDDWE9Ba2YprbrmFQF/F+LW+s6wJt0C3oukZDogPhDeEn65cvl3Gc/DJ4NqkdM4gTyhlVcImFXzaT8bAp1VCWoaJHmI97fT3MbZqUTB1vMBL3rgLmIDi/QTLhomrN/dMhfILyfB8qmcCasoGrgpAv6FXWLU0xU6CzL7fTO1Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xHVEnHzjzqMUacivAbnh39H58n/KLfJsRKRtqTLIRDs=; b=QpPyTdJ7EHlOZg75L7naAGwWsYkdLzaJ8+GjEsVaQYXol8tABBZhYrx0APWDnGRqk7FxftPdnnYjEbll84fLjT+iFRlEpeHvp4TlT/6EvDOnHimRegPnBgpVPV1ovu+9tQQXlW5cKvnNfSub+xC6W2JmlNghL099dCPg9ajAYwCMYYxNw12MNU1pWbRegX1WsGFtW3MZYQnKzRbkANPcNxnKraSJSrlyBRwrNpihuSC9iiiktxkBRG5I1igAKKfPQwylEje01P6KpneHdySKlrDqDJdCEuGN0fb1qvwMmbpd/p8GBUZ/2uXTwJVCTZy74Z5EY4uL2emY5wodAVXLlw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:31 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:31 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:18 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [GkPxjhOVBhMt1LbXRHNlZDYJWby1vEr0] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-36-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: fb955a58-97e6-4bd1-7223-08da4a73d0e5 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKLkAYCmHAduU3v4IIh4OQCKCyJ2tdAL8wnJAwzLYzxgoweCt7+kBiJtfrzycGSj/zf56SgcrBpq0DuqH731u6vOcGoT3W6fxyfYnktiLx9Y/Uw11AtejranVI4Ll6VfDK0r+a1uEBCEme3HWn8f85TLHAmjxFGOLD86Tv9jzHVRyJOEOT2/3pgkVjAqdWwO/qFKPS4WyskkXUBetKniDi1Ysk7+EoGa232+eVbgCMAMg8BnFJZbwIHA7lpYI/VUc2vc4Cvue7gP2dcW9lPpOMToxnazo9hbiJrPIEOINxTq7r70ujsQEKmmac0pwsBaI7Aa/5VVgVziTTyZCfEjIoyudX5TNKbF/37mhdGNiJJAmda9AIJrLnnekt0RGPHCEZhm25FjEv7hpUWQ9cGCArnfpGr8vYK7ybJO7pZhPU7XZ0hD68gO3WC9tx1KfRcwu+XdY9CXwjFamEzGH19BLaM1F+NCzstJxRyxG84oHHk9sODp2kUzl5z9q7PBtNsuBiSZz6RidHEKLOddzV4mhWgOQxYKyfZgU3j4veXnzVWUAFyCZta6DLujIuUlXAnwt8h73dU4sp3ZwqNHnjQc81nJ1kA//SpAgkBGGTFF1EEjZQ9PR2Vy4CTrjSXeMVjkVE24Eu4Ut67oRYs32rWnTj5/NgBn/iRlTp0IsyJrCPXUpMODy5vHEiJCTxQCVLpI9QQUAxRDbA+B9fG8dQR8mmpxAI8uCOk28O+qRYNidg39M= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: fA1u3BiWc4qeRP5RR29o8IIFDYxe0EoX4JGm1n7SkOirNQQGR88v56SHqfLrBX/u7Qm8TuSSUtubn7/WJJpc8qWZgs4ol4HBYr+cbzJQtOZEUBnXV8Z2eAOBUyBGUvcshpLJ/hRtWGIjy0Lv+AxVyF71x2CqJObpsyuII8Xlddr8BcWv+w86whZuBwpgkNX3LXpcb925uF8K7K3lXrim3umeSnJbzeJQ22NxYY3mwedA6HKsHq/o5REzgK2PCbP7YWQYjWCzUQqWtK3BbZIXkGYKt16OCHf3YrMPgtL6XbpxIBsbgiHhbXy5AU3xwTX4MgjwXcoRgQHfHpRU+C4kC3PvEV+ZmlpzhG2UlYfMZeSetSseO0VPaxYjplKG4ahCWcrMaXJ0zJ72esMx2AMgv2oOvxil8mlGFxoMGGWBuCFjV3T3eW6uNmztOPRqOs7K25lZKO3at6tk+PJjEOF/54STtas1ch3FXFSg+0sFjjX+nnxx6DA7Zdain04YviK2uVQVWZRABnQlCVTmjnmWjBArw/XiG6WEWpnoWcYyvVu1mDf+8+C+/Eg6b4pT6m+EKEpBVezaTZb6e7DpyB4+wg== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: WSwar6bBmquUsHISPD3sS2wigBUKZTf4Ey35xpPcnURbK3zSn3ZBYeO3g6aaLZJGhUb7ABdOh3AgaXPPWss2/8SZdqtQM+tLoP34pGqxX+pnjlAr76lm20M3fdPbYIPpy3mSZNt4qgUQvIKAofhsbkdQsBMuo8aPAfZs4DTRyQOSfaqvu6xUVMqIZQLMSAW7j6eR4xc7Lw0h0IBDrQrTvTVeaU15MmJjOhAYv/Krg7FyVeCHGbsSF33bPeXAVQRW2YRclXve0BekYVskKHB/hmb7Xd2A/7x0yqjuettLhb68AGw1FsSUlxodOfCJFK8/aUzOg5vUhVG/fpMsst/slr8sU5AiGgKUJoYqWrRg5+my7XE2D56GNYAebo3y317ICGr+SXc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7kQ1WHde+SU81+C7w== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: fb955a58-97e6-4bd1-7223-08da4a73d0e5 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:31.5082 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 36/41] swresample/x86/rematrix_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: bMWuy6F04IwT x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by the SSE2 specific implementation) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libswresample/x86/rematrix.asm | 2 ++ libswresample/x86/rematrix_init.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/libswresample/x86/rematrix.asm b/libswresample/x86/rematrix.asm index 7984b9a729..1c657ff72f 100644 --- a/libswresample/x86/rematrix.asm +++ b/libswresample/x86/rematrix.asm @@ -223,11 +223,13 @@ mix_2_1_int16_u_int %+ SUFFIX: %endmacro +%if ARCH_X86_32 INIT_MMX mmx MIX1_INT16 u MIX1_INT16 a MIX2_INT16 u MIX2_INT16 a +%endif INIT_XMM sse MIX2_FLT u diff --git a/libswresample/x86/rematrix_init.c b/libswresample/x86/rematrix_init.c index 0608c74e7f..3981de4277 100644 --- a/libswresample/x86/rematrix_init.c +++ b/libswresample/x86/rematrix_init.c @@ -43,10 +43,12 @@ av_cold int swri_rematrix_init_x86(struct SwrContext *s){ s->mix_2_1_simd = NULL; if (s->midbuf.fmt == AV_SAMPLE_FMT_S16P){ +#if ARCH_X86_32 if(EXTERNAL_MMX(mm_flags)) { s->mix_1_1_simd = ff_mix_1_1_a_int16_mmx; s->mix_2_1_simd = ff_mix_2_1_a_int16_mmx; } +#endif if(EXTERNAL_SSE2(mm_flags)) { s->mix_1_1_simd = ff_mix_1_1_a_int16_sse2; s->mix_2_1_simd = ff_mix_2_1_a_int16_sse2; From patchwork Thu Jun 9 23:55:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36135 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656342pzj; Thu, 9 Jun 2022 17:02:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxdjmEIJeo/F6FJmM3OrAnf/6K9VjWUK7C4eN6WR0vZwavVekbwU/e1y0cZKqI7lGjzceRY X-Received: by 2002:a17:906:a45a:b0:711:d546:478f with SMTP id cb26-20020a170906a45a00b00711d546478fmr19210527ejb.741.1654819335455; Thu, 09 Jun 2022 17:02:15 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id qa42-20020a17090786aa00b006dff4dd30f9si11604970ejc.862.2022.06.09.17.02.14; Thu, 09 Jun 2022 17:02:15 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=ndkUylyA; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2C10868B820; Fri, 10 Jun 2022 02:57:40 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073052.outbound.protection.outlook.com [40.92.73.52]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id CB73C68B937 for ; Fri, 10 Jun 2022 02:57:37 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=h0KY2NBdSLo3+6CMLG/aaYNQc4aIFmqP/hBzlRuSUnysZQtYdDTZHC9VlT85iVcx4GwSPlh751DVe5V1+CLPHlxuHH8V+X/oXvnWbmaRrdtFag+CrS5JT8wUJMuSNjOdPAvLKqNMfgSKHvEABIsrMmQs+vHdP+RPgyXQN+WWDrXT4obeQ8UmksKfzycpSg2dl7zfmt2PvGnCxbjyF8utKkONT0zzlrRc3FIYImRlLPxDsrOrNPiF+sLWY7O4x5qiWWNLMXFbf1fxJqZI3ioW0mzLumktxtzxtSBz0+NnYy9vg/yUxRX2+lxq44MmSlgJi8kJ88K8VLh36DoKPGHOIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=56Va3EDl1Vp30DLIU9d0p/XBWVa4baMi0ePKSchM47o=; b=P4vMDrWIXK0yiryYJDIBXTODDaP/N6tH1W+Q4Zs+36xzY7QXRY8yxKTGcdLgs9Jd2RdlYYhvSlyq0hmufpLqHNo7bACect+2pc1YcdlVnwfKrV9pnAJFIraaku5YWdpWUOwHyP6I4LKATCPBt3lApK9pFhKJtRbYECFhLXTf41Ln6HDV+Ie2dg90a26tJnlkiJhrBNP+fxW8GkDDPaaqvZEQFsp1pmsREa2BI9atIHDyBnG1tvlnkipMgLDt9PIyQ0bod+E0xB/7SS6wqyLCEbeW804yx4vTQLHh6FnInz3TAuu5xELkfa9FgNsAZTm3zKq+ofg1aQrRoFiew0l/9Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=56Va3EDl1Vp30DLIU9d0p/XBWVa4baMi0ePKSchM47o=; b=ndkUylyAFxl5w7yvSzLORmmThPEuPT7wGbdbNkANGyBjPILWPwDEnV+KvEA0Vrt+VVniUQBgVTj7dGkmkPqDzCn2691Lo84q2ja6r/frd9t5HqABqgIc1spgDbZmJRXXJYpjix3j3xQ33/DA7lOjoqdwDG2O7nWrL3lI70RyBdInDo6Fcuxx7vTtMoiywfZNiIdAcsbNSJkQwInNCxLy4nhk5OrZViqcNqkoKZAcKNeMFMW99UzyXrTlHeaFVIJjdZ2kKYg5K5vQlPW8EXQgIcamh6Fb76sNEHV5PFnkS3DdnMhFmAVEr5XPuecNrYMDkKK44X611OorbYtsoLiiUg== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:33 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:33 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:19 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [VbH0V7Jr+QRIb0wNA/cOO6E0tQtIOQ5Z] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-37-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b5df39f3-4607-48b2-f0ec-08da4a73d1e6 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKlUyWZ3/UssyWmvZ/CrdyhhwcijUPndPwrnDCx9pXZNAFgf0n+XSVhlfPS6hhLcpiveAbaxH0Gx2xDIsIXpylcnrG6luo7UGxjczRkTXbgpV82BAd4Y1KQLxc7DJxkNm09Y8vhs2tWyZ4UMzq0lgwb5zNFdJz5beXqfxBGd3WXNhQeWbc+eP7IWVhiOaP9hvixd37jElw0+7TC/UqxT4cC74/nbRJuWQuuTYgKWAli1WFRAEKT9+mDxog4xVMIwA3scNWnBD89ScGjByGAEP4dk5Pi4PrGh7gDl711tXEn9t2QEpzvR7az/S91WtgoN3WVh4QRMyiYeqWIRpwIwJZVHPklCQsKnheKqSOzYOQ/MpEvvNH15VPKFnHnxhuEyE0oSzKkOMND47HBLVYbIVzGLmADVGWVIvSearqlAP1ZZ5KDT0gdYT9I+jCAD8LMMbIkIVcLVSfI28nEZaUzGLYz2By7+wKtycq+uQIDHaMLlvxSM03HgS5oKRYdf0p/AjV22qhpjF/Kx9/EOoidla1kWj0M+6iK5qjngWfLP4+0YhxDcOZjlDzH9qTq7+HOIKQXyU5Tp0ex+Td2S+xuVV3OQGB8XGevRwgzwAfSv7Z7HjL7Ukf+XkzYrqvA/laTMUzL/CO3mzJ3s7uml2398RoCoXUC1zDI5HLOvUKCR7Xz32DtCuuuNqNxYq/qoL8mOPJzL3ObI95t+sxnZj55y63ZrTCo/opHcTV4Yyota+WhjM= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uT4CWezY9yQPDIsP/xwqjFYYSH1nuriOqVawReBPBTrmc1SDIlxPTxfF433GTASJYQH539K3FyHKwSEiZx6AgWO3Pnxh5TcB7J+iUfCtYqJnEdi3Y89SpPPXELEHkt60j5Rq/yPfm+AsreuWSAfd4A2wBULC9qbQsiFi3Gz2xqh4n1/Kxt4t3hQJfAyP1j8BS1bdncGhzuDOsATw5bRkE6oaBy8b8wpEEJhB3YuCsVckB0T6MUv4xlG4K6kz8fxvprILkXlJFzkhDbz4UAoiNCA6QntVB393JiLdF59YDchX26aIi9Db16MXz7WS6cyoM63wXdrMhCuogtaDFSCFQwDKNTF1mR5mRaUUHFWY654UKBLnN4a8d04i+Q42vOM14q4tzErVbVnde/DGOceS3BIPu2+N/Chffofp1ZhlRjqLNwtbjWM0jTKZvqT1xx6I0Zv7cBERjcOkNPUS8b+vn7SeoOiYGZ4xAJ10XOa4k6F52bmlPLZIPDLdZlDHlXudHTda4cVdRxAUE5yCeIFcEe3NISNU6ISiEfkj3WyhNofxFuprrvw0dfEBYw4tsdvxFPx4+HSp2w1pXezdYV48WA== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Uc75eGMTO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gtiuzVbSjAWxdxeiZRn245qnGn0stx024g4hQ0DqvN5hfjapYlf23N2bqIyN4sc6y8IFuKke4CeZOount4Cu93YPIMYEeTWkAV+mQl2iNOSkCIuLSjQswoYPVr0PMMxdKEwpyLkc0hFU+yh6qz/EYGQt0x81IELfpq+FpiOJvuBW7iY1a/QyQw20O/zwkyAe0NhVeLqLbafuts3IMEa7KfwJF92QrktL3uPpOpQ9RbR37CK2DcSgl5YGGW0OdyjZrYKkJSi5YKK9VIxotsmrVl4v3Ei8JMwRAxweL9NimTWuUap+IcuSkIwhEWHRLcVDrMq81/cGdFOdf2qCA8m/cZOza2lGbHB/FUlSu1t1hwC015d9kLdVTgRAjHDC9/CAgyqhjHoytpUFAesk8/dc5qSnCJIF6qdEQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: b5df39f3-4607-48b2-f0ec-08da4a73d1e6 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:33.1801 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 37/41] swscale/x86/rgb2rgb: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 6QK2/G5Pvg9i x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX and 3dnow implementations (overridden by MMXEXT) and a single MMXEXT function (overridden by SSE2) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libswscale/x86/rgb2rgb.c | 6 ++++++ libswscale/x86/rgb2rgb_template.c | 10 ++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/libswscale/x86/rgb2rgb.c b/libswscale/x86/rgb2rgb.c index 0ab139aca4..d8dfbbca35 100644 --- a/libswscale/x86/rgb2rgb.c +++ b/libswscale/x86/rgb2rgb.c @@ -91,9 +91,11 @@ DECLARE_ALIGNED(8, extern const uint64_t, ff_bgr2UVOffset); #define COMPILE_TEMPLATE_AVX 0 //MMX versions +#if ARCH_X86_32 #undef RENAME #define RENAME(a) a ## _mmx #include "rgb2rgb_template.c" +#endif // MMXEXT versions #undef RENAME @@ -116,6 +118,7 @@ DECLARE_ALIGNED(8, extern const uint64_t, ff_bgr2UVOffset); #define RENAME(a) a ## _avx #include "rgb2rgb_template.c" +#if ARCH_X86_32 //3DNOW versions #undef RENAME #undef COMPILE_TEMPLATE_MMXEXT @@ -128,6 +131,7 @@ DECLARE_ALIGNED(8, extern const uint64_t, ff_bgr2UVOffset); #define COMPILE_TEMPLATE_AMD3DNOW 1 #define RENAME(a) a ## _3dnow #include "rgb2rgb_template.c" +#endif /* RGB15->RGB16 original by Strepto/Astral @@ -165,10 +169,12 @@ av_cold void rgb2rgb_init_x86(void) int cpu_flags = av_get_cpu_flags(); #if HAVE_INLINE_ASM +#if ARCH_X86_32 if (INLINE_MMX(cpu_flags)) rgb2rgb_init_mmx(); if (INLINE_AMD3DNOW(cpu_flags)) rgb2rgb_init_3dnow(); +#endif if (INLINE_MMXEXT(cpu_flags)) rgb2rgb_init_mmxext(); if (INLINE_SSE2(cpu_flags)) diff --git a/libswscale/x86/rgb2rgb_template.c b/libswscale/x86/rgb2rgb_template.c index ae2469e663..ae7af550e0 100644 --- a/libswscale/x86/rgb2rgb_template.c +++ b/libswscale/x86/rgb2rgb_template.c @@ -1822,7 +1822,7 @@ static inline void RENAME(rgb24toyv12)(const uint8_t *src, uint8_t *ydst, uint8_ #endif /* HAVE_7REGS */ #endif /* !COMPILE_TEMPLATE_SSE2 */ -#if !COMPILE_TEMPLATE_AMD3DNOW && !COMPILE_TEMPLATE_AVX +#if !COMPILE_TEMPLATE_AMD3DNOW && !COMPILE_TEMPLATE_AVX && (ARCH_X86_32 || COMPILE_TEMPLATE_SSE2) static void RENAME(interleaveBytes)(const uint8_t *src1, const uint8_t *src2, uint8_t *dest, int width, int height, int src1Stride, int src2Stride, int dstStride) @@ -2185,7 +2185,7 @@ static void RENAME(extract_odd)(const uint8_t *src, uint8_t *dst, x86_reg count) } } -#if !COMPILE_TEMPLATE_AMD3DNOW +#if !COMPILE_TEMPLATE_AMD3DNOW && ARCH_X86_32 static void RENAME(extract_even2)(const uint8_t *src, uint8_t *dst0, uint8_t *dst1, x86_reg count) { dst0+= count; @@ -2465,7 +2465,7 @@ static void RENAME(uyvytoyuv420)(uint8_t *ydst, uint8_t *udst, uint8_t *vdst, co ); } -#if !COMPILE_TEMPLATE_AMD3DNOW +#if !COMPILE_TEMPLATE_AMD3DNOW && ARCH_X86_32 static void RENAME(uyvytoyuv422)(uint8_t *ydst, uint8_t *udst, uint8_t *vdst, const uint8_t *src, int width, int height, int lumStride, int chromStride, int srcStride) @@ -2519,7 +2519,9 @@ static av_cold void RENAME(rgb2rgb_init)(void) yuy2toyv12 = RENAME(yuy2toyv12); vu9_to_vu12 = RENAME(vu9_to_vu12); yvu9_to_yuy2 = RENAME(yvu9_to_yuy2); +#if ARCH_X86_32 uyvytoyuv422 = RENAME(uyvytoyuv422); +#endif yuyvtoyuv422 = RENAME(yuyvtoyuv422); #endif /* !COMPILE_TEMPLATE_AMD3DNOW */ @@ -2534,7 +2536,7 @@ static av_cold void RENAME(rgb2rgb_init)(void) uyvytoyuv420 = RENAME(uyvytoyuv420); #endif /* !COMPILE_TEMPLATE_SSE2 */ -#if !COMPILE_TEMPLATE_AMD3DNOW && !COMPILE_TEMPLATE_AVX +#if !COMPILE_TEMPLATE_AMD3DNOW && !COMPILE_TEMPLATE_AVX && (ARCH_X86_32 || COMPILE_TEMPLATE_SSE2) interleaveBytes = RENAME(interleaveBytes); #endif /* !COMPILE_TEMPLATE_AMD3DNOW && !COMPILE_TEMPLATE_AVX */ #if !COMPILE_TEMPLATE_AVX || HAVE_AVX_EXTERNAL From patchwork Thu Jun 9 23:55:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36136 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656446pzj; Thu, 9 Jun 2022 17:02:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzJS0476jONOtudnCuJ2PM57TP+EaOHwcAv5+EhXXe56K2kxgGK+z9UlWuJ6R2y3EfPRrW/ X-Received: by 2002:a17:906:3bd2:b0:711:ce53:5d5f with SMTP id v18-20020a1709063bd200b00711ce535d5fmr22118566ejf.500.1654819346411; Thu, 09 Jun 2022 17:02:26 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id w8-20020a05640234c800b0042b6e025f01si24693063edc.29.2022.06.09.17.02.25; Thu, 09 Jun 2022 17:02:26 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=cqAxzoMc; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 3652968B931; Fri, 10 Jun 2022 02:57:41 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073052.outbound.protection.outlook.com [40.92.73.52]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 1A01368B820 for ; Fri, 10 Jun 2022 02:57:38 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=n/0RJlhVugpUSoTF7YBlwDRlssUHavyRUzRtgNwJQR75t09BJkmvJ/o/QiGZ8V0HAdbOwB5S9WY3TlWPPpIKRkmNsDmXWGYnZLckXxVlgsD6rZjopQqoCrGC8ivE9kRIEOQx1kr/bQCoeAelmDgleif785Z2vgQmrnYuwrQRuYbgLVjAvjfgpvUW5e4eLc4PnjUls8TQPx+mXRRuAEzp4Tif6UZt2AbH9rdWEa6hOSOiTmadYzp8KEu1NxSOVRLMRQuVFk9t6jmOAH4lLvLb9glifWeu4dvTcFK6wOCmQ3eBpiBgWRNbykuoJj24T2GnpbtfRmHddaSPFUBu3+XUaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=OvS+I/OZXMteGULQqZWE3qBzOP/fzOLDZgZSogkX3Ak=; b=EhDTLIvkGZSmYH1d8IzLl37kTlKI9+TzlHjJTBaqs/FbZt9nF4tq4Ubw7OvbeoB7bI0WHVU1iPJLzTvu50TCjhxMEwUMAzePCZBClvi3Irik3ud7jo9LJinrz+0R+k+HclmDfy61ykTswXvhRYgRP2WkwBRYyaQhlgn0pZEftYipTjOPagKSvy4blaLw4zTqItE2zJapExJe5oWWWlMYCMuUZhP4/pskgbmbL0fVNu8adzKZ4QZTJnVSb9CdLEbXOnbNJCU3mVuEd2o/assSX8KrbnUji+eLgmKN9j4I15XYpGuZTHyobKgur6YvfJrMZd5vqmwt+Ps6MyY0lEty+w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OvS+I/OZXMteGULQqZWE3qBzOP/fzOLDZgZSogkX3Ak=; b=cqAxzoMcW4r+lVFYvHPxzA4LW1EiI4ceBP+hQWPY/Jlfa/RHRKn2nu6IR8GsuYiKrQSIx7dQAFq5cuqGjG1ejXLD8eEHXfgHVydkutc9okVIcDPU5wLX/aQrka1L/F0cEZzs7XOWL6Q12BeB9JsOfJ/aCq2ek1S8GhzbnpzLdj2FmQqPnfeqRMl3fYE4u8rDTe6y3+QzxRdatVHkYIzOMhqVpj1nfa/lvLO4Nn67Or7ETldkJWiqkYpurDSYuSKYAH0aw7/i76YsJF+3C+4VjxWuIteFMvbIoniModSD3o0KRbHYWZmc2Fc4P+gdAq3G1PTMuwOIQBtuX39+vaSpfA== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:34 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:34 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:20 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [CVNJv707IPUDPcys2o6/hfz8kfzuqnU1] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-38-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 1ed01510-482d-447e-e8eb-08da4a73d2a0 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKlUyWZ3/UssyWmvZ/CrdyhrEv8C1Plir70mH4ll73KFFIjKkp5G+SYM1kIdUtduLOjUjbNrupiM0o4xxzhU/UQUD4t5vel+F24XyPh7uD9lfn9Mz/S+85qsVC35wRX83bNnC5jYQua764UJEg24BTJmfBbnPzYwii0fFxmfX2OUGblj9li5x3h3rNooGD6HhMDSPCpSDjJfqBEq0jnygdQp7+gpdEHxTIN+4OAufA00gAlmB128HAzzHSIek7z6yTwx2e/eF6YwLttOjK21OPPK1o32KGRpoII8X52nBfu4aQ/EbYEybpKmoEusCoBrpXiOMTmZ6jP0xJscgawpYR7LcEDaVVAY/7dMlTnbesIYmHR3cQ9i74TZJ/XIPU1G4kY+Y5JBRzZJuPdlpnO2libKCmx/LPcfm9k6ClIDSAHG2MYfc3Kb7kyQEWUsBCBumit9PlcVqnZ+KI4p22OHwz679V6CmKexp6/uV0aT9ZTBTOTUkDwCJ8oT3s21qNrSIXaAalDXxW9TBFL194Gerne2+zbjOTE2O9B+ZjWZPGHgXsDikC9DzwjMEIQqYrvfDS8xDdTasS7QB3chmn3c8xvRFipmzPtRVLHC93kYAoLBKZTETWg7JarYtcbfhD06V5fP3rbci14CVQmmKuVjjGUu+x9z7ObUnOKfKJf+EYaYlqzAqRVP3zGmg3S3lqGtQQ6HkfFh2efDrBmy3Gh9P6zpKJK9ekTZsRgF43U+HCSm8= X-MS-TrafficTypeDiagnostic: DB6PR01MB3862:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 1vTd4JdrmADGcZlzKE6QzVVXbiZ1cQjD4+INiJ0RHW3UzdAH8IU1OCIJf24uHUCdOlXt0GuoQVVRE8q1U91MnkP721ZPJQpf4D7A7oh8ECe6WsRpOJt4uNRnwkLCet45FP3sthyx9tZZBbn1AeCfZZj+ncgIEugF5tPCWXeGujaYo6O8A4JLp/vEItMlwMKnVIgGmoAVz+sLNjKzmBDXcYP3vMWQHUT5kfkout46JB8dJn6Ax0Bi2ttrUY5NTsHAZDyMZ2kT4pPiR8ay3FLF0UD1nsEGyIhQGJdviiZlcAvToqZhSUYl4L77KMLgCo6jG8AyO5VcDnhAwIOkJUDNGUiGh/cOYdzUUjVX3IevEaDVOJS7+AcRH5pI9whE/9HbzbVQCeQQg1thiEfBHGmxfpvlKAEdBbVVQN6a4LSn/R+ni+CjMl4iybkYNuIR/8GqKDY/VRZbNFf/HGwRsmG9k/pn/ZW3u72xnXv8jnW18hzohn1gGtclXRf1DoQDz9nnpNCldlM6d5ErmDpY0VZchKtmH3/DSirIdJLXLFWo6wgaLC7BV0Bhm45f3YTIXKGNfeLA7/fyjDhRCxohXbSFag== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: KNXrR9b1kPLdd87vQ+cMv2Wl3SEgxjt9MYxqyfs2YMqYRV+6eMaDdP+HUYYD0E7NHqMWHnmd2stjG0PcETTE7Ash44iBuXfSDjbFNe9q3ZSyyqsIz3fxEASDVGD1DF9BAO6cAyjVbi6eygU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Zilz0l7rs/GBQ+sxZq2fvCSdImNQUuGvhi1nvUanTp53LJBEMKe3/j0kO7n05GizbtgVc5ongvjCzxgtXqxTSN7hCZ1DO0n//iD7Od19NRMGh8Hg4xdSNejCy4DnZrFSfiLkBrAisAAXv0C5wQO4DQyqVRHKVxeUn+3G0378zBGvsD0aF4KqKsh/jSgodCGBpSeouDoDZo0pFCi2A3Xmb22SWhGlFW83oNfl3igPzwfQOUTeidN49IDq+n6tYxcNYVlF0wK+8q/+Sx76Q== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1ed01510-482d-447e-e8eb-08da4a73d2a0 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:34.4145 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 38/41] swscale/x86/yuv2rgb: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: eL7lGjDc/gN6 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables some MMX functions that are overridden by MMXEXT at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libswscale/x86/yuv2rgb.c | 13 +++++++------ libswscale/x86/yuv2rgb_template.c | 5 +++-- libswscale/x86/yuv_2_rgb.asm | 5 +++++ 3 files changed, 15 insertions(+), 8 deletions(-) diff --git a/libswscale/x86/yuv2rgb.c b/libswscale/x86/yuv2rgb.c index 47f45bd7c2..60dcb4b7be 100644 --- a/libswscale/x86/yuv2rgb.c +++ b/libswscale/x86/yuv2rgb.c @@ -44,23 +44,22 @@ //MMX versions #if HAVE_MMX #undef RENAME -#undef COMPILE_TEMPLATE_MMXEXT -#define COMPILE_TEMPLATE_MMXEXT 0 +#define COMPILE_TEMPLATE_MMX #define RENAME(a) a ## _mmx #include "yuv2rgb_template.c" +#undef COMPILE_TEMPLATE_MMX #endif /* HAVE_MMX */ // MMXEXT versions #undef RENAME -#undef COMPILE_TEMPLATE_MMXEXT -#define COMPILE_TEMPLATE_MMXEXT 1 +#define COMPILE_TEMPLATE_MMXEXT #define RENAME(a) a ## _mmxext #include "yuv2rgb_template.c" +#undef COMPILE_TEMPLATE_MMXEXT //SSSE3 versions #undef RENAME -#undef COMPILE_TEMPLATE_MMXEXT -#define COMPILE_TEMPLATE_MMXEXT 0 +#define COMPILE_TEMPLATE_SSSE3 #define RENAME(a) a ## _ssse3 #include "yuv2rgb_template.c" @@ -127,10 +126,12 @@ av_cold SwsFunc ff_yuv2rgb_init_x86(SwsContext *c) break; } else return yuv420_bgr32_mmx; +#if ARCH_X86_32 case AV_PIX_FMT_RGB24: return yuv420_rgb24_mmx; case AV_PIX_FMT_BGR24: return yuv420_bgr24_mmx; +#endif case AV_PIX_FMT_RGB565: return yuv420_rgb16_mmx; case AV_PIX_FMT_RGB555: diff --git a/libswscale/x86/yuv2rgb_template.c b/libswscale/x86/yuv2rgb_template.c index d506f75e15..b60567b8f6 100644 --- a/libswscale/x86/yuv2rgb_template.c +++ b/libswscale/x86/yuv2rgb_template.c @@ -47,7 +47,7 @@ extern void RENAME(ff_yuv_420_bgr24)(x86_reg index, uint8_t *image, const uint8_ const uint8_t *pv_index, const uint64_t *pointer_c_dither, const uint8_t *py_2index); -#if !COMPILE_TEMPLATE_MMXEXT +#ifndef COMPILE_TEMPLATE_MMXEXT extern void RENAME(ff_yuv_420_rgb15)(x86_reg index, uint8_t *image, const uint8_t *pu_index, const uint8_t *pv_index, const uint64_t *pointer_c_dither, const uint8_t *py_2index); @@ -165,6 +165,7 @@ static inline int RENAME(yuva420_bgr32)(SwsContext *c, const uint8_t *src[], } #endif +#if ARCH_X86_32 || !defined(COMPILE_TEMPLATE_MMX) static inline int RENAME(yuv420_rgb24)(SwsContext *c, const uint8_t *src[], int srcStride[], int srcSliceY, int srcSliceH, @@ -192,4 +193,4 @@ static inline int RENAME(yuv420_bgr24)(SwsContext *c, const uint8_t *src[], } return srcSliceH; } - +#endif diff --git a/libswscale/x86/yuv_2_rgb.asm b/libswscale/x86/yuv_2_rgb.asm index f968b3a0a2..542e3cb1ab 100644 --- a/libswscale/x86/yuv_2_rgb.asm +++ b/libswscale/x86/yuv_2_rgb.asm @@ -69,6 +69,9 @@ SECTION .text %ifidn %1, yuva %define parameters index, image, pu_index, pv_index, pointer_c_dither, py_2index, pa_2index %define GPR_num 7 + %else + %define parameters index, image, pu_index, pv_index, pointer_c_dither, py_2index + %define GPR_num 6 %endif %else %define parameters index, image, pu_index, pv_index, pointer_c_dither, py_2index @@ -356,8 +359,10 @@ REP_RET %endmacro INIT_MMX mmx +%if ARCH_X86_32 yuv2rgb_fn yuv, rgb, 24 yuv2rgb_fn yuv, bgr, 24 +%endif yuv2rgb_fn yuv, rgb, 32 yuv2rgb_fn yuv, bgr, 32 yuv2rgb_fn yuva, rgb, 32 From patchwork Thu Jun 9 23:55:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36137 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656554pzj; Thu, 9 Jun 2022 17:02:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwHEyLHMv/FZKrF1uAsOrBVO/9oEfqgm4XJVZBMClRMLRluQmFiI+JJ6L+JJYw0xALMAZ/y X-Received: by 2002:a05:6402:50d0:b0:431:70e1:956 with SMTP id h16-20020a05640250d000b0043170e10956mr23196122edb.205.1654819357628; Thu, 09 Jun 2022 17:02:37 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id qb37-20020a1709077ea500b00711ed907e82si5224892ejc.492.2022.06.09.17.02.37; Thu, 09 Jun 2022 17:02:37 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=IEaaYDyh; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 2E62468B955; Fri, 10 Jun 2022 02:57:43 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073025.outbound.protection.outlook.com [40.92.73.25]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id F360D68B80F for ; Fri, 10 Jun 2022 02:57:38 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Tjon/ch6TCezJNyJflfsb658XrAkI/an5DLT1EQ+CJsC5vfZYxPKTRsUe2cHz72FwnN+ACefKWyeGCTN0j77o6+i0RqspeisdLliDgW/kKB2vfNy817sULnvKLN5mLgnwl8x35qkD6EJ+CyMWMTh4TTT0LImCjag/GgO6U957LK4rQOl8nDrtV1mDTHaKknGSzeTBbkOBqk0Pg/GzH5XXeIG1sWLXergdWdIYGR5/NTNLFKBzYUEqvweni6ZFfUFU1D/nYBu0tcUlvkA5E6glxXwM5QtgY0MCahoziVgC2sy9xUR3m3y1PJUuYNIkQV0EVuvPvQ91IaGTJ2Ct6DJeQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=k5G8p/UzyAhd/Lk/FKvdgMZ5Jbe86lzjnlcu4lI+cM4=; b=hCY1s5TOUi77lRnDpoCoxgKmZ7gr4mvI/BMTebl9H2QXYjp+ZUtCGoE7sdBBqXTFq5lNIjRWKdWKT+IpWv0uZuu+V/WYuceEFvkvXr0fZWIiNLf6zUI2ATlx/+V2b4ee736fm4jExMB3rs1mziZ0c/JJpQDM19zJCIAj4yHALC7PZSKCgnl9HbjyVfxYMkusddNtVCfjmCaXm4ICjMvycVmtzYdFpHAbsEaxOnn1/DBPmZ4EZOjO+FRcVijzqPQbcKBu3AkxOG+SR0P6HAzgpIWlRQI76kt9nHcM4uJYzwDN1vlBw+c5aP48fLQxUYm2Q4Ifi1/AJEhJeVFFGJ0Ubw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=k5G8p/UzyAhd/Lk/FKvdgMZ5Jbe86lzjnlcu4lI+cM4=; b=IEaaYDyh3CeYIgWh6RCyl7PMXT9C1+K1Xl7wC4z0iJb1vjid6uoTR2ihoUSdOEPfkeEcfP6WEwIIYxbSWCDaRkY15E4fQb/6D9Cx0qhMnotRoWwQi4bgtFeSZ4q63Sasee+VhomRBbRSiBt8rIrd6IHIyGHVm0HuwYLn9f0xAhiWItdjjziwEaqAN2qt6CxjFTwmMQwgNuE45Q5xJp80So/Y8hgaJOYp14BS5dio13pWdLTLXg+m6dljVAChZf5/VMqCzt38cFI1mY2lUgIJPE81EJnhWtfY7Pa74Wf9uhTeCd5ZFJFyDm0GNqblxCVXaw5yVvYaW2XcImi74yllYQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:37 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:37 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:21 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [ZCV0GWrMenHqyUhDrB3ImBVvucf8WWwu] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-39-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c50c38cb-ae36-45f4-374a-08da4a73d474 X-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CrossTenant-Network-Message-Id: c50c38cb-ae36-45f4-374a-08da4a73d474 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:37.4770 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 39/41] swscale/x86/swscale: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: HOtGKajsqFgi x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the MMX implementation (which is overridden by MMXEXT) at compile-time for x64. Notice that yuv2yuvX_mmx is not removed, because it is used by SSE3 and AVX2 as fallback in case of unaligned data and also for tail processing. I don't know why yuv2yuvX_mmxext isn't being used for this; an earlier version [1] of 554c2bc7086f49ef5a6a989ad6bc4bc11807eb6f used it, but the version that was eventually applied does not. [1]: https://ffmpeg.org/pipermail/ffmpeg-devel/2020-November/272124.html Signed-off-by: Andreas Rheinhardt --- There is some issue with 32bit versions of some of the MMX functions here, leading to failures with the f32le and f32be versions of gray, gbrp and gbrap. See https://fate.ffmpeg.org/report.cgi?time=20220609221253&slot=x86_32-debian-kfreebsd-gcc-4.4-cpuflags-mmx It does not affect x64 and if SSE2 is available, the MMX functions are overridden by SSE2 functions that don't suffer from this defect. This is a good reason to remove these overridden functions for x86, too. libswscale/x86/swscale.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libswscale/x86/swscale.c b/libswscale/x86/swscale.c index 73869355b8..5cc174694c 100644 --- a/libswscale/x86/swscale.c +++ b/libswscale/x86/swscale.c @@ -55,7 +55,7 @@ DECLARE_ASM_ALIGNED(8, const uint64_t, ff_w1111) = 0x0001000100010001ULL; //MMX versions -#if HAVE_MMX_INLINE +#if ARCH_X86_32 && HAVE_MMX_INLINE #undef RENAME #define COMPILE_TEMPLATE_MMXEXT 0 #define RENAME(a) a ## _mmx @@ -470,7 +470,7 @@ av_cold void ff_sws_init_swscale_x86(SwsContext *c) { int cpu_flags = av_get_cpu_flags(); -#if HAVE_MMX_INLINE +#if ARCH_X86_32 && HAVE_MMX_INLINE if (INLINE_MMX(cpu_flags)) sws_init_swscale_mmx(c); #endif @@ -479,7 +479,7 @@ av_cold void ff_sws_init_swscale_x86(SwsContext *c) sws_init_swscale_mmxext(c); #endif if(c->use_mmx_vfilter && !(c->flags & SWS_ACCURATE_RND)) { -#if HAVE_MMX_EXTERNAL +#if ARCH_X86_32 && HAVE_MMX_EXTERNAL if (EXTERNAL_MMX(cpu_flags)) c->yuv2planeX = yuv2yuvX_mmx; #endif From patchwork Thu Jun 9 23:55:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36138 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656650pzj; Thu, 9 Jun 2022 17:02:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyhcs97/RSaxcbIw2c8dUWgzsuCs/DjsuRpzXM0HcpG27lFaP7oTlbB94P6UhpdTYS98XSd X-Received: by 2002:a05:6402:542:b0:42d:c7d6:4121 with SMTP id i2-20020a056402054200b0042dc7d64121mr47232489edx.302.1654819369257; Thu, 09 Jun 2022 17:02:49 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id di9-20020a170906730900b00710c2e87a02si5425011ejc.215.2022.06.09.17.02.48; Thu, 09 Jun 2022 17:02:49 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=okR2IHBl; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 22E5B68B95D; Fri, 10 Jun 2022 02:57:44 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-oln040092073023.outbound.protection.outlook.com [40.92.73.23]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6B9B468B955 for ; Fri, 10 Jun 2022 02:57:41 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=mYsKFQ6UG3HTCt0ljMDOkLvioG9+zgtz71Wn90kqAWfbQ9BMqBB/7ARFMfdiKU4Dtw7OyHl01NL+NmxsnS3CQr/Yi/CxOiTWB+2vCojYDAu1diymxtqSxEu0xsY/WGkVq+nl8NSl5mTm/MHAfhFHd8SMjx4uMevECD3EmDuiXcCXmZXj0vtQCc2IbHpjlV6JpRZxaXWl4DTEIjDBU81UxpdPZHU4QcmERaYz2L6MFjGclO1nICDIFL2m5IKihtvksiXppu+WfuiL3MDYc4spDHUc7Qs25TXgZq5/7aER8JrNr67fRPQ0AhchPKKiKqIxL8TyT7CFs1Z7S99xO7r5Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=FrWIJK7mzLoULM8tbwNdkUlsNR3P9dHtz1zNAqUznic=; b=PjbtgMdTYXDT3dGCe7ahp4YIE1uOkWqOPjjHfTLrlpm71mZnaQ87pCm+MfKDRQAYUf7ovs1YsM25Oii5rZvOE9HwLElMNTAOh67utAvIK9bjy50B/22B4X8QyT2PZVdrVedR1d51SZDIz6t4tZwkwPmj8mmPhTRQsj8a2I+cZEXariONGL0OLdGPCd37UDgbstImzcoZ5CSonmUB72Fzn2IFyoheneFz+XacW12kW+WTs78e2yX0c2mHlPLh/GPmT2cWTu+xbbnn/I2ubu9PlpAbmUQQPm0ZUcKulZRxFuBiVJDQB16udiMVMKwPjYi5AFr4gObOWTuNEeY1bLc+/g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FrWIJK7mzLoULM8tbwNdkUlsNR3P9dHtz1zNAqUznic=; b=okR2IHBlw8z3XaME1UUDOGWlCo+Y020YSMbWvY0RlguF16xive1ldlMK4Kf+qUb+BHZ50r/FGQelSn4fg4ZatVtqSOCyWhtl/gkvuZtZmI5is3I+04ep6zmfHQhXuuvinPvIFNSew+AYLJgnQOL3a7PH6JkEb/vg4dxqqETkY2GJqRy7TJqJLbt2liGIhwdUoLk+aC3pqmPHsPotsU2cSYk5RhBQMzU1mr90YkTtIC8gjwq543/BDTdj0HP534/ckACL5VJDRIjxNUD60TwW3UIA7nk4iG9FkRd6H3pEQAjO5hcHomvBDlEfvJ0MY0RpHdDXon3BYRRj65IcRtMNIw== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by DB6PR01MB3862.eurprd01.prod.exchangelabs.com (2603:10a6:6:48::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.15; Thu, 9 Jun 2022 23:57:39 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:39 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:22 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [5WepWJU8Yxxo0k6ORKZQs+0XBHNzqk0x] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-40-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: de959d09-3d88-4ca5-5266-08da4a73d592 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lK/K0mVwNAsvsdQ0E+jHQnnTigsWHWdPlAN5UQH2UfQVakLK6ky4F63AadDKheWZV+SPDwtet07qOHP4PoVUVu+K6Qn90TmVGG8QqixVoNMflU+QgMyjZa9eb/7CW/G9ccnd5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Dyxd5CV/uYsdgEjd/djYkTKZT4JpGAP0saZtV4K0iaB9eSnudWNgZbH3g4gd3HyIrPqXaKYoup2b/j5/kSTgRJOR9rXsb40mKpi7t9Z6PStcndPxLr6Uq0u8bjk7CyCiBoRQWEAuoLWqa8hE/pkrCsVuDfNAwEdTx3whuKo1sapWW17s3LpcQR+we1bD7MzzUXy/YBrjDvHW17hblrwkvqbIA6Pm29S90e88OkcUmD+YWiziOua7EEdb+WTJUSfOHH49nPBHT+p1Im8vb1uuDA4/M/dG9MeyfQlJuLwqjlGIx6rtSFyDnjDJmW0ZsINQ4NzjVdFCPrQEF8OclvP2XWUjPSab/lSf7M/WGtKL1AxFw+6Xo/JfSaVmvBjhG0UACdn+5xFIhRf5xCyGq6nLPB8G7Ne9zPBaYLPdTmaTfA/qCYTgbppwcrwz/GpzPzrrU9lCLAjp6ykBhSN9wdGI7VIgklproT8B3vpMOjChaAC+UG8vaiXL0UIasdIObByFsBzl/9MHGqQcPalVm88B+zlh0W2RfYyK3BEQARnBg4MApGbPAFqCelIGKcbJIjXxe+k7llHl4hrE2J8+8HPp9Ck3AUaEH/thzVC4LkZL4CJtRDtDOxj4qyjoEAoisRp6IexuM5+kY80LiFi0mmqRx5hZ4HN2sfIoQ== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: de959d09-3d88-4ca5-5266-08da4a73d592 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:39.3364 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR01MB3862 Subject: [FFmpeg-devel] [PATCH 40/41] avfilter/x86/vf_eq_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: T1qlYC7xPHgw x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables process_mmxext (overridden by process_sse2) at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavfilter/x86/vf_eq.asm | 2 ++ libavfilter/x86/vf_eq_init.c | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/libavfilter/x86/vf_eq.asm b/libavfilter/x86/vf_eq.asm index a30a287029..0b55d28c6b 100644 --- a/libavfilter/x86/vf_eq.asm +++ b/libavfilter/x86/vf_eq.asm @@ -83,8 +83,10 @@ cglobal process_one_line, 5, 7, 5, src, dst, contrast, brightness, w %endmacro +%if ARCH_X86_32 INIT_MMX mmxext PROCESS_ONE_LINE 3 +%endif INIT_XMM sse2 PROCESS_ONE_LINE 4 diff --git a/libavfilter/x86/vf_eq_init.c b/libavfilter/x86/vf_eq_init.c index 113056e76b..0ca341e07d 100644 --- a/libavfilter/x86/vf_eq_init.c +++ b/libavfilter/x86/vf_eq_init.c @@ -31,6 +31,7 @@ extern void ff_process_one_line_sse2(const uint8_t *src, uint8_t *dst, short con short brightness, int w); #if HAVE_X86ASM +#if ARCH_X86_32 static void process_mmxext(EQParameters *param, uint8_t *dst, int dst_stride, const uint8_t *src, int src_stride, int w, int h) { @@ -45,6 +46,7 @@ static void process_mmxext(EQParameters *param, uint8_t *dst, int dst_stride, } emms_c(); } +#endif static void process_sse2(EQParameters *param, uint8_t *dst, int dst_stride, const uint8_t *src, int src_stride, int w, int h) @@ -65,9 +67,11 @@ av_cold void ff_eq_init_x86(EQContext *eq) { #if HAVE_X86ASM int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMXEXT(cpu_flags)) { eq->process = process_mmxext; } +#endif if (EXTERNAL_SSE2(cpu_flags)) { eq->process = process_sse2; } From patchwork Thu Jun 9 23:55:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 36139 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a20:6914:b0:82:6b11:2509 with SMTP id q20csp656756pzj; Thu, 9 Jun 2022 17:03:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEL+dom97Z+kzoBln4e5V+TWoIaMKNKsMwe/i1FsPvHOfgLS9aLTorvviayoLpL74KAM3q X-Received: by 2002:a17:906:33cc:b0:711:609f:8a63 with SMTP id w12-20020a17090633cc00b00711609f8a63mr25473747eja.128.1654819381548; Thu, 09 Jun 2022 17:03:01 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id aj12-20020a1709069a4c00b006fef833c67dsi5634493ejc.168.2022.06.09.17.03.00; Thu, 09 Jun 2022 17:03:01 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@outlook.com header.s=selector1 header.b=LXRCfsmh; arc=fail (body hash mismatch); spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=outlook.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 1801768B965; Fri, 10 Jun 2022 02:57:48 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05olkn2017.outbound.protection.outlook.com [40.92.91.17]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 61ED168B864 for ; Fri, 10 Jun 2022 02:57:45 +0300 (EEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kyvh8GnU3mMVAm0kvOBybel8+uV6oQJLMPl4o0hQiMNsADukOgBICEFw5770fc43xz7pKU/0e7RIAFqsb57qVnPAbwOYQVLBNppktbxCUp+dVwowIZy9ifr7CwGR7seqUmLFm1rMBu8oo3pO/dIQgAMEyClcWASVM7sO7pfgm/ZaOQPANm+hHmYU4IDkfiknh5RDG9A9XOSR7atcOO3urerc7mblorj+q0ZbKZVL294BKoTCqjYTFC2+eQ0UlzcnngaIsy12xDDuthKGprAihKSb3xlUEjECZ+pRBV7tm0v1pKD0aAF65maF/ndnJOHN7DCFZxx4DzTTXEtsJt+pFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=6loOczMUmpjppQ8PhqWtpG2L3ZCuAIM8caa3ByB9FPE=; b=URjn3VuZfjpMhxQ4RMY2NgoF97V3QTjLcpSZTIyPD6LWDdcxSWQYnZi/kRhy6YRdJObxq14y2ZoEVfR0yAs+vtSaVmc2zFQm55UJL6G9IylvZKXOZ2k3HWSMTQnO/PiO4/GhkD9P8kYiNBcxD0OJ4qHJCdNbz2KiRILlEg4a8Bi727yrIAwF/R35hUUTlvxUTneON7AhkgtL6c0xzwWus3mLHuwh3f67/qdkyXvVYBWG9SlqiwYP7euh95nP44vKgeuYu2sm5K8655fzU2PzUtcyaXULTrbERJKeZKKkbHwIfTj0Txdq52m5TrblS4V6MAToA9oUEwr9fRKB43YUDA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6loOczMUmpjppQ8PhqWtpG2L3ZCuAIM8caa3ByB9FPE=; b=LXRCfsmhs80TeXbdeDNqRzZbJig8JeS3PmyVIwDK/pIWLfXhbTlPJzMft1q3qCtf5S8fYWFoL6q5w4zLtwCsHAMBEH0cxtLHsjfOcaXVSz/cZzPPQP9UuqMxyZscw5ZeegVWBaDOIoM7IIICxa3ZkgONVXHN5OlsaSPlu2vioYFaWK9ig67tjVYiI2/F9g0o9V/O4zE6L6Oaaktt+FPq9ufObX2upUhXWKRCak9i9XDte56rPc5SNVrtlxWPzIfBdI1Al966rNelDQ69lsTLP2zXC//Y2yL+QBanQNDe3lSqZDbnI8uns3Xh2vrJl4pea394Xkmrvx+wxiIP2kMcKQ== Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) by AM0PR01MB5699.eurprd01.prod.exchangelabs.com (2603:10a6:208:176::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5332.12; Thu, 9 Jun 2022 23:57:44 +0000 Received: from DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c]) by DB6PR0101MB2214.eurprd01.prod.exchangelabs.com ([fe80::60b9:9f29:40cc:f01c%10]) with mapi id 15.20.5332.013; Thu, 9 Jun 2022 23:57:44 +0000 From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Fri, 10 Jun 2022 01:55:23 +0200 Message-ID: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: X-TMN: [fRZoI5/lNtUjZEaZbSd3XECorpPv0ubn] X-ClientProxiedBy: AM5PR04CA0005.eurprd04.prod.outlook.com (2603:10a6:206:1::18) To DB6PR0101MB2214.eurprd01.prod.exchangelabs.com (2603:10a6:4:42::27) X-Microsoft-Original-Message-ID: <20220609235523.458689-41-andreas.rheinhardt@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: ad08c843-2a98-47f2-6af3-08da4a73d8b3 X-MS-Exchange-SLBlob-MailProps: S/btQ8cKWiTijo6adWu98SHbtEySq1lKry91Qzc+7yrqqC4Hgj5YvKApKZ4lKiCIjpAZHTJ/dFzcm0uHrYV1BVSNCUSRQ+kBRAoNUqXiLvpE+wvw6GJNM7k47zqjD2zi/t0QFQLwnVFv9OFazV6Nfx3kN80LDsp/FxD13sh9Aivu7ac4RC3FW6+OKsfA4PhzBPPsyG/ronDDPUYpDxL1dhp59XtV+Q19fFwQsouNFM93Ikg5y+sNGianWcDv6at9bES2lr+hrNUZtLzajRlQs8jtLp5S/zVmAS5A9V1UdXeIje2dXhA9RwfkiZafI8N8xEL+/eMfZHuQX+TgxbtyX1hYR7sJrm5q8Fha9aXiukBXlZ7P8VG3WcrB0/ULwauChdm7JL1+N/EsA6qO5UAXNwA10sOipnsKos0YxkQQjjtJWuSIp0LPY4hd9bOYZ1r282nLz6Joj0a3DBfwidFv1n34rtA7gKv7mZD/g+fAX4VpnsI+4OSzBf0eekatpm9e8zcOK+8UVN94N/xAGZBWWVs98uPvVmny5eJttkAoqTCV4G1qir0AnVB4R/dvmtHdndrp4/WOppHSFOydt90zbDZ/phAPbBTqYmLajW9Yb5LsKKkSugolj5XEYBIBgRk7xQli1Puh8vLx75F3obKnXGLl50adQuY2dXddrwJ0tAO2bPZ41Zpz5FqZ9+f/0958TCE7PuX83zoenSjccy7M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aKvXt9Ibvtiw3vFlzLSVlqVWGV4uG2hYPVtWa/uRz9V7TtIElA7hOevXww8LQJbp8WDHQR7GpJpxCIjwlkRwVKg+NRPe44JO3XKVOdqND/bIoAIygtsrDkjf3Rfk2V1MYDSYHbq3ccOw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: ad08c843-2a98-47f2-6af3-08da4a73d8b3 X-MS-Exchange-CrossTenant-AuthSource: DB6PR0101MB2214.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jun 2022 23:57:44.5865 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR01MB5699 Subject: [FFmpeg-devel] [PATCH 41/41] avutil/x86/pixelutils_init: Disable overridden functions on x64 X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: vnxcevKAUvu2 x64 always has MMX, MMXEXT, SSE and SSE2 and this means that some functions for MMX, MMXEXT, SSE and 3dnow are always overridden by other functions (unless one e.g. explicitly disables SSE2). This commit therefore disables the 8x8 MMX (overridden by MMXEXT) as well as the 16x16 MMXEXT (overridden by SSE2) sad functions at compile-time for x64. Signed-off-by: Andreas Rheinhardt --- libavutil/x86/pixelutils.asm | 4 ++++ libavutil/x86/pixelutils_init.c | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/libavutil/x86/pixelutils.asm b/libavutil/x86/pixelutils.asm index 8b45ead78b..ea79186e19 100644 --- a/libavutil/x86/pixelutils.asm +++ b/libavutil/x86/pixelutils.asm @@ -25,6 +25,7 @@ SECTION .text +%if ARCH_X86_32 ;------------------------------------------------------------------------------- ; int ff_pixelutils_sad_8x8_mmx(const uint8_t *src1, ptrdiff_t stride1, ; const uint8_t *src2, ptrdiff_t stride2); @@ -62,6 +63,7 @@ cglobal pixelutils_sad_8x8, 4,4,0, src1, stride1, src2, stride2 movd eax, m6 movzx eax, ax RET +%endif ;------------------------------------------------------------------------------- ; int ff_pixelutils_sad_8x8_mmxext(const uint8_t *src1, ptrdiff_t stride1, @@ -83,6 +85,7 @@ cglobal pixelutils_sad_8x8, 4,4,0, src1, stride1, src2, stride2 movd eax, m2 RET +%if ARCH_X86_32 ;------------------------------------------------------------------------------- ; int ff_pixelutils_sad_16x16_mmxext(const uint8_t *src1, ptrdiff_t stride1, ; const uint8_t *src2, ptrdiff_t stride2); @@ -102,6 +105,7 @@ cglobal pixelutils_sad_16x16, 4,4,0, src1, stride1, src2, stride2 %endrep movd eax, m2 RET +%endif ;------------------------------------------------------------------------------- ; int ff_pixelutils_sad_16x16_sse2(const uint8_t *src1, ptrdiff_t stride1, diff --git a/libavutil/x86/pixelutils_init.c b/libavutil/x86/pixelutils_init.c index 184a3a4a9f..e74d5634d7 100644 --- a/libavutil/x86/pixelutils_init.c +++ b/libavutil/x86/pixelutils_init.c @@ -53,9 +53,11 @@ void ff_pixelutils_sad_init_x86(av_pixelutils_sad_fn *sad, int aligned) { int cpu_flags = av_get_cpu_flags(); +#if ARCH_X86_32 if (EXTERNAL_MMX(cpu_flags)) { sad[2] = ff_pixelutils_sad_8x8_mmx; } +#endif // The best way to use SSE2 would be to do 2 SADs in parallel, // but we'd have to modify the pixelutils API to return SIMD functions. @@ -65,7 +67,9 @@ void ff_pixelutils_sad_init_x86(av_pixelutils_sad_fn *sad, int aligned) // so just use the MMX 8x8 version even when SSE2 is available. if (EXTERNAL_MMXEXT(cpu_flags)) { sad[2] = ff_pixelutils_sad_8x8_mmxext; +#if ARCH_X86_32 sad[3] = ff_pixelutils_sad_16x16_mmxext; +#endif } if (EXTERNAL_SSE2(cpu_flags)) {