lkml.org 
[lkml]   [2009]   [Oct]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: i686 quirk for AMD Geode
On Sat, Oct 3, 2009 at 4:34 AM, H. Peter Anvin <hpa@zytor.com> wrote:
> On 10/02/2009 07:12 PM, Matteo Croce wrote:
>> Hi,
>>
>> the AMD GEode LX has an x86 id of 5 (i586) tought it's technically an i686:
>>
>
> a) Wrong place - it should be in cpu/amd.c.
> b) You need to also make sure that it has FCOMI and the long NOP\
>   instructions.
>
>        -hpa
>
> --
> H. Peter Anvin, Intel Open Source Technology Center
> I work for Intel.  I don't speak on their behalf.
>
>

I've run the attached files and I get this:

root@alix:/usr/src# ./longnop
Long NOPs supported: no
root@alix:/usr/src# ./fcomi
Long FCOMi supported: yes
#include <stdio.h>
#include <signal.h>
#include <setjmp.h>

static sigjmp_buf out;

void sigill(int signal)
{
siglongjmp(out, 1);
}

int main(void)
{
int died;

signal(SIGILL, sigill);

died = sigsetjmp(out, 1);

if (!died)
asm volatile("nopl 0(%eax)");

printf("Long NOPs supported: %s\n", died ? "no" : "yes");
return died;
}
#include <stdio.h>
#include <signal.h>
#include <setjmp.h>

static sigjmp_buf out;

void sigill(int signal)
{
siglongjmp(out, 1);
}

int main(void)
{
int died;

signal(SIGILL, sigill);

died = sigsetjmp(out, 1);

if (!died)
asm volatile("fcomi st(0), st(1)");

printf("Long FCOMi supported: %s\n", died ? "no" : "yes");
return died;
}
\
 
 \ /
  Last update: 2009-10-03 05:11    [W:0.112 / U:0.492 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site