[Bug jit/117923] New: ICE in SET_TYPE_VECTOR_SUBPARTS on Aarch64

2024-12-05 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117923

Bug ID: 117923
   Summary: ICE in SET_TYPE_VECTOR_SUBPARTS on Aarch64
   Product: gcc
   Version: 15.0
Status: UNCONFIRMED
  Severity: major
  Priority: P3
 Component: jit
  Assignee: dmalcolm at gcc dot gnu.org
  Reporter: antoyo at gcc dot gnu.org
CC: antoyo at gcc dot gnu.org
  Target Milestone: ---

Many tests fail on Aarch64 because of this.
It gives the following backtrace:

./gcc/testsuite/jit/test-temp.c.exe: :0:0: error: in
SET_TYPE_VECTOR_SUBPARTS, at tree.h:4311
0x879a4b6f internal_error(char const*, ...)
../../../gcc/gcc/diagnostic-global-context.cc:517
0x8641ad13 fancy_abort(char const*, int, char const*)
../../../gcc/gcc/diagnostic.cc:1696
0x86c7451f SET_TYPE_VECTOR_SUBPARTS(tree_node*, poly_int<2u, unsigned
long>)
../../../gcc/gcc/tree.h:4311
0x86c7451f SET_TYPE_VECTOR_SUBPARTS(tree_node*, poly_int<2u, unsigned
long>)
../../../gcc/gcc/tree.h:4306
0x86c7451f make_vector_type
../../../gcc/gcc/tree.cc:9284
0x86db4bdb aarch64_init_simd_builtin_types
../../../gcc/gcc/config/aarch64/aarch64-builtins.cc:1243
0x86db4bdb aarch64_init_simd_builtins
../../../gcc/gcc/config/aarch64/aarch64-builtins.cc:1833
0x86db4bdb aarch64_general_init_builtins()
../../../gcc/gcc/config/aarch64/aarch64-builtins.cc:2361
0x86ce2a6b aarch64_init_builtins
../../../gcc/gcc/config/aarch64/aarch64.cc:15791
0x864300a3 jit_langhook_init
../../../gcc/gcc/jit/dummy-frontend.cc:1102
0x86426b3b lang_dependent_init
../../../gcc/gcc/toplev.cc:1898
0x86426b3b do_compile
../../../gcc/gcc/toplev.cc:2196

I'll soon post a patch that fixes this issue.

[Bug jit/117923] ICE in SET_TYPE_VECTOR_SUBPARTS on Aarch64

2024-12-06 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117923

--- Comment #2 from Antoni  ---
Created attachment 59801
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59801&action=edit
Updated patch

[Bug jit/117923] ICE in SET_TYPE_VECTOR_SUBPARTS on Aarch64

2024-12-05 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117923

Antoni  changed:

   What|Removed |Added

   Assignee|dmalcolm at gcc dot gnu.org|antoyo at gcc dot 
gnu.org
 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2024-12-05
 Ever confirmed|0   |1

--- Comment #1 from Antoni  ---
Created attachment 59798
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59798&action=edit
Patch to fix the issue

[Bug jit/117923] ICE in SET_TYPE_VECTOR_SUBPARTS on Aarch64

2024-12-09 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117923

Antoni  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|ASSIGNED|RESOLVED

--- Comment #4 from Antoni  ---
Fixed in r15-6070-g62fa2e434b60558a7c3b4c578fda744bde96.

[Bug jit/118034] libgccjit++ has no wrapping C++ API to create a union

2024-12-13 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118034

--- Comment #1 from Antoni  ---
Many C API does not have a C++ wrapper.
Contributions are welcomed.

[Bug target/118268] bc-1.07.1 fails to build with -masm=intel

2025-01-02 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118268

--- Comment #11 from Antoni  ---
Oh, I didn't try with bc, I only tried with this code:

void byte() {}

The error is the same as without this patch:

/tmp/ccX2cpcq.s: Error: .size expression for byte does not evaluate to a
constant

[Bug target/118268] bc-1.07.1 fails to build with -masm=intel

2025-01-02 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118268

--- Comment #9 from Antoni  ---
(In reply to LIU Hao from comment #8)
> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59639 should solve this
> issue. The unfortunate fact is that nobody is taking care of it so you
> probably have to build GCC yourself.

This doesn't seem to work.

>From what I can see, it seems we might need to define ASM_OUTPUT_LABELREF for
i386. Would that make sense?

[Bug jit/119767] libgccjit fails on sparc

2025-04-13 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119767

--- Comment #1 from Antoni  ---
Hi.
Did it work on SPARC with GCC 14?
Thanks for the bug report!

[Bug jit/119268] New: Exception thrown when host_detect_local_cpu returns NULL

2025-03-13 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119268

Bug ID: 119268
   Summary: Exception thrown when host_detect_local_cpu returns
NULL
   Product: gcc
   Version: 15.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: jit
  Assignee: dmalcolm at gcc dot gnu.org
  Reporter: antoyo at gcc dot gnu.org
CC: antoyo at gcc dot gnu.org
  Target Milestone: ---

host_detect_local_cpu is called in gcc/config/i386/i386-jit.cc and the result
is sent directly to a std::string, so if the result is NULL, this will throw an
exception.

Since this code is automatically ran at startup, I suspect the priority to fix
it should be higher. What do you think?

Hopefully, the fix should be easy.

[Bug jit/119268] Exception thrown when host_detect_local_cpu returns NULL

2025-03-13 Thread antoyo at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119268

--- Comment #4 from Antoni  ---
Oh sorry. I thought this was merged.
I guess we can close this issue then.