Article View: comp.dsp
Article #2653Re: g21k under OS/2
From: Will Rose
Date: Thu, 19 Nov 1998 00:00
Date: Thu, 19 Nov 1998 00:00
55 lines
2976 bytes
2976 bytes
Ken (shiva@well.com) wrote:
: [g21k is DOS-based Gnu C 2.3.3 targeted for Analog Devices SHARC 21000
: architecture.]
: I'm compiling in a DOS window under OS/2, specifically Warp 4 with
: fixpak 8. After a few modules compile, the whole system crashes to a
: register screen. It's not related to a specific source module, as
: following a reboot, the Make will resume, go for a few more modules, and
: crash again. Anyone seen this? It's most likely IBM's fault, but I don't
: have a good idea on how to narrow it down for a bug report or
: workaround. I suppose I'll have to start doing my compiles under NT and
: hope it works a little better.
You might try changing the version of make you are using; there are
several around. I've done quite a bit with Mix C in a DOS box under
OS/2, and had no problems.
: Also, I've inherited an idiom that looks like this:
: [in header]
: #define LOCAL_LINKAGE
: #define near
: #define local_proc static near LOCAL_LINKAGE
: [in .c file]
: int local_proc foo (int arg) { ... }
: g21k warns about "static" not being at the beginning of the declaration.
: Does standard C not allow "static" (a property of the function, not the
: return type) to be sytacticly adjacent to the function name?
Gimpel lint gives:
int local_proc foo(int arg) { return 0; }
.\test.c(74:15) : Warning 618: Storage class specified after a type
.\test.c(74:40) : Info 715: arg (line 74) not referenced
That is, the storage class specifier was found after the type was
specified, which is legal but deprecated. Hence the warning.
: I've also seen warnings about an array index being of type char. Why
: should it care?
Because it's unusual to index an array with a character; mostly arrays
are larger than 127 elements, a common maximum for the char type. OTOH,
you are dealing with a DSP processor and chars could well be 32 bits.
: Is there a way to silence these warnings?
Not really, no; I'd be inclined to run a lint (eg: LCLint, which is
freely available) on the code, and fix whatever warnings come up.
Will
cwr@crash.cts.com
Technical Details
Message-ID:
<911462796.793087@optional.cts.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<365244F8.5371@well.com> <72u0o6$nad@gcsin3.geccs.gecm.com> <3653A950.30D9@well.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,64e721e99efdb086 X-Google-Attributes: gid11318c,public X-Google-Thread: 1014db,64e721e99efdb086 X-Google-Attributes: gid1014db,public X-Google-Thread: f8fcc,88111ff3decc9144 X-Google-Attributes: gidf8fcc,public X-Google-Thread: 10c4f5,64e721e99efdb086 X-Google-Attributes: gid10c4f5,public From: cwr@cts.com (Will Rose) Subject: Re: g21k under OS/2 Date: 1998/11/19 Message-ID: <911462796.793087@optional.cts.com> X-Deja-AN: 413436932 Cache-Post-Path: optional.cts.com!cwr@crash-i2.cts.com References: <365244F8.5371@well.com> <72u0o6$nad@gcsin3.geccs.gecm.com> <3653A950.30D9@well.com> Organization: CTS Network Services (CTSNET), San Diego, CA Followup-To: comp.dsp,comp.os.os2.bugs,comp.lang.c,gnu.gcc.help Newsgroups: comp.dsp,comp.os.os2.bugs,comp.lang.c,gnu.gcc.help