aboutsummaryrefslogtreecommitdiff
path: root/src/libmach
diff options
context:
space:
mode:
authorRuss Cox <rsc@swtch.com>2017-01-06 16:32:31 -0500
committerRuss Cox <rsc@swtch.com>2017-01-06 21:37:31 +0000
commit310ae03327a815e721166b64aa3af27b1cc8c2ff (patch)
tree3aaf93aaf66d29658ec8da82b3b09c1a6d941660 /src/libmach
parent9e0d3750c543de49ccc43512cb3fbaa1f42f1648 (diff)
downloadplan9port-310ae03327a815e721166b64aa3af27b1cc8c2ff.tar.gz
plan9port-310ae03327a815e721166b64aa3af27b1cc8c2ff.tar.bz2
plan9port-310ae03327a815e721166b64aa3af27b1cc8c2ff.zip
all: fix or silence all INSTALL warnings on macOS
Should be a clean build now. Change-Id: Id3460371cb5e8d4071f8faa9c2aec870d213a067 Reviewed-on: https://plan9port-review.googlesource.com/2781 Reviewed-by: Russ Cox <rsc@swtch.com>
Diffstat (limited to 'src/libmach')
-rw-r--r--src/libmach/mach386.c2
-rw-r--r--src/libmach/machpower.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/libmach/mach386.c b/src/libmach/mach386.c
index 3b39d697..336cec35 100644
--- a/src/libmach/mach386.c
+++ b/src/libmach/mach386.c
@@ -1701,7 +1701,7 @@ badop:
return 0;
ip->imm64 = ip->imm;
if(ip->rex&REXW && (ip->imm & (1<<31)) != 0)
- ip->imm64 |= (vlong)~0 << 32;
+ ip->imm64 |= (vlong)(~0ULL << 32);
} else {
if (igets(map, ip, &s)< 0)
return 0;
diff --git a/src/libmach/machpower.c b/src/libmach/machpower.c
index 4c9b574c..2799f37a 100644
--- a/src/libmach/machpower.c
+++ b/src/libmach/machpower.c
@@ -138,7 +138,7 @@ typedef struct {
char *err; /* errmsg */
} Instr;
-#define IBF(v,a,b) (((ulong)(v)>>(32-(b)-1)) & ~(~0L<<(((b)-(a)+1))))
+#define IBF(v,a,b) (((ulong)(v)>>(32-(b)-1)) & ~(~0UL<<(((b)-(a)+1))))
#define IB(v,b) IBF((v),(b),(b))
static void
@@ -165,7 +165,7 @@ decode(ulong pc, Instr *i)
i->crbb = IBF(w, 16, 20);
i->bd = IBF(w, 16, 29)<<2;
if(i->bd & 0x8000)
- i->bd |= ~0L<<16;
+ i->bd |= ~0UL<<16;
i->crfd = IBF(w, 6, 8);
i->crfs = IBF(w, 11, 13);
i->bi = IBF(w, 11, 15);
@@ -181,7 +181,7 @@ decode(ulong pc, Instr *i)
i->crm = IBF(w, 12, 19);
i->li = IBF(w, 6, 29)<<2;
if(IB(w, 6))
- i->li |= ~0<<25;
+ i->li |= ~0UL<<25;
i->lk = IB(w, 31);
i->mb = IBF(w, 21, 25);
i->me = IBF(w, 26, 30);