Re: [PATCH v10 10/12] LoongArch Port: libgomp

2022-03-24 Thread 程璐璐
Hi, Jakub:  Thanks for your review. 在 2022/3/24 下午8:41, Jakub Jelinek 写道: On Thu, Mar 24, 2022 at 08:37:32PM +0800, chenglulu wrote: libgomp/ * configure.tgt: Add LoongArch triplet. Ok. diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8

Re: [PATCH v10 10/12] LoongArch Port: libgomp

2022-03-24 Thread Jakub Jelinek via Gcc-patches
On Thu, Mar 24, 2022 at 08:37:32PM +0800, chenglulu wrote: > libgomp/ > > * configure.tgt: Add LoongArch triplet. Ok. > diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt > index d4f1e741b5a..2cd7272fcd8 100644 > --- a/libgomp/configure.tgt > +++ b/libgomp/configure.tgt > @@

[PATCH v10 12/12] LoongArch Port: Add doc.

2022-03-24 Thread chenglulu
* contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch options section. --- contrib/config-list.mk | 4 +- gcc/doc/install.texi

[PATCH v10 08/12] LoongArch Port: libgcc

2022-03-24 Thread chenglulu
libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/linux-unwind.h: Like wise. * config/loongarch/sfp-machine.h: Like wise. * config/loongarch/t-crtstuff: Like wise. * config/loongarch/t-loongarch: Like wise. *

[PATCH v10 06/12] LoongArch Port: Builtin functions.

2022-03-24 Thread chenglulu
gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 355 + gcc/config/loongarch/loongarch-builtins.cc | 424 + 2 files changed, 779 insertions(+)

[PATCH v10 11/12] LoongArch Port: gcc/testsuite

2022-03-24 Thread chenglulu
gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. * gcc.dg/20020312-2.c: Add LoongArch support. *

[PATCH v10 02/12] LoongArch Port: gcc build

2022-03-24 Thread chenglulu
gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. * config/loongarch/genopts/loongarch.opt.in: New file. * config/loongarch/loongarch-str.h:

[PATCH v10 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-03-24 Thread chenglulu
libgcc/ * configure: Regenerate file. --- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 52bf25d4e94..1f9b2ac578b 100755 --- a/libgcc/configure +++ b/libgcc/configure @@ -2403,6 +2403,9 @@ case "${host}"

[PATCH v10 07/12] LoongArch Port: Builtin macros.

2022-03-24 Thread chenglulu
gcc/ * config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git a/gcc/config/loongarch/loongarch-c.cc

[PATCH v10 03/12] LoongArch Port: Regenerate gcc/configure.

2022-03-24 Thread chenglulu
gcc/ * configure: Regenerate file. --- gcc/configure | 66 ++- 1 file changed, 60 insertions(+), 6 deletions(-) diff --git a/gcc/configure b/gcc/configure index 14b19c8fe0c..1c1195e95cb 100755 --- a/gcc/configure +++ b/gcc/configure @@

[PATCH v10 10/12] LoongArch Port: libgomp

2022-03-24 Thread chenglulu
libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 --- a/libgomp/configure.tgt +++ b/libgomp/configure.tgt @@ -56,6 +56,10

[PATCH v10 01/12] LoongArch Port: Regenerate configure

2022-03-24 Thread chenglulu
* config/picflag.m4: Default add build option '-fpic' for LoongArch. * configure: Add LoongArch tuples. * configure.ac: Like wise. --- config/picflag.m4 | 3 +++ configure | 10 +- configure.ac | 10 +- 3 files changed, 21 insertions(+), 2

Re: [PATCH v9 12/12] LoongArch Port: Add doc.

2022-03-22 Thread Richard Sandiford via Gcc-patches
chenglulu writes: > +@item -msmall-data-limit=@var{number} > +@opindex -msmall-data-limit > +Put global and static data smaller than @code{number} bytes into a special > +section (on some targets). The default value is 0. One minor left-over from v8: this should be @var{number} rather than

Re: [PATCH v9 11/12] LoongArch Port: gcc/testsuite

2022-03-22 Thread Richard Sandiford via Gcc-patches
chenglulu writes: > diff --git a/gcc/testsuite/lib/target-supports.exp > b/gcc/testsuite/lib/target-supports.exp > index 737e1a8913b..843b508b010 100644 > --- a/gcc/testsuite/lib/target-supports.exp > +++ b/gcc/testsuite/lib/target-supports.exp > @@ -286,6 +286,10 @@ proc check_configured_with {

Re: [PATCH v9 06/12] LoongArch Port: Builtin functions.

2022-03-22 Thread Richard Sandiford via Gcc-patches
Hi, Thanks for the update. It looks like there are some unaddressed comments from the v8 review: chenglulu writes: > gcc/ > > * config/loongarch/larchintrin.h: New file. > * config/loongarch/loongarch-builtins.cc: New file. > --- > gcc/config/loongarch/larchintrin.h | 409

Re: [PATCH v9 04/12] LoongArch Port: Machine description files.

2022-03-20 Thread Richard Sandiford via Gcc-patches
Thanks, this addresses most of my comments from the v8 review. There were a couple left over though: chenglulu writes: > +(define_attr "compression" "none,all" > + (const_string "none")) I still don't understand the purpose of keeping this for LoongArch. > +(define_insn "truncdisi2_extended"

Re: [PATCH v8 04/12] LoongArch Port: Machine description files.

2022-03-19 Thread 程璐璐
在 2022/3/7 上午12:16, Richard Sandiford 写道: +(define_split + [(match_operand 0 "small_data_pattern")] + "reload_completed" + [(match_dup 0)] + { operands[0] = loongarch_rewrite_small_data (operands[0]); }) + + +;; Match paired HI/SI/SF/DFmode load/stores. +(define_insn "*join2_load_store" +

Re: [PATCH v8 05/12] LoongArch Port: Machine description C files and .h files.

2022-03-19 Thread 程璐璐
在 2022/3/8 上午2:17, Richard Sandiford 写道: […] +/* This definition replaces the formerly used 'm' constraint with a + different constraint letter in order to avoid changing semantics of + the 'm' constraint when accepting new address formats in + TARGET_LEGITIMATE_ADDRESS_P. The

[PATCH v9 08/12] LoongArch Port: libgcc

2022-03-19 Thread chenglulu
libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/linux-unwind.h: Like wise. * config/loongarch/sfp-machine.h: Like wise. * config/loongarch/t-crtstuff: Like wise. * config/loongarch/t-loongarch: Like wise. *

[PATCH v9 02/12] LoongArch Port: gcc build

2022-03-19 Thread chenglulu
gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. * config/loongarch/genopts/loongarch.opt.in: New file. * config/loongarch/loongarch-str.h:

[PATCH v9 12/12] LoongArch Port: Add doc.

2022-03-19 Thread chenglulu
* contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch options section. --- contrib/config-list.mk | 4 +- gcc/doc/install.texi

[PATCH v9 06/12] LoongArch Port: Builtin functions.

2022-03-19 Thread chenglulu
gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 409 + gcc/config/loongarch/loongarch-builtins.cc | 511 + 2 files changed, 920 insertions(+)

[PATCH v9 10/12] LoongArch Port: libgomp

2022-03-19 Thread chenglulu
libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 --- a/libgomp/configure.tgt +++ b/libgomp/configure.tgt @@ -56,6 +56,10

[PATCH v9 11/12] LoongArch Port: gcc/testsuite

2022-03-19 Thread chenglulu
gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. * gcc.dg/20020312-2.c: Add LoongArch support. *

[PATCH v9 07/12] LoongArch Port: Builtin macros.

2022-03-19 Thread chenglulu
gcc/ * config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git a/gcc/config/loongarch/loongarch-c.cc

[PATCH v9 03/12] LoongArch Port: Regenerate gcc/configure.

2022-03-19 Thread chenglulu
gcc/ * configure: Regenerate file. --- gcc/configure | 66 ++- 1 file changed, 60 insertions(+), 6 deletions(-) diff --git a/gcc/configure b/gcc/configure index 14b19c8fe0c..1c1195e95cb 100755 --- a/gcc/configure +++ b/gcc/configure @@

[PATCH v9 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-03-19 Thread chenglulu
libgcc/ * configure: Regenerate file. --- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 52bf25d4e94..1f9b2ac578b 100755 --- a/libgcc/configure +++ b/libgcc/configure @@ -2403,6 +2403,9 @@ case "${host}"

[PATCH v9 01/12] LoongArch Port: Regenerate configure

2022-03-19 Thread chenglulu
* config/picflag.m4: Default add build option '-fpic' for LoongArch. * configure: Add LoongArch tuples. * configure.ac: Like wise. --- config/picflag.m4 | 3 +++ configure | 10 +- configure.ac | 10 +- 3 files changed, 21 insertions(+), 2

Re: [PATCH v8 04/12] LoongArch Port: Machine description files.

2022-03-09 Thread 程璐璐
Hi,    We are modifying the code, this support will be added in the next commit. Thanks. 在 2022/3/8 上午4:15, Xi Ruoyao 写道: On Fri, 2022-03-04 at 15:18 +0800, xucheng...@loongson.cn wrote: * config/loongarch/loongarch.md: New file. An ICE happens building OpenSSH-8.9p1.

Re: [PATCH v8 12/12] LoongArch Port: Add doc.

2022-03-08 Thread Richard Sandiford via Gcc-patches
xucheng...@loongson.cn writes: > From: chenglulu > > 2022-03-04 Chenghua Xu > Lulu Cheng > > * contrib/config-list.mk: Add LoongArch triplet. > * gcc/doc/install.texi: Add LoongArch options section. > * gcc/doc/invoke.texi: Add LoongArch options section. > *

Re: [PATCH v8 08/12] LoongArch Port: libgcc

2022-03-08 Thread Andreas Schwab
On Mär 08 2022, Richard Sandiford via Gcc-patches wrote: >> + >> +.section .init,"ax",@progbits >> +.globl _init >> +.type _init,@function >> +_init: >> +addi.d $r3,$r3,-16 >> +st.d $r1,$r3,8 >> +addi.d $r3,$r3,16 >> +jirl$r0,$r1,0 >> + >> +.section

Re: [PATCH v8 11/12] LoongArch Port: gcc/testsuite

2022-03-08 Thread Richard Sandiford via Gcc-patches
xucheng...@loongson.cn writes: > diff --git a/gcc/testsuite/lib/target-supports.exp > b/gcc/testsuite/lib/target-supports.exp > index 737e1a8913b..843b508b010 100644 > --- a/gcc/testsuite/lib/target-supports.exp > +++ b/gcc/testsuite/lib/target-supports.exp > @@ -286,6 +286,10 @@ proc

Re: [PATCH v8 08/12] LoongArch Port: libgcc

2022-03-08 Thread Richard Sandiford via Gcc-patches
xucheng...@loongson.cn writes: > diff --git a/libgcc/config/loongarch/crti.S b/libgcc/config/loongarch/crti.S > new file mode 100644 > index 000..27b7eab3626 > --- /dev/null > +++ b/libgcc/config/loongarch/crti.S > @@ -0,0 +1,43 @@ > +/* Copyright (C) 2021-2022 Free Software Foundation,

Re: [PATCH v8 06/12] LoongArch Port: Builtin functions.

2022-03-08 Thread Richard Sandiford via Gcc-patches
xucheng...@loongson.cn writes: > +#ifndef _GCC_LOONGARCH_BASE_INTRIN_H > +#define _GCC_LOONGARCH_BASE_INTRIN_H > + > +#ifdef __cplusplus > +extern "C" { > +#endif > + > +typedef struct drdtime > +{ > + unsigned long dvalue; > + unsigned long dtimeid; > +} __drdtime_t; > + > +typedef struct

Re: [PATCH v8 04/12] LoongArch Port: Machine description files.

2022-03-07 Thread Xi Ruoyao via Gcc-patches
On Fri, 2022-03-04 at 15:18 +0800, xucheng...@loongson.cn wrote: > * config/loongarch/loongarch.md: New file. An ICE happens building OpenSSH-8.9p1. Investigation shows it's caused by the flag "-fzero-call-used-regs=". It's because the compiler attempts to clear FCCx registers but

Re: [PATCH v8 05/12] LoongArch Port: Machine description C files and .h files.

2022-03-07 Thread Richard Sandiford via Gcc-patches
Hi, Some comments below, but otherwise it looks good to me. A few of the comments are about removing hook or macro definitions that are the same as the default. Doing that helps people who want to update a hook interface in future, since there are then fewer places to adjust.

Re: [PATCH v8 04/12] LoongArch Port: Machine description files.

2022-03-06 Thread 程璐璐
Hi, Richard:  Thanks for your review. We will revise it as soon as possible and submit it in the next version. 在 2022/3/7 上午12:16, Richard Sandiford 写道: Hi, Some comments below, but otherwise it looks good to me. xucheng...@loongson.cn writes: […] +(define_memory_constraint "k" + "A

Re: [PATCH v8 04/12] LoongArch Port: Machine description files.

2022-03-06 Thread Richard Sandiford via Gcc-patches
Hi, Some comments below, but otherwise it looks good to me. xucheng...@loongson.cn writes: > […] > +(define_memory_constraint "k" > + "A memory operand whose address is formed by a base register and > (optionally scaled) > + index register." > + (and (match_code "mem") > + (not

Re: [PATCH v8 02/12] LoongArch Port: gcc build

2022-03-06 Thread Andreas Schwab
On Mär 06 2022, Richard Sandiford via Gcc-patches wrote: > Similarly here we need to avoid bash's $(...). $(...) is 100% POSIX. -- Andreas Schwab, sch...@linux-m68k.org GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1 "And now for something completely different."

Re: [PATCH v8 02/12] LoongArch Port: gcc build

2022-03-06 Thread Richard Sandiford via Gcc-patches
Hi, Thanks for the submission. Some comments below on this patch, but otherwise it looks good. I hope to get to the other patches in the series soon. I haven't followed all of the previous discussion, so some of these points might already have been discussed. Sorry in advance if so.

[PATCH v8 12/12] LoongArch Port: Add doc.

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng * contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch

[PATCH v8 11/12] LoongArch Port: gcc/testsuite

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. *

[PATCH v8 08/12] LoongArch Port: libgcc

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/crti.S: Like wise. * config/loongarch/crtn.S: Like wise. * config/loongarch/linux-unwind.h: Like wise. *

[PATCH v8 10/12] LoongArch Port: libgomp

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 ---

[PATCH v8 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng * libgcc/configure: Regenerated. --- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 52bf25d4e94..1f9b2ac578b 100755 --- a/libgcc/configure

[PATCH v8 06/12] LoongArch Port: Builtin functions.

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 413 +

[PATCH v8 02/12] LoongArch Port: gcc build

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. *

[PATCH v8 07/12] LoongArch Port: Builtin macros.

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng gcc/ *config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git

[PATCH v8 03/12] LoongArch Port: Regenerate gcc/configure.

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng gcc/ * configure: Regenerate. --- gcc/configure | 66 ++- 1 file changed, 60 insertions(+), 6 deletions(-) diff --git a/gcc/configure b/gcc/configure index

[PATCH v8 01/12] LoongArch Port: Regenerate configure

2022-03-03 Thread xuchenghua
From: chenglulu 2022-03-04 Chenghua Xu Lulu Cheng * config/picflag.m4: Default add build option '-fpic' for LoongArch. * configure: Add LoongArch tuples. * configure.ac: Like wise. --- config/picflag.m4 | 3 +++ configure | 10 +-

Re: [PATCH v7 11/12] LoongArch Port: gcc/testsuite

2022-02-27 Thread 程璐璐
Thanks,  speculation barrier is not needed for loongarch. I have removed the warning. 在 2022/2/25 上午3:32, Xi Ruoyao 写道: On Sat, 2022-02-12 at 11:11 +0800, xucheng...@loongson.cn wrote: From: chenglulu 2022-02-12  Chenghua Xu      Lulu Cheng  gcc/testsuite/ spec-barrier tests

Re: [PATCH v7 05/12] LoongArch Port: Machine description C files and .h files.

2022-02-24 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-02-12 at 11:11 +0800, xucheng...@loongson.cn wrote: > +  /* Clean up the vars set above.  Note that final_end_function resets > + the global pointer for us.  */ We don't have a global pointer. Let's kill this MIPS remenant :). > +  reload_completed = 0; -- Xi Ruoyao School

Re: [PATCH v7 11/12] LoongArch Port: gcc/testsuite

2022-02-24 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-02-12 at 11:11 +0800, xucheng...@loongson.cn wrote: > From: chenglulu > > 2022-02-12  Chenghua Xu  >     Lulu Cheng  > > gcc/testsuite/ spec-barrier tests fail with: ./testsuite/c-c++-common/spec-barrier-1.c:21:3: warning: this target does not define a speculation

Re: [PATCH v7 02/12] LoongArch Port: gcc build

2022-02-24 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-02-12 at 11:11 +0800, xucheng...@loongson.cn wrote: > +mstrict-align > +Target Var(TARGET_STRICT_ALIGN) Init(0) > +Do not generate unaligned memory accesses. Any update on the rational to make -mno-strict-align the default? Note that I'm not against this decision: I'm really not a

Re: [PATCH v7 08/12] LoongArch Port: libgcc

2022-02-24 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-02-12 at 11:11 +0800, xucheng...@loongson.cn wrote: > +  sc = _->uc.uc_mcontext; Get a warning: In file included from ../../../libgcc/unwind-dw2.c:412: ./md-unwind-support.h: In function ‘loongarch_fallback_frame_state’: ./md-unwind-support.h:55:10: warning: assignment to

Re: [PATCH v6 11/12] LoongArch Port: gcc/testsuite

2022-02-19 Thread Paul Hua via Gcc-patches
Hi Mike, Thanks for your review. On Wed, Feb 16, 2022 at 12:30 PM Mike Stump via Gcc-patches wrote: > > On Jan 28, 2022, at 5:49 AM, chenglulu wrote: > > > > gcc/testsuite/ > > > >* g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. > >*

Re: [PATCH v6 11/12] LoongArch Port: gcc/testsuite

2022-02-15 Thread Mike Stump via Gcc-patches
On Jan 28, 2022, at 5:49 AM, chenglulu wrote: > > gcc/testsuite/ > >* g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. >* g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. >* g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. >*

[PATCH v7 12/12] LoongArch Port: Add doc.

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng * contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch

[PATCH v7 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng * libgcc/configure: Regenerate. --- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 4919a56f518..ce04c4f529f 100755 --- a/libgcc/configure

[PATCH v7 11/12] LoongArch Port: gcc/testsuite

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. *

[PATCH v7 08/12] LoongArch Port: libgcc

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/crti.S: Like wise. * config/loongarch/crtn.S: Like wise. * config/loongarch/linux-unwind.h: Like wise. *

[PATCH v7 10/12] LoongArch Port: libgomp

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 ---

[PATCH v7 02/12] LoongArch Port: gcc build

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. *

[PATCH v7 06/12] LoongArch Port: Builtin functions.

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 413 +

[PATCH v7 07/12] LoongArch Port: Builtin macros.

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng gcc/ *config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git

[PATCH v7 03/12] LoongArch Port: Regenerate gcc/configure.

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng gcc/ * configure: Regenerate. --- gcc/configure | 66 ++- 1 file changed, 60 insertions(+), 6 deletions(-) diff --git a/gcc/configure b/gcc/configure index

[PATCH v7 01/12] LoongArch Port: Regenerate configure

2022-02-11 Thread xuchenghua
From: chenglulu 2022-02-12 Chenghua Xu Lulu Cheng * config/picflag.m4: Default add build option '-fpic' for LoongArch. * configure: Add LoongArch tuples. * configure.ac: Like wise. --- config/picflag.m4 | 3 +++ configure | 10 +-

[PATCH v6 12/12] LoongArch Port: Add doc.

2022-01-28 Thread chenglulu
* contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch options section. --- contrib/config-list.mk | 5 +- gcc/doc/install.texi

[PATCH v6 11/12] LoongArch Port: gcc/testsuite

2022-01-28 Thread chenglulu
gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. * gcc.dg/20020312-2.c: Add LoongArch support. * gcc.dg/loop-8.c:

[PATCH v6 06/12] LoongArch Port: Builtin functions.

2022-01-28 Thread chenglulu
gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 413 + gcc/config/loongarch/loongarch-builtins.cc | 511 + 2 files changed, 924 insertions(+)

[PATCH v6 02/12] LoongArch Port: gcc build

2022-01-28 Thread chenglulu
gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. * config/loongarch/genopts/loongarch.opt.in: New file. * config/loongarch/loongarch-str.h:

[PATCH v6 08/12] LoongArch Port: libgcc

2022-01-28 Thread chenglulu
libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/crti.S: Like wise. * config/loongarch/crtn.S: Like wise. * config/loongarch/linux-unwind.h: Like wise. * config/loongarch/sfp-machine.h: Like wise. * config/loongarch/t-crtstuff:

[PATCH v6 10/12] LoongArch Port: libgomp

2022-01-28 Thread chenglulu
libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 --- a/libgomp/configure.tgt +++ b/libgomp/configure.tgt @@ -56,6 +56,10

[PATCH v6 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-01-28 Thread chenglulu
--- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 4919a56f518..ce04c4f529f 100755 --- a/libgcc/configure +++ b/libgcc/configure @@ -2412,6 +2412,9 @@ case "${host}" in # sets the default TLS model and

[PATCH v6 07/12] LoongArch Port: Builtin macros.

2022-01-28 Thread chenglulu
gcc/ *config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git a/gcc/config/loongarch/loongarch-c.cc

[PATCH v6 03/12] LoongArch Port: Regenerate gcc/configure.

2022-01-28 Thread chenglulu
--- gcc/configure | 66 ++- 1 file changed, 60 insertions(+), 6 deletions(-) diff --git a/gcc/configure b/gcc/configure index bd4d4721868..3823bc4e783 100755 --- a/gcc/configure +++ b/gcc/configure @@ -5442,6 +5442,9 @@ case "${target}" in

[PATCH v6 01/12] LoongArch Port: Regenerate configure

2022-01-28 Thread chenglulu
* config/picflag.m4: Default add build option '-fpic' for LoongArch. * configure: Add LoongArch tuples. * configure.ac: Like wise. --- config/picflag.m4 | 3 +++ configure | 10 +- configure.ac | 10 +- 3 files changed, 21 insertions(+), 2

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-23 Thread 程璐璐
在 2022/1/23 下午5:00, Xi Ruoyao 写道: On Sun, 2022-01-23 at 16:39 +0800, 程璐璐 wrote: 在 2022/1/22 下午4:42, Xi Ruoyao 写道: On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: +mstrict-align +Target Var(TARGET_STRICT_ALIGN) Init(0) +Do not generate unaligned memory accesses. Section 2.1.8

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-23 Thread Xi Ruoyao via Gcc-patches
On Sun, 2022-01-23 at 16:39 +0800, 程璐璐 wrote: > > 在 2022/1/22 下午4:42, Xi Ruoyao 写道: >   > > > On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > >   > > > > > +mstrict-align > > > +Target Var(TARGET_STRICT_ALIGN) Init(0) > > > +Do not generate unaligned memory accesses. > > Section 2.1.8

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-23 Thread 程璐璐
在 2022/1/22 下午4:42, Xi Ruoyao 写道: On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: +mstrict-align +Target Var(TARGET_STRICT_ALIGN) Init(0) +Do not generate unaligned memory accesses. Section 2.1.8 of LoongArch spec says "load/store instruction *may* be implemented to allow unaligned

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-23 Thread 程璐璐
在 2022/1/22 下午5:31, Jakub Jelinek 写道: On Sat, Jan 22, 2022 at 05:05:00PM +0800, Xi Ruoyao wrote: On Sat, 2022-01-22 at 16:56 +0800, 程璐璐 wrote: Under the MIPS architecture, *.opt files are also generated in $(srcdir). Well, but then you should put the commands for generating those files

Re: Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread 程璐璐
-原始邮件- 发件人: "Jakub Jelinek" 发送时间: 2022-01-22 17:31:40 (星期六) 收件人: "Xi Ruoyao" 抄送: "程璐璐" , "Chenghua Xu" , gcc-patches@gcc.gnu.org, jos...@codesourcery.com 主题: Re: [PATCH v5 02/12] LoongArch Port: gcc build On Sat, Jan 22, 2022 at 05:

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Jakub Jelinek via Gcc-patches
On Sat, Jan 22, 2022 at 05:05:00PM +0800, Xi Ruoyao wrote: > On Sat, 2022-01-22 at 16:56 +0800, 程璐璐 wrote: > > > Under the MIPS architecture, *.opt files are also generated in > > $(srcdir). > > Well, but then you should put the commands for generating those files > into contrib/gcc_update

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Andreas Schwab
On Jan 22 2022, Xi Ruoyao via Gcc-patches wrote: > Well, but then you should put the commands for generating those files > into contrib/gcc_update instead of Makefile.in, just like MIPS. contrib/gcc_update doesn't regenerate any files, it only updates timestamps. -- Andreas Schwab,

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread 程璐璐
在 2022/1/22 下午5:05, Xi Ruoyao 写道: On Sat, 2022-01-22 at 16:56 +0800, 程璐璐 wrote: Under the MIPS architecture, *.opt files are also generated in $(srcdir). Well, but then you should put the commands for generating those files into contrib/gcc_update instead of Makefile.in, just like MIPS.

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-01-22 at 16:56 +0800, 程璐璐 wrote: > Under the MIPS architecture, *.opt files are also generated in > $(srcdir). Well, but then you should put the commands for generating those files into contrib/gcc_update instead of Makefile.in, just like MIPS. -- Xi Ruoyao School of Aerospace

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread 程璐璐
在 2022/1/22 下午4:46, Xi Ruoyao 写道: On Sat, 2022-01-22 at 09:41 +0100, Jakub Jelinek wrote: On Sat, Jan 22, 2022 at 04:33:08PM +0800, Xi Ruoyao via Gcc-patches wrote: On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: +$(srcdir)/config/loongarch/loongarch.opt: \ +   

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-01-22 at 09:41 +0100, Jakub Jelinek wrote: > On Sat, Jan 22, 2022 at 04:33:08PM +0800, Xi Ruoyao via Gcc-patches > wrote: > > On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > > > +$(srcdir)/config/loongarch/loongarch.opt: \ > > > +   

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > +mstrict-align > +Target Var(TARGET_STRICT_ALIGN) Init(0) > +Do not generate unaligned memory accesses. Section 2.1.8 of LoongArch spec says "load/store instruction *may* be implemented to allow unaligned memory access". As it's not a

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Jakub Jelinek via Gcc-patches
On Sat, Jan 22, 2022 at 04:33:08PM +0800, Xi Ruoyao via Gcc-patches wrote: > On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > > +$(srcdir)/config/loongarch/loongarch.opt: \ > > +   $(srcdir)/config/loongarch/genopts/genstr.sh \ > > +   

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > +   Copyright (C) 2021 Free Software Foundation, Inc. All of those should be 2021 - 2022 (or just 2022?) now. -- Xi Ruoyao School of Aerospace Science and Technology, Xidian University

Re: [PATCH v5 02/12] LoongArch Port: gcc build

2022-01-22 Thread Xi Ruoyao via Gcc-patches
On Sat, 2022-01-22 at 15:55 +0800, Chenghua Xu wrote: > +$(srcdir)/config/loongarch/loongarch.opt: \ > +   $(srcdir)/config/loongarch/genopts/genstr.sh \ > +   $(srcdir)/config/loongarch/genopts/loongarch.opt.in > +   $(SHELL) $< opt > $@ > + > +$(LA_STR_H): \ > +   

[PATCH v5 12/12] LoongArch Port: Add doc.

2022-01-22 Thread Chenghua Xu
From: chenglulu * contrib/config-list.mk: Add LoongArch triplet. * gcc/doc/install.texi: Add LoongArch options section. * gcc/doc/invoke.texi: Add LoongArch options section. * gcc/doc/md.texi: Add LoongArch options section. --- contrib/config-list.mk | 5 +-

[PATCH v5 08/12] LoongArch Port: libgcc

2022-01-22 Thread Chenghua Xu
From: chenglulu libgcc/ * config/loongarch/crtfastmath.c: New file. * config/loongarch/crti.S: Like wise. * config/loongarch/crtn.S: Like wise. * config/loongarch/lib2funcs.c: Like wise. * config/loongarch/linux-unwind.h: Like wise. *

[PATCH v5 11/12] LoongArch Port: gcc/testsuite

2022-01-22 Thread Chenghua Xu
From: chenglulu gcc/testsuite/ * g++.dg/cpp0x/constexpr-rom.C: Add build options for LoongArch. * g++.old-deja/g++.abi/ptrmem.C: Add LoongArch support. * g++.old-deja/g++.pt/ptrmem6.C: xfail for LoongArch. * gcc.dg/20020312-2.c: Add LoongArch support. *

[PATCH v5 06/12] LoongArch Port: Builtin functions.

2022-01-22 Thread Chenghua Xu
From: chenglulu gcc/ * config/loongarch/larchintrin.h: New file. * config/loongarch/loongarch-builtins.cc: New file. --- gcc/config/loongarch/larchintrin.h | 413 + gcc/config/loongarch/loongarch-builtins.cc | 511 + 2 files changed,

[PATCH v5 02/12] LoongArch Port: gcc build

2022-01-21 Thread Chenghua Xu
From: chenglulu gcc/ * common/config/loongarch/loongarch-common.cc: New file. * config/loongarch/genopts/genstr.sh: New file. * config/loongarch/genopts/loongarch-strings: New file. * config/loongarch/genopts/loongarch.opt.in: New file. *

[PATCH v5 10/12] LoongArch Port: libgomp

2022-01-21 Thread Chenghua Xu
From: chenglulu libgomp/ * configure.tgt: Add LoongArch triplet. --- libgomp/configure.tgt | 4 1 file changed, 4 insertions(+) diff --git a/libgomp/configure.tgt b/libgomp/configure.tgt index d4f1e741b5a..2cd7272fcd8 100644 --- a/libgomp/configure.tgt +++ b/libgomp/configure.tgt

[PATCH v5 09/12] LoongArch Port: Regenerate libgcc/configure.

2022-01-21 Thread Chenghua Xu
From: chenglulu --- libgcc/configure | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libgcc/configure b/libgcc/configure index 4919a56f518..ce04c4f529f 100755 --- a/libgcc/configure +++ b/libgcc/configure @@ -2412,6 +2412,9 @@ case "${host}" in # sets the default

[PATCH v5 07/12] LoongArch Port: Builtin macros.

2022-01-21 Thread Chenghua Xu
From: chenglulu gcc/ *config/loongarch/loongarch-c.cc --- gcc/config/loongarch/loongarch-c.cc | 109 1 file changed, 109 insertions(+) create mode 100644 gcc/config/loongarch/loongarch-c.cc diff --git a/gcc/config/loongarch/loongarch-c.cc

  1   2   >