History

avfilter/vf_colorspace: Remove redundant emms_c()

It is not even clear what these emms_c() are supposed to achieve: create_filtergraph() (where it may be called) does not call ASM functions itself; it merely sets some function pointers. Furthermore, there are no colorspacedsp functions using MMX (checked by checkasm which does not use declare_new_emms()). Finally, checking whether to issue emms_c() is overblown anyway.

Andreas Rheinhardt committed 3 years ago

Commit 03a60b21 parent d84ee801 file · +1 −8Browse files

Showing the changes to libavfilter (1 of 1 file). Show all

Unified · Split

libavfilter/vf_colorspace.c+1−8
@@ -400,7 +400,7 @@ static int create_filtergraph(AVFilterContext *ctx, · 399 unmodified lines
400400 ColorSpaceContext *s = ctx->priv;
401401 const AVPixFmtDescriptor *in_desc = av_pix_fmt_desc_get(in->format);
402402 const AVPixFmtDescriptor *out_desc = av_pix_fmt_desc_get(out->format);
403− int emms = 0, m, n, o, res, fmt_identical, redo_yuv2rgb = 0, redo_rgb2yuv = 0;
403+ int m, n, o, res, fmt_identical, redo_yuv2rgb = 0, redo_rgb2yuv = 0;
404404
405405 #define supported_depth(d) ((d) == 8 || (d) == 10 || (d) == 12)
406406 #define supported_subsampling(lcw, lch) \
@@ -494,7 +494,6 @@ static int create_filtergraph(AVFilterContext *ctx, · 87 unmodified lines
494494 s->lrgb2lrgb_coeffs[m][n][o] = s->lrgb2lrgb_coeffs[m][n][0];
495495 }
496496
497− emms = 1;
498497 }
499498 }
500499
@@ -542,7 +541,6 @@ static int create_filtergraph(AVFilterContext *ctx, · 41 unmodified lines
542541 res = fill_gamma_table(s);
543542 if (res < 0)
544543 return res;
545− emms = 1;
546544 }
547545
548546 if (!s->in_lumacoef) {
@@ -625,7 +623,6 @@ static int create_filtergraph(AVFilterContext *ctx, · 76 unmodified lines
625623 av_assert2(s->yuv2rgb_coeffs[0][0][0] == s->yuv2rgb_coeffs[2][0][0]);
626624 s->yuv2rgb = s->dsp.yuv2rgb[(in_desc->comp[0].depth - 8) >> 1]
627625 [in_desc->log2_chroma_h + in_desc->log2_chroma_w];
628− emms = 1;
629626 }
630627
631628 if (redo_rgb2yuv) {
@@ -656,7 +653,6 @@ static int create_filtergraph(AVFilterContext *ctx, · 24 unmodified lines
656653 [out_desc->log2_chroma_h + out_desc->log2_chroma_w];
657654 s->rgb2yuv_fsb = s->dsp.rgb2yuv_fsb[(out_desc->comp[0].depth - 8) >> 1]
658655 [out_desc->log2_chroma_h + out_desc->log2_chroma_w];
659− emms = 1;
660656 }
661657
662658 if (s->yuv2yuv_fastmode && (redo_yuv2rgb || redo_rgb2yuv)) {
@@ -683,9 +679,6 @@ static int create_filtergraph(AVFilterContext *ctx, · 20 unmodified lines
683679 }
684680 }
685681
686− if (emms)
687− emms_c();
688−
689682 return 0;
690683 }
691684

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t