--- uae/src/drawing.c 2018/04/24 16:47:27 1.1.1.5 +++ uae/src/drawing.c 2018/04/24 16:48:44 1.1.1.6 @@ -127,7 +127,7 @@ int framecnt = 0; static int frame_redraw_necessary; static int picasso_redraw_necessary; -static __inline__ void count_frame (void) +STATIC_INLINE void count_frame (void) { framecnt++; if (framecnt >= currprefs.gfx_framerate) @@ -459,7 +459,7 @@ static void fill_line_24 (char *buf, int } #endif -static __inline__ void fill_line_full (void) +STATIC_INLINE void fill_line_full (void) { switch (gfxvidinfo.pixbytes) { case 1: fill_line_8 (xlinebuffer, linetoscr_x_adjust, linetoscr_x_adjust + gfxvidinfo.width); break; @@ -483,7 +483,7 @@ static __inline__ void fill_line_full (v #if 1 #undef fill_line -static __inline__ void fill_line (void) +STATIC_INLINE void fill_line (void) { int shift; int nints, nrem; @@ -1019,7 +1019,7 @@ static uae_u32 do_sprite_collisions (str return datab; } -static __inline__ void render_sprite (int spr, int sprxp, uae_u32 datab, int ham, int attch, int sprx_inc) +STATIC_INLINE void render_sprite (int spr, int sprxp, uae_u32 datab, int ham, int attch, int sprx_inc) { uae_u32 datcd; int basecol = 16; @@ -1331,7 +1331,7 @@ static void pfield_doline_unaligned_l (i #else /* not UNALIGNED_PROFITABLE */ -static __inline__ void pfield_orword_hires_h(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_orword_hires_h(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1341,7 +1341,7 @@ static __inline__ void pfield_orword_hir *(pixptr+3) |= hirestab_h[data & 255][1] << bit; } -static __inline__ void pfield_orword_lores_h(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_orword_lores_h(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1355,7 +1355,7 @@ static __inline__ void pfield_orword_lor *(pixptr+7) |= lorestab_h[data & 255][3] << bit; } -static __inline__ void pfield_setword_hires_h(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_setword_hires_h(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1365,7 +1365,7 @@ static __inline__ void pfield_setword_hi *(pixptr+3) = hirestab_h[data & 255][1] << bit; } -static __inline__ void pfield_setword_lores_h(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_setword_lores_h(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1379,7 +1379,7 @@ static __inline__ void pfield_setword_lo *(pixptr+7) = lorestab_h[data & 255][3] << bit; } -static __inline__ void pfield_orword_hires_l(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_orword_hires_l(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1387,7 +1387,7 @@ static __inline__ void pfield_orword_hir *(pixptr+1) |= hirestab_l[data & 255][0] << bit; } -static __inline__ void pfield_orword_lores_l(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_orword_lores_l(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1397,7 +1397,7 @@ static __inline__ void pfield_orword_lor *(pixptr+3) |= lorestab_l[data & 255][1] << bit; } -static __inline__ void pfield_setword_hires_l(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_setword_hires_l(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1405,7 +1405,7 @@ static __inline__ void pfield_setword_hi *(pixptr+1) = hirestab_l[data & 255][0] << bit; } -static __inline__ void pfield_setword_lores_l(int data, unsigned char *dp, int bit) +STATIC_INLINE void pfield_setword_lores_l(int data, unsigned char *dp, int bit) { uae_u32 *pixptr = (uae_u32 *)dp; @@ -1768,7 +1768,7 @@ static void do_flush_line_1 (int lineno) } } -static __inline__ void do_flush_line (int lineno) +STATIC_INLINE void do_flush_line (int lineno) { /* We don't want to call X libraries from the second thread right now. */ #ifndef SUPPORT_PENGUINS @@ -1784,7 +1784,7 @@ static __inline__ void do_flush_line (in * systems. */ -static __inline__ void do_flush_screen (int start, int stop) +STATIC_INLINE void do_flush_screen (int start, int stop) { #ifdef SUPPORT_PENGUINS int i; @@ -1793,6 +1793,11 @@ static __inline__ void do_flush_screen ( do_flush_line_1 (i); } #endif + + /* TODO: this flush operation is executed outside locked state! + Should be corrected. + (sjo 26.9.99) */ + if (gfxvidinfo.maxblocklines != 0 && first_block_line != -2) { flush_block (first_block_line, last_block_line); } @@ -1800,7 +1805,7 @@ static __inline__ void do_flush_screen ( flush_screen (start, stop); } -static __inline__ void finish_line_aga (void) +STATIC_INLINE void finish_line_aga (void) { #if AGA_CHIPSET != 0 aga_lbufptr = aga_linebuf; @@ -1839,7 +1844,7 @@ static void adjust_drawing_colors (int c #endif } -static __inline__ void adjust_color0_for_color_change (void) +STATIC_INLINE void adjust_color0_for_color_change (void) { drawing_color_matches = -1; if (dp_for_drawing->color0 != 0xFFFFFFFFul) { @@ -1855,7 +1860,7 @@ static __inline__ void adjust_color0_for * compensate (much easier that way). */ #define COPPER_MAGIC_FUDGE -9 -static __inline__ void do_color_changes (line_draw_func worker) +STATIC_INLINE void do_color_changes (line_draw_func worker) { int lastpos = 0, nextpos, i; struct color_change *cc = curr_color_changes + dip_for_drawing->first_color_change; @@ -1912,7 +1917,7 @@ enum double_how { dh_emerg }; -static __inline__ void pfield_draw_line (int lineno, int gfx_ypos, int follow_ypos) +STATIC_INLINE void pfield_draw_line (int lineno, int gfx_ypos, int follow_ypos) { int border = 0; int do_double = 0; @@ -2380,7 +2385,7 @@ void hardware_line_completed (int lineno #endif } -static __inline__ void check_picasso (void) +STATIC_INLINE void check_picasso (void) { #ifdef PICASSO96 if (picasso_on && picasso_redraw_necessary)