Skip to Main Content
Itanium® Architecture for Programmers: Understanding 64-Bit Processors and EPIC Principles
book

Itanium® Architecture for Programmers: Understanding 64-Bit Processors and EPIC Principles

by James S. Evans - Lawrence University, Gregory L. Trimper - viika
April 2003
Intermediate to advanced content levelIntermediate to advanced
576 pages
15h 13m
English
Pearson
Content preview from Itanium® Architecture for Programmers: Understanding 64-Bit Processors and EPIC Principles

6.6. DECNUM: Converting an Integer to Decimal Format

The formatting of numeric data as strings of ASCII characters is a common and important issue. When we discussed number systems in Chapter 1, we did not dwell on detailed methods for converting numbers from one radix to another. In this section, we develop one method for formatting unsigned decimal integers that illustrates several instructions and techniques presented in this chapter.

If we start with a value such as FE16, how might we systematically convert this to 25410? If we divide the value by 10, we get a quotient of 25 and a remainder of 4. If we divide that first quotient by 10, we get a second quotient of 2 and a second remainder of 5. We can repeat this process until we get a quotient ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

ARM System Developer's Guide

ARM System Developer's Guide

Andrew Sloss, Dominic Symes, Chris Wright
Intel Xeon Phi Processor High Performance Programming, 2nd Edition

Intel Xeon Phi Processor High Performance Programming, 2nd Edition

James Jeffers, James Reinders, Avinash Sodani

Publisher Resources

ISBN: 0131013726Purchase book