This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 11/12] RISC-V: Linux ABI
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Palmer Dabbelt <palmer at dabbelt dot com>
- Cc: <libc-alpha at sourceware dot org>, Andrew Waterman <andrew at sifive dot com>, <patches at groups dot riscv dot org>, Darius Rad <darius at bluespec dot com>
- Date: Wed, 14 Jun 2017 21:23:10 +0000
- Subject: Re: [PATCH 11/12] RISC-V: Linux ABI
- Authentication-results: sourceware.org; auth=none
- References: <20170614183048.11040-1-palmer@dabbelt.com> <20170614183048.11040-12-palmer@dabbelt.com>
On Wed, 14 Jun 2017, Palmer Dabbelt wrote:
> diff --git a/sysdeps/riscv/rv32/divdi3.c b/sysdeps/riscv/rv32/divdi3.c
> new file mode 100644
> index 0000000000..52f3a0396c
> --- /dev/null
> +++ b/sysdeps/riscv/rv32/divdi3.c
> @@ -0,0 +1 @@
> +/* libgcc.a provides optimized versions of these routines. */
divdi3.c is now only used if an architecture explicitly requests it. You
shouldn't need this file.
> diff --git a/sysdeps/riscv/rv32/symbol-hacks.h b/sysdeps/riscv/rv32/symbol-hacks.h
> new file mode 100644
> index 0000000000..22aad04437
> --- /dev/null
> +++ b/sysdeps/riscv/rv32/symbol-hacks.h
> @@ -0,0 +1 @@
> +#include <sysdeps/generic/symbol-hacks.h>
Likewise, you shouldn't need this file either.
> diff --git a/sysdeps/unix/sysv/linux/riscv/sys/ucontext.h b/sysdeps/unix/sysv/linux/riscv/sys/ucontext.h
> +/* Number of general registers. */
> +#define NGREG 32
> +#define NFPREG 32
> +
> +#define REG_PC 0
> +#define REG_RA 1
> +#define REG_SP 2
> +#define REG_TP 4
> +#define REG_S0 8
> +#define REG_A0 10
> +#define REG_NARGS 8
> +
> +/* Container for all general registers. */
> +typedef greg_t gregset_t[NGREG];
> +
> +/* Container for all FPU registers. */
> +typedef fpreg_t fpregset_t[NFPREG];
See my recent cleanups, and make sure your sys/ucontext.h is
namespace-clean in all the ways in which I've cleaned up other
sys/ucontext.h files so far.
--
Joseph S. Myers
joseph@codesourcery.com