fixes for building on 32 bit host systems

This commit is contained in:
kub 2018-05-31 23:24:21 +02:00 committed by queueRAM
parent 4cb644d4b0
commit b9d1f49337
4 changed files with 23 additions and 7 deletions

1
configure vendored
View File

@ -6836,6 +6836,7 @@ case "$target_name" in
solaris)
TARGET_ARCH=sparc
TARGET_ABI_DIR=solaris
TARGET_BASE_ARCH=sparc
echo "TARGET_ABI_SOLARIS=y" >> $config_target_mak
;;
solaris64)

View File

@ -2067,6 +2067,8 @@ abi_ulong sgi_map_elf_image(int image_fd, struct elf_phdr *phdr, int phnum)
}
}
mmap_lock();
/* The image indicates that it can be loaded anywhere. Find a
location that can hold the memory space required. If the
image is pre-linked, LOADDR will be non-zero. Since we do
@ -2113,9 +2115,13 @@ abi_ulong sgi_map_elf_image(int image_fd, struct elf_phdr *phdr, int phnum)
}
}
mmap_unlock();
return load_bias + phdr[0].p_vaddr;
exit_perror:
mmap_unlock();
errmsg = strerror(errno);
fprintf(stderr, "error in syssgi elfmap: %s\n", errmsg);
return -ENOEXEC;

View File

@ -1622,7 +1622,7 @@ struct target_stat {
abi_long target_st_ctime;
abi_ulong __unused3;
abi_int st_blksize;
int64_t st_blocks;
abi_llong st_blocks;
char st_fstype[16];
abi_long __unused4[8];
};
@ -1631,14 +1631,14 @@ struct target_stat {
struct target_stat64 {
abi_ulong st_dev;
abi_long st_pad1[3];
uint64_t st_ino;
abi_ullong st_ino;
abi_uint st_mode;
abi_uint st_nlink;
abi_int st_uid;
abi_int st_gid;
abi_ulong st_rdev;
abi_long st_pad2[2];
int64_t st_size;
abi_llong st_size;
abi_long target_st_atime;
abi_ulong __unused1;
abi_long target_st_mtime;
@ -1646,7 +1646,7 @@ struct target_stat64 {
abi_long target_st_ctime;
abi_ulong __unused3;
abi_int st_blksize;
int64_t st_blocks;
abi_llong st_blocks;
char st_fstype[16];
abi_long __unused4[8];
};
@ -1977,7 +1977,7 @@ struct target_stat {
struct target_stat64 {
uint32_t st_dev;
abi_long st_pad0[3]; /* Reserved for st_dev expansion */
uint64_t st_ino;
abi_ullong st_ino;
uint32_t st_mode;
uint32_t st_nlink;
@ -1987,7 +1987,7 @@ struct target_stat64 {
uint32_t st_rdev;
abi_long st_pad1[2]; /* Reserved for st_rdev expansion */
int64_t st_size;
abi_llong st_size;
abi_long st_pad2;
/*
@ -2004,7 +2004,7 @@ struct target_stat64 {
abi_long target_st_ctime_nsec;
abi_long st_blksize;
int64_t st_blocks;
abi_llong st_blocks;
char st_fstype[16];
abi_long st_projid;
abi_long st_pad[7];

View File

@ -2696,6 +2696,12 @@ static void tcg_out_vec_op(TCGContext *s, TCGOpcode opc,
case INDEX_op_x86_packus_vec:
insn = packus_insn[vece];
goto gen_simd;
#if TCG_TARGET_REG_BITS == 32
case INDEX_op_dup2_vec:
/* Constraints have already placed both 32-bit inputs in xmm regs. */
insn = OPC_PUNPCKLDQ;
goto gen_simd;
#endif
gen_simd:
tcg_debug_assert(insn != OPC_UD2);
if (type == TCG_TYPE_V256) {
@ -3045,6 +3051,9 @@ static const TCGTargetOpDef *tcg_target_op_def(TCGOpcode op)
case INDEX_op_x86_vperm2i128_vec:
case INDEX_op_x86_punpckl_vec:
case INDEX_op_x86_punpckh_vec:
#if TCG_TARGET_REG_BITS == 32
case INDEX_op_dup2_vec:
#endif
return &x_x_x;
case INDEX_op_dup_vec:
case INDEX_op_shli_vec: