From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1CqfF0-0006kb-1J for qemu-devel@nongnu.org; Mon, 17 Jan 2005 17:20:54 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1CqfEr-0006Ze-Gh for qemu-devel@nongnu.org; Mon, 17 Jan 2005 17:20:45 -0500 Received: from [129.104.30.34] (helo=mx1.polytechnique.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1Cqep5-0006zk-1O for qemu-devel@nongnu.org; Mon, 17 Jan 2005 16:54:07 -0500 Message-ID: <41EC342C.9010401@bellard.org> Date: Mon, 17 Jan 2005 22:54:52 +0100 From: Fabrice Bellard MIME-Version: 1.0 Subject: Re: [Qemu-devel] Re: Re: 2.6.10-mm3: swsusp: out of memory on resume References: <200501131909.26021.rjw@sisk.pl> <20050114143400.GA27657@hugang.soulinfo.com> <200501150042.35377.rjw@sisk.pl> <20050115012120.GA4743@hugang.soulinfo.com> <41E90326.2020901@bellard.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: quoted-printable Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: daimon55@free.fr, qemu-devel@nongnu.org Hi, My plan is to add a more generic option to select a given cpu model and=20 to be able to disable or enable some specific features (for example=20 '-cpu p6+pae+sse3', any other suggestions ?), so I prefer not to include=20 this patch now. Fabrice. Ronald wrote: > Le Sat, 15 Jan 2005 12:48:54 +0100, Fabrice Bellard a =E9crit : >=20 > =20 >=20 >>Now that SSE and MMX are implemented, no feature is lacking in the QEMU >>x86_64 emulation... "just" a problem of debugging now :-) >> >>I did not enable SSE and MMX for x86 because I fear there are still bug= s >>which may cause regressions. Interested people can enable the line: >> >>-- >> env->cpuid_features |=3D CPUID_FXSR | CPUID_MMX | CPUID_SSE | >>CPUID_SSE2 | CPUID_PAE; >=20 >=20 > What about doing this with qemu options? >=20 > Perhaps I'am wrong, but something like that: >=20 > --- vl.c.old 2005-01-15 23:49:25.124123925 +0100 > +++ vl.c 2005-01-17 17:19:18.528256753 +0100 > @@ -134,6 +134,8 @@ > int graphic_height =3D 600; > int graphic_depth =3D 15; > int full_screen =3D 0; > +int use_mmx =3D 0; > +int use_sse =3D 0; > TextConsole *vga_console; > CharDriverState *serial_hds[MAX_SERIAL_PORTS]; > CharDriverState *parallel_hds[MAX_PARALLEL_PORTS]; > @@ -2848,6 +2850,8 @@ > QEMU_OPTION_loadvm, > QEMU_OPTION_full_screen, > QEMU_OPTION_pidfile, > + QEMU_OPTION_use_mmx, > + QEMU_OPTION_use_sse, > }; >=20 > typedef struct QEMUOption { > @@ -2911,7 +2915,10 @@ > { "loadvm", HAS_ARG, QEMU_OPTION_loadvm }, > { "full-screen", 0, QEMU_OPTION_full_screen }, > { "pidfile", HAS_ARG, QEMU_OPTION_pidfile }, > - > +#ifdef TARGET_I386 > + { "mmx", 0, QEMU_OPTION_use_mmx }, > + { "sse", 0, QEMU_OPTION_use_sse }, > +#endif > /* temporary options */ > { "pci", 0, QEMU_OPTION_pci }, > { "cirrusvga", 0, QEMU_OPTION_cirrusvga }, > @@ -3358,6 +3365,12 @@ > case QEMU_OPTION_pidfile: > create_pidfile(optarg); > break; > + case QEMU_OPTION_use_mmx: > + use_mmx =3D 1; > + break; > + case QEMU_OPTION_use_sse: > + use_sse =3D 1; > + break; > } > } > } > --- vl.h.old 2005-01-17 17:28:37.491471386 +0100 > +++ vl.h 2005-01-17 17:19:13.723332164 +0100 > @@ -123,6 +123,8 @@ > extern int graphic_width; > extern int graphic_height; > extern int graphic_depth; > +extern int use_mmx; > +extern int use_sse; > extern const char *keyboard_layout; >=20 > /* XXX: make it dynamic */ > --- target-i386/helper2.c.old 2005-01-17 17:37:57.199481651 +0100 > +++ target-i386/helper2.c 2005-01-17 17:46:18.834424698 +0100 > @@ -25,6 +25,7 @@ > #include > #include >=20 > +#include "vl.h" > #include "cpu.h" > #include "exec-all.h" >=20 > @@ -106,6 +107,13 @@ > env->cpuid_features =3D (CPUID_FP87 | CPUID_DE | CPUID_PSE | > CPUID_TSC | CPUID_MSR | CPUID_MCE | > CPUID_CX8 | CPUID_PGE | CPUID_CMOV); > +#ifdef TARGET_I386 > + if(use_mmx =3D=3D 1) > + env->cpuid_features |=3D CPUID_MMX; > + if(use_sse =3D=3D 1) > + env->cpuid_features |=3D CPUID_FXSR | CPUID_SSE= ; > +#endif > + > #ifdef TARGET_X86_64 > /* currently not enabled for std i386 because not fully tested= */ > env->cpuid_features |=3D CPUID_FXSR | CPUID_MMX | CPUID_SSE | > CPUID_SSE2; >=20 >=20 >=20 > _______________________________________________ > Qemu-devel mailing list > Qemu-devel@nongnu.org > http://lists.nongnu.org/mailman/listinfo/qemu-devel >=20 >=20 >=20