]> rtime.felk.cvut.cz Git - frescor/ffmpeg.git/commitdiff
Use DECLARE_ALIGNED for alignment in libpostprocess
authorreimar <reimar@9553f0bf-9b14-0410-a0b8-cfaf0461ba5b>
Thu, 17 May 2007 09:30:38 +0000 (09:30 +0000)
committerreimar <reimar@9553f0bf-9b14-0410-a0b8-cfaf0461ba5b>
Thu, 17 May 2007 09:30:38 +0000 (09:30 +0000)
git-svn-id: file:///var/local/repositories/ffmpeg/trunk@9043 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b

libpostproc/postprocess.c
libpostproc/postprocess_template.c

index f68c8a7232c7863f64344c85803a0d35be5ae7e3..14a66c956082a4544ea4d43b54f5bbeb063561ed 100644 (file)
@@ -106,14 +106,14 @@ try to unroll inner for(x=0 ... loop to avoid these damn if(x ... checks
 //#define NUM_BLOCKS_AT_ONCE 16 //not used yet
 
 #if defined(ARCH_X86)
-static uint64_t __attribute__((aligned(8))) attribute_used w05= 0x0005000500050005LL;
-static uint64_t __attribute__((aligned(8))) attribute_used w04= 0x0004000400040004LL;
-static uint64_t __attribute__((aligned(8))) attribute_used w20= 0x0020002000200020LL;
-static uint64_t __attribute__((aligned(8))) attribute_used b00= 0x0000000000000000LL;
-static uint64_t __attribute__((aligned(8))) attribute_used b01= 0x0101010101010101LL;
-static uint64_t __attribute__((aligned(8))) attribute_used b02= 0x0202020202020202LL;
-static uint64_t __attribute__((aligned(8))) attribute_used b08= 0x0808080808080808LL;
-static uint64_t __attribute__((aligned(8))) attribute_used b80= 0x8080808080808080LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, w05)= 0x0005000500050005LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, w04)= 0x0004000400040004LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, w20)= 0x0020002000200020LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, b00)= 0x0000000000000000LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, b01)= 0x0101010101010101LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, b02)= 0x0202020202020202LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, b08)= 0x0808080808080808LL;
+static DECLARE_ALIGNED(8, uint64_t attribute_used, b80)= 0x8080808080808080LL;
 #endif
 
 static uint8_t clip_table[3*256];
index 730c58b231d3146092de49f55b2d18f088e255c1..6bc1efc2df95392573bc1a3e49ad50a6b1bd854a 100644 (file)
@@ -3348,7 +3348,7 @@ static inline void RENAME(duplicate)(uint8_t src[], int stride)
 static void RENAME(postProcess)(uint8_t src[], int srcStride, uint8_t dst[], int dstStride, int width, int height,
         QP_STORE_T QPs[], int QPStride, int isColor, PPContext *c2)
 {
-        PPContext __attribute__((aligned(8))) c= *c2; //copy to stack for faster access
+        DECLARE_ALIGNED(8, PPContext, c)= *c2; //copy to stack for faster access
         int x,y;
 #ifdef COMPILE_TIME_MODE
         const int mode= COMPILE_TIME_MODE;
@@ -3717,7 +3717,7 @@ static void RENAME(postProcess)(uint8_t src[], int srcStride, uint8_t dst[], int
                                 else if(mode & H_DEBLOCK)
                                 {
 #ifdef HAVE_ALTIVEC
-                                        unsigned char __attribute__ ((aligned(16))) tempBlock[272];
+                                        DECLARE_ALIGNED(16, unsigned char, tempBlock[272]);
                                         transpose_16x8_char_toPackedAlign_altivec(tempBlock, dstBlock - (4 + 1), stride);
 
                                         const int t=vertClassify_altivec(tempBlock-48, 16, &c);