intern symbol names
Symbols in the source file are still limited in length because the rest of the code assumes that strings always fit in NString bytes. Regardless, there is already a benefit because comparing/copying symbol names does not require using strcmp()/strcpy() anymore.
This commit is contained in:
parent
2d02070af0
commit
a3a1451c5f
10 changed files with 143 additions and 87 deletions
|
@ -244,9 +244,9 @@ loadcon(Con *c, int r, int k, FILE *f)
|
|||
off[0] = 0;
|
||||
p = c->local ? ".L" : "";
|
||||
fprintf(f, "\tadrp\t%s, %s%s%s\n",
|
||||
rn, p, c->label, off);
|
||||
rn, p, str(c->label), off);
|
||||
fprintf(f, "\tadd\t%s, %s, #:lo12:%s%s%s\n",
|
||||
rn, rn, p, c->label, off);
|
||||
rn, rn, p, str(c->label), off);
|
||||
return;
|
||||
}
|
||||
assert(c->type == CBits);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue