summaryrefslogtreecommitdiff
blob: 3b614554e87a5d7cd3d267e04b57a02bdb158ecf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
diff -uNr mjpegtools-1.6.0/mplex/multplex.cc mjpegtools-1.6.0-gcc33/mplex/multplex.cc
--- mjpegtools-1.6.0/mplex/multplex.cc	2002-04-29 12:30:56.000000000 -0400
+++ mjpegtools-1.6.0-gcc33/mplex/multplex.cc	2003-07-25 01:51:57.228994776 -0400
@@ -2,6 +2,7 @@
 #include <config.h>
 #include <math.h>
 #include <stdlib.h>
+#include <assert.h>
 #include <unistd.h>
 
 #include <mjpeg_types.h>
diff -uNr mjpegtools-1.6.0/mplex/stillsstream.cc mjpegtools-1.6.0-gcc33/mplex/stillsstream.cc
--- mjpegtools-1.6.0/mplex/stillsstream.cc	2002-04-19 11:14:17.000000000 -0400
+++ mjpegtools-1.6.0-gcc33/mplex/stillsstream.cc	2003-07-25 01:52:12.769632240 -0400
@@ -22,6 +22,7 @@
 
 
 #include <format_codes.h>
+#include <assert.h>
 
 #include "stillsstream.hh"
 #include "interact.hh"
diff -uNr mjpegtools-1.6.0/mplex/systems.cc mjpegtools-1.6.0-gcc33/mplex/systems.cc
--- mjpegtools-1.6.0/mplex/systems.cc	2003-07-25 01:51:14.205535336 -0400
+++ mjpegtools-1.6.0-gcc33/mplex/systems.cc	2003-07-25 01:51:44.020002848 -0400
@@ -1,6 +1,7 @@
 #include <config.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <assert.h>
 #include <string.h>
 #include <sys/param.h>
 #include <sys/stat.h>
Files mjpegtools-1.6.0/yuvdenoise/.motion.c.swp and mjpegtools-1.6.0-gcc33/yuvdenoise/.motion.c.swp differ
diff -uNr mjpegtools-1.6.0/yuvdenoise/motion.c mjpegtools-1.6.0-gcc33/yuvdenoise/motion.c
--- mjpegtools-1.6.0/yuvdenoise/motion.c	2002-05-06 04:13:37.000000000 -0400
+++ mjpegtools-1.6.0-gcc33/yuvdenoise/motion.c	2003-07-25 01:52:38.339744992 -0400
@@ -251,6 +251,9 @@
     " movl         %1    , %%eax;          /* load frameadress into eax                          */\n"
     " movl         %2    , %%ebx;          /* load frameadress into ebx                          */\n"
     " movl         %3    , %%ecx;          /* load width       into ecx                          */\n"
+	" shrl         $1    , %%ecx;          /* shift width to scale it in the asm.                */\n"
+	"                                      /* why? we need an lvalue as input... gcc33...        */\n"
+	"                                      /* (carrbc1@wfu.edu)                                  */\n"
     "                                      /*                                                    */\n"
     ".rept 4                    ;          /* Loop for 4 lines                                   */\n"
     " movd        (%%eax), %%mm1;          /* 4 Pixels from filtered frame to mm1                */\n"
@@ -270,7 +273,7 @@
     "                                      /*                                                    */\n"
     " movq         %%mm0 , %0   ;          /* make mm0 available to gcc ...                      */\n"
     :"=m" (a)     
-    :"m" (frm), "m" (ref), "m" (denoiser.frame.w/2)
+    :"m" (frm), "m" (ref), "m" (denoiser.frame.w)
     :"%eax", "%ebx", "%ecx"
     );
 #endif
@@ -295,7 +298,10 @@
     " movl         %1    , %%eax;          /* load frameadress into eax                          */\n"
     " movl         %2    , %%ebx;          /* load frameadress into ebx                          */\n"
     " movl         %3    , %%ecx;          /* load width       into ecx                          */\n"
-    "                           ;          /*                                                    */\n"
+	" shrl         $1    , %%ecx;          /* shift width to scale it in the asm.                */\n"
+	"                                      /* why? we need an lvalue as input... gcc33...        */\n"
+	"                                      /* (carrbc1@wfu.edu)                                  */\n"
+    "                                      /*                                                    */\n"
     " .rept 4                   ;          /*                                                    */\n"
     " movd        (%%eax), %%mm1;          /* 4 Pixels from filtered frame to mm1                */\n"
     " movd        (%%ebx), %%mm2;          /* 4 Pixels from filtered frame to mm2                */\n"
@@ -307,7 +313,7 @@
     "                                      /*                                                    */\n"
     " movq         %%mm0 , %0   ;          /* make mm0 available to gcc ...                      */\n"
     :"=m" (a)     
-    :"m" (frm), "m" (ref), "m" (denoiser.frame.w/2)
+    :"m" (frm), "m" (ref), "m" (denoiser.frame.w)
     :"%eax", "%ebx", "%ecx"
     );
 #endif
@@ -349,6 +355,7 @@
   static uint32_t a;
 #ifdef HAVE_ASM_MMX
   static uint32_t bit_mask[2] = {0x7f7f7f7f,0x7f7f7f7f};
+  static uint32_t* bit_mask_addr = bit_mask;
 
   __asm__ __volatile__
       (
@@ -380,7 +387,7 @@
 	  "                                      /*                                                    */"
 	  " movq         %%mm0 , %0   ;          /* make mm0 available to gcc ...                      */"
 	  :"=m" (a)     
-	  :"m" (frm1),"m" (frm2), "m" (ref), "m" (denoiser.frame.w), "m" (bit_mask)
+	  :"m" (frm1),"m" (frm2), "m" (ref), "m" (denoiser.frame.w), "m" (bit_mask_addr)
 	  :"%eax", "%ebx", "%ecx", "%edx"
 	  );
 #endif