Skip to contentSkip to conversation

[5319] Add Atom (x86) cpu identification.

Qemu-devel Andrzej Zaborowski 2 participants 6 messages Sep 25, 2008 – Sep 27, 2008

lore
Share & tools
lore
#0 lore raw

Revision: 5319

          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=5319
Author:   balrog
Date:     2008-09-25 18:31:12 +0000 (Thu, 25 Sep 2008)

Log Message:
-----------
Add Atom (x86) cpu identification.

Also add SSSE3 to Core2 features.

Modified Paths:
--------------

    trunk/target-i386/helper.c

Modified: trunk/target-i386/helper.c
===================================================================

target-i386/helper.c +24 -3
@@ -174,11 +174,11 @@
         .stepping = 11,
         /* the original CPU does have many more features that are
          * not implemented yet */
-        .features = PPRO_FEATURES | 
+        .features = PPRO_FEATURES |
             CPUID_MTRR | CPUID_CLFLUSH | CPUID_MCA |
             CPUID_PSE36,
-        .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR,
-        .ext2_features = (PPRO_FEATURES & 0x0183F3FF) | 
+        .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR | CPUID_EXT_SSSE3,
+        .ext2_features = (PPRO_FEATURES & 0x0183F3FF) |
             CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX,
         .xlevel = 0x8000000A,
         .model_id = "Intel(R) Core(TM)2 Duo CPU     T7700  @ 2.40GHz",
@@ -246,6 +246,27 @@
         /* XXX: put another string ? */
         .model_id = "QEMU Virtual CPU version " QEMU_VERSION,
     },
+    {
+        .name = "atom",
+        /* original is on level 10 */
+        .level = 5,
+        .family = 6,
+        .model = 28,
+        .stepping = 2,
+        .features = PPRO_FEATURES |
+            CPUID_MTRR | CPUID_CLFLUSH | CPUID_MCA | CPUID_VME,
+            /* Missing: CPUID_DTS | CPUID_ACPI | CPUID_SS |
+             * CPUID_HT | CPUID_TM | CPUID_PBE */
+            /* Some CPUs got no CPUID_SEP */
+        .ext_features = CPUID_EXT_MONITOR |
+            CPUID_EXT_SSE3 /* PNI */, CPUID_EXT_SSSE3,
+            /* Missing: CPUID_EXT_DSCPL | CPUID_EXT_EST |
+             * CPUID_EXT_TM2 | CPUID_EXT_XTPR */
+        .ext2_features = (PPRO_FEATURES & 0x0183F3FF) | CPUID_EXT2_NX,
+        /* Missing: .ext3_features = CPUID_EXT3_LAHF_LM */
+        .xlevel = 0x8000000A,
+        .model_id = "Intel(R) Atom(TM) CPU N270   @ 1.60GHz",
+    },
 };
 
 static int cpu_x86_find_by_name(x86_def_t *x86_cpu_def, const char *cpu_model)
#1 lore raw
Quoted 37 lines · Andrzej Zaborowski

Revision: 5319

         http://svn.sv.gnu.org/viewvc/? 
view=rev&root=qemu&revision=5319
Author:   balrog
Date:     2008-09-25 18:31:12 +0000 (Thu, 25 Sep 2008)

Log Message:
-----------
Add Atom (x86) cpu identification.

Also add SSSE3 to Core2 features.

Modified Paths:
--------------
trunk/target-i386/helper.c

Modified: trunk/target-i386/helper.c
===================================================================

target-i386/helper.c +3 -3
@@ -174,11 +174,11 @@
        .stepping = 11,
        /* the original CPU does have many more features that are
         * not implemented yet */
-        .features = PPRO_FEATURES |
+        .features = PPRO_FEATURES |
            CPUID_MTRR | CPUID_CLFLUSH | CPUID_MCA |
            CPUID_PSE36,
-        .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR,
-        .ext2_features = (PPRO_FEATURES & 0x0183F3FF) |
+        .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR |  
 CPUID_EXT_SSSE3,
+        .ext2_features = (PPRO_FEATURES & 0x0183F3FF) |
            CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX,
        .xlevel = 0x8000000A,
        .model_id = "Intel(R) Core(TM)2 Duo CPU     T7700  @ 2.40GHz",

target-i386/helper.c line 250

Quoted 5 lines
target-i386/helper.c +2 -0
@@ -246,6 +246,27 @@
        /* XXX: put another string ? */
        .model_id = "QEMU Virtual CPU version " QEMU_VERSION,
    },
+    {
+        .name = "atom",

Wouldn't it be good to call it N270? Atom is a series of CPUs from Intel that contain very different CPU features. More expensive ones for example do support VMX, while that first cheap one does not.

Alex

#2 lore raw

2008/9/26 Alexander Graf <[email protected]>:

Quoted 8 lines

target-i386/helper.c line 250

Quoted 6 lines
target-i386/helper.c +2 -0
@@ -246,6 +246,27 @@
       /* XXX: put another string ? */
       .model_id = "QEMU Virtual CPU version " QEMU_VERSION,
   },
+    {
+        .name = "atom",

Wouldn't it be good to call it N270? Atom is a series of CPUs from Intel

Yes, good point. I'll rename it to something containing model number.

Cheers

#3 lore raw
Quoted 11 lines · andrzej zaborowski

2008/9/26 Alexander Graf <[email protected]>:

Quoted 8 lines

target-i386/helper.c line 250

Quoted 6 lines
target-i386/helper.c +2 -0
@@ -246,6 +246,27 @@
      /* XXX: put another string ? */
      .model_id = "QEMU Virtual CPU version " QEMU_VERSION,
  },
+    {
+        .name = "atom",

Wouldn't it be good to call it N270? Atom is a series of CPUs from Intel

Yes, good point. I'll rename it to something containing model number.

Great :-). Are you also considering to work on an ICH-7 (or above) emulation?

Alex

#4 lore raw

2008/9/27 Alexander Graf <[email protected]>:

Quoted 2 lines

Great :-). Are you also considering to work on an ICH-7 (or above) emulation?

I was considering adding parts of ICH and intel 945GSE (especially grpahics) but I don't know yet what we'll end up needing most and how much time I will have. If you start on something related it would be great to know.

Cheers

#5 lore raw
Quoted 8 lines · andrzej zaborowski

2008/9/27 Alexander Graf <[email protected]>:

Quoted 2 lines

Great :-). Are you also considering to work on an ICH-7 (or above) emulation?

I was considering adding parts of ICH and intel 945GSE (especially grpahics) but I don't know yet what we'll end up needing most and how much time I will have. If you start on something related it would be great to know.

As far as I see it, the only chance in getting Mac OS X guest support upstream is an ICH-7 or up implementation in qemu. So I was considering to start working on it. I haven't had the time to do so yet though, but it's one of the things on my todo list. I wanted to focus mostly on the IDE and LPC parts first. Takashi might help me out on an HDA emulation.

Alex