Mercurial > hg-old > index.cgi
comparison src/pass2.c @ 74:c8c772ef5df9
Checkpointing object target implementation
author | lost |
---|---|
date | Thu, 08 Jan 2009 01:18:40 +0000 |
parents | 31d8e85706e7 |
children |
comparison
equal
deleted
inserted
replaced
73:4b37f17624a7 | 74:c8c772ef5df9 |
---|---|
29 #include "lwasm.h" | 29 #include "lwasm.h" |
30 | 30 |
31 void lwasm_pass2(asmstate_t *as) | 31 void lwasm_pass2(asmstate_t *as) |
32 { | 32 { |
33 lwasm_line_t *l; | 33 lwasm_line_t *l; |
34 | 34 sectiontab_t *st; |
35 | |
35 debug_message(1, "Entering pass 2"); | 36 debug_message(1, "Entering pass 2"); |
36 as -> passnum = 2; | 37 as -> passnum = 2; |
37 as -> addr = 0; | 38 as -> addr = 0; |
38 as -> context = 0; | 39 as -> context = 0; |
39 as -> endseen = 0; | 40 as -> endseen = 0; |
43 as -> inmacro = 0; | 44 as -> inmacro = 0; |
44 as -> nextcontext = 1; | 45 as -> nextcontext = 1; |
45 as -> skiplines = 0; | 46 as -> skiplines = 0; |
46 as -> dpval = 0; | 47 as -> dpval = 0; |
47 | 48 |
49 for (st = as -> sections; st; st = st -> next) | |
50 st -> offset = 0; | |
51 as -> csect = NULL; | |
52 | |
48 // iterate over all the lines and re-parse them | 53 // iterate over all the lines and re-parse them |
49 for (l = as -> lineshead; l && !(as -> endseen); l = l -> next) | 54 for (l = as -> lineshead; l && !(as -> endseen); l = l -> next) |
50 { | 55 { |
51 if (as -> skiplines) | 56 if (as -> skiplines) |
52 as -> skiplines--; | 57 as -> skiplines--; |