[Bug bootstrap/95122] New: Cross-compile arm32 toolchain with hard float, but Error in gcc final

2020-05-13 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95122

Bug ID: 95122
   Summary: Cross-compile arm32 toolchain with hard float, but
Error in gcc final
   Product: gcc
   Version: 4.9.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: bootstrap
  Assignee: unassigned at gcc dot gnu.org
  Reporter: chengcongxiu at huawei dot com
  Target Milestone: ---

Created attachment 48531
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48531&action=edit
Cross-compile arm32 toolchain with hard float, but Error in gcc final

Details of cross toolchain:

TARGET="arm-linux-gnueabihf"
HOST="$(gcc -dumpmachine)"
BUILD="$(gcc -dumpmachine)"

1、 GCC FIRST: 
CFLAGS_FOR_TARGET="${-march=armv7-a -mhard-float}"
CXXFLAGS_FOR_TARGET="${-march=armv7-a -mhardfloat}" ./configure --build=$BUILD
--host=$HOST --target=$TARGET --without-headers --with-newlib
make -j 16 && make install

this step is OK

2、GLIBC HEADER 
CC="arm-linux-gnueabihf-gcc -mhard-float"
$ROOT_TAR_SRC/$EGLIBC/configure --with-float=hard --with-fp

this step is OK

3、GCC SECOND
CFLAGS_FOR_TARGET="${-march=armv7-a -mhard-float}"
CXXFLAGS_FOR_TARGET="${-march=armv7-a -mhardfloat}" --enable-shared

this step is OK

4、GLIBC 
CC="arm-linux-gnueabihf-gcc -mhard-float"
$ROOT_TAR_SRC/$EGLIBC/configure --with-float=hard --with-fp 

this step is OK

5、GCC Final
CFLAGS_FOR_TARGET="${-march=armv7-a -mhard-float}"
CXXFLAGS_FOR_TARGET="${-march=armv7-a -mhardfloat}" --enable-shared 

compier error:the error is checking libgcc terminated。 the checking log at
File, the reason is stubs.h, but I add the option -mhard-float. How I solve
this Error?


/home/ccx/fenghuo/SDK_CPU_HCC/build/hcc_arm32le/arm32le_build_dir/hcc_arm32le/arm-linux-gnueabihf/sys-include/gnu/stubs.h:7:29:
fatal error: gnu/stubs-soft.h: No such file or directory
 # include 
 ^
compilation terminated.

[Bug bootstrap/95122] Cross-compile arm32 toolchain with hard float, but Error in gcc final

2020-05-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95122

--- Comment #3 from chengcongxiu at huawei dot com  ---
(In reply to Richard Biener from comment #1)
> You seem to build from inside the source directory, that is not supported. 
> Please create a separate object directory like
> 
> mkdir obj
> cd obj
> ../configure 
> 
> and re-try.

But option is arm-linux-gnueabi-gcc -msoft-float, the toolchain is OK, so
separate object directory is not userful

[Bug bootstrap/95122] Cross-compile arm32 toolchain with hard float, but Error in gcc final

2020-05-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95122

--- Comment #5 from chengcongxiu at huawei dot com  ---
(In reply to Richard Earnshaw from comment #4)
> Don't use -mhard-float or -msoft-float.  Instead, you should be using
> -mfloat-abi=[hard|softfp|soft] as appropriate.  Also, rather than encoding
> this into various sets of flags you should configure the compiler with
> --with-float=[hard|softfp|soft] as your environment requires.  Then it
> should not be necessary to pass various flags into the library builds.
> 
> There's no such option as -mhardfloat.


thank you! for GCC 4.9, compile gcc first ,gcc second and final with flags
--with-float=hard can compiler arm-linux-gnueabihf!!!

[Bug bootstrap/95122] Cross-compile arm32 toolchain with hard float, but Error in gcc final

2020-05-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95122

chengcongxiu at huawei dot com  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|WAITING |RESOLVED

[Bug bootstrap/95204] New: patch commit, and making gcc error.

2020-05-19 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95204

Bug ID: 95204
   Summary: patch commit, and making gcc error.
   Product: gcc
   Version: 7.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: bootstrap
  Assignee: unassigned at gcc dot gnu.org
  Reporter: chengcongxiu at huawei dot com
  Target Milestone: ---

when i patch this commit
(https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=1ce87609c91e51d7eee8284c5fe000c7d5b240db),
make gcc error:

You should edit
/home/ccx/test2/SDK_CPU_HCC/build/hcc_arm64be/../../open_source/hcc_arm64be_build_src/gcc-7.3.0/gcc/doc/tm.texi.in
rather than
/home/ccx/test2/SDK_CPU_HCC/build/hcc_arm64be/../../open_source/hcc_arm64be_build_src/gcc-7.3.0/gcc/doc/tm.texi
.
Makefile:2447: recipe for target 's-tm-texi' failed
make[2]: *** [s-tm-texi] Error 1
make[2]: *** Waiting for unfinished jobs
echo timestamp > s-options-h

any one know what's wrong?

[Bug bootstrap/95205] New: patch commit, and making gcc error.

2020-05-19 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95205

Bug ID: 95205
   Summary: patch commit, and making gcc error.
   Product: gcc
   Version: 7.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: bootstrap
  Assignee: unassigned at gcc dot gnu.org
  Reporter: chengcongxiu at huawei dot com
  Target Milestone: ---

when i patch this commit
(https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=1ce87609c91e51d7eee8284c5fe000c7d5b240db),
make gcc error:

You should edit
/home/ccx/test2/SDK_CPU_HCC/build/hcc_arm64be/../../open_source/hcc_arm64be_build_src/gcc-7.3.0/gcc/doc/tm.texi.in
rather than
/home/ccx/test2/SDK_CPU_HCC/build/hcc_arm64be/../../open_source/hcc_arm64be_build_src/gcc-7.3.0/gcc/doc/tm.texi
.
Makefile:2447: recipe for target 's-tm-texi' failed
make[2]: *** [s-tm-texi] Error 1
make[2]: *** Waiting for unfinished jobs
echo timestamp > s-options-h

any one know what's wrong?

[Bug bootstrap/95205] patch commit, and making gcc error.

2020-05-19 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95205

--- Comment #2 from chengcongxiu at huawei dot com  ---
(In reply to Richard Biener from comment #1)
> read the full message, you need to copy gcc/tm.texi to $src/gcc/doc/

thanks you! now making is ok!

[Bug analyzer/95207] New: the papers about gcc optimized

2020-05-19 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95207

Bug ID: 95207
   Summary: the papers about gcc optimized
   Product: gcc
   Version: analyzer branch
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: analyzer
  Assignee: dmalcolm at gcc dot gnu.org
  Reporter: chengcongxiu at huawei dot com
  Target Milestone: ---

someone can introduces some papers about gcc optimize!

[Bug c/95668] New: patching the commit of SVE on GCC7.3, But fail in test

2020-06-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95668

Bug ID: 95668
   Summary: patching the commit of SVE on GCC7.3, But fail in test
   Product: gcc
   Version: 7.3.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: c
  Assignee: unassigned at gcc dot gnu.org
  Reporter: chengcongxiu at huawei dot com
  Target Milestone: ---

Created attachment 48727
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48727&action=edit
The gcc as follow:

The test as follow:

void foo (int *  restrict in, int * restrict out, int s)
{
for (int i = 0; i < 16; i++) {
  for (int j = 0; j < 6; ++j)
out[j] = in[j];
  in += 6;
  out += s*6;
 }
}

using gcc compile above test:

.cfi_startproc
moviv5.2s, 0
add w2, w2, w2, lsl 1
ldr q16, [x0]
lsl w2, w2, 1
ldr q7, [x0, 16]
sbfiz   x2, x2, 2, 32
orr v4.8b, v5.8b, v5.8b 
orr v3.8b, v5.8b, v5.8b
orr v2.8b, v5.8b, v5.8b
orr v1.8b, v5.8b, v5.8b
ldr q6, [x0, 32]
orr v0.8b, v5.8b, v5.8b
orr v25.8b, v5.8b, v5.8b
orr v24.8b, v5.8b, v5.8b
ins v4.s[60], v16.s[61]  //this instruction error:
ins v5.s[60], v16.s[63]
ins v3.s[60], v7.s[63]
ins v2.s[60], v7.s[61]
ins v1.s[60], v6.s[63]
add x5, x1, x2

[Bug c/95668] patching the commit of SVE on GCC7.3, But fail in test

2020-06-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95668

--- Comment #1 from chengcongxiu at huawei dot com  ---
./gcc -O3 test.c -S -o -

[Bug target/95668] patching the commit of SVE on GCC7.3, But fail in test

2020-06-14 Thread chengcongxiu at huawei dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95668

chengcongxiu at huawei dot com  changed:

   What|Removed |Added

 Status|WAITING |RESOLVED
 Resolution|--- |FIXED