diff mbox

[FFmpeg-devel] avcodec: add missing xmm/neon clobber test wrappers for the new encode API

Message ID 20161001162529.904-1-jamrial@gmail.com
State Accepted
Commit 449f263f9fbdd17cef4d3b6e21d263c322eb014b
Headers show

Commit Message

James Almer Oct. 1, 2016, 4:25 p.m. UTC
Signed-off-by: James Almer <jamrial@gmail.com>
---
 configure                     |  4 ++++
 libavcodec/aarch64/neontest.c | 10 ++++++++++
 libavcodec/arm/neontest.c     | 10 ++++++++++
 libavcodec/x86/w64xmmtest.c   | 10 ++++++++++
 4 files changed, 34 insertions(+)

Comments

Ronald S. Bultje Oct. 1, 2016, 4:55 p.m. UTC | #1
Hi,

On Sat, Oct 1, 2016 at 12:25 PM, James Almer <jamrial@gmail.com> wrote:

> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>  configure                     |  4 ++++
>  libavcodec/aarch64/neontest.c | 10 ++++++++++
>  libavcodec/arm/neontest.c     | 10 ++++++++++
>  libavcodec/x86/w64xmmtest.c   | 10 ++++++++++
>  4 files changed, 34 insertions(+)


lgtm.

Ronald
James Almer Oct. 1, 2016, 5:11 p.m. UTC | #2
On 10/1/2016 1:55 PM, Ronald S. Bultje wrote:
> Hi,
> 
> On Sat, Oct 1, 2016 at 12:25 PM, James Almer <jamrial@gmail.com> wrote:
> 
>> Signed-off-by: James Almer <jamrial@gmail.com>
>> ---
>>  configure                     |  4 ++++
>>  libavcodec/aarch64/neontest.c | 10 ++++++++++
>>  libavcodec/arm/neontest.c     | 10 ++++++++++
>>  libavcodec/x86/w64xmmtest.c   | 10 ++++++++++
>>  4 files changed, 34 insertions(+)
> 
> 
> lgtm.
> 
> Ronald

Pushed, thanks.
diff mbox

Patch

diff --git a/configure b/configure
index 74db9b5..5216260 100755
--- a/configure
+++ b/configure
@@ -6079,6 +6079,8 @@  enabled neon_clobber_test &&
                   -Wl,--wrap,avcodec_encode_video2      \
                   -Wl,--wrap,avcodec_send_packet        \
                   -Wl,--wrap,avcodec_receive_frame      \
+                  -Wl,--wrap,avcodec_send_frame         \
+                  -Wl,--wrap,avcodec_receive_packet     \
                   -Wl,--wrap,avcodec_encode_subtitle    \
                   -Wl,--wrap,swr_convert                \
                   -Wl,--wrap,avresample_convert ||
@@ -6094,6 +6096,8 @@  enabled xmm_clobber_test &&
                   -Wl,--wrap,avcodec_encode_subtitle    \
                   -Wl,--wrap,avcodec_send_packet        \
                   -Wl,--wrap,avcodec_receive_frame      \
+                  -Wl,--wrap,avcodec_send_frame         \
+                  -Wl,--wrap,avcodec_receive_packet     \
                   -Wl,--wrap,swr_convert                \
                   -Wl,--wrap,avresample_convert         \
                   -Wl,--wrap,sws_scale ||
diff --git a/libavcodec/aarch64/neontest.c b/libavcodec/aarch64/neontest.c
index 302a322..93f162d 100644
--- a/libavcodec/aarch64/neontest.c
+++ b/libavcodec/aarch64/neontest.c
@@ -87,3 +87,13 @@  wrap(avcodec_receive_frame(AVCodecContext *avctx, AVFrame *frame))
 {
     testneonclobbers(avcodec_receive_frame, avctx, frame);
 }
+
+wrap(avcodec_send_frame(AVCodecContext *avctx, const AVFrame *frame))
+{
+    testneonclobbers(avcodec_send_frame, avctx, avpkt);
+}
+
+wrap(avcodec_receive_packet(AVCodecContext *avctx, AVPacket *avpkt))
+{
+    testneonclobbers(avcodec_receive_packet, avctx, frame);
+}
diff --git a/libavcodec/arm/neontest.c b/libavcodec/arm/neontest.c
index 51d158b..b24120c 100644
--- a/libavcodec/arm/neontest.c
+++ b/libavcodec/arm/neontest.c
@@ -87,3 +87,13 @@  wrap(avcodec_receive_frame(AVCodecContext *avctx, AVFrame *frame))
 {
     testneonclobbers(avcodec_receive_frame, avctx, frame);
 }
+
+wrap(avcodec_send_frame(AVCodecContext *avctx, const AVFrame *frame))
+{
+    testneonclobbers(avcodec_send_frame, avctx, avpkt);
+}
+
+wrap(avcodec_receive_packet(AVCodecContext *avctx, AVPacket *avpkt))
+{
+    testneonclobbers(avcodec_receive_packet, avctx, frame);
+}
diff --git a/libavcodec/x86/w64xmmtest.c b/libavcodec/x86/w64xmmtest.c
index 3d466d2..d76a322 100644
--- a/libavcodec/x86/w64xmmtest.c
+++ b/libavcodec/x86/w64xmmtest.c
@@ -87,3 +87,13 @@  wrap(avcodec_receive_frame(AVCodecContext *avctx, AVFrame *frame))
 {
     testxmmclobbers(avcodec_receive_frame, avctx, frame);
 }
+
+wrap(avcodec_send_frame(AVCodecContext *avctx, const AVFrame *frame))
+{
+    testxmmclobbers(avcodec_send_frame, avctx, avpkt);
+}
+
+wrap(avcodec_receive_packet(AVCodecContext *avctx, AVPacket *avpkt))
+{
+    testxmmclobbers(avcodec_receive_packet, avctx, frame);
+}