Avalon-MM Byte Ordering

cancel
Showing results for 
Search instead for 
Did you mean: 

Avalon-MM Byte Ordering

Avalon-MM Byte Ordering



Over the years I have been consulted on big endian and mixed endian systems. Since this topic is fairly important and often confusing I decided to put this topic into a document so that others can benefit from this as well. At a high level this document will discusses the following topics:


  • Avalon-MM specification for bit and byte ordering (little endian)
  • Nios II bit and byte ordering as well as the internal arithmetic ordering (little endian)
  • PowerPC bit and byte ordering as well as the internal arithmetic ordering (big endian)
  • ARM bit and byte ordering as well as the internal arithmetic ordering (big endian - BE32 and BE8)
  • Mixed endian systems
  • Arithemtic ordering corrections in software


Although Qsys is referenced throughout this document, all of this information applies to SOPC Builder systems as well. Please feel free to carry this topic on by adding to either the document or this webpage. I have also attached a byte swapper custom instruction which you can connect to Nios II and use it to accelerate 16, 32, and 64-bit byte reversals. Remember that you need to use the appropriate macro for the variable you are swapping around otherwise you'll corrupt the value stored in it.


www.altera.com/literature/hb/nios2/MM_byte_ordering.pdf


File:Nios ii endian converter.zip

© 2010 Altera Corporation. The material in this wiki page or document is provided AS-IS and is not

supported by Altera Corporation. Use the material in this document at your own risk; it might be, for example, objectionable,

misleading or inaccurate.

CategoryEmbedded Processing


Version history
Last update:
‎06-21-2019 09:16 PM
Updated by:
Contributors