commit 36946a5142c40b733d25ea5ca469f7949ee03439
parent baf11b7175c468d3d9408d332b1c0d529a4957ee
Author: Quentin Carbonneaux <quentin@c9x.me>
Date: Fri, 18 Aug 2023 15:12:56 +0200
file,loc become dbgfile,dbgloc
Diffstat:
7 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/amd64/emit.c b/amd64/emit.c
@@ -547,7 +547,7 @@ emitins(Ins i, Fn *fn, FILE *f)
emitcopy(i.arg[0], i.arg[1], i.cls, fn, f);
emitcopy(i.arg[1], TMP(XMM0+15), i.cls, fn, f);
break;
- case Oloc:
+ case Odbgloc:
emitdbgloc(i.arg[0].val, f);
break;
}
diff --git a/amd64/isel.c b/amd64/isel.c
@@ -392,7 +392,7 @@ sel(Ins i, ANum *an, Fn *fn)
case_Oload:
seladdr(&i.arg[0], an, fn);
goto Emit;
- case Oloc:
+ case Odbgloc:
case Ocall:
case Osalloc:
case Ocopy:
diff --git a/arm64/emit.c b/arm64/emit.c
@@ -446,7 +446,7 @@ emitins(Ins *i, E *e)
if (!req(i->to, R))
emitf("mov %=, sp", i, e);
break;
- case Oloc:
+ case Odbgloc:
emitdbgloc(i->arg[0].val, e->f);
break;
}
diff --git a/ops.h b/ops.h
@@ -122,7 +122,7 @@ O(vastart, T(m,e,e,e, x,e,e,e), 0) X(0, 0, 0) V(0)
O(copy, T(w,l,s,d, x,x,x,x), 0) X(0, 0, 1) V(0)
/* Debug */
-O(loc, T(w,l,s,d, x,x,x,x), 0) X(0, 0, 1) V(0)
+O(dbgloc, T(w,l,s,d, x,x,x,x), 0) X(0, 0, 1) V(0)
/****************************************/
/* INTERNAL OPERATIONS (keep nop first) */
diff --git a/parse.c b/parse.c
@@ -53,7 +53,7 @@ enum Token {
Tdata,
Tsection,
Talign,
- Tfile,
+ Tdbgfile,
Tl,
Tw,
Tsh,
@@ -111,7 +111,7 @@ static char *kwmap[Ntok] = {
[Tdata] = "data",
[Tsection] = "section",
[Talign] = "align",
- [Tfile] = "file",
+ [Tdbgfile] = "dbgfile",
[Tsb] = "sb",
[Tub] = "ub",
[Tsh] = "sh",
@@ -132,7 +132,7 @@ enum {
TMask = 16383, /* for temps hash */
BMask = 8191, /* for blocks hash */
- K = 10525445, /* found using tools/lexh.c */
+ K = 9583425, /* found using tools/lexh.c */
M = 23,
};
@@ -661,8 +661,8 @@ parseline(PState ps)
expect(Tnl);
closeblk();
return PLbl;
- case Oloc:
- op = Oloc;
+ case Odbgloc:
+ op = t;
k = Kw;
r = R;
expect(Tint);
@@ -1186,7 +1186,7 @@ parse(FILE *f, char *path, void dbgfile(char *), void data(Dat *), void func(Fn
switch (parselnk(&lnk)) {
default:
err("top-level definition expected");
- case Tfile:
+ case Tdbgfile:
expect(Tstr);
dbgfile(tokval.str);
break;
diff --git a/rv64/emit.c b/rv64/emit.c
@@ -405,7 +405,7 @@ emitins(Ins *i, Fn *fn, FILE *f)
if (!req(i->to, R))
emitf("mv %=, sp", i, fn, f);
break;
- case Oloc:
+ case Odbgloc:
emitdbgloc(i->arg[0].val, f);
break;
}
diff --git a/tools/lexh.c b/tools/lexh.c
@@ -23,10 +23,10 @@ char *tok[] = {
"ceql", "cnel", "cles", "clts", "cgts", "cges",
"cnes", "ceqs", "cos", "cuos", "cled", "cltd",
"cgtd", "cged", "cned", "ceqd", "cod", "cuod",
- "vaarg", "vastart", "...", "env", "loc",
+ "vaarg", "vastart", "...", "env", "dbgloc",
"call", "phi", "jmp", "jnz", "ret", "hlt", "export",
- "function", "type", "data", "section", "align", "file",
+ "function", "type", "data", "section", "align", "dbgfile",
"blit", "l", "w", "sh", "uh", "h", "sb", "ub", "b",
"d", "s", "z", "loadw", "loadl", "loads", "loadd",
"alloc1", "alloc2",