aboutsummaryrefslogtreecommitdiffhomepage
path: root/ir.h
diff options
context:
space:
mode:
author lemon<lsof@mailbox.org>2023-06-18 09:05:15 +0200
committer lemon<lsof@mailbox.org>2023-06-18 09:05:15 +0200
commit04de327e9ac7c1502716336e9bbfecf544b31126 (patch)
tree52c1644c5b10c492037d8853b07155c8d334329b /ir.h
parent962ad175aee634274b408ead38b13e6bc90e2fe7 (diff)
ELF output static data
Diffstat (limited to 'ir.h')
-rw-r--r--ir.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/ir.h b/ir.h
index 5187e4b..ca4fe47 100644
--- a/ir.h
+++ b/ir.h
@@ -16,12 +16,13 @@ union irtype {
};
struct irdat {
- uchar align : 7, mut : 1;
+ uchar align : 6, mut : 1, globl : 1;
uint siz;
union {
vec_of(uchar) dat;
uchar sdat[8];
};
+ const char *name;
struct symref {
struct symref *next;
const char *sym;
@@ -207,7 +208,7 @@ union ref mkfltcon(enum irclass, double);
#define intconval(r) ((r).t == RICON ? (r).i : conht[(r).i].i)
#define fltconval(r) (conht[(r).i].f)
union ref mksymref(const char *);
-union ref mkdatref(uint siz, uint align, const void *, uint n, bool deref);
+union ref mkdatref(const char *name, uint siz, uint align, const void *, uint n, bool deref);
const char *xcon2sym(int ref);
struct instr mkalloca(uint siz, uint align);
void conputdat(struct irdat *, uint off, enum typetag t, const void *dat);