CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-04-18 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Thu Apr 18 06:32:21 UTC 2019

Removed Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: riscv-opc.h t-elf
t-linux64

Log Message:
delete files no longer present in GCC 7 port of riscv.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r0 \
src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h
cvs rdiff -u -r1.2 -r0 src/external/gpl3/gcc/dist/gcc/config/riscv/t-elf \
src/external/gpl3/gcc/dist/gcc/config/riscv/t-linux64

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-04-15 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Mon Apr 15 21:13:36 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
Remove unused definition.


To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 \
src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.9 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.10
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.9	Mon Apr 15 18:49:07 2019
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Mon Apr 15 21:13:36 2019
@@ -20,9 +20,6 @@ along with this program; see the file CO
 the Free Software Foundation, 59 Temple Place - Suite 330,
 Boston, MA 02111-1307, USA.  */
 
-#undef TARGET_USE_GP
-#define TARGET_USE_GP 0
-
 #undef DRIVER_SELF_SPECS
 #define DRIVER_SELF_SPECS ""
 



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-04-15 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Mon Apr 15 18:49:07 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
Re-do previous:
emulate the addition of NETBSD_SUBTARGET_EXTRA_SPECS usually done by
SUBTARGET_EXTRA_SPECS (not used in risc-v) with EXTRA_SPECS.
Go back to using %(netbsd_link_spec) in our link spec, now that it's
a valid string.

Try to mimic other riscv OSes in our LINK_SPEC. they all start with
"-melf" XLEN_SPEC "lriscv" LD_EMUL_SUFFIX

and a definition of LD_EMUL_SUFFIX,
let's copy the LD_EMUL_SUFFIX linux uses.

Now we can link executables.


To generate a diff of this commit:
cvs rdiff -u -r1.8 -r1.9 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.8 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.9
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.8	Mon Apr 15 14:19:20 2019
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Mon Apr 15 18:49:07 2019
@@ -48,17 +48,20 @@ Boston, MA 02111-1307, USA.  */
 #undef LIB_SPEC
 #define LIB_SPEC NETBSD_LIB_SPEC
 
-#undef LINK_SPEC
-#define LINK_SPEC NETBSD_LINK_SPEC_ELF
-/* Provide a LINK_SPEC appropriate for a NetBSD/mips target.
-   This is a copy of LINK_SPEC from  tweaked for
-   the MIPS target.  */
+#define EXTRA_SPECS NETBSD_SUBTARGET_EXTRA_SPECS
+
+#define LD_EMUL_SUFFIX \
+  "%{mabi=lp64d:}" \
+  "%{mabi=lp64f:_lp64f}" \
+  "%{mabi=lp64:_lp64}" \
+  "%{mabi=ilp32d:}" \
+  "%{mabi=ilp32f:_ilp32f}" \
+  "%{mabi=ilp32:_ilp32}"
 
 #undef LINK_SPEC
-#define LINK_SPEC \
-  "%{m64:-m elf64lriscv} \
-   %{m32:-m elf32lriscv}" \
-   NETBSD_LINK_SPEC_ELF
+#define LINK_SPEC "\
+-melf" XLEN_SPEC "lriscv" LD_EMUL_SUFFIX " \
+%(netbsd_link_spec)"
 
 #undef NETBSD_ENTRY_POINT
 #define NETBSD_ENTRY_POINT	"_start"



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-04-15 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Mon Apr 15 14:19:20 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
don't redefine types.
UINTMAX_TYPE / INTMAX_TYPE are mostly not redefined on netbsd.
These choices contradict typical 64bit archs, perhaps we don't want them.

XXX is the SIZE_TYPE default for riscv reasonable?
(long unsigned int for 64bit abi, unsigned int for 32bit abi)


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.7 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.8
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.7	Sat Apr 13 15:53:32 2019
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Mon Apr 15 14:19:20 2019
@@ -62,12 +62,3 @@ Boston, MA 02111-1307, USA.  */
 
 #undef NETBSD_ENTRY_POINT
 #define NETBSD_ENTRY_POINT	"_start"
-
-#undef SIZE_TYPE
-#define SIZE_TYPE "long unsigned int"
-
-#undef INTMAX_TYPE
-#define INTMAX_TYPE "long long int"
-
-#undef UINTMAX_TYPE
-#define UINTMAX_TYPE "long long unsigned int"



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-04-13 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Sat Apr 13 15:53:32 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
use NETBSD_LINK_SPEC_ELF rather than netbsd_link_spec.

My current guess as to why it makes a difference is that riscv, unlike other
targets, doesn't use the macro SUBTARGET_EXTRA_SPECS for anything meaningful

Fixes linking libgcc_s.so, which is now emitted as a dynamic library, not
a static object (which fails, as it has undefined references)

XXX there might be a better way of doing this


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.6 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.7
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.6	Sun Feb 10 07:56:21 2019
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Sat Apr 13 15:53:32 2019
@@ -57,8 +57,8 @@ Boston, MA 02111-1307, USA.  */
 #undef LINK_SPEC
 #define LINK_SPEC \
   "%{m64:-m elf64lriscv} \
-   %{m32:-m elf32lriscv} \
-   %(netbsd_link_spec)"
+   %{m32:-m elf32lriscv}" \
+   NETBSD_LINK_SPEC_ELF
 
 #undef NETBSD_ENTRY_POINT
 #define NETBSD_ENTRY_POINT	"_start"



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-02-09 Thread matthew green
Module Name:src
Committed By:   mrg
Date:   Sun Feb 10 07:56:21 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
remove stuff provided by netbsd-stdint.h.


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.6 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.5 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.6
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.5	Sat Feb  9 21:00:41 2019
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Sun Feb 10 07:56:21 2019
@@ -63,38 +63,6 @@ Boston, MA 02111-1307, USA.  */
 #undef NETBSD_ENTRY_POINT
 #define NETBSD_ENTRY_POINT	"_start"
 
-#define SIG_ATOMIC_TYPE   "int"
-
-#define INT8_TYPE "signed char"
-#define INT16_TYPE "short int"
-#define INT32_TYPE "int"
-#define INT64_TYPE "long long int"
-#define UINT8_TYPE "unsigned char"
-#define UINT16_TYPE "short unsigned int"
-#define UINT32_TYPE "unsigned int"
-#define UINT64_TYPE "long long unsigned int"
-
-#define INT_LEAST8_TYPE "signed char"
-#define INT_LEAST16_TYPE "short int"
-#define INT_LEAST32_TYPE "int"
-#define INT_LEAST64_TYPE "long long int"
-#define UINT_LEAST8_TYPE "unsigned char"
-#define UINT_LEAST16_TYPE "short unsigned int"
-#define UINT_LEAST32_TYPE "unsigned int"
-#define UINT_LEAST64_TYPE "long long unsigned int"
-
-#define INT_FAST8_TYPE "signed char"
-#define INT_FAST16_TYPE "short int"
-#define INT_FAST32_TYPE "int"
-#define INT_FAST64_TYPE "long long int"
-#define UINT_FAST8_TYPE "unsigned char"
-#define UINT_FAST16_TYPE "short unsigned int"
-#define UINT_FAST32_TYPE "unsigned int"
-#define UINT_FAST64_TYPE "long long unsigned int"
-
-#undef PTRDIFF_TYPE
-#define PTRDIFF_TYPE "long int"
-
 #undef SIZE_TYPE
 #define SIZE_TYPE "long unsigned int"
 



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2019-02-09 Thread Maya Rashish
Module Name:src
Committed By:   maya
Date:   Sat Feb  9 21:00:41 UTC 2019

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h

Log Message:
s/TARGET_HARD_FLOAT_ABI/TARGET_HARD_FLOAT, the latter has the
benefit of existing. Inspired by mips/netbsd.h.

remove some redefinitions. There are still a few left, but these ones
seem to match.


To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.4 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.5
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.4	Fri Aug 19 05:11:10 2016
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Sat Feb  9 21:00:41 2019
@@ -38,7 +38,7 @@ Boston, MA 02111-1307, USA.  */
 /* The GNU C++ standard library requires this.  */		\
 if (c_dialect_cxx ())	\
   builtin_define ("_GNU_SOURCE");\
-if (!TARGET_HARD_FLOAT_ABI)	\
+if (!TARGET_HARD_FLOAT)	\
   builtin_define ("_SOFT_FLOAT");\
   } while (0)
 
@@ -98,9 +98,6 @@ Boston, MA 02111-1307, USA.  */
 #undef SIZE_TYPE
 #define SIZE_TYPE "long unsigned int"
 
-#define INTPTR_TYPE PTRDIFF_TYPE
-#define UINTPTR_TYPE SIZE_TYPE
-
 #undef INTMAX_TYPE
 #define INTMAX_TYPE "long long int"
 



CVS commit: src/external/gpl3/gcc/dist/gcc/config/riscv

2015-04-01 Thread Matt Thomas
Module Name:src
Committed By:   matt
Date:   Wed Apr  1 06:35:01 UTC 2015

Modified Files:
src/external/gpl3/gcc/dist/gcc/config/riscv: netbsd.h riscv-opc.h
riscv.c riscv.h riscv.md

Log Message:
Update to latest gcc changes.  Default NetBSD to the medany cmodel.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h \
src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h \
src/external/gpl3/gcc/dist/gcc/config/riscv/riscv.c \
src/external/gpl3/gcc/dist/gcc/config/riscv/riscv.md
cvs rdiff -u -r1.3 -r1.4 src/external/gpl3/gcc/dist/gcc/config/riscv/riscv.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.2 src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.3
--- src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h:1.2	Sat Mar 28 00:47:17 2015
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h	Wed Apr  1 06:35:01 2015
@@ -27,7 +27,10 @@ Boston, MA 02111-1307, USA.  */
 #define DRIVER_SELF_SPECS 
 
 #undef TARGET_DEFAULT
-#define TARGET_DEFAULT (MASK_ATOMIC | MASK_FDIV)
+#define TARGET_DEFAULT (MASK_FDIV)
+
+#undef TARGET_DEFAULT_CMODEL
+#define TARGET_DEFAULT_CMODEL	CM_MEDANY
 
 #define TARGET_OS_CPP_BUILTINS()\
   do {\
Index: src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h
diff -u src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h:1.2 src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h:1.3
--- src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h:1.2	Fri Mar 27 01:51:34 2015
+++ src/external/gpl3/gcc/dist/gcc/config/riscv/riscv-opc.h	Wed Apr  1 06:35:01 2015
@@ -1,714 +1,688 @@
 /* Automatically generated by parse-opcodes */
 #ifndef RISCV_ENCODING_H
 #define RISCV_ENCODING_H
-#define MATCH_CUSTOM3_RD_RS1_RS2 0x707b
-#define MASK_CUSTOM3_RD_RS1_RS2  0x707f
-#define MATCH_VLSEGSTWU 0xc00305b
-#define MASK_VLSEGSTWU  0x1e00707f
-#define MATCH_C_LW0 0x12
-#define MASK_C_LW0  0x801f
-#define MATCH_FMV_D_X 0xf253
-#define MASK_FMV_D_X  0xfff0707f
-#define MATCH_VLH 0x200205b
-#define MASK_VLH  0xfff0707f
-#define MATCH_C_LI 0x0
-#define MASK_C_LI  0x1f
-#define MATCH_FADD_D 0x253
-#define MASK_FADD_D  0xfe7f
-#define MATCH_C_LD 0x9
-#define MASK_C_LD  0x1f
-#define MATCH_VLD 0x600205b
-#define MASK_VLD  0xfff0707f
-#define MATCH_FADD_S 0x53
-#define MASK_FADD_S  0xfe7f
-#define MATCH_C_LW 0xa
-#define MASK_C_LW  0x1f
-#define MATCH_VLW 0x400205b
-#define MASK_VLW  0xfff0707f
-#define MATCH_VSSEGSTW 0x400307b
-#define MASK_VSSEGSTW  0x1e00707f
-#define MATCH_UTIDX 0x6077
-#define MASK_UTIDX  0xf07f
-#define MATCH_C_FLW 0x14
-#define MASK_C_FLW  0x1f
-#define MATCH_FSUB_D 0xa53
-#define MASK_FSUB_D  0xfe7f
-#define MATCH_VSSEGSTD 0x600307b
-#define MASK_VSSEGSTD  0x1e00707f
-#define MATCH_VSSEGSTB 0x307b
-#define MASK_VSSEGSTB  0x1e00707f
-#define MATCH_DIV 0x2004033
-#define MASK_DIV  0xfe00707f
-#define MATCH_FMV_H_X 0xf453
-#define MASK_FMV_H_X  0xfff0707f
-#define MATCH_C_FLD 0x15
-#define MASK_C_FLD  0x1f
-#define MATCH_FRRM 0x202073
-#define MASK_FRRM  0xf07f
-#define MATCH_VFMSV_S 0x1000202b
-#define MASK_VFMSV_S  0xfff0707f
-#define MATCH_C_LWSP 0x5
-#define MASK_C_LWSP  0x1f
-#define MATCH_FENCE 0xf
-#define MASK_FENCE  0x707f
-#define MATCH_FNMSUB_S 0x4b
-#define MASK_FNMSUB_S  0x67f
-#define MATCH_FLE_S 0xa053
-#define MASK_FLE_S  0xfe00707f
-#define MATCH_FNMSUB_H 0x44b
-#define MASK_FNMSUB_H  0x67f
-#define MATCH_FLE_H 0xbc53
-#define MASK_FLE_H  0xfe00707f
-#define MATCH_FLW 0x2007
-#define MASK_FLW  0x707f
-#define MATCH_VSETVL 0x600b
-#define MASK_VSETVL  0xfff0707f
-#define MATCH_VFMSV_D 0x1200202b
-#define MASK_VFMSV_D  0xfff0707f
-#define MATCH_FLE_D 0xa253
-#define MASK_FLE_D  0xfe00707f
-#define MATCH_FENCE_I 0x100f
-#define MASK_FENCE_I  0x707f
-#define MATCH_FNMSUB_D 0x24b
-#define MASK_FNMSUB_D  0x67f
-#define MATCH_ADDW 0x3b
-#define MASK_ADDW  0xfe00707f
-#define MATCH_XOR 0x4033
-#define MASK_XOR  0xfe00707f
-#define MATCH_SUB 0x4033
-#define MASK_SUB  0xfe00707f
-#define MATCH_VSSTW 0x400307b
-#define MASK_VSSTW  0xfe00707f
-#define MATCH_VSSTH 0x200307b
-#define MASK_VSSTH  0xfe00707f
-#define MATCH_SC_W 0x1800202f
-#define MASK_SC_W  0xf800707f
-#define MATCH_VSSTB 0x307b
-#define MASK_VSSTB  0xfe00707f
-#define MATCH_VSSTD 0x600307b
-#define MASK_VSSTD  0xfe00707f
+#define MATCH_ADD 0x33
+#define MASK_ADD  0xfe00707f
 #define MATCH_ADDI 0x13
 #define MASK_ADDI  0x707f
-#define MATCH_RDTIMEH 0xc8102073
-#define MASK_RDTIMEH  0xf07f
-#define MATCH_MULH 0x2001033
-#define MASK_MULH  0xfe00707f
-#define MATCH_CSRRSI 0x6073
-#define MASK_CSRRSI  0x707f
-#define MATCH_FCVT_D_WU 0xd2100053
-#define MASK_FCVT_D_WU  0xfff0007f
-#define MATCH_MULW 0x23b
-#define