* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
@ 1996-08-16 4:00 ` Ron Natalie
1996-08-17 4:00 ` Ping Huang
` (3 more replies)
1996-08-17 4:00 ` David-Michael Lincke
` (4 subsequent siblings)
5 siblings, 4 replies; 56+ messages in thread
From: Ron Natalie @ 1996-08-16 4:00 UTC (permalink / raw)
Jianlin Chang wrote:
> That is, which
> should you start with, then porting to other platfroms? There are lots
> of
> difference between stability, and availability of system services to
> aid system
> software programming. For example, HP-UX doesn't allow you to attach
> to a proces
> s from a debugger. Some OS are still not very POSIX compliant. Any
> comments?
The comment about HP-UX not allowing to connect to a process with the
debugger is just blatently wrong. Try looking up the -P option.
Of course, the best platform is probably the most difficult one. In
my opinion you should start with a DEC Alpha. It will catch your
assumptions about pointer and integer sizes and give you an alternate
view of byte orders.
The HP (where I do my development) has a vary "lenient" enviornment.
The compiler will accept constructs that stricter ANSI compliant ones
(notably the IRIX and DEC ones) don't allow. Also, there are some
quirks in structure vs. pointer passing that cause bugs to go unnoticed
on the HP (by the code actually working) that will bite you on other
platforms.
^ permalink raw reply [flat|nested] 56+ messages in thread
* best UNIX OS as primary platform for UNIX system software develpoment?
@ 1996-08-16 4:00 Jianlin Chang
1996-08-16 4:00 ` Ron Natalie
` (5 more replies)
0 siblings, 6 replies; 56+ messages in thread
From: Jianlin Chang @ 1996-08-16 4:00 UTC (permalink / raw)
Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
which is the
best primary platform for UNIX system software development (and which
version of
the OS)? That is, which
should you start with, then porting to other platfroms? There are lots
of
difference between stability, and availability of system services to
aid system
software programming. For example, HP-UX doesn't allow you to attach
to a proces
s from a debugger. Some OS are still not very POSIX compliant. Any
comments?
Thanks.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 ` Ron Natalie
@ 1996-08-17 4:00 ` Ping Huang
1996-08-17 4:00 ` Jianlin Chang
` (2 subsequent siblings)
3 siblings, 0 replies; 56+ messages in thread
From: Ping Huang @ 1996-08-17 4:00 UTC (permalink / raw)
To: chang
In article <3214E7D0.1CEA@sensor.com> Ron Natalie <ron@sensor.com> writes:
> Of course, the best platform is probably the most difficult one. In
> my opinion you should start with a DEC Alpha. It will catch your
> assumptions about pointer and integer sizes and give you an alternate
> view of byte orders.
I'll put in a soft plug here for IRIX 6.2 (running on one of the
64-bit kernel platforms, which is basically everything except the
Indy) as a development platform, in that you can do both 32-bit and
64-bit development and test both the 32-bit and 64-bit executables on
a single system.
--
Ping Huang <pshuang@sgi.com> | Silicon Graphics, Inc., Mountain View, CA
http://web.mit.edu/pshuang/.plan; PGP: 1906684DD1537EC4 30876EACC18ADFC5
Disclaimer: unless explicitly otherwise stated, my
statements represent my personal viewpoints only.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 ` Ron Natalie
1996-08-17 4:00 ` Ping Huang
@ 1996-08-17 4:00 ` Jianlin Chang
1996-08-19 4:00 ` James Youngman
` (3 more replies)
1996-08-19 4:00 ` Jianlin Chang
1996-08-21 4:00 ` Richard Cognot
3 siblings, 4 replies; 56+ messages in thread
From: Jianlin Chang @ 1996-08-17 4:00 UTC (permalink / raw)
Sorry, I am using gdb which doesn't allow me to attach to a process, I
don't like the interface of xdb, and never bothered to learn it.
OSF is notoriously buggy and unstable for its initial versions, is it
getting better?
Ron Natalie (ron@sensor.com) wrote:
: Jianlin Chang wrote:
: > That is, which
: > should you start with, then porting to other platfroms? There are lots
: > of
: > difference between stability, and availability of system services to
: > aid system
: > software programming. For example, HP-UX doesn't allow you to attach
: > to a proces
: > s from a debugger. Some OS are still not very POSIX compliant. Any
: > comments?
: The comment about HP-UX not allowing to connect to a process with the
: debugger is just blatently wrong. Try looking up the -P option.
: Of course, the best platform is probably the most difficult one. In
: my opinion you should start with a DEC Alpha. It will catch your
: assumptions about pointer and integer sizes and give you an alternate
: view of byte orders.
: The HP (where I do my development) has a vary "lenient" enviornment.
: The compiler will accept constructs that stricter ANSI compliant ones
: (notably the IRIX and DEC ones) don't allow. Also, there are some
: quirks in structure vs. pointer passing that cause bugs to go unnoticed
: on the HP (by the code actually working) that will bite you on other
: platforms.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
1996-08-16 4:00 ` Ron Natalie
1996-08-17 4:00 ` David-Michael Lincke
@ 1996-08-17 4:00 ` Andrew Gabriel
1996-08-18 4:00 ` Nick Sayer
1996-08-19 4:00 ` Matt Houseman x4408
` (2 subsequent siblings)
5 siblings, 1 reply; 56+ messages in thread
From: Andrew Gabriel @ 1996-08-17 4:00 UTC (permalink / raw)
In article <4v2j4b$2bs@knot.queensu.ca>,
chang@mjs1 (Jianlin Chang) writes:
>
>Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
>which is the
>best primary platform for UNIX system software development (and which
We develop for all the above (except IRIX) and may more besides.
Also non-unix platforms.
My initial development is always on Solaris (x86 as it happens,
although that doesn't matter much).
>version of the OS)?
The oldest version which you will support in the field (2.4 in our
case for Solaris x86, 2.3 for sparc), but we use more recent versions
of the development tools, and you also need up-to-date verions of the
OS to ensure you run correctly on them too.
>That is, which
>should you start with, then porting to other platfroms? There are lots
>of
>difference between stability, and availability of system services to
>aid system
>software programming. For example, HP-UX doesn't allow you to attach
>to a proces
>s from a debugger. Some OS are still not very POSIX compliant. Any
>comments?
Solaris has excellent development tools, which are fully multi-thread
aware for example. I find it much easier to debug and get working an
application under Solaris and then port it to another unix. I also
find this true when going to NT, Win95 or OS/2 - that may be because
I am more familiar with unix; I can't stand OS's which lock solid
on application faults and don't give core dumps...
--
Andrew Gabriel Home: Andrew@cucumber.demon.co.uk
Consultant Software Engineer Work: Andrew.Gabriel@net-tel.co.uk
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
1996-08-16 4:00 ` Ron Natalie
@ 1996-08-17 4:00 ` David-Michael Lincke
1996-08-17 4:00 ` Andrew Gabriel
` (3 subsequent siblings)
5 siblings, 0 replies; 56+ messages in thread
From: David-Michael Lincke @ 1996-08-17 4:00 UTC (permalink / raw)
Jianlin Chang (chang@mjs1) wrote:
: Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
: which is the
: best primary platform for UNIX system software development (and which
: version of
: the OS)? That is, which
: should you start with, then porting to other platfroms? There are lots
: of
: difference between stability, and availability of system services to
: aid system
: software programming. For example, HP-UX doesn't allow you to attach
: to a proces
: s from a debugger. Some OS are still not very POSIX compliant. Any
: comments?
: Thanks.
:
From a porting perspective you might want to go with the most
standard-compliant Unix for inital developement and there HP-UX being
certified for UNIX95 compliance starting with version 10.10 is hard to beat.
As far as I know among the leading Unix derivatives Digital Unix is the
only other Unix also featuring UNIX95 branding so far.
dave
--
David-Michael Lincke
Research Assistant
Institute for Information Management IWI-HSG, University of St. Gallen
EMail: David-Michael.Lincke@iwi.unisg.ch, dlincke@bandon.unisg.ch
URL: http://www-iwi.unisg.ch/about/team/dal.html
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-17 4:00 ` Andrew Gabriel
@ 1996-08-18 4:00 ` Nick Sayer
0 siblings, 0 replies; 56+ messages in thread
From: Nick Sayer @ 1996-08-18 4:00 UTC (permalink / raw)
andrew@cucumber.demon.co.uk (Andrew Gabriel) writes:
>Solaris has excellent development tools, which are fully multi-thread
>aware for example.
Shouldn't this be restated as 'SunSoft has excellent dev tools...'?
Solaris doesn't even come with a compiler anymore.
--
Nick Sayer <nsayer@quack.kfu.com> | If you're old enough to legally vote,
N6QQQ @ N0ARY.#NORCAL.CA.USA.NOAM | drive, contract, copulate, smoke,
+1 408 249 9630, log in as 'guest' | fight for and die for your country,
URL: http://www.kfu.com/~nsayer/ | I say you're old enough to drink.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-17 4:00 ` Jianlin Chang
@ 1996-08-19 4:00 ` James Youngman
1996-08-19 4:00 ` Jianlin Chang
1996-08-19 4:00 ` Jeff Diewald
` (2 subsequent siblings)
3 siblings, 1 reply; 56+ messages in thread
From: James Youngman @ 1996-08-19 4:00 UTC (permalink / raw)
In article <4v4o5g$cb@knot.queensu.ca>, chang@mjs1 says...
>
>Sorry, I am using gdb which doesn't allow me to attach to a process,
Yes it does. Type "help attach".
--
James Youngman VG Gas Analysis Systems
The trouble with the rat-race is, even if you win, you're still a rat.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
` (3 preceding siblings ...)
1996-08-19 4:00 ` Matt Houseman x4408
@ 1996-08-19 4:00 ` amk
1996-08-20 4:00 ` guest
1996-08-22 4:00 ` Roger Binns
5 siblings, 1 reply; 56+ messages in thread
From: amk @ 1996-08-19 4:00 UTC (permalink / raw)
Jianlin Chang (chang@mjs1) wrote:
: Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
: which is the
: best primary platform for UNIX system software development (and which
: version of
: the OS)? That is, which
: should you start with, then porting to other platfroms? There are lots
: of
: difference between stability, and availability of system services to
: aid system
: software programming. For example, HP-UX doesn't allow you to attach
: to a proces
: s from a debugger. Some OS are still not very POSIX compliant. Any
: comments?
: Thanks.
Had to respond to this: "For example, HP-UX doesn't allow you to attach
to a process from a debugger...". Check out the man page (from HP-UX)
on xdb, specifically the -P option. We do this all the time.
Tony Kruse
SysAdmin
Ford Vehicle Operations Emissions Lab
Allen Park, Mi USA
akruse1@ford.com
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 ` Ron Natalie
1996-08-17 4:00 ` Ping Huang
1996-08-17 4:00 ` Jianlin Chang
@ 1996-08-19 4:00 ` Jianlin Chang
1996-08-22 4:00 ` Jason C R Hill
1996-08-21 4:00 ` Richard Cognot
3 siblings, 1 reply; 56+ messages in thread
From: Jianlin Chang @ 1996-08-19 4:00 UTC (permalink / raw)
I found that on HP-UX 10.00 and 10.10, I can't attach to a process
using either gdb or xdb, but on HP-UX 9.01, I can. Previously, I had
been using primarily 10.x, that's why I can't do it.
Ron Natalie (ron@sensor.com) wrote:
: Jianlin Chang wrote:
: > That is, which
: > should you start with, then porting to other platfroms? There are lots
: > of
: > difference between stability, and availability of system services to
: > aid system
: > software programming. For example, HP-UX doesn't allow you to attach
: > to a proces
: > s from a debugger. Some OS are still not very POSIX compliant. Any
: > comments?
: The comment about HP-UX not allowing to connect to a process with the
: debugger is just blatently wrong. Try looking up the -P option.
: Of course, the best platform is probably the most difficult one. In
: my opinion you should start with a DEC Alpha. It will catch your
: assumptions about pointer and integer sizes and give you an alternate
: view of byte orders.
: The HP (where I do my development) has a vary "lenient" enviornment.
: The compiler will accept constructs that stricter ANSI compliant ones
: (notably the IRIX and DEC ones) don't allow. Also, there are some
: quirks in structure vs. pointer passing that cause bugs to go unnoticed
: on the HP (by the code actually working) that will bite you on other
: platforms.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` James Youngman
@ 1996-08-19 4:00 ` Jianlin Chang
0 siblings, 0 replies; 56+ messages in thread
From: Jianlin Chang @ 1996-08-19 4:00 UTC (permalink / raw)
I found that on HP-UX 10.00 and 10.10, I can't attach to a process
using either gdb or xdb, but on HP-UX 9.01, I can. Previously, I had
been using primarily 10.x, that's why I can't do it.
James Youngman (JYoungman@vggas.com) wrote:
: In article <4v4o5g$cb@knot.queensu.ca>, chang@mjs1 says...
: >
: >Sorry, I am using gdb which doesn't allow me to attach to a process,
: Yes it does. Type "help attach".
: --
: James Youngman VG Gas Analysis Systems
: The trouble with the rat-race is, even if you win, you're still a rat.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
` (2 preceding siblings ...)
1996-08-17 4:00 ` Andrew Gabriel
@ 1996-08-19 4:00 ` Matt Houseman x4408
1996-08-19 4:00 ` Thomas Graichen
` (11 more replies)
1996-08-19 4:00 ` amk
1996-08-22 4:00 ` Roger Binns
5 siblings, 12 replies; 56+ messages in thread
From: Matt Houseman x4408 @ 1996-08-19 4:00 UTC (permalink / raw)
Jianlin Chang wrote:
>
> Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
> which is the
> best primary platform for UNIX system software development (and which
> version of
> the OS)? That is, which
> should you start with, then porting to other platfroms? There are lots
> of
> difference between stability, and availability of system services to
> aid system
> software programming. For example, HP-UX doesn't allow you to attach
> to a proces
> s from a debugger. Some OS are still not very POSIX compliant. Any
> comments?
> Thanks.
Since I've been brainwashed by our marketing group, I would choose
the platform that the largest segment of our customer base is on.
If it were completely up to me, I would choose Solaris 'cause if
you can get your app to run on Solaris, it'll run on anything!
I've always found that if I code to POSIX, I can port the app quite
easily.
Regards,
Matt
--
==================================================
Matt Houseman Arbor Software
mhouseman@arborsoft.com 408.541.4408
"...honest to the point of recklessness,
self-centered to the extreme..."
==================================================
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-17 4:00 ` Jianlin Chang
1996-08-19 4:00 ` James Youngman
1996-08-19 4:00 ` Jeff Diewald
@ 1996-08-19 4:00 ` Bill Deegan
1996-08-20 4:00 ` Ron Natalie
3 siblings, 0 replies; 56+ messages in thread
From: Bill Deegan @ 1996-08-19 4:00 UTC (permalink / raw)
To: chang
Re: OSF buggy.
While some of the earlier releases 2.0 or less my have had problems
I've been using Digital Unix 3.2{cd} and 4.0 without problems for
several years.
I'll agree that is a very good platform to start your port from
for numerous reasons.
1) Compilers are strict (and can be made very strict via compiler
flags)
2) Man pages indicate compliancy of the different system and non-system
calls.
3) FUSE has a lot of nice features for developing and maintaining
large projects (RCS, profiler,xref, class browser, graphical
debugger, + more)
4) ATOM toolkit which allows instrumentation of object level code
can be used to automatically debug executables.
--
William P. Deegan
Analysis & Verification tools - dept. 7141 +-----+
Third Party Interface & CAD - dept. 7221 +-----+
Layout - dept. 7142 +-----+
LSI Logic Corporation phone : (408) 433-7986 LSI|LOGIC|
1501 McCarthy Blvd. FAX : (408) 433-4156 | |
M/S E-192 email : deegan +-----+
Milpitas, Ca. 95035 internet : deegan@lsil.com
I Speak for myself and not my company or anyone else.
-------------------------------------------------------------------------
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
@ 1996-08-19 4:00 ` Thomas Graichen
1996-10-17 4:00 ` sukumar
1996-08-27 4:00 ` Martin Ibert
` (10 subsequent siblings)
11 siblings, 1 reply; 56+ messages in thread
From: Thomas Graichen @ 1996-08-19 4:00 UTC (permalink / raw)
Matt Houseman x4408 (mhouseman@arborsoft.com) wrote:
: If it were completely up to me, I would choose Solaris 'cause if
: you can get your app to run on Solaris, it'll run on anything!
. for that point you would run better with NetBSD or linux ... i think
anything is more than just x86, sparc and maybe something more ... :-)
t
--
thomas graichen graichen@mail.physik.fu-berlin.de graichen@FreeBSD.org
perfection is reached, not when there is no longer anything to add, but when
there is no longer anything to take away antoine de saint-exupery
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-17 4:00 ` Jianlin Chang
1996-08-19 4:00 ` James Youngman
@ 1996-08-19 4:00 ` Jeff Diewald
1996-08-19 4:00 ` Bill Deegan
1996-08-20 4:00 ` Ron Natalie
3 siblings, 0 replies; 56+ messages in thread
From: Jeff Diewald @ 1996-08-19 4:00 UTC (permalink / raw)
Jianlin Chang wrote:
>
> Sorry, I am using gdb which doesn't allow me to attach to a process, I
> don't like the interface of xdb, and never bothered to learn it.
>
> OSF is notoriously buggy and unstable for its initial versions, is it
> getting better?
>
I've been working on OSF, now Digital Unix, for quite some time now.
My systems have been very stable - and I beat on them pretty severely
during the course of my work day.
That work day is spent as one of the developers on the Ladebug
debugger, which comes as part of Digital Unix. Ladebug takes dbx
commands, and allows you to attach to a process - so you could
get an interface you're used to with the features you need.
I've used a lot of Unix boxes in my career. The Alpha I have under
my desk runs one of the best Unixes I've ever had - and I'm not just
saying that because I work for Digital. ;-)
-----------------------------------------------------------------------
Jeff Diewald EASYNET: VIRRUS::DIEWALD
Ladebug group INTERNET: diewald@zko.dec.com
Digital Equipment Corp.
Note: I don't read every article in this group. If you have debugger
questions, I may be able to get you an answer. You're much more likely
to get an answer if you put "Ladebug" somewhere in your subject line.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-17 4:00 ` Jianlin Chang
` (2 preceding siblings ...)
1996-08-19 4:00 ` Bill Deegan
@ 1996-08-20 4:00 ` Ron Natalie
3 siblings, 0 replies; 56+ messages in thread
From: Ron Natalie @ 1996-08-20 4:00 UTC (permalink / raw)
> OSF is notoriously buggy and unstable for its initial versions, is it
> getting better?
OSF1 past about gen 10 has been pretty good. Certainly, one the
3.x releases came out we've not had any OS problems to speak of.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` amk
@ 1996-08-20 4:00 ` guest
0 siblings, 0 replies; 56+ messages in thread
From: guest @ 1996-08-20 4:00 UTC (permalink / raw)
In article <4v9jaf$406@eccdb1.pms.ford.com> amk@ba0024.ba.ford.com
wrote:
> Had to respond to this: "For example, HP-UX doesn't allow you to attach
> to a process from a debugger...". Check out the man page (from HP-UX)
> on xdb, specifically the -P option. We do this all the time.
>
I don't know what JianLin means when he say "HP-UX doesn't allow you
to attach to a process from a debugger ...". However, I will agree with
him if he means "have trouble to attach". Our company upgradated to
HP-UX 10 recently and I do get trouble on attaching a running process
For small test code, there is no problem at all. But when trying to
attach our real code process(we do vfork()+ *exec()* because we use
pthread and need to avoid the hassle of thread resource management in
child process, so, attaching is the easiest way to catch and debug the
child process), the xdb simply issues "Attach failed":
%guest: ps -fu guest
UID PID PPID C STIME TTY TIME COMMAND
guest 16548 1 0 17:42:44 ? 0:00 bin/a.out
...
%guest: xdb -d src bin/a.out -P 16548
....
Attaching process 16548
Attach failed
%guest:
without further message. I am not work with JianLin despite we post
from same domain(I work in SF Bay and he in Toronto believe me or not).
So, if he has same trouble (i just know that from his post and your
followup)on attaching running process with xdb, then xdb must has some
bugs on attaching process not documented by the man page and the Release
Notes. Of cause, my code certainly has *lots of* bugs. That is what the
xdb for, isn't it?
However, I am not trying to say HP is a good or poor system for
development job(actually, I would like to work on HP for some kind job
and like to work on other platforms for other kinds of projects).
Sometime, you would like pick one depend on what you are going to do
(for example, I am now using DCE which is boundled with HP, so I will
not consider solaris or sunos even they are also nice and systems) and
sometime you simply have no choice.
-g
>Tony Kruse
>SysAdmin
>Ford Vehicle Operations Emissions Lab
>Allen Park, Mi USA
>akruse1@ford.com
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 ` Ron Natalie
` (2 preceding siblings ...)
1996-08-19 4:00 ` Jianlin Chang
@ 1996-08-21 4:00 ` Richard Cognot
3 siblings, 0 replies; 56+ messages in thread
From: Richard Cognot @ 1996-08-21 4:00 UTC (permalink / raw)
>>>>> "Ron" == Ron Natalie <ron@sensor.com> writes:
Ron> Jianlin Chang wrote:
>> That is, which should you start with, then porting to other
>> platfroms? There are lots of difference between stability, and
>> availability of system services to aid system software
>> programming. For example, HP-UX doesn't allow you to attach to
>> a proces s from a debugger. Some OS are still not very POSIX
>> compliant. Any comments?
Ron> The HP (where I do my development) has a vary "lenient"
Ron> enviornment. The compiler will accept constructs that
Ron> stricter ANSI compliant ones (notably the IRIX and DEC ones)
Ron> don't allow. Also, there are some quirks in structure
Ron> vs. pointer passing that cause bugs to go unnoticed on the HP
Ron> (by the code actually working) that will bite you on other
Ron> platforms.
Hmmm. Half of our developpers here are using SGIs, the others
HPs. Guess what: each time there is a problem after a developper
commited his changes to the CVS repository, it comes from... one of
the SGIs user!
Till recently, for exemple, the SGI c++ compiler allowed instanciation
of abstract classes, which HP chokes on (and rightfuly so).
But it's true that the HP compiler somewhat lacks behind when it comes
to template instanciations.
Richard.
--
|-------------------------------------------------------------|
| Richard Cognot | Proceed, with fingers crossed... |
| | /\^^/\ |
| <cognot@ensg.u-nancy.fr> | `' |
|-------------------------------------------------------------|
| http://www.ensg.u-nancy.fr/~cognot |
|-------------------------------------------------------------|
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
` (4 preceding siblings ...)
1996-08-19 4:00 ` amk
@ 1996-08-22 4:00 ` Roger Binns
5 siblings, 0 replies; 56+ messages in thread
From: Roger Binns @ 1996-08-22 4:00 UTC (permalink / raw)
Jianlin Chang (chang@mjs1) wrote:
: Among the major UNIX OS, Solaris, HP-UX, AIX, Digital-UNIX, IRIX,
: which is the
: best primary platform for UNIX system software development (and which
: version of
: the OS)?
If you intend the final software to run on lots of platforms, the earlier
you build and test on them, the better.
You will generally find that your tools, your libraries and your customers
determine the earliest version of an OS to support. As an example, you
are unlikely to find vendors supporting Solaris before 2.3.
For the main development OS, I would suggest looking at the development
hardware (eg you are going to need lots of disk space to store version control
repositories), and the various tools available (eg purify is an excellent
memory checker, but is only available for a limited number of platforms).
There is no one correct answer to your question, but hopefully this should
have given you some ideas about what to consider.
Roger
--
Roger Binns rogerb@sco.com | The reasonable man adapts himself to the world;
Software Engineer | the unreasonable one persists in trying to
Client Integration Division | to adapt the world to himself. Therefore all
SCO, Vision Park, Cambridge | progress depends on the unreasonable man - GBS
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Jianlin Chang
@ 1996-08-22 4:00 ` Jason C R Hill
0 siblings, 0 replies; 56+ messages in thread
From: Jason C R Hill @ 1996-08-22 4:00 UTC (permalink / raw)
xdb -P <pid> <object> attatches fine on HP-UX 10.01 (9000/837 G50)
jase
Jianlin Chang wrote:
>
> I found that on HP-UX 10.00 and 10.10, I can't attach to a process
> using either gdb or xdb, but on HP-UX 9.01, I can. Previously, I had
> been using primarily 10.x, that's why I can't do it.
>
> Ron Natalie (ron@sensor.com) wrote:
> : Jianlin Chang wrote:
> : > That is, which
> : > should you start with, then porting to other platfroms? There are lots
> : > of
> : > difference between stability, and availability of system services to
> : > aid system
> : > software programming. For example, HP-UX doesn't allow you to attach
> : > to a proces
> : > s from a debugger. Some OS are still not very POSIX compliant. Any
> : > comments?
>
> : The comment about HP-UX not allowing to connect to a process with the
> : debugger is just blatently wrong. Try looking up the -P option.
>
> : Of course, the best platform is probably the most difficult one. In
> : my opinion you should start with a DEC Alpha. It will catch your
> : assumptions about pointer and integer sizes and give you an alternate
> : view of byte orders.
>
> : The HP (where I do my development) has a vary "lenient" enviornment.
> : The compiler will accept constructs that stricter ANSI compliant ones
> : (notably the IRIX and DEC ones) don't allow. Also, there are some
> : quirks in structure vs. pointer passing that cause bugs to go unnoticed
> : on the HP (by the code actually working) that will bite you on other
> : platforms.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
1996-08-19 4:00 ` Thomas Graichen
@ 1996-08-27 4:00 ` Martin Ibert
1996-08-29 4:00 ` Mike Miscevic
1996-08-29 4:00 ` Wojciech Galazka
1996-09-02 4:00 ` mib
` (9 subsequent siblings)
11 siblings, 2 replies; 56+ messages in thread
From: Martin Ibert @ 1996-08-27 4:00 UTC (permalink / raw)
In article <32189D13.3834@arborsoft.com> Matt Houseman x4408 <mhouseman@arborsoft.com> writes:
: If it were completely up to me, I would choose Solaris 'cause if
: you can get your app to run on Solaris, it'll run on anything!
Not so. (Really, I'm talking from experience.) I do subscribe to your
line of reasoning, but Solaris is not the the way to. No platform that
has sizeof(int) == sizeof(long) resp. sizeof(int) == sizeof(void*)
should be your choice in this case.
In porting your average vintage UN*X app, you'll encounter endless
headaches from missing prototypes, wrong *printf formats, free mixing
of int and long, ...
Before I first came across a 64-bit-UN*X, I'd also recommended
Solaris. These days, I'd recommand Digital UNIX.
--
---------------------------------------------------------------------------
Dipl.-Inform. Martin Ibert, BB-DATA GmbH, Brunnenstra�e 111, D-13355 Berlin
E-Mail <mib@ppe.bb-data.de> - Phone +49-30-245-56582 - Fax +49-30-245-56577
\/\Disclaimer: My views do not necessarily reflect those of my employer./\/
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-27 4:00 ` Martin Ibert
@ 1996-08-29 4:00 ` Mike Miscevic
1996-09-04 4:00 ` Patrick Horgan
1996-08-29 4:00 ` Wojciech Galazka
1 sibling, 1 reply; 56+ messages in thread
From: Mike Miscevic @ 1996-08-29 4:00 UTC (permalink / raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1373 bytes --]
Martin Ibert (mib@bb-data.de) wrote:
: In article <32189D13.3834@arborsoft.com> Matt Houseman x4408 <mhouseman@arborsoft.com> writes:
:
: : If it were completely up to me, I would choose Solaris 'cause if
: : you can get your app to run on Solaris, it'll run on anything!
:
: Not so. (Really, I'm talking from experience.) I do subscribe to your
: line of reasoning, but Solaris is not the the way to. No platform that
: has sizeof(int) == sizeof(long) resp. sizeof(int) == sizeof(void*)
: should be your choice in this case.
:
: In porting your average vintage UN*X app, you'll encounter endless
: headaches from missing prototypes, wrong *printf formats, free mixing
: of int and long, ...
:
: Before I first came across a 64-bit-UN*X, I'd also recommended
: Solaris. These days, I'd recommand Digital UNIX.
: --
: ---------------------------------------------------------------------------
: Dipl.-Inform. Martin Ibert, BB-DATA GmbH, Brunnenstra�e 111, D-13355 Berlin
: E-Mail <mib@ppe.bb-data.de> - Phone +49-30-245-56582 - Fax +49-30-245-56577
: \/\Disclaimer: My views do not necessarily reflect those of my employer./\/
--
Mike Miscevic email: mmiscevi@on.bell.ca
Bell Sygma Telecom Solutions IIS: MMISCEVI
160 Elgin Street, room 550 phone: (613) 781-4361
Ottawa, Ontario K2P 2C4 fax: (613) 238-7772
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-27 4:00 ` Martin Ibert
1996-08-29 4:00 ` Mike Miscevic
@ 1996-08-29 4:00 ` Wojciech Galazka
1996-08-29 4:00 ` Scott G. Hall
1 sibling, 1 reply; 56+ messages in thread
From: Wojciech Galazka @ 1996-08-29 4:00 UTC (permalink / raw)
In article <kiawwyl8j89.fsf@laforge.ppe.bb-data.de> mib@bb-data.de (Martin Ibert) writes:
>From: mib@bb-data.de (Martin Ibert)
>Subject: Re: best UNIX OS as primary platform for UNIX system software develpoment?
>Date: 27 Aug 1996 07:54:46 +0200
>Before I first came across a 64-bit-UN*X, I'd also recommended
>Solaris. These days, I'd recommand Digital UNIX.
>--
Try Linux first.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Wojciech Galazka
@ 1996-08-29 4:00 ` Scott G. Hall
1996-08-30 4:00 ` Timothy M. Wieman
` (3 more replies)
0 siblings, 4 replies; 56+ messages in thread
From: Scott G. Hall @ 1996-08-29 4:00 UTC (permalink / raw)
Wojciech Galazka <wgalazka@zoolook.chem.uw.edu.pl> wrote:
>mib@bb-data.de (Martin Ibert) writes:
>>From: mib@bb-data.de (Martin Ibert)
>>Subject: Re: best UNIX OS as primary platform for UNIX system software develpoment?
>>Date: 27 Aug 1996 07:54:46 +0200
>
>>Before I first came across a 64-bit-UN*X, I'd also recommended
>>Solaris. These days, I'd recommand Digital UNIX.
>>
>Try Linux first.
No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
something where these are different.
--
"It was our last, best hope for peace -- it failed. | Scott G. Hall
Now it's our last best hope." (Babylon-5 opener) | Lucent Technologies
----------------------------------------------------------| Bell Labs - BCS
Scott.Hall@bell-labs.com sgh@cbgbcs.cb.lucent.com | Columbus, OH, USA
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Scott G. Hall
1996-08-30 4:00 ` Timothy M. Wieman
1996-08-30 4:00 ` Jon Reeves
@ 1996-08-30 4:00 ` R!ch
1996-09-01 4:00 ` John J. Rushford
3 siblings, 0 replies; 56+ messages in thread
From: R!ch @ 1996-08-30 4:00 UTC (permalink / raw)
To: Scott G. Hall
On 29 Aug 1996, Scott G. Hall wrote:
> Wojciech Galazka <wgalazka@zoolook.chem.uw.edu.pl> wrote:
> >mib@bb-data.de (Martin Ibert) writes:
> >>From: mib@bb-data.de (Martin Ibert)
> >>Subject: Re: best UNIX OS as primary platform for UNIX system software develpoment?
> >>Date: 27 Aug 1996 07:54:46 +0200
> >
> >>Before I first came across a 64-bit-UN*X, I'd also recommended
> >>Solaris. These days, I'd recommand Digital UNIX.
> >>
> >Try Linux first.
>
> No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
> something where these are different.
Not sure I agree here. Certainly, one should code assuming that
sizeof (int) != sizeof (long). And more to the point (no pun intended!),
sizeof ({int, long}) != sizeof (void *).
I guess using a machine for which the above cases are true helps, but IMHO,
a good programmer should make no such assumptions.
---
R!ch
If it ain't analogue, it ain't music.
#include <disclaimer.h> \\|// - ?
(o o)
/==================================oOOo=(_)=oOOo========\
| Richard Teer richard.teer@uk.sun.com |
| Sun Service Contractor |
| Voice: +44 (0)1276 691974 |
\=======================================================/
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Scott G. Hall
1996-08-30 4:00 ` Timothy M. Wieman
@ 1996-08-30 4:00 ` Jon Reeves
1996-08-30 4:00 ` R!ch
1996-09-01 4:00 ` John J. Rushford
3 siblings, 0 replies; 56+ messages in thread
From: Jon Reeves @ 1996-08-30 4:00 UTC (permalink / raw)
In article <5050gc$1fc@nntpa.cb.lucent.com>, sgh@cbgbcs.cb.att.com (Scott G. Hall) writes:
|> No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
|> something where these are different.
Like, for instance, Linux (when run on an Alpha platform, that is).
(Though I personally do more software development on Digital UNIX, for obvious
reasons.)
--
Jon Reeves Digital UNIX Software Group reeves@zk3.dec.com
MA/NH movie schedules: http://www.sai.com/movies/ or "help" to mtw@zk3.dec.com
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Scott G. Hall
@ 1996-08-30 4:00 ` Timothy M. Wieman
1996-08-30 4:00 ` Jon Reeves
` (2 subsequent siblings)
3 siblings, 0 replies; 56+ messages in thread
From: Timothy M. Wieman @ 1996-08-30 4:00 UTC (permalink / raw)
Scott G. Hall (sgh@cbgbcs.cb.att.com) wrote:
> Wojciech Galazka <wgalazka@zoolook.chem.uw.edu.pl> wrote:
> >mib@bb-data.de (Martin Ibert) writes:
> >>From: mib@bb-data.de (Martin Ibert)
> >>Subject: Re: best UNIX OS as primary platform for UNIX system software develpoment?
> >>Date: 27 Aug 1996 07:54:46 +0200
> >
> >>Before I first came across a 64-bit-UN*X, I'd also recommended
> >>Solaris. These days, I'd recommand Digital UNIX.
> >>
> >Try Linux first.
>
> No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
> something where these are different.
I've also got to plug a 64-bit-UN*X (in my case Digital UNIX). We do
a lot of malloc'ing large chunks, pointing fields of structures into these
chunks, and then later dereferencing these pointers. Alignment becomes
a big issue in this case, and a 64-bit UN*X (at least Digital UNIX)
makes the structs be aligned on an 8 byte bound. Well, if it's aligned
on 8 byte, it'll also be aligned on 4 byte for the 32-bit platforms.
Another good thing (I think) about Digital UNIX is that it will NOT let
you dereference a NULL pointer (some may argue that this is valid,
though). Other OS's I've worked on WILL let you do this (AIX, SCO,
UnixWare, Interactive, DG-UX, and I believe HP-UX). Don't know about
IRIX and Solaris.
Just my 2 pennies -- Tim
--
------------------------------------------------------------------------
Timothy M. Wieman | PACE Health Management Systems
Software Engineer | 1025 Ashworth Rd. Suite 200 Voice: 515.222.1717
timw@hces.com | West Des Moines, IA 50265 Fax: 515.222.1716
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Scott G. Hall
` (2 preceding siblings ...)
1996-08-30 4:00 ` R!ch
@ 1996-09-01 4:00 ` John J. Rushford
1996-09-02 4:00 ` Pawel Wezgowiec
3 siblings, 1 reply; 56+ messages in thread
From: John J. Rushford @ 1996-09-01 4:00 UTC (permalink / raw)
Scott G. Hall (sgh@cbgbcs.cb.att.com) wrote:
: Wojciech Galazka <wgalazka@zoolook.chem.uw.edu.pl> wrote:
: >mib@bb-data.de (Martin Ibert) writes:
: >>From: mib@bb-data.de (Martin Ibert)
: >>Subject: Re: best UNIX OS as primary platform for UNIX system software develpoment?
: >>Date: 27 Aug 1996 07:54:46 +0200
: >
: >>Before I first came across a 64-bit-UN*X, I'd also recommended
: >>Solaris. These days, I'd recommand Digital UNIX.
: >>
: >Try Linux first.
: No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
: something where these are different.
sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not just Linux
or Solaris x86 and has been for a long time. Just curious as to why you use
this criteria to judge which OS to use.
John
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (2 preceding siblings ...)
1996-09-02 4:00 ` mib
@ 1996-09-02 4:00 ` mib
1996-09-02 4:00 ` Robert Lipe
1996-09-03 4:00 ` mib
` (7 subsequent siblings)
11 siblings, 1 reply; 56+ messages in thread
From: mib @ 1996-09-02 4:00 UTC (permalink / raw)
timw@isac.hces.com (Timothy M. Wieman) writes:
> Another good thing (I think) about Digital UNIX is that it will NOT let
> you dereference a NULL pointer (some may argue that this is valid,
> though). Other OS's I've worked on WILL let you do this (AIX, SCO,
> UnixWare, Interactive, DG-UX, and I believe HP-UX). Don't know about
> IRIX and Solaris.
Solaris shoots dereferenced NULLs on sight (which is why I used to
recommend it). So does HP-UX if you let it (it's optional). So does Linux.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
1996-08-19 4:00 ` Thomas Graichen
1996-08-27 4:00 ` Martin Ibert
@ 1996-09-02 4:00 ` mib
1996-09-02 4:00 ` mib
` (8 subsequent siblings)
11 siblings, 0 replies; 56+ messages in thread
From: mib @ 1996-09-02 4:00 UTC (permalink / raw)
wjjr@sapphire.alisa.org (John J. Rushford) writes:
> sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not just Linux
> or Solaris x86 and has been for a long time. Just curious as to why you use
> this criteria to judge which OS to use.
Take another look at the subject. For primary development, use the
platform that is most unforgiving when it comes to coding errors, and
port to more lenient platforms. The other way around it is a nightmare (believe
me--I've been there). Two of the most frequent coding errors in the
UNIX developer community (precisely because it is, as you say, common
to have int and long to be identical) is to confuse ints and longs,
especially when it comes to passing parameters, mixing pointers, and
*printf formats, and "tunneling" pointer values through int variables
and arguments. Try porting a 100.000+ lines of code application laced
with these bugs to Digital Unix *shudder*. If you code for dUNIX
first, you'll catch these buggers up-front. Plus, you learn to avoid them.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-02 4:00 ` mib
@ 1996-09-02 4:00 ` Robert Lipe
1996-09-04 4:00 ` Tom Kelly
0 siblings, 1 reply; 56+ messages in thread
From: Robert Lipe @ 1996-09-02 4:00 UTC (permalink / raw)
In <uraoltob2.fsf@ppe.bb-data.de> mib@ppe.bb-data.de writes:
>timw@isac.hces.com (Timothy M. Wieman) writes:
>> Another good thing (I think) about Digital UNIX is that it will NOT let
>> you dereference a NULL pointer (some may argue that this is valid,
>> though). Other OS's I've worked on WILL let you do this (AIX, SCO,
>> UnixWare, Interactive, DG-UX, and I believe HP-UX). Don't know about
>> IRIX and Solaris.
>Solaris shoots dereferenced NULLs on sight (which is why I used to
>recommend it). So does HP-UX if you let it (it's optional). So does Linux.
Just for completness of your list, SCO OpenServer 5 has two kernel
tunables to allow you adjust the behaviour.
'notice_null_refs' prints the PID, name, etc. of the process on
the console. Clearly, this is useful only if you're sitting
at the console or are otherwise watching /var/adm/messages.
'signal_null_refs' delivers a signal to the offenders.
Yes, it's smart enough to look at the object file format and know if
a NULL deref really is valid. For example, on an OMF (xenix) binary,
it's legal so it won't whine or signal. For an ELF binary, it's never
legal, so it invokes the appropriate militant behaviour.
--
Robert Lipe
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-01 4:00 ` John J. Rushford
@ 1996-09-02 4:00 ` Pawel Wezgowiec
0 siblings, 0 replies; 56+ messages in thread
From: Pawel Wezgowiec @ 1996-09-02 4:00 UTC (permalink / raw)
On Sun, 1 Sep 1996, John J. Rushford wrote:
> Scott G. Hall (sgh@cbgbcs.cb.att.com) wrote:
> : Wojciech Galazka <wgalazka@zoolook.chem.uw.edu.pl> wrote:
> : >mib@bb-data.de (Martin Ibert) writes:
> : No -- Linux has the same problem: sizeof(int) == sizeof(long). You need
> : something where these are different.
>
> sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not just Linux
> or Solaris x86 and has been for a long time. Just curious as to why you use
> this criteria to judge which OS to use.
>
Hmm...
This complicated piece of code I run on our HP9000 K200 under HP-UX
10.01:
-------------------------------------
#include <iostream.h>
int main()
{
cout << "Size of int = " << sizeof(int) << endl;
cout << "Size of long = " << sizeof(long) << endl;
cout << "Size of long long = " << sizeof(long long) << endl;
return 0;
}
-------------------------------
I compiled it with gcc 2.7.2.1 (I haven't got HP C++,
and I don't want to rewrite it to "printf version" to compile
it with the original cc) - AFAIK the result would be the same
with the original one.
What was the output ?
-----------------------------
Size of int = 4
Size of long = 4
Size of long long = 8
-------------------------------
Is HP-UX that bad platform ??
Probably there are more Unix systems with
sizeof(int) == sizeof(long). But I don't think it's
really important.
If I were you I'd focused on the quality of development tools
for the "recommended platform".
Assuming size of data types is one of the best ways to
write code very hard to maintain. Along with some other
"hard-coded" code it would be not the primary but the only
platform for your application.
Paul
=======================================================================
Pawel Wezgowiec | Technical University of Czestochowa
| Institute of Mathematics
Network Administrator | and Computer Science
=======================================================================
http://k2.pcz.czest.pl/~paulw
=======================================================================
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (3 preceding siblings ...)
1996-09-02 4:00 ` mib
@ 1996-09-03 4:00 ` mib
1996-09-06 4:00 ` Per Schr�der
1996-09-03 4:00 ` Chuck Dillon
` (6 subsequent siblings)
11 siblings, 1 reply; 56+ messages in thread
From: mib @ 1996-09-03 4:00 UTC (permalink / raw)
Pawel Wezgowiec <paulw@k2.pcz.czest.pl> writes:
> Is HP-UX that bad platform ??
>
> Probably there are more Unix systems with
> sizeof(int) == sizeof(long). But I don't think it's
> really important.
If you are a very good developer who doesn't make the stupid kind of
mistakes we mere mortals make (and you don't have any code from mere
mortals to maintain or incorporate into your code), or if you
absolutely, positively know that you'll never port your code to a
platform where ints and longs are really distinct types, then it is
not important.
But my experience, people do make mistakes like
time_t t;
sprintf(buf, "%ld", t);
or
long l;
time(&l);
or
int foo(long *l);
int i;
foo(&i);
or
int foo(int i)
{
void *p=(void*)i;
}
or
...
Believe me. It does happen (especially legacy code is full of this
kind of stuff). And if you have to weed these out during a port -- nightmare.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (5 preceding siblings ...)
1996-09-03 4:00 ` Chuck Dillon
@ 1996-09-03 4:00 ` Martin Knoblauch
1996-09-04 4:00 ` Urs Thuermann
` (4 subsequent siblings)
11 siblings, 0 replies; 56+ messages in thread
From: Martin Knoblauch @ 1996-09-03 4:00 UTC (permalink / raw)
mib@ppe.bb-data.de wrote:
>
> Pawel Wezgowiec <paulw@k2.pcz.czest.pl> writes:
>
> > Is HP-UX that bad platform ??
> >
> > Probably there are more Unix systems with
> > sizeof(int) == sizeof(long). But I don't think it's
> > really important.
>
I would actually say, that most 32-bit OSes will have that
relation. But it is a big mistake to assume that this holds
forever. This implicit assumption is probably the major
hurdle when porting from ILP32 (-32/-n32) to LP64 (-64).
> If you are a very good developer who doesn't make the stupid kind of
> mistakes we mere mortals make (and you don't have any code from mere
> mortals to maintain or incorporate into your code), or if you
> absolutely, positively know that you'll never port your code to a
> platform where ints and longs are really distinct types, then it is
> not important.
>
> But my experience, people do make mistakes like
>
> time_t t;
> sprintf(buf, "%ld", t);
>
> or
>
> long l;
> time(&l);
>
> or
> int foo(long *l);
> int i;
>
> foo(&i);
>
> or
> int foo(int i)
> {
> void *p=(void*)i;
> }
>
> or
>
> ...
>
> Believe me. It does happen (especially legacy code is full of this
> kind of stuff). And if you have to weed these out during a
> port -- nightmare.
Actually, the compilers for n32/64 are pretty good at
showing you how crappy your code is. If you want all the
fun, just turn on "-fullwarn".
Martin
--
+---------------------------------+-----------------------------------+
|Martin Knoblauch | Silicon Graphics GmbH |
|Manager Application Center | Am Hochacker 3 - Technopark |
|Silicon Graphics Computer Systems| D-85630 Grasbrunn-Neukeferloh, FRG|
| | Phone: (+int) 89 46108-179 or -0 |
| | Fax: (+int) 89 46108-190 (-222) |
+---------------------------------+-----------------------------------+
|e-mail: <knobi@munich.sgi.com> | V-Mail: 5-8935 | M/S: IDE-3150 |
+---------------------------------------------------------------------+
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (4 preceding siblings ...)
1996-09-03 4:00 ` mib
@ 1996-09-03 4:00 ` Chuck Dillon
1996-09-03 4:00 ` Poll Dubh
1996-09-06 4:00 ` Paul T. Wilson
1996-09-03 4:00 ` Martin Knoblauch
` (5 subsequent siblings)
11 siblings, 2 replies; 56+ messages in thread
From: Chuck Dillon @ 1996-09-03 4:00 UTC (permalink / raw)
mib@ppe.bb-data.de wrote:
>
> wjjr@sapphire.alisa.org (John J. Rushford) writes:
>
> > sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not just Linux
> > or Solaris x86 and has been for a long time. Just curious as to why you use
> > this criteria to judge which OS to use.
>
> Take another look at the subject. For primary development, use the
> platform that is most unforgiving when it comes to coding errors, and
> port to more lenient platforms. The other way around it is a nightmare (believe
> me--I've been there). Two of the most frequent coding errors in the
> UNIX developer community (precisely because it is, as you say, common
> to have int and long to be identical) is to confuse ints and longs,
> especially when it comes to passing parameters, mixing pointers, and
> *printf formats, and "tunneling" pointer values through int variables
> and arguments. Try porting a 100.000+ lines of code application laced
> with these bugs to Digital Unix *shudder*. If you code for dUNIX
> first, you'll catch these buggers up-front. Plus, you learn to avoid them.
I would respectfully submit that you should not equate your development
environment with your test bed. If you force yourself to develop on
your 'most unforgiving' target environment you may significantly reduce
your productivity. A much better development environment could be
available on another system. Development of portable code is a matter
of discipline. I would agree that your 'most unforgiving' target should
be the first one tested against. If the system passes that test it should
work on less 'unforgiving' systems. Your development environment can and
should keep you from developing non-portable code as defined by your
coding standards regardless of what platform it runs on.
I don't mean to argue against dUNIX or for any other system. Only to
point out that there are tradeoffs to be considered.
--
Chuck Dillon
ced@noran.com
--- Gratuitous waste of bandwidth omitted ---
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-03 4:00 ` Chuck Dillon
@ 1996-09-03 4:00 ` Poll Dubh
1996-09-06 4:00 ` Paul T. Wilson
1 sibling, 0 replies; 56+ messages in thread
From: Poll Dubh @ 1996-09-03 4:00 UTC (permalink / raw)
>mib@ppe.bb-data.de wrote:
>> wjjr@sapphire.alisa.org (John J. Rushford) writes:
>> > sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not just Linux
>> > or Solaris x86 and has been for a long time. Just curious as to why you use
>> > this criteria to judge which OS to use.
>> Take another look at the subject. For primary development, use the
>> platform that is most unforgiving when it comes to coding errors, and
>> port to more lenient platforms. The other way around it is a nightmare (believe
>> me--I've been there). Two of the most frequent coding errors in the
>> UNIX developer community (precisely because it is, as you say, common
>> to have int and long to be identical) is to confuse ints and longs,
>> especially when it comes to passing parameters, mixing pointers, and
>> *printf formats, and "tunneling" pointer values through int variables
>> and arguments. Try porting a 100.000+ lines of code application laced
>> with these bugs to Digital Unix *shudder*. If you code for dUNIX
>> first, you'll catch these buggers up-front. Plus, you learn to avoid them.
A good compiler will warn you about these things. My makefiles tend to have
CC=gcc -ansi -pedantic -Wall -Wtraditional -Wpointer-arith -Wcast-qual \
-Wcast-align -Wwrite-strings -Wconversion -Wstrict-prototypes \
-Wmissing-prototypes -Waggregate-return
(and also -fshort-enums, but that's besides the point).
Parameter passing? Anything without a prototype will be flagged.
Prototype mismatches will be flagged. Cases where old K&R C
would implicitly change the passed type are flagged.
Mixing pointers? Will be flagged too, albeit perhaps not quite as
strictly as with IBM's XL compilers for AIX.
*printf formats? Mismatches between int and long int are flagged.
Since gcc runs on many platforms, the only factor left is the quality
of each platform's /usr/include header files. I'm not sure which is most
unforgiving.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (6 preceding siblings ...)
1996-09-03 4:00 ` Martin Knoblauch
@ 1996-09-04 4:00 ` Urs Thuermann
1996-09-05 4:00 ` Peter Gross
1996-09-05 4:00 ` Ronald Fischer
` (3 subsequent siblings)
11 siblings, 1 reply; 56+ messages in thread
From: Urs Thuermann @ 1996-09-04 4:00 UTC (permalink / raw)
In article <u7mqcma7d.fsf@ppe.bb-data.de> mib@ppe.bb-data.de writes:
> But my experience, people do make mistakes like
>
> time_t t;
> sprintf(buf, "%ld", t);
What is the portable way to printf size_t, time_t, and so on values?
On some machines, where int is 16 bit, size_t and time_t will be
typedefed as long so %ld seems right. On most unices they are
typedefed as int.
Is there another portable way than
time_t t;
printf("%ld", (long)t);
urs
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-02 4:00 ` Robert Lipe
@ 1996-09-04 4:00 ` Tom Kelly
0 siblings, 0 replies; 56+ messages in thread
From: Tom Kelly @ 1996-09-04 4:00 UTC (permalink / raw)
Robert Lipe wrote:
>
> In <uraoltob2.fsf@ppe.bb-data.de> mib@ppe.bb-data.de writes:
>
>
> Just for completness of your list, SCO OpenServer 5 has two kernel
> tunables to allow you adjust the behaviour.
>
> 'notice_null_refs' prints the PID, name, etc. of the process on
> the console. Clearly, this is useful only if you're sitting
> at the console or are otherwise watching /var/adm/messages.
>
> 'signal_null_refs' delivers a signal to the offenders.
Sometimes changing kernel configuration parameters is not possible (you
aren't root, or your threats are insufficiently terrifying. :-)) or
inadvisable (you don't want to change the behaviour for everyone).
On ftp.sco.com in TLS/tls594.* is a little program that allows you to
trap
null pointer references on a case-by-case basis.
Tom Kelly
tom@mks.com
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-29 4:00 ` Mike Miscevic
@ 1996-09-04 4:00 ` Patrick Horgan
0 siblings, 0 replies; 56+ messages in thread
From: Patrick Horgan @ 1996-09-04 4:00 UTC (permalink / raw)
In article <DwvqEq.8BK@on.bell.ca>, mmiscevi@on.bell.ca (Mike Miscevic) writes:
> Martin Ibert (mib@bb-data.de) wrote:
> : In article <32189D13.3834@arborsoft.com> Matt Houseman x4408 <mhouseman@arborsoft.com> writes:
> :
> : : If it were completely up to me, I would choose Solaris 'cause if
> : : you can get your app to run on Solaris, it'll run on anything!
> :
> : Not so. (Really, I'm talking from experience.) I do subscribe to your
> : line of reasoning, but Solaris is not the the way to. No platform that
> : has sizeof(int) == sizeof(long) resp. sizeof(int) == sizeof(void*)
> : should be your choice in this case.
> :
Don't make the mistake of thinking that this is platform dependent. I've worked
on platforms where one compiler had sizeof(int) == sizeof(long) and a compiler
from another vendor had sizeof(int) < sizeof(long). The relationship of int and
long is not a platform issue but an implementation detail. (Of course the
specs say that sizeof(int)<=sizeof(long) ). I've seen other compilers where
this was dependent on compiler flags.
--
Patrick J. Horgan patrick@broadvision.com Have horse will ride.
Opinions mine, not my employer's except by most bizarre coincidence.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (8 preceding siblings ...)
1996-09-05 4:00 ` Ronald Fischer
@ 1996-09-05 4:00 ` mib
1996-09-06 4:00 ` mib
1996-09-06 4:00 ` Peter Mayne
11 siblings, 0 replies; 56+ messages in thread
From: mib @ 1996-09-05 4:00 UTC (permalink / raw)
thuerman@ibr.cs.tu-bs.de (Urs Thuermann) writes:
> Is there another portable way than
>
> time_t t;
> printf("%ld", (long)t);
No. That's the best you can do. I've made a habit of casting printf
arguments every time, unless the type is totally clear. At the very
least, entities of the POSIXy types like pid_t or uid_t must be cast
(casted? Non-native speaker, sorry.) before use as a printf argument.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (7 preceding siblings ...)
1996-09-04 4:00 ` Urs Thuermann
@ 1996-09-05 4:00 ` Ronald Fischer
1996-09-05 4:00 ` mib
` (2 subsequent siblings)
11 siblings, 0 replies; 56+ messages in thread
From: Ronald Fischer @ 1996-09-05 4:00 UTC (permalink / raw)
To: Urs Thuermann
Urs Thuermann wrote:
> What is the portable way to printf size_t, time_t, and so on values?
> On some machines, where int is 16 bit, size_t and time_t will be
> typedefed as long so %ld seems right. On most unices they are
> typedefed as int.
>
> Is there another portable way than
>
> time_t t;
> printf("%ld", (long)t);
What about
printf(sizeof(long)==sizeof(time_t) ? "%ld" : "%d",t)
--
Ronald Otto Valentin Fischer
business: ronald.fischer@uebemc.siemens.de
private: ronald.fischer@acm.org
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-04 4:00 ` Urs Thuermann
@ 1996-09-05 4:00 ` Peter Gross
0 siblings, 0 replies; 56+ messages in thread
From: Peter Gross @ 1996-09-05 4:00 UTC (permalink / raw)
thuerman@ibr.cs.tu-bs.de (Urs Thuermann) wrote:
>In article <u7mqcma7d.fsf@ppe.bb-data.de> mib@ppe.bb-data.de writes:
>> But my experience, people do make mistakes like
>>
>> time_t t;
>> sprintf(buf, "%ld", t);
>What is the portable way to printf size_t, time_t, and so on values?
>On some machines, where int is 16 bit, size_t and time_t will be
>typedefed as long so %ld seems right. On most unices they are
>typedefed as int.
>Is there another portable way than
> time_t t;
> printf("%ld", (long)t);
The portable way is to use C++ :)
time_t t;
cout << t;
peter gross
pag@probita.com
+1.303.546.6307 x3329
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-03 4:00 ` Chuck Dillon
1996-09-03 4:00 ` Poll Dubh
@ 1996-09-06 4:00 ` Paul T. Wilson
1996-09-09 4:00 ` Chuck Dillon
1 sibling, 1 reply; 56+ messages in thread
From: Paul T. Wilson @ 1996-09-06 4:00 UTC (permalink / raw)
In article <322C385A.1AB4@noran.com>, Chuck Dillon <ced@noran.com> wrote:
>mib@ppe.bb-data.de wrote:
>>
>> wjjr@sapphire.alisa.org (John J. Rushford) writes:
>>
>> > sizeof(int) == sizeof(long) is true on a lot of UNIX platforms not
just Linux
>> > or Solaris x86 and has been for a long time. Just curious as to why
you use
>> > this criteria to judge which OS to use.
>>
>> Take another look at the subject. For primary development, use the
>> platform that is most unforgiving when it comes to coding errors, and
>> port to more lenient platforms. The other way around it is a nightmare
(believe
>> me--I've been there). Two of the most frequent coding errors in the
>> UNIX developer community (precisely because it is, as you say, common
>> to have int and long to be identical) is to confuse ints and longs,
>> especially when it comes to passing parameters, mixing pointers, and
>> *printf formats, and "tunneling" pointer values through int variables
>> and arguments. Try porting a 100.000+ lines of code application laced
>> with these bugs to Digital Unix *shudder*. If you code for dUNIX
>> first, you'll catch these buggers up-front. Plus, you learn to avoid them.
>
>I would respectfully submit that you should not equate your development
>environment with your test bed. If you force yourself to develop on
>your 'most unforgiving' target environment you may significantly reduce
>your productivity. A much better development environment could be
>available on another system. Development of portable code is a matter
>of discipline. I would agree that your 'most unforgiving' target should
>be the first one tested against. If the system passes that test it should
>work on less 'unforgiving' systems. Your development environment can and
>should keep you from developing non-portable code as defined by your
>coding standards regardless of what platform it runs on.
>
>I don't mean to argue against dUNIX or for any other system. Only to
>point out that there are tradeoffs to be considered.
My only comment to this Chuck is that in more than 18 years of programming
I've yet to work with a "development environment" by which I assume you
mean some capability that has some level of smarts and helps you create
the program. As a programmer I still need to know that int != long.
Indeed, being familiar with the differences between platforms provides the
necessary heads up if you haven't developed "portable" code. Frankly,
simply because portability was not a requirement much of the code I've
written hasn't been "portable". But, believe it or not, it's been ported.
The discipline necessary to practice correct ("portable") programming is
not, IMHO, instilled by a "development environment". Not that I wouldn't
like to program in one!
--
Paul T. Wilson Programmer Guy (:-)
Look, do you mind if we have an argument here? - Merlo
Do you have enough mind for an argument here? - Marty
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (10 preceding siblings ...)
1996-09-06 4:00 ` mib
@ 1996-09-06 4:00 ` Peter Mayne
1996-09-06 4:00 ` Eric Fischer
` (2 more replies)
11 siblings, 3 replies; 56+ messages in thread
From: Peter Mayne @ 1996-09-06 4:00 UTC (permalink / raw)
Ronald Fischer wrote:
>
> Urs Thuermann wrote:
>
> > What is the portable way to printf size_t, time_t, and so on values?
> > On some machines, where int is 16 bit, size_t and time_t will be
> > typedefed as long so %ld seems right. On most unices they are
> > typedefed as int.
> >
> > Is there another portable way than
> >
> > time_t t;
> > printf("%ld", (long)t);
>
> What about
> printf(sizeof(long)==sizeof(time_t) ? "%ld" : "%d",t)
Who said time_t is a scalar? It might be something else, mightn't it?
Use ctime(3) or locatime(3) and print the results.
--
PJDM
Digital Equipment Corporation (Australia), Canberra, ACT
-------------------------------------------------------------------------------
These are my opinions, and have nothing to do with Digital.
I design Internet Service Providers. It's a job.
.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Matt Houseman x4408
` (9 preceding siblings ...)
1996-09-05 4:00 ` mib
@ 1996-09-06 4:00 ` mib
1996-09-06 4:00 ` Peter Mayne
11 siblings, 0 replies; 56+ messages in thread
From: mib @ 1996-09-06 4:00 UTC (permalink / raw)
Ronald Fischer <ronald.fischer@uebemc.siemens.de> writes:
> What about
> printf(sizeof(long)==sizeof(time_t) ? "%ld" : "%d",t)
Is there any guarantee that time_t is either long or int? I doubt it.
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-03 4:00 ` mib
@ 1996-09-06 4:00 ` Per Schr�der
0 siblings, 0 replies; 56+ messages in thread
From: Per Schr�der @ 1996-09-06 4:00 UTC (permalink / raw)
In article <u7mqcma7d.fsf@ppe.bb-data.de>, mib@ppe.bb-data.de
<kiawwyl8j89.fsf@laforge.ppe.bb-data.de>
<wgalazka.213.841321343@zoolook.chem.uw.edu.pl>
<5050gc$1fc@nntpa.cb.lucent.com> <Dx2Hx7.AFw@sapphire.alisa.org>
<Pine.HPP.3.94.960902140235.15361A-100000@k2.pcz.czest.pl> wrote:
>Pawel Wezgowiec <paulw@k2.pcz.czest.pl> writes:
>
>> Is HP-UX that bad platform ??
>>
>> Probably there are more Unix systems with
>> sizeof(int) == sizeof(long). But I don't think it's
>> really important.
>
>If you are a very good developer who doesn't make the stupid kind of
>mistakes we mere mortals make (and you don't have any code from mere
>mortals to maintain or incorporate into your code), or if you
>absolutely, positively know that you'll never port your code to a
>platform where ints and longs are really distinct types, then it is
>not important.
>
[snip]
Take a look at http://xoweb.xopen.org/public/tech/aspen/lp64_wp.htm
This document describes the programming model to be used for 64-bit
computing. The model preferred was LP64 (sizeof(int) < sizeof(long)).
Some of the companies participating (HP, Sun, etc?) are already using the
LLP64 model (sizeof(int) == sizeof(long) < sizeof(long long)).
So how are HP and Sun going to move to 64-bit computing? Migrating the
existing programking model and porting existing applications? Supporting
two models at once (with two versions of system header files and
difficulties linking libraries compiled with different models)? What?
--
E-mail: per@mimer.se Address: Sysdeco Mimer AB
Phone: (+46) 18 18 51 33 Box 1713
Fax: (+46) 18 18 51 00 S-751 47 Uppsala SWEDEN
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-06 4:00 ` Peter Mayne
@ 1996-09-06 4:00 ` Eric Fischer
1996-09-09 4:00 ` Dan Pop
1996-09-13 4:00 ` David Mosberger-Tang
2 siblings, 0 replies; 56+ messages in thread
From: Eric Fischer @ 1996-09-06 4:00 UTC (permalink / raw)
Peter Mayne <Peter.Mayne@cao.mts.dec.com> wrote:
> Who said time_t is a scalar? It might be something else, mightn't it?
ANSI C says it's a numeric type, though you're not supposed to do any
arithmetic on it at all, which probably makes printing it a bad idea
too. POSIX actually says it's the number of seconds since January 1st,
1970, and I think even says that it'll be either a long or a double.
Eric
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-06 4:00 ` Peter Mayne
1996-09-06 4:00 ` Eric Fischer
@ 1996-09-09 4:00 ` Dan Pop
1996-09-11 4:00 ` Richard Tobin
1996-09-13 4:00 ` David Mosberger-Tang
2 siblings, 1 reply; 56+ messages in thread
From: Dan Pop @ 1996-09-09 4:00 UTC (permalink / raw)
In <322F54A6.44FE@cao.mts.dec.com> Peter Mayne <Peter.Mayne@cao.mts.dec.com> writes:
>Who said time_t is a scalar?
ANSI/ISO C. But it doesn't say what kind of scalar:
The types declared are size_t (described in $4.1.5);
clock_t
and
time_t
which are arithmetic types capable of representing times;
^^^^^^^^^^^^^^^^
So, it can be any of the 9 integral types or 3 floating point types.
>It might be something else, mightn't it?
Nope. All the standard library functions returning a time_t value
return (time_t)-1 in case of failure.
Within the frame of ANSI C, printing a time_t value is pointless,
because the way the time is encoded is unspecified.
Dan
--
Dan Pop
CERN, CN Division
Email: Dan.Pop@cern.ch
Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-06 4:00 ` Paul T. Wilson
@ 1996-09-09 4:00 ` Chuck Dillon
0 siblings, 0 replies; 56+ messages in thread
From: Chuck Dillon @ 1996-09-09 4:00 UTC (permalink / raw)
Paul T. Wilson wrote:
>
> My only comment to this Chuck is that in more than 18 years of programming
> I've yet to work with a "development environment" by which I assume you
> mean some capability that has some level of smarts and helps you create
> the program. As a programmer I still need to know that int != long.
> Indeed, being familiar with the differences between platforms provides the
> necessary heads up if you haven't developed "portable" code. Frankly,
> simply because portability was not a requirement much of the code I've
> written hasn't been "portable". But, believe it or not, it's been ported.
I couldn't agree more. In MY 18 years of software development I have
rarely been given a portability requirement and because of that when
the code finally was ported it was not done so as gracefully as it might
have been. But then developing portable code is more expensive than
building to a standard platform so the savings over the lifetime of the
code on the old system may well have paid for the cost of porting it.
But then that may not be so if time to market is taken into account.
>
> The discipline necessary to practice correct ("portable") programming is
> not, IMHO, instilled by a "development environment". Not that I wouldn't
> like to program in one!
Again I agree. Although you have far to grandiose an interpretation of
what I refer to as a development environment. By development environment
I mean the environment in which you develop including the system (hardare
and OS) and the tools (a compiler and editor are tools). What I do not
do is assume that the development environment is the same as the target
environment in which the app must run. For a multi-platform system it
can't be and I would argue it doesn't have to be any of the targets.
I would want the development environment that provides me with the best
tools to do my job regardless of the target. If I am developing a UI
for a VCR I don't want to develop on a VCR.
--
Chuck Dillon
ced@noran.com
--- Gratuitous waste of bandwidth omitted ---
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-09 4:00 ` Dan Pop
@ 1996-09-11 4:00 ` Richard Tobin
1996-09-12 4:00 ` Lawrence Kirby
1996-09-13 4:00 ` Marc Roussel
0 siblings, 2 replies; 56+ messages in thread
From: Richard Tobin @ 1996-09-11 4:00 UTC (permalink / raw)
In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop) writes:
>Within the frame of ANSI C, printing a time_t value is pointless,
>because the way the time is encoded is unspecified.
You might want to read it in again later.
> it can be any of the 9 integral types or 3 floating point types.
There might be some trick for portably determining whether it's an
integral or floating type. How about
(time_t)0.3 == 0
Am I right in thinking this expression is always legal and must be
true iff time_t is an integral type?
-- Richard
--
:wq
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-11 4:00 ` Richard Tobin
@ 1996-09-12 4:00 ` Lawrence Kirby
1996-09-13 4:00 ` Dan Pop
1996-09-13 4:00 ` Marc Roussel
1 sibling, 1 reply; 56+ messages in thread
From: Lawrence Kirby @ 1996-09-12 4:00 UTC (permalink / raw)
In article <DxKEKD.B04@cogsci.ed.ac.uk>
richard@cogsci.ed.ac.uk "Richard Tobin" writes:
>In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop) writes:
>
>>Within the frame of ANSI C, printing a time_t value is pointless,
>>because the way the time is encoded is unspecified.
>
>You might want to read it in again later.
In that case just print it as:
printf("%Lf", (long double)t);
This is generally of more interest for clock_t values.
>> it can be any of the 9 integral types or 3 floating point types.
>
>There might be some trick for portably determining whether it's an
>integral or floating type. How about
>
> (time_t)0.3 == 0
That looks OK but I can't think of any situation where it would be
particularly useful.
size_t values should be cast to unsigned long, ptrdiff_t values to long.
Integral constants (EOF, BUFSIZ) can usually be categorised by whether
they can be negative or not and by usage i.e. the type of arguments/return
values that they can be passed through.
>Am I right in thinking this expression is always legal and must be
>true iff time_t is an integral type?
Yes.
--
-----------------------------------------
Lawrence Kirby | fred@genesis.demon.co.uk
Wilts, England | 70734.126@compuserve.com
-----------------------------------------
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-11 4:00 ` Richard Tobin
1996-09-12 4:00 ` Lawrence Kirby
@ 1996-09-13 4:00 ` Marc Roussel
1 sibling, 0 replies; 56+ messages in thread
From: Marc Roussel @ 1996-09-13 4:00 UTC (permalink / raw)
Richard Tobin wrote:
> In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop)
> writes:
> > it [time_t] can be any of the 9 integral types or 3 floating point
> > types.
>
> There might be some trick for portably determining whether it's an
> integral or floating type. How about
>
> (time_t)0.3 == 0
>
> Am I right in thinking this expression is always legal and must be
> true iff time_t is an integral type?
Why would you ever want to do that? You might thereby figure out
whether time_t is an integral or floating point type, but you still
can't do much directly with time_t values. That's why there are
standard library functions for handling them and converting them to and
from more useful formats.
If you try to use tricks like these, one of three things is likely
to happen:
1. Your code is perfectly portable and equally unreadable.
2. Your code should be portable but some compiler and library
writers with less legalistic minds than yours have
interpreted the standard in a sloppy way so your
code isn't really portable.
3. You have overinterpreted the standard and your code only
works as intended on a small number of machines.
This kind of fun you don't need.
Marc R. Roussel
(roussel@henri.chem.uleth.ca)
Department of Chemistry
University of Lethbridge
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-12 4:00 ` Lawrence Kirby
@ 1996-09-13 4:00 ` Dan Pop
1996-09-15 4:00 ` Lawrence Kirby
0 siblings, 1 reply; 56+ messages in thread
From: Dan Pop @ 1996-09-13 4:00 UTC (permalink / raw)
In <842570087snz@genesis.demon.co.uk> fred@genesis.demon.co.uk (Lawrence Kirby) writes:
>In article <DxKEKD.B04@cogsci.ed.ac.uk>
> richard@cogsci.ed.ac.uk "Richard Tobin" writes:
>
>>In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop) writes:
>>
>>>Within the frame of ANSI C, printing a time_t value is pointless,
>>>because the way the time is encoded is unspecified.
>>
>>You might want to read it in again later.
>
>In that case just print it as:
>
> printf("%Lf", (long double)t);
But you may lose bits of precision if the bits of the time_t value don't
fit in the mantissa of a long double.
Dan
--
Dan Pop
CERN, CN Division
Email: Dan.Pop@cern.ch
Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-06 4:00 ` Peter Mayne
1996-09-06 4:00 ` Eric Fischer
1996-09-09 4:00 ` Dan Pop
@ 1996-09-13 4:00 ` David Mosberger-Tang
2 siblings, 0 replies; 56+ messages in thread
From: David Mosberger-Tang @ 1996-09-13 4:00 UTC (permalink / raw)
fred@genesis.demon.co.uk (Lawrence Kirby) writes:
> In article <DxKEKD.B04@cogsci.ed.ac.uk>
> richard@cogsci.ed.ac.uk "Richard Tobin" writes:
>
> >In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop) writes:
> >
> >>Within the frame of ANSI C, printing a time_t value is pointless,
> >>because the way the time is encoded is unspecified.
> >
> >You might want to read it in again later.
>
> In that case just print it as:
>
> printf("%Lf", (long double)t);
No, this would lose precision on some platforms (e.g., Linux on Alpha
has sizeof(time_t)==sizeof(long double)==8).
--david
--
David Mosberger-Tang; Dept. of CS; The University of Arizona; Tucson, AZ 85721
davidm@cs.arizona.edu http://www.cs.arizona.edu/people/davidm
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-09-13 4:00 ` Dan Pop
@ 1996-09-15 4:00 ` Lawrence Kirby
0 siblings, 0 replies; 56+ messages in thread
From: Lawrence Kirby @ 1996-09-15 4:00 UTC (permalink / raw)
In article <danpop.842645393@news.cern.ch> Dan.Pop@cern.ch "Dan Pop" writes:
>In <842570087snz@genesis.demon.co.uk> fred@genesis.demon.co.uk (Lawrence Kirby)
> writes:
>
>>In article <DxKEKD.B04@cogsci.ed.ac.uk>
>> richard@cogsci.ed.ac.uk "Richard Tobin" writes:
>>
>>>In article <danpop.842229249@news.cern.ch> Dan.Pop@cern.ch (Dan Pop) writes:
>>>
>>>>Within the frame of ANSI C, printing a time_t value is pointless,
>>>>because the way the time is encoded is unspecified.
>>>
>>>You might want to read it in again later.
>>
>>In that case just print it as:
>>
>> printf("%Lf", (long double)t);
>
>But you may lose bits of precision if the bits of the time_t value don't
>fit in the mantissa of a long double.
OTOH double may well be considered enough since that is the limit of
the precision of difftime(). OK, there's no perfect solution however
double/long double will work on any reasonable implementation and even
where it isn't exact it is only likely to be inexact to a vary small
fraction of a second. There's a problem even when time_t is known to
be integral since there's no guarantee that you can uniquely map
all the values of long to unsigned long (or vice versa). So for the
ultimate belts-and-braces solution one you'd determined it was integral
you'd also need to test whether time_t is a signed or unsigned integral
type.
I'm still happy with long double.
--
-----------------------------------------
Lawrence Kirby | fred@genesis.demon.co.uk
Wilts, England | 70734.126@compuserve.com
-----------------------------------------
^ permalink raw reply [flat|nested] 56+ messages in thread
* Re: best UNIX OS as primary platform for UNIX system software develpoment?
1996-08-19 4:00 ` Thomas Graichen
@ 1996-10-17 4:00 ` sukumar
0 siblings, 0 replies; 56+ messages in thread
From: sukumar @ 1996-10-17 4:00 UTC (permalink / raw)
I think Digital Unix 3.2D and upwards or 4.0 should be an ideal choice. It
is really
stable and supports all kinds of unix flavors.
Sukumar Alagappan
^ permalink raw reply [flat|nested] 56+ messages in thread
end of thread, other threads:[~1996-10-17 4:00 UTC | newest]
Thread overview: 56+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1996-08-16 4:00 best UNIX OS as primary platform for UNIX system software develpoment? Jianlin Chang
1996-08-16 4:00 ` Ron Natalie
1996-08-17 4:00 ` Ping Huang
1996-08-17 4:00 ` Jianlin Chang
1996-08-19 4:00 ` James Youngman
1996-08-19 4:00 ` Jianlin Chang
1996-08-19 4:00 ` Jeff Diewald
1996-08-19 4:00 ` Bill Deegan
1996-08-20 4:00 ` Ron Natalie
1996-08-19 4:00 ` Jianlin Chang
1996-08-22 4:00 ` Jason C R Hill
1996-08-21 4:00 ` Richard Cognot
1996-08-17 4:00 ` David-Michael Lincke
1996-08-17 4:00 ` Andrew Gabriel
1996-08-18 4:00 ` Nick Sayer
1996-08-19 4:00 ` Matt Houseman x4408
1996-08-19 4:00 ` Thomas Graichen
1996-10-17 4:00 ` sukumar
1996-08-27 4:00 ` Martin Ibert
1996-08-29 4:00 ` Mike Miscevic
1996-09-04 4:00 ` Patrick Horgan
1996-08-29 4:00 ` Wojciech Galazka
1996-08-29 4:00 ` Scott G. Hall
1996-08-30 4:00 ` Timothy M. Wieman
1996-08-30 4:00 ` Jon Reeves
1996-08-30 4:00 ` R!ch
1996-09-01 4:00 ` John J. Rushford
1996-09-02 4:00 ` Pawel Wezgowiec
1996-09-02 4:00 ` mib
1996-09-02 4:00 ` mib
1996-09-02 4:00 ` Robert Lipe
1996-09-04 4:00 ` Tom Kelly
1996-09-03 4:00 ` mib
1996-09-06 4:00 ` Per Schr�der
1996-09-03 4:00 ` Chuck Dillon
1996-09-03 4:00 ` Poll Dubh
1996-09-06 4:00 ` Paul T. Wilson
1996-09-09 4:00 ` Chuck Dillon
1996-09-03 4:00 ` Martin Knoblauch
1996-09-04 4:00 ` Urs Thuermann
1996-09-05 4:00 ` Peter Gross
1996-09-05 4:00 ` Ronald Fischer
1996-09-05 4:00 ` mib
1996-09-06 4:00 ` mib
1996-09-06 4:00 ` Peter Mayne
1996-09-06 4:00 ` Eric Fischer
1996-09-09 4:00 ` Dan Pop
1996-09-11 4:00 ` Richard Tobin
1996-09-12 4:00 ` Lawrence Kirby
1996-09-13 4:00 ` Dan Pop
1996-09-15 4:00 ` Lawrence Kirby
1996-09-13 4:00 ` Marc Roussel
1996-09-13 4:00 ` David Mosberger-Tang
1996-08-19 4:00 ` amk
1996-08-20 4:00 ` guest
1996-08-22 4:00 ` Roger Binns
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox