Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home

HP-UX 64-bit Porting and Transition Guide: HP 9000 Computers

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Glossary

 » Index

HP Part Number: 5966-9887

Published: June 1998


Table of Contents

Preface
Related Documentation
Finding this Manual
Printing History
1 Overview
Overview of HP-UX 11.0
Benefits for 64-bit Applications
HP-UX Compilers
Transition Tools
Cross-Platform Development
Compiler Options for Cross Development
Compiling in Networked Environments
Compatibility with Previous Releases
2 Summary of Changes
HP C
HP aC++
HP Fortran 90
HP Fortran 90 and HP C Data Types
New Fortran 90 Features
Programming Toolset
64-bit Linker Toolset Features
Link Time Differences
Run Time Differences
Dynamic Path Searching for Shared Libraries
Symbol Searching in Dependent Libraries
System Libraries
32-bit and 64-bit Application Interoperability
General Issue
Shared Memory
Message Queues
Memory-Mapped Files
nlist
X11/graphics
Large Files
pstat
3 HP-UX 64-bit Porting Concepts
ILP32 and LP64 Data Models
Data Type Sizes
Huge Data
ILP32 to LP64 Porting Concerns
Data Truncation
Pointers
Data Type Promotion
Data Alignment and Data Sharing
Constants
Bit Fields
Bit Shifts and Bit Masks
Enumerated Types
Architecture Specific Changes
Assembly Language
Object File Format
Procedure Calling Conventions
HP-UX 64-bit Performance Considerations
What Impacts Performance in 64-bit Applications
Tuning Your 64-bit Application
4 Transitioning C and aC++ Programs to 64-bit Mode
Step 1: Identify Programs that Need to Compile to 64-bit Mode
Step 2: Identify Non-Portable Constructs
Step 3: Make Source Code Changes
Avoid Assigning longs to ints
Avoid Arithmetic between Signed and Unsigned Numbers
Avoid Storing Pointers in ints
Avoid Truncating Function Return Values
Avoid Passing Invalid Structure References
Avoid Pointer Arithmetic between longs and ints
Avoid Casting Pointers to ints or ints to Pointers
Avoid Using Unnamed and Unqualified Bit Fields
Avoid Using Literals and Masks that Assume 32 bits
Avoid Hardcoding Size of Data Types
Avoid Hardcoding Bit Shift Values
Avoid Hardcoding Constants with malloc(), memory(3), string(3)
Use Appropriate Print Specifiers
Step 4: Compile in 64-bit Mode
5 Writing Portable Code
Making Code 64-bit Clean
Using Integral Types Defined in <inttypes.h>
Integer Data Types with Consistent Lengths
intfast Data Types with Defined Minimum Sizes
Guidelines for Using <inttypes.h>
Using portal.h
Using Portable Bit Masks
Using pstat(2) instead of /dev/kmem
Getting Configurable System Information
Isolating System-Specific Code
Using System-Specific Include Files
Glossary
Index
Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1998 Hewlett-Packard Development Company, L.P.