Re: Testing ham radio software on Sun hardware.



Know Code wrote:
Dr. David Kirkby wrote:

By *not* using gcc, but a commercial C and C++ compiler which adheres more strictly to the respective standards,
Dave K G8WRB.


Is that like the way Micro$oft adheres to the W3C standards? Bwahahahah!

Yes, gcc is very much like Micro$oft adhere to W3C standards.

gcc extends the language, has a compiler flag (-pedantic) which is supposed to warn you if you use such extensions, but the documentation admit it does not do this fully and that they have no plans to do anything about it.

I find this annoying. It sometimes means code built with gcc will not compile on better compilers. Usually the changes are necessary are minor.

To be more specific, taking information *only* from the gcc homepage:

--
http://gcc.gnu.org/onlinedocs/gcc-4.0.2/gcc/index.html#toc_C-Extensions

lists the extensions to the C programming language.

To quote:

"GNU C provides several language features not found in ISO standard C. (The -pedantic option directs GCC to print a warning message if any of these features is used.)"

Then we read here:

http://gcc.gnu.org/onlinedocs/gcc-4.0.2/gcc/Warning-Options.html#Warning-Options

"Some users try to use -pedantic to check programs for strict ISO C conformance. They soon find that it does not do quite what they want: it finds some non-ISO practices, but not all—only those for which ISO C requires a diagnostic, and some others for which diagnostics have been added.

A feature to report any failure to conform to ISO C might be useful in some instances, but would require considerable additional work and would be quite different from -pedantic. We don't have plans to support such a feature in the near future."

Hence my suggestion that people test their code on other compilers.

The other issue is that people often write code that works on Linux, but makes use of Linux specific header files. On many occasions, this is unnecessary.

Hence the offer. If anyone has some open-source UNIX or Linux code they would like to test on a Sun, using a commercially produced C compiler, let me know.

BTW, you can install Solaris x86 on your own PC. It is a free download

http://www.sun.com/software/solaris/

although it tends to be more fussy about what hardware it supports than Linux. The Sun compiler

http://www.sun.com/software/products/studio/index.xml

which used to sell for a few thousand dollars was very recently made free too. (That will incidently run on Linux x86 too).

I run Solaris on a 64-bit SPARC, not on a PC, so the word size is different to most PCs and the byte ordering is different too.

PS, I am not employed by Sun and have no financial interests in the company. I just rather like their hardware.

--
Dave K G8WRB

http://www.southminster-branch-line.org.uk/

Please note my email address changes periodically to avoid spam.
It is always of the form: month-year@domain. Hitting reply will work
for a couple of months only. Later set it manually. The month is
always written in 3 letters (e.g. Jan, not January etc)
.



Relevant Pages

  • Re: how to install ruby in home folder ?.
    ... i am using linux ubuntu 7.04. ... configure:1892: checking build system type ... configure:2245: checking for gcc ... configure:2563: checking for C compiler default output file name ...
    (comp.lang.ruby)
  • Re: Use of C99 int types
    ... > those that actually are part of the C-implementation for Linux. ... the kernel definitions are part of /usr/include). ... The kernel uses __foobar stuff provided by the compiler because it has ... > the Gimp and GCC run on completely different architectures aswell. ...
    (Linux-Kernel)
  • Re: function pointers
    ... I am using gcc under ... gdb, and the compiler, exactly like in 1986 when I first started using ... when running on linux, I usually use gedit or kedit. ... There is only one debugger: ...
    (comp.lang.c)
  • Re: Use of C99 int types
    ... the compiler. ... > Except the kernel wants to be optimized and work and use what features ... And where exactly are linux and libc when compiling code for an ... Just to make the bloody point GCC is not dependent on Linux in any way ...
    (Linux-Kernel)
  • Re: Richard Stallman is responsible for the shrinking economy
    ... That was 2004 for the benchmark on GCC. ... advancing innovation _and_ standards development. ... gcc has a *functional* test suite (checking that the code generated ... compiler to the standards. ...
    (comp.arch.embedded)