comparison doc/manual/manual.html @ 442:a9521955554f 3.0

Added pragma pcaspcr to treat PC as PCR; additional fixes for PCR addressing modes
author lost@l-w.ca
date Sat, 30 Oct 2010 12:15:00 -0600
parents b8bf63962a99
children
comparison
equal deleted inserted replaced
441:7b8d89435f30 442:a9521955554f
174 ></DT 174 ></DT
175 ></DL 175 ></DL
176 ></DD 176 ></DD
177 ><DT 177 ><DT
178 >4. <A 178 >4. <A
179 HREF="#AEN625" 179 HREF="#AEN629"
180 >LWLINK</A 180 >LWLINK</A
181 ></DT 181 ></DT
182 ><DD 182 ><DD
183 ><DL 183 ><DL
184 ><DT 184 ><DT
185 >4.1. <A 185 >4.1. <A
186 HREF="#AEN628" 186 HREF="#AEN632"
187 >Command Line Options</A 187 >Command Line Options</A
188 ></DT 188 ></DT
189 ><DT 189 ><DT
190 >4.2. <A 190 >4.2. <A
191 HREF="#AEN725" 191 HREF="#AEN729"
192 >Linker Operation</A 192 >Linker Operation</A
193 ></DT 193 ></DT
194 ><DT 194 ><DT
195 >4.3. <A 195 >4.3. <A
196 HREF="#AEN739" 196 HREF="#AEN743"
197 >Linking Scripts</A 197 >Linking Scripts</A
198 ></DT 198 ></DT
199 ></DL 199 ></DL
200 ></DD 200 ></DD
201 ><DT 201 ><DT
202 >5. <A 202 >5. <A
203 HREF="#AEN773" 203 HREF="#AEN777"
204 >Libraries and LWAR</A 204 >Libraries and LWAR</A
205 ></DT 205 ></DT
206 ><DD 206 ><DD
207 ><DL 207 ><DL
208 ><DT 208 ><DT
209 >5.1. <A 209 >5.1. <A
210 HREF="#AEN777" 210 HREF="#AEN781"
211 >Command Line Options</A 211 >Command Line Options</A
212 ></DT 212 ></DT
213 ></DL 213 ></DL
214 ></DD 214 ></DD
215 ><DT 215 ><DT
227 ><B 227 ><B
228 >List of Tables</B 228 >List of Tables</B
229 ></DT 229 ></DT
230 ><DT 230 ><DT
231 >6-1. <A 231 >6-1. <A
232 HREF="#AEN860" 232 HREF="#AEN864"
233 >Object File Term Types</A 233 >Object File Term Types</A
234 ></DT 234 ></DT
235 ><DT 235 ><DT
236 >6-2. <A 236 >6-2. <A
237 HREF="#AEN890" 237 HREF="#AEN894"
238 >Object File Operator Numbers</A 238 >Object File Operator Numbers</A
239 ></DT 239 ></DT
240 ></DL 240 ></DL
241 ></DIV 241 ></DIV
242 ><DIV 242 ><DIV
2033 ><P 2033 ><P
2034 > This is the same as the "dollarlocal" pragma except its sense is 2034 > This is the same as the "dollarlocal" pragma except its sense is
2035 reversed. That is, "dollarlocal" and "nodollarnotlocal" are equivalent and 2035 reversed. That is, "dollarlocal" and "nodollarnotlocal" are equivalent and
2036 "nodollarlocal" and "dollarnotlocal" are equivalent. </P 2036 "nodollarlocal" and "dollarnotlocal" are equivalent. </P
2037 ></DD 2037 ></DD
2038 ><DT
2039 >pcaspcr</DT
2040 ><DD
2041 ><P
2042 > Normally, LWASM makes a distinction between PC and PCR in program
2043 counter relative addressing. In particular, the use of PC means an absolute
2044 offset from PC while PCR causes the assembler to calculate the offset to the
2045 specified operand and use that as the offset from PC. By setting this
2046 pragma, you can have PC treated the same as PCR. </P
2047 ></DD
2038 ></DL 2048 ></DL
2039 ></DIV 2049 ></DIV
2040 ></DIV 2050 ></DIV
2041 ></DIV 2051 ></DIV
2042 ><DIV 2052 ><DIV
2043 CLASS="CHAPTER" 2053 CLASS="CHAPTER"
2044 ><HR><H1 2054 ><HR><H1
2045 ><A 2055 ><A
2046 NAME="AEN625" 2056 NAME="AEN629"
2047 ></A 2057 ></A
2048 >Chapter 4. LWLINK</H1 2058 >Chapter 4. LWLINK</H1
2049 ><P 2059 ><P
2050 >The LWTOOLS linker is called LWLINK. This chapter documents the various features 2060 >The LWTOOLS linker is called LWLINK. This chapter documents the various features
2051 of the linker.</P 2061 of the linker.</P
2052 ><DIV 2062 ><DIV
2053 CLASS="SECTION" 2063 CLASS="SECTION"
2054 ><HR><H2 2064 ><HR><H2
2055 CLASS="SECTION" 2065 CLASS="SECTION"
2056 ><A 2066 ><A
2057 NAME="AEN628" 2067 NAME="AEN632"
2058 >4.1. Command Line Options</A 2068 >4.1. Command Line Options</A
2059 ></H2 2069 ></H2
2060 ><P 2070 ><P
2061 >The binary for LWLINK is called "lwlink". Note that the binary is in lower 2071 >The binary for LWLINK is called "lwlink". Note that the binary is in lower
2062 case. lwlink takes the following command line arguments.</P 2072 case. lwlink takes the following command line arguments.</P
2249 ><DIV 2259 ><DIV
2250 CLASS="SECTION" 2260 CLASS="SECTION"
2251 ><HR><H2 2261 ><HR><H2
2252 CLASS="SECTION" 2262 CLASS="SECTION"
2253 ><A 2263 ><A
2254 NAME="AEN725" 2264 NAME="AEN729"
2255 >4.2. Linker Operation</A 2265 >4.2. Linker Operation</A
2256 ></H2 2266 ></H2
2257 ><P 2267 ><P
2258 >&#13;LWLINK takes one or more files in supported input formats and links them 2268 >&#13;LWLINK takes one or more files in supported input formats and links them
2259 into a single binary. Currently supported formats are the LWTOOLS object 2269 into a single binary. Currently supported formats are the LWTOOLS object
2305 ><DIV 2315 ><DIV
2306 CLASS="SECTION" 2316 CLASS="SECTION"
2307 ><HR><H2 2317 ><HR><H2
2308 CLASS="SECTION" 2318 CLASS="SECTION"
2309 ><A 2319 ><A
2310 NAME="AEN739" 2320 NAME="AEN743"
2311 >4.3. Linking Scripts</A 2321 >4.3. Linking Scripts</A
2312 ></H2 2322 ></H2
2313 ><P 2323 ><P
2314 >A linker script is used to instruct the linker about how to assemble the 2324 >A linker script is used to instruct the linker about how to assemble the
2315 various sections into a completed binary. It consists of a series of 2325 various sections into a completed binary. It consists of a series of
2413 ></DIV 2423 ></DIV
2414 ><DIV 2424 ><DIV
2415 CLASS="CHAPTER" 2425 CLASS="CHAPTER"
2416 ><HR><H1 2426 ><HR><H1
2417 ><A 2427 ><A
2418 NAME="AEN773" 2428 NAME="AEN777"
2419 ></A 2429 ></A
2420 >Chapter 5. Libraries and LWAR</H1 2430 >Chapter 5. Libraries and LWAR</H1
2421 ><P 2431 ><P
2422 >LWTOOLS also includes a tool for managing libraries. These are analogous to 2432 >LWTOOLS also includes a tool for managing libraries. These are analogous to
2423 the static libraries created with the "ar" tool on POSIX systems. Each library 2433 the static libraries created with the "ar" tool on POSIX systems. Each library
2432 ><DIV 2442 ><DIV
2433 CLASS="SECTION" 2443 CLASS="SECTION"
2434 ><HR><H2 2444 ><HR><H2
2435 CLASS="SECTION" 2445 CLASS="SECTION"
2436 ><A 2446 ><A
2437 NAME="AEN777" 2447 NAME="AEN781"
2438 >5.1. Command Line Options</A 2448 >5.1. Command Line Options</A
2439 ></H2 2449 ></H2
2440 ><P 2450 ><P
2441 >The binary for LWAR is called "lwar". Note that the binary is in lower 2451 >The binary for LWAR is called "lwar". Note that the binary is in lower
2442 case. The options lwar understands are listed below. For archive manipulation 2452 case. The options lwar understands are listed below. For archive manipulation
2633 followed by any data required by the term. Then end of the list is flagged 2643 followed by any data required by the term. Then end of the list is flagged
2634 by a NULL expression (only an end of expression term).</P 2644 by a NULL expression (only an end of expression term).</P
2635 ><DIV 2645 ><DIV
2636 CLASS="TABLE" 2646 CLASS="TABLE"
2637 ><A 2647 ><A
2638 NAME="AEN860" 2648 NAME="AEN864"
2639 ></A 2649 ></A
2640 ><P 2650 ><P
2641 ><B 2651 ><B
2642 >Table 6-1. Object File Term Types</B 2652 >Table 6-1. Object File Term Types</B
2643 ></P 2653 ></P
2705 allows local symbols that are not exported to have the same names as 2715 allows local symbols that are not exported to have the same names as
2706 exported symbols or external references.</P 2716 exported symbols or external references.</P
2707 ><DIV 2717 ><DIV
2708 CLASS="TABLE" 2718 CLASS="TABLE"
2709 ><A 2719 ><A
2710 NAME="AEN890" 2720 NAME="AEN894"
2711 ></A 2721 ></A
2712 ><P 2722 ><P
2713 ><B 2723 ><B
2714 >Table 6-2. Object File Operator Numbers</B 2724 >Table 6-2. Object File Operator Numbers</B
2715 ></P 2725 ></P