[x264-devel] commit: rename vector+array unions to closer match the vector typedefs names. ( Guillaume Poirier )

git version control git at videolan.org
Wed Jan 14 21:50:56 CET 2009


x264 | branch: master | Guillaume Poirier <gpoirier at mplayerhq.hu> | Wed Jan 14 21:49:42 2009 +0100| [d2b6423db8310e5238fd7c0e517b3344578cc08a] | committer: Guillaume Poirier 

rename vector+array unions to closer match the vector typedefs names.

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=d2b6423db8310e5238fd7c0e517b3344578cc08a
---

 common/ppc/mc.c        |    2 +-
 common/ppc/ppccommon.h |   22 +++++++++++-----------
 common/ppc/predict.c   |    4 ++--
 common/ppc/quant.c     |   32 ++++++++++++++++----------------
 4 files changed, 30 insertions(+), 30 deletions(-)

diff --git a/common/ppc/mc.c b/common/ppc/mc.c
index b11f531..471f141 100644
--- a/common/ppc/mc.c
+++ b/common/ppc/mc.c
@@ -559,7 +559,7 @@ void x264_hpel_filter_altivec( uint8_t *dsth, uint8_t *dstv, uint8_t *dstc, uint
 
     vec_u16_t twov, fourv, fivev, sixv;
     vec_s16_t sixteenv, thirtytwov;
-    vect_ushort_u temp_u;
+    vec_u16_u temp_u;
 
     temp_u.s[0]=2;
     twov = vec_splat( temp_u.v, 0 );
diff --git a/common/ppc/ppccommon.h b/common/ppc/ppccommon.h
index 3db035c..a3d18b5 100644
--- a/common/ppc/ppccommon.h
+++ b/common/ppc/ppccommon.h
@@ -42,23 +42,23 @@
 #define vec_s32_t vector signed int
 
 typedef union {
-  unsigned int s[4];
-  vector unsigned int v;
-} vect_int_u;
+  uint32_t s[4];
+  vec_u32_t v;
+} vec_u32_u;
 
 typedef union {
-  unsigned short s[8];
-  vector unsigned short v;
-} vect_ushort_u;
+  uint16_t s[8];
+  vec_u16_t v;
+} vec_u16_u;
 
 typedef union {
-  signed short s[8];
-  vector signed short v;
-} vect_sshort_u;
+  int16_t s[8];
+  vec_s16_t v;
+} vec_s16_u;
 
 typedef union {
-  unsigned char s[16];
-  vector unsigned char v;
+  uint8_t s[16];
+  vec_u8_t v;
 } vec_u8_u;
 
 /***********************************************************************
diff --git a/common/ppc/predict.c b/common/ppc/predict.c
index 62a5578..589b00c 100644
--- a/common/ppc/predict.c
+++ b/common/ppc/predict.c
@@ -45,7 +45,7 @@ static void predict_16x16_p_altivec( uint8_t *src )
     c = ( 5 * V + 32 ) >> 6;
     i00 = a - b * 7 - c * 7 + 16;
 
-    vect_sshort_u i00_u, b_u, c_u;
+    vec_s16_u i00_u, b_u, c_u;
     i00_u.s[0] = i00;
     b_u.s[0]   = b;
     c_u.s[0]   = c;
@@ -158,7 +158,7 @@ static void predict_16x16_h_altivec( uint8_t *src )
 
 static void predict_16x16_v_altivec( uint8_t *src )
 {
-    vect_int_u v;
+    vec_u32_u v;
     v.s[0] = *(uint32_t*)&src[ 0-FDEC_STRIDE];
     v.s[1] = *(uint32_t*)&src[ 4-FDEC_STRIDE];
     v.s[2] = *(uint32_t*)&src[ 8-FDEC_STRIDE];
diff --git a/common/ppc/quant.c b/common/ppc/quant.c
index b4d551e..64b34ab 100644
--- a/common/ppc/quant.c
+++ b/common/ppc/quant.c
@@ -71,7 +71,7 @@ void x264_quant_4x4_altivec( int16_t dct[4][4], uint16_t mf[16], uint16_t bias[1
 
     vec_s16_t temp1v, temp2v;
 
-    vect_int_u qbits_u;
+    vec_u32_u qbits_u;
     qbits_u.s[0]=16;
     i_qbitsv = vec_splat(qbits_u.v, 0);
 
@@ -125,15 +125,15 @@ void x264_quant_4x4_dc_altivec( int16_t dct[4][4], int mf, int bias )
     vec_u16_t mfv;
     vec_u16_t biasv;
 
-    vect_ushort_u mf_u;
+    vec_u16_u mf_u;
     mf_u.s[0]=mf;
     mfv = vec_splat( mf_u.v, 0 );
 
-    vect_int_u qbits_u;
+    vec_u32_u qbits_u;
     qbits_u.s[0]=16;
     i_qbitsv = vec_splat(qbits_u.v, 0);
 
-    vect_ushort_u bias_u;
+    vec_u16_u bias_u;
     bias_u.s[0]=bias;
     biasv = vec_splat(bias_u.v, 0);
 
@@ -173,15 +173,15 @@ void x264_quant_2x2_dc_altivec( int16_t dct[2][2], int mf, int bias )
     vec_u16_t mfv;
     vec_u16_t biasv;
 
-    vect_ushort_u mf_u;
+    vec_u16_u mf_u;
     mf_u.s[0]=mf;
     mfv = vec_splat( mf_u.v, 0 );
 
-    vect_int_u qbits_u;
+    vec_u32_u qbits_u;
     qbits_u.s[0]=16;
     i_qbitsv = vec_splat(qbits_u.v, 0);
 
-    vect_ushort_u bias_u;
+    vec_u16_u bias_u;
     bias_u.s[0]=bias;
     biasv = vec_splat(bias_u.v, 0);
 
@@ -209,7 +209,7 @@ void x264_quant_8x8_altivec( int16_t dct[8][8], uint16_t mf[64], uint16_t bias[6
     
     vec_s16_t temp1v, temp2v;
     
-    vect_int_u qbits_u;
+    vec_u32_u qbits_u;
     qbits_u.s[0]=16;
     i_qbitsv = vec_splat(qbits_u.v, 0);
 
@@ -278,7 +278,7 @@ void x264_dequant_4x4_altivec( int16_t dct[4][4], int dequant_mf[6][4][4], int i
     if( i_qbits >= 0 )
     {
         vec_u16_t i_qbitsv;
-        vect_ushort_u qbits_u;
+        vec_u16_u qbits_u;
         qbits_u.s[0]=i_qbits;
         i_qbitsv = vec_splat(qbits_u.v, 0);
 
@@ -290,17 +290,17 @@ void x264_dequant_4x4_altivec( int16_t dct[4][4], int dequant_mf[6][4][4], int i
         const int f = 1 << (-i_qbits-1);
 
         vec_s32_t fv;
-        vect_int_u f_u;
+        vec_u32_u f_u;
         f_u.s[0]=f;
         fv = (vec_s32_t)vec_splat(f_u.v, 0);
 
         vec_u32_t i_qbitsv;
-        vect_int_u qbits_u;
+        vec_u32_u qbits_u;
         qbits_u.s[0]=-i_qbits;
         i_qbitsv = vec_splat(qbits_u.v, 0);
 
         vec_u32_t sixteenv;
-        vect_int_u sixteen_u;
+        vec_u32_u sixteen_u;
         sixteen_u.s[0]=16;
         sixteenv = vec_splat(sixteen_u.v, 0);
 
@@ -325,7 +325,7 @@ void x264_dequant_8x8_altivec( int16_t dct[8][8], int dequant_mf[6][8][8], int i
     if( i_qbits >= 0 )
     {
         vec_u16_t i_qbitsv;
-        vect_ushort_u qbits_u;
+        vec_u16_u qbits_u;
         qbits_u.s[0]=i_qbits;
         i_qbitsv = vec_splat(qbits_u.v, 0);
 
@@ -337,17 +337,17 @@ void x264_dequant_8x8_altivec( int16_t dct[8][8], int dequant_mf[6][8][8], int i
         const int f = 1 << (-i_qbits-1);
 
         vec_s32_t fv;
-        vect_int_u f_u;
+        vec_u32_u f_u;
         f_u.s[0]=f;
         fv = (vec_s32_t)vec_splat(f_u.v, 0);
 
         vec_u32_t i_qbitsv;
-        vect_int_u qbits_u;
+        vec_u32_u qbits_u;
         qbits_u.s[0]=-i_qbits;
         i_qbitsv = vec_splat(qbits_u.v, 0);
 
         vec_u32_t sixteenv;
-        vect_int_u sixteen_u;
+        vec_u32_u sixteen_u;
         sixteen_u.s[0]=16;
         sixteenv = vec_splat(sixteen_u.v, 0);
 



More information about the x264-devel mailing list