rename blknew() to newblk()

This is consistent with newtmp()
and newcon().
This commit is contained in:
Quentin Carbonneaux 2023-03-22 11:43:42 +01:00
parent eb9fcece9e
commit 5fee3da6ac
6 changed files with 7 additions and 7 deletions

2
all.h
View file

@ -511,7 +511,7 @@ void err(char *, ...) __attribute__((noreturn));
void elimsb(Fn *);
/* cfg.c */
Blk *blknew(void);
Blk *newblk(void);
void edgedel(Blk *, Blk **);
void fillpreds(Fn *);
void fillrpo(Fn *);

View file

@ -507,7 +507,7 @@ split(Fn *fn, Blk *b)
Blk *bn;
++fn->nblk;
bn = blknew();
bn = newblk();
bn->nins = &insb[NIns] - curi;
idup(&bn->ins, curi, bn->nins);
curi = &insb[NIns];

View file

@ -542,7 +542,7 @@ split(Fn *fn, Blk *b)
Blk *bn;
++fn->nblk;
bn = blknew();
bn = newblk();
bn->nins = &insb[NIns] - curi;
idup(&bn->ins, curi, bn->nins);
curi = &insb[NIns];

4
cfg.c
View file

@ -1,7 +1,7 @@
#include "all.h"
Blk *
blknew()
newblk()
{
static Blk z;
Blk *b;
@ -299,7 +299,7 @@ simpljmp(Fn *fn)
Blk **uf; /* union-find */
Blk **p, *b, *ret;
ret = blknew();
ret = newblk();
ret->id = fn->nblk++;
ret->jmp.type = Jret0;
uf = emalloc(fn->nblk * sizeof uf[0]);

View file

@ -555,7 +555,7 @@ findblk(char *name)
for (b=blkh[h]; b; b=b->dlink)
if (strcmp(b->name, name) == 0)
return b;
b = blknew();
b = newblk();
b->id = nblk++;
strcpy(b->name, name);
b->dlink = blkh[h];

2
rega.c
View file

@ -665,7 +665,7 @@ rega(Fn *fn)
pmgen();
if (curi == &insb[NIns])
continue;
b1 = blknew();
b1 = newblk();
b1->loop = (b->loop+s->loop) / 2;
b1->link = blist;
blist = b1;