Skip to content

Commit 3d4a902

Browse files
authored
Fixes for Windows ARM64 (#251)
* aarch64_fpmath.h: deal with LLP64 (Windows ARM64) use uint64_t instead of unsigned long, as unsigned long is only 32 bits on Windows * Make.inc: WINNT aarch64 long double is double Add to list along with Darwin
1 parent a9568fb commit 3d4a902

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Make.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ ifneq ($(filter $(ARCH),i387 amd64),)
151151
# `long double` is the same as `double`.
152152
LONG_DOUBLE_NOT_DOUBLE := 1
153153
else ifeq ($(ARCH), aarch64)
154-
ifneq ($(OS),Darwin)
154+
ifeq ($(filter $(OS),Darwin WINNT),)
155155
LONG_DOUBLE_NOT_DOUBLE := 1
156156
endif
157157
endif

src/aarch64_fpmath.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,15 @@
3030
union IEEEl2bits {
3131
long double e;
3232
struct {
33-
unsigned long manl :64;
34-
unsigned long manh :48;
33+
uint64_t manl :64;
34+
uint64_t manh :48;
3535
unsigned int exp :15;
3636
unsigned int sign :1;
3737
} bits;
3838
/* TODO andrew: Check the packing here */
3939
struct {
40-
unsigned long manl :64;
41-
unsigned long manh :48;
40+
uint64_t manl :64;
41+
uint64_t manh :48;
4242
unsigned int expsign :16;
4343
} xbits;
4444
};

0 commit comments

Comments
 (0)