Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

< Previous PageNext Page > Hide TOC

Making Code 64-Bit Clean

Before you begin to update your code, you should familiarize yourself with the document Mac OS X Technology Overview. After reading that document, the first thing you should do is compile your code with the -Wall compiler flag and fix any warnings that occur. In particular, make sure that all function prototypes are in scope, because out-of-scope prototypes can hide many subtle portability problems.

At a high level, to make your code 64-bit clean, you must do the following:

Contents:

General Programming Tips
Data Type and Alignment Tips
Avoiding Pointer-to-Integer Conversion
Working with Bits and Bitmasks
Tools Tips
Alignment Pragmas
Sign Extension Rules for C and C-derived Languages
Velocity Engine and SSE Alignment Tips
Porting Assembly Language Code




< Previous PageNext Page > Hide TOC


Last updated: 2008-04-08




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice