diff options
| -rw-r--r-- | amd64/emit.c | 5 | ||||
| -rw-r--r-- | common.h | 2 | ||||
| -rw-r--r-- | ir/regalloc.c | 2 |
3 files changed, 4 insertions, 5 deletions
diff --git a/amd64/emit.c b/amd64/emit.c index e188782..8f29cfc 100644 --- a/amd64/emit.c +++ b/amd64/emit.c @@ -1187,10 +1187,9 @@ emitbranch(uchar **pcode, struct block *blk) if (blk->s2) { /* conditional branch.. */ union ref arg = blk->jmp.arg[0]; - struct instr *ins; - struct block *unord; + struct block *unord = NULL; assert(arg.t == RTMP); - ins = &instrtab[arg.i]; + struct instr *ins = &instrtab[arg.i]; if ((oiscmp(ins->op) || ins->op == Oand || ins->op == Osub)) { if (ins->r.bits != ZEROREF.bits) { /* for CMP instr */ @@ -79,7 +79,7 @@ ispo2(uvlong x) { static inline uint ilog2(uvlong x) { /* assumes x is a power of 2 */ #if HAS_BUILTIN(ctz) - return __builtin_ctz(x); + return __builtin_ctzll(x); #else uint n = 0; while (x >>= 1) ++n; diff --git a/ir/regalloc.c b/ir/regalloc.c index 520870e..3642d36 100644 --- a/ir/regalloc.c +++ b/ir/regalloc.c @@ -147,7 +147,7 @@ struct interval { fpr : 1; /* needs float register? */ /* sorted ranges array */ - uchar nrange; + uint nrange; union { struct range _inl[2]; struct range *_dyn; |