History

swscale/x86/swscale: Make M24 variables static

Andreas Rheinhardt committed 1 year ago

Commit 4afe61e1 parent 3797e922 files · +12 −12Browse files

Unified · Split

2 files
  1. libswscale/x86/swscale.c +3 −3
  2. libswscale/x86/swscale_template.c +9 −9
libswscale/x86/swscale.c+3−3
@@ -43,9 +43,9 @@ const DECLARE_ALIGNED(8, uint64_t, ff_dither8)[2] = { · 42 unmodified lines
4343 DECLARE_ASM_CONST(8, uint64_t, bF8)= 0xF8F8F8F8F8F8F8F8LL;
4444 DECLARE_ASM_CONST(8, uint64_t, bFC)= 0xFCFCFCFCFCFCFCFCLL;
4545
46−DECLARE_ASM_ALIGNED(8, const uint64_t, ff_M24A) = 0x00FF0000FF0000FFLL;
47−DECLARE_ASM_ALIGNED(8, const uint64_t, ff_M24B) = 0xFF0000FF0000FF00LL;
48−DECLARE_ASM_ALIGNED(8, const uint64_t, ff_M24C) = 0x0000FF0000FF0000LL;
46+DECLARE_ASM_CONST(8, uint64_t, M24A) = 0x00FF0000FF0000FFLL;
47+DECLARE_ASM_CONST(8, uint64_t, M24B) = 0xFF0000FF0000FF00LL;
48+DECLARE_ASM_CONST(8, uint64_t, M24C) = 0x0000FF0000FF0000LL;
4949
5050 // MMXEXT versions
5151 #if HAVE_MMXEXT_INLINE
libswscale/x86/swscale_template.c+9−9
@@ -541,8 +541,8 @@ static void RENAME(yuv2rgb555_X)(SwsInternal *c, const int16_t *lumFilter, · 540 unmodified lines
541541
542542 #define WRITEBGR24MMXEXT(dst, dstw, index) \
543543 /* mm2=B, %%mm4=G, %%mm5=R, %%mm7=0 */\
544− "movq "MANGLE(ff_M24A)", %%mm0 \n\t"\
545− "movq "MANGLE(ff_M24C)", %%mm7 \n\t"\
544+ "movq "MANGLE(M24A)", %%mm0 \n\t"\
545+ "movq "MANGLE(M24C)", %%mm7 \n\t"\
546546 "pshufw $0x50, %%mm2, %%mm1 \n\t" /* B3 B2 B3 B2 B1 B0 B1 B0 */\
547547 "pshufw $0x50, %%mm4, %%mm3 \n\t" /* G3 G2 G3 G2 G1 G0 G1 G0 */\
548548 "pshufw $0x00, %%mm5, %%mm6 \n\t" /* R1 R0 R1 R0 R1 R0 R1 R0 */\
@@ -561,7 +561,7 @@ static void RENAME(yuv2rgb555_X)(SwsInternal *c, const int16_t *lumFilter, · 12 unmodified lines
561561 "pshufw $0x55, %%mm4, %%mm3 \n\t" /* G4 G3 G4 G3 G4 G3 G4 G3 */\
562562 "pshufw $0xA5, %%mm5, %%mm6 \n\t" /* R5 R4 R5 R4 R3 R2 R3 R2 */\
563563 \
564− "pand "MANGLE(ff_M24B)", %%mm1 \n\t" /* B5 B4 B3 */\
564+ "pand "MANGLE(M24B)", %%mm1 \n\t" /* B5 B4 B3 */\
565565 "pand %%mm7, %%mm3 \n\t" /* G4 G3 */\
566566 "pand %%mm0, %%mm6 \n\t" /* R4 R3 R2 */\
567567 \
@@ -575,7 +575,7 @@ static void RENAME(yuv2rgb555_X)(SwsInternal *c, const int16_t *lumFilter, · 7 unmodified lines
575575 \
576576 "pand %%mm7, %%mm1 \n\t" /* B7 B6 */\
577577 "pand %%mm0, %%mm3 \n\t" /* G7 G6 G5 */\
578− "pand "MANGLE(ff_M24B)", %%mm6 \n\t" /* R7 R6 R5 */\
578+ "pand "MANGLE(M24B)", %%mm6 \n\t" /* R7 R6 R5 */\
579579 \
580580 "por %%mm1, %%mm3 \n\t"\
581581 "por %%mm3, %%mm6 \n\t"\
@@ -611,7 +611,7 @@ static void RENAME(yuv2bgr24_X_ar)(SwsInternal *c, const int16_t *lumFilter, · 29 unmodified lines
611611 :: "r" (&c->redDither),
612612 "m" (dummy), "m" (dummy), "m" (dummy),
613613 "r" (dest), "m" (dstW_reg), "m"(uv_off)
614− NAMED_CONSTRAINTS_ADD(ff_M24A,ff_M24C,ff_M24B)
614+ NAMED_CONSTRAINTS_ADD(M24A,M24C,M24B)
615615 : "%"FF_REG_a, "%"FF_REG_c, "%"FF_REG_d, "%"FF_REG_S
616616 );
617617 }
@@ -636,7 +636,7 @@ static void RENAME(yuv2bgr24_X)(SwsInternal *c, const int16_t *lumFilter, · 18 unmodified lines
636636 :: "r" (&c->redDither),
637637 "m" (dummy), "m" (dummy), "m" (dummy),
638638 "r" (dest), "m" (dstW_reg), "m"(uv_off)
639− NAMED_CONSTRAINTS_ADD(ff_M24A,ff_M24C,ff_M24B)
639+ NAMED_CONSTRAINTS_ADD(M24A,M24C,M24B)
640640 : "%"FF_REG_a, "%"FF_REG_c, "%"FF_REG_d, "%"FF_REG_S
641641 );
642642 }
@@ -864,7 +864,7 @@ static void RENAME(yuv2bgr24_2)(SwsInternal *c, const int16_t *buf[2], · 221 unmodified lines
864864 "mov "ESP_OFFSET"(%5), %%"FF_REG_b" \n\t"
865865 :: "c" (buf0), "d" (buf1), "S" (ubuf0), "D" (ubuf1), "m" (dest),
866866 "a" (&c->redDither)
867− NAMED_CONSTRAINTS_ADD(ff_M24A,ff_M24C,ff_M24B)
867+ NAMED_CONSTRAINTS_ADD(M24A,M24C,M24B)
868868 );
869869 }
870870
@@ -1191,7 +1191,7 @@ static void RENAME(yuv2bgr24_1)(SwsInternal *c, const int16_t *buf0, · 320 unmodified lines
11911191 "mov "ESP_OFFSET"(%5), %%"FF_REG_b" \n\t"
11921192 :: "c" (buf0), "d" (buf1), "S" (ubuf0), "D" (ubuf1), "m" (dest),
11931193 "a" (&c->redDither)
1194− NAMED_CONSTRAINTS_ADD(ff_M24A,ff_M24C,ff_M24B)
1194+ NAMED_CONSTRAINTS_ADD(M24A,M24C,M24B)
11951195 );
11961196 } else {
11971197 const int16_t *ubuf1 = ubuf[1];
@@ -1206,7 +1206,7 @@ static void RENAME(yuv2bgr24_1)(SwsInternal *c, const int16_t *buf0, · 8 unmodified lines
12061206 "mov "ESP_OFFSET"(%5), %%"FF_REG_b" \n\t"
12071207 :: "c" (buf0), "d" (buf1), "S" (ubuf0), "D" (ubuf1), "m" (dest),
12081208 "a" (&c->redDither)
1209− NAMED_CONSTRAINTS_ADD(ff_M24A,ff_M24C,ff_M24B)
1209+ NAMED_CONSTRAINTS_ADD(M24A,M24C,M24B)
12101210 );
12111211 }
12121212 }

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