static void genblob(FILE *fd, Node *blob, Htab *globls, Htab *strtab) { char *lbl; Blob *b; /* lits and such also get wrapped in decls */ assert(blob->type == Ndecl); lbl = htget(globls, blob); fprintf(fd, "GLOBL %s+0(SB),$%zd\n", lbl, size(blob)); if (blob->decl.init) b = litblob(globls, strtab, blob->decl.init); else b = mkblobpad(size(blob)); writeblob(fd, b, 0, lbl); }
void genblob(FILE *fd, Node *blob, Htab *globls, Htab *strtab) { char *lbl; Blob *b; /* lits and such also get wrapped in decls */ assert(blob->type == Ndecl); lbl = htget(globls, blob); if (blob->decl.vis != Visintern) fprintf(fd, ".globl %s\n", lbl); if (blob->decl.init) { fprintf(fd, ".align %zd\n", tyalign(decltype(blob))); fprintf(fd, "%s:\n", lbl); b = litblob(globls, strtab, blob->decl.init); writeblob(fd, b); blobfree(b); } else {