From: mischa_sandberg@mindlink.bc.ca
Subject: Q: The perils of 32-bit mode?
Date: 1996/11/14 [thread overview]
Message-ID: <56eh4a$9d@fountain.mindlink.net> (raw)
I'm in the process of porting a system from 32-bit Unixes to an Alpha
running OSF/1. The code makes many assumptions about LONG and POINTER
types being 32 bits. The first attempt at simply letting the chips
fall where they might in 64-bit mode were pretty dismal.
I've recompiled the system using "cc -c -xtaso_short" and "cc -taso"
to (per the documentation) create a program that uses 32-bit pointers
and is loaded into the 32bit address space. This doesn't solve my
problem with longs, but, one step at a time, right?
The resulting executable displays "anomalous" behaviour off the bat.
The main routine is your standard "int main(int argc, char **argv)",
and when I invoke the program with a single argument, "argc" is as
expected (2), and argv[0] is the name of the program --- but argv[1]
is always NULL.
This posting amounts to three questions:
(1) What the heck might I doing wrong? A simple "hello, world"
program, predictably, does NOT betray this same weirdness related to
argv[1].
(2) Are there are any hidden gotchas in using -taso/-xtaso_short? What
happens if I need to use a library that was compiled for 64 bits ---
are pointers properly coerced, or am I out of luck?
(3) Should I expect a significant performance hit? This is a
network-traffic-intensive application, not a compute-intensive one.
Many thanks in advance. It sure is fun to play with this sucker; the
Alpha is *fast*.
Engineers believe that the equations approximate reality.
Physicists believe that reality approximates the equations.
Mathematicians never make the connection.
next reply other threads:[~1996-11-14 5:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-11-14 5:00 mischa_sandberg [this message]
1996-11-18 5:00 ` Q: The perils of 32-bit mode? Craig Neth USG
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox