Re: [hatari-devel] UAE 68030 MMU + prefetch + instruction and data cache emulation |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
Am Wed, 2 Aug 2017 16:46:00 +0200
schrieb Nicolas Pomarède <npomarede@xxxxxxxxxxxx>:
> Le 02/08/2017 à 16:20, Eero Tamminen a écrit :
> > Hi,
> >
> > On 07/27/2017 09:15 PM, Toni Wilen wrote:
> >> I just pushed update to winuae tree that adds yet another UAE CPU
> >> emulation mode: 68030 MMU with prefetch pipeline, instruction and
> >> data cache (Previously this was only available in non-MMU mode).
> >> Data cache emulation is also improved.
> >>
> >> Perhaps this is useful in Atari emulation too and if it is,
> >> hopefully it also has better test cases :)
> >>
> >> It is not very well tested (it seems to work with Amiga debugging
> >> utilities, Amix and NetBSD 6, didn't bother to do more testing
> >> yet..)
> >>
> >> It also isn't very optimized but that isn't important at this
> >> point.
> >
> > I'm seeing following compiler warnings:
> >
> > hatari/src/cpu/cpummu030.c: In function ‘m68k_do_rte_mmu030’:
> > hatari/src/cpu/cpummu030.c:2532:41: warning: signed and unsigned
> > type in conditional expression [-Wsign-compare]
> > mmu030_opcode = (ps & 0x80000000) ? -1 : (oc & 0xffff);
> > ^
> > hatari/src/cpu/cpummu030.c: In function ‘m68k_do_rte_mmu030c’:
> > hatari/src/cpu/cpummu030.c:2794:41: warning: signed and unsigned
> > type in conditional expression [-Wsign-compare]
> > mmu030_opcode = (ps & 0x80000000) ? -1 : (oc & 0xffff);
> > ^
> > hatari/src/cpu/cpummu030.c:2843:53: warning: signed and unsigned
> > type in conditional expression [-Wsign-compare]
> > regs.pipeline_stop = ((ps >> 20) & 15) == 15 ? -1 : (ps >> 20)
> > & 15; ^
> >
> > (In addition to the warnings from the FPU emulation code.)
>
> I'm afraid this is similar to some other warnings we already have
> regarding signed/unsigned but that don't bother Toni as they might
> not be triggered into visual studio :) (clang doesn't report them
> either, which seems right in the end, as "(ps >> 20) & 15)" for
> example will alway be >0 even if ps is a signed int)
We've already got this in the CMakeList.txt file of the cpu directory:
# The remaining warnings can be hidden for the release:
# set next if to "1" instead of "0"
if (0)
set(CPUMAIN_CFLAGS "${CPUMAIN_CFLAGS} -Wno-sign-compare -Wno-maybe-uninitialized -Wno-bad-function-cast")
endif()
If we do not expect to fix the sign-compare warnings, maybe we should
simply move the -Wno-sign-compare to the section that is always set
there?
Thomas