Nonsensical Uses Of Literals; Literal Pools - HP 9835A Programming Manual

35 series desktop computer assembly development rom
Table of Contents

Advertisement

74
Assembly Language Fundamentals
and the locations starting at "Pi" now contains the full-precision value indicated (which is a fair
approximation to pi). This would replace coding which could have looked like this (without
using literals) -
Nonsensical Uses of Literals
A literal, basically, is an address. Since it can be used in an operand wherever an address may
be used, it is possible to use it in instructions where the result is a little nonsensical.
For example, consider the result of doing some of the following -
Caution dictates that you well consider the appropriateness of the action when using the literal.
Literals can be a highly useful tool, but only when properly employed.
Literal Pools
Literals are assemble-time constructs, but they eventually resolve to an actual address in the
object code. That address points into a literal "pool".
A literal pool is part of your module where the actual values of literals are stored. There is
automatically a literal pool assigned at the end of each module where literals are used. As many
literal values as possible are stored there by the assembler. However, in some cases, a literal
pool is needed earlier in the program (a need indicated by the assembler with the "L T"
assembly-time error). In that case a pool should be created using the LIT pseudo-instruction.
This instruction has the form -
LIT
{size}

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the 9835A and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Table of Contents