0010 0000 or 0000 0010 which one are you?

on Aug 10, 10 • by Eric Hollebone • with 4 Comments

I love this quote by Carl Ek from  Code Integrity solutions: There are 0010 0000 kinds of people in the world: Those that understand the difference between Big Endian and Little Endian, and those that do not. Issues with Endianism and processor architecture ports are becoming more and more common these days as more...

Home » Static Analysis » 0010 0000 or 0000 0010 which one are you?

I love this quote by Carl Ek from  Code Integrity solutions:

There are 0010 0000 kinds of people in the world: Those that understand the difference between Big Endian and Little Endian, and those that do not.

Issues with Endianism and processor architecture ports are becoming more and more common these days as more desktop source code moves into different arenas.  Gone are the days when the 32-bit memory model or little-endian format dominate. Software changes are required to support the growth occurring not at the desktop, but in the server  and mobile platforms.

Mobile devices especially have opened a Pandora’s box of Endian and memory problems, with variety of processor architectures with ARM[1] leading the way.  Add to this mix,  end-consumers are demanding desktop features like Adobe Flash or Office apps on mobile devices, many a stable codebase will fall apart when ported to either mobile or server.

For developers porting to different platforms, there are some significant challenges.  Just to list a few:

  • CPU optimizations need to be reviewed
  • inline assembly calls require rewriting or removal
  • machine word (WORD) allocations may require refactoring
  • any binary data exchanged over the network stacks require verification

None of these are  new, they’re just not a common skillset for most developers.

Source code analysis can be a boon in two ways. Firstly, in the planning phase by helping you determine the breadth of the effort,  and secondly by identifying any existing  issues, particularly of the memory allocation and Endian varieties.

For more in depth information, there are two recent articles available from Dr. Dobbs:

[1] Note: Some ARM processors support both big and little Endian formats.

Related Posts

4 Responses to 0010 0000 or 0000 0010 which one are you?

  1. Andrey says:

    Related topic: Pattern 11. Serialization and data interchange – http://www.viva64.com/lessons-x64/19_Pattern_11_Serialization.html

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Scroll to top