X-Authentication-Warning: delorie.com: mailnull set sender to djgpp-bounces using -f From: "A. Sinan Unur" Newsgroups: comp.os.msdos.djgpp Subject: Re: Help with extended inline asm (or I'm stupid) Date: 28 Feb 2002 17:35:39 GMT Organization: Cornell University Lines: 32 Sender: asu1 AT cornell DOT invalid (on 128.253.251.212) Message-ID: References: <6124b64f DOT 0202280857 DOT 5d8c4dda AT posting DOT google DOT com> NNTP-Posting-Host: 128.253.251.212 X-Trace: news01.cit.cornell.edu 1014917739 13975 128.253.251.212 (28 Feb 2002 17:35:39 GMT) X-Complaints-To: usenet AT news01 DOT cit DOT cornell DOT edu NNTP-Posting-Date: 28 Feb 2002 17:35:39 GMT User-Agent: Xnews/L5 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com luisllo AT alumni DOT uv DOT es (Luis) wrote in news:6124b64f DOT 0202280857 DOT 5d8c4dda AT posting DOT google DOT com: > Hi all! > > I need to save the fpu state in order to be able to make a context > switch, in a multi-thread package I'm writting. I know how to do it in > assembler with a small function i cannot say whether this is correct or not cause i know nothing about this topic. however, see below. > void main(void) there is no such thing as void main. don't argue. read the comp.lang.c FAQ. thanks. > { > char buffer[108]; > > obt_flags(buffer); > printf("%s\n",buffer); > } > > It compiles fine, but when executing it crashes with a sigsev FAULT, > when executing the print instruction. i seriously doubt that the FPU state is a null-terminated array of char. Sinan.