diff options
author | R. Belmont <rb6502@users.noreply.github.com> | 2009-06-10 21:39:18 +0000 |
---|---|---|
committer | R. Belmont <rb6502@users.noreply.github.com> | 2009-06-10 21:39:18 +0000 |
commit | 68a74253b132ddfce424438b0e76c143626dd39f (patch) | |
tree | 36148c0fa14deebbdba38501a78a7145c1d7e2bf /src/mame | |
parent | dce3614807da6d19ebbf523f71d2746e11fb45c6 (diff) |
GCC 4.4 fixes.
src/emu/machine/74181.c and 74148.c seem to be almost impossible to fix. Help?
Diffstat (limited to 'src/mame')
-rw-r--r-- | src/mame/drivers/thayers.c | 2 | ||||
-rw-r--r-- | src/mame/machine/scramble.c | 16 | ||||
-rw-r--r-- | src/mame/video/aerofgt.c | 6 | ||||
-rw-r--r-- | src/mame/video/arabian.c | 6 | ||||
-rw-r--r-- | src/mame/video/cosmic.c | 8 | ||||
-rw-r--r-- | src/mame/video/tubep.c | 4 |
6 files changed, 23 insertions, 19 deletions
diff --git a/src/mame/drivers/thayers.c b/src/mame/drivers/thayers.c index fbefd1d8eee..aa21e612d94 100644 --- a/src/mame/drivers/thayers.c +++ b/src/mame/drivers/thayers.c @@ -300,7 +300,7 @@ static WRITE8_HANDLER( control2_w ) */ - if (!BIT(data, 2) & cart_present) + if ((!BIT(data, 2)) & cart_present) { cputag_set_input_line(space->machine, "maincpu", INPUT_LINE_NMI, HOLD_LINE); } diff --git a/src/mame/machine/scramble.c b/src/mame/machine/scramble.c index ce6a9a99961..cecdfa3eed2 100644 --- a/src/mame/machine/scramble.c +++ b/src/mame/machine/scramble.c @@ -601,14 +601,14 @@ DRIVER_INIT( billiard ) bits[i] = (A >> i) & 1; xormask = 0x55; - if (bits[2] ^ ( bits[3] & bits[6])) xormask ^= 0x01; - if (bits[4] ^ ( bits[5] & bits[7])) xormask ^= 0x02; - if (bits[0] ^ ( bits[7] & !bits[3])) xormask ^= 0x04; - if (bits[3] ^ (!bits[0] & bits[2])) xormask ^= 0x08; - if (bits[5] ^ (!bits[4] & bits[1])) xormask ^= 0x10; - if (bits[6] ^ (!bits[2] & !bits[5])) xormask ^= 0x20; - if (bits[1] ^ (!bits[6] & !bits[4])) xormask ^= 0x40; - if (bits[7] ^ (!bits[1] & bits[0])) xormask ^= 0x80; + if (bits[2] ^ (( bits[3]) & ( bits[6]))) xormask ^= 0x01; + if (bits[4] ^ (( bits[5]) & ( bits[7]))) xormask ^= 0x02; + if (bits[0] ^ (( bits[7]) & (!bits[3]))) xormask ^= 0x04; + if (bits[3] ^ ((!bits[0]) & ( bits[2]))) xormask ^= 0x08; + if (bits[5] ^ ((!bits[4]) & ( bits[1]))) xormask ^= 0x10; + if (bits[6] ^ ((!bits[2]) & (!bits[5]))) xormask ^= 0x20; + if (bits[1] ^ ((!bits[6]) & (!bits[4]))) xormask ^= 0x40; + if (bits[7] ^ ((!bits[1]) & ( bits[0]))) xormask ^= 0x80; rom[A] ^= xormask; diff --git a/src/mame/video/aerofgt.c b/src/mame/video/aerofgt.c index 29fd02ec0bb..b355374ca6a 100644 --- a/src/mame/video/aerofgt.c +++ b/src/mame/video/aerofgt.c @@ -416,7 +416,7 @@ static void turbofrc_draw_sprites(running_machine *machine, bitmap_t *bitmap,con if (!(aerofgt_spriteram3[attr_start + 2] & 0x0080)) continue; pri = aerofgt_spriteram3[attr_start + 2] & 0x0010; if ( chip_disabled_pri & !pri) continue; - if (!chip_disabled_pri & (pri>>4)) continue; + if ((!chip_disabled_pri) & (pri>>4)) continue; ox = aerofgt_spriteram3[attr_start + 1] & 0x01ff; xsize = (aerofgt_spriteram3[attr_start + 2] & 0x0700) >> 8; zoomx = (aerofgt_spriteram3[attr_start + 1] & 0xf000) >> 12; @@ -491,7 +491,7 @@ static void spinlbrk_draw_sprites(running_machine *machine, bitmap_t *bitmap,con if (!(aerofgt_spriteram3[attr_start + 2] & 0x0080)) continue; pri = aerofgt_spriteram3[attr_start + 2] & 0x0010; if ( chip_disabled_pri & !pri) continue; - if (!chip_disabled_pri & (pri>>4)) continue; + if ((!chip_disabled_pri) & (pri>>4)) continue; ox = aerofgt_spriteram3[attr_start + 1] & 0x01ff; xsize = (aerofgt_spriteram3[attr_start + 2] & 0x0700) >> 8; zoomx = (aerofgt_spriteram3[attr_start + 1] & 0xf000) >> 12; @@ -567,7 +567,7 @@ static void aerfboo2_draw_sprites(running_machine *machine, bitmap_t *bitmap,con if (!(aerofgt_spriteram3[attr_start + 2] & 0x0080)) continue; pri = aerofgt_spriteram3[attr_start + 2] & 0x0010; if ( chip_disabled_pri & !pri) continue; - if (!chip_disabled_pri & (pri>>4)) continue; + if ((!chip_disabled_pri) & (pri>>4)) continue; ox = aerofgt_spriteram3[attr_start + 1] & 0x01ff; xsize = (aerofgt_spriteram3[attr_start + 2] & 0x0700) >> 8; zoomx = (aerofgt_spriteram3[attr_start + 1] & 0xf000) >> 12; diff --git a/src/mame/video/arabian.c b/src/mame/video/arabian.c index 037675178df..55177631cd1 100644 --- a/src/mame/video/arabian.c +++ b/src/mame/video/arabian.c @@ -86,7 +86,7 @@ PALETTE_INIT( arabian ) -------------------------------------------------------------------------*/ int rhi = planea ? ar : enb ? bz : 0; - int rlo = planea ? ((!arhf & az) ? 0 : ar) : enb ? br : 0; + int rlo = planea ? (((!arhf) & az) ? 0 : ar) : enb ? br : 0; /*------------------------------------------------------------------------- green derivation: @@ -117,7 +117,7 @@ PALETTE_INIT( arabian ) -------------------------------------------------------------------------*/ int ghi = planea ? ag : enb ? bb : 0; - int glo = planea ? ((!aghf & az) ? 0 : ag) : enb ? bg : 0; + int glo = planea ? (((!aghf) & az) ? 0 : ag) : enb ? bg : 0; /*------------------------------------------------------------------------- blue derivation: @@ -138,7 +138,7 @@ PALETTE_INIT( arabian ) -------------------------------------------------------------------------*/ int bhi = ab; - int bbase = (!abhf & az) ? 0 : ab; + int bbase = ((!abhf) & az) ? 0 : ab; /* convert an RGB color - there are effectively 6 bits of color: 2 red, 2 green, 2 blue */ diff --git a/src/mame/video/cosmic.c b/src/mame/video/cosmic.c index d96fb894f13..e9501242962 100644 --- a/src/mame/video/cosmic.c +++ b/src/mame/video/cosmic.c @@ -344,7 +344,7 @@ static void cosmica_draw_starfield(const device_config *screen, bitmap_t *bitmap // flip-flop at IC11 is clocked map = PROM[(x1 >> 5) | (y >> 1 << 3)]; - if ((!(hc & va) & (vb ^ hb_)) && /* right network */ + if (((!(hc & va)) & (vb ^ hb_)) && /* right network */ (((x1 ^ map) & (hc | 0x1e)) == 0x1e)) /* left network */ { /* RGB order is reversed -- bit 7=R, 6=G, 5=B */ @@ -482,10 +482,10 @@ static void nomnlnd_draw_background(const device_config *screen, bitmap_t *bitma int hc_ = (x >> 6) & 0x01; int hd_ = x >> 7; - if ((!vb_ & vc_ & !vd_) ^ (vb_ & !vc_ & vd_)) + if (((!vb_) & vc_ & (!vd_)) ^ (vb_ & (!vc_) & vd_)) { /* tree */ - if (!hd_ & hc_ & !hb_) + if ((!hd_) & hc_ & (!hb_)) { offs_t offs = ((x >> 3) & 0x03) | ((y & 0x1f) << 2) | (flip_screen_get(screen->machine) ? 0x80 : 0); @@ -516,7 +516,7 @@ static void nomnlnd_draw_background(const device_config *screen, bitmap_t *bitma color = ( plane1 & plane2) | // R ( plane1 | plane2) << 1 | // G - (!plane1 & hd) << 2; // B - see above + ((!plane1) & hd) << 2; // B - see above } } diff --git a/src/mame/video/tubep.c b/src/mame/video/tubep.c index f4be6f7a6bc..8fcec323376 100644 --- a/src/mame/video/tubep.c +++ b/src/mame/video/tubep.c @@ -192,6 +192,10 @@ PALETTE_INIT( tubep ) double weights_txt_rg[3]; double weights_txt_b[2]; + memset(weights_r, 0, sizeof(weights_r)); + memset(weights_g, 0, sizeof(weights_g)); + memset(weights_b, 0, sizeof(weights_b)); + compute_resistor_weights(0, 255, -1.0, 3, resistors_txt_rg, weights_txt_rg, 470, 0, 2, resistors_txt_b, weights_txt_b, 470, 0, |