public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/113950] New: PowerPC, ICE with -O1 or higher compiling __builtin_vsx_splat_2di test case
@ 2024-02-15 23:43 carll at gcc dot gnu.org
  2024-02-16  0:00 ` [Bug target/113950] " bergner at gcc dot gnu.org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: carll at gcc dot gnu.org @ 2024-02-15 23:43 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113950

            Bug ID: 113950
           Summary: PowerPC, ICE with -O1 or higher compiling
                    __builtin_vsx_splat_2di test case
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: carll at gcc dot gnu.org
  Target Milestone: ---

Power 10 LE
Fedora 38

Test of the __builtin_vsx_splat_2di ICEs on GCC 12 and later.

The following test case generates an ICE for -O1 and above.  It does work for
 -O0.

void abort (void);

int main ()
{
  int i;
  vector signed long long vsll_result, vsll_expected_result;
  signed long long sll_arg1;

  sll_arg1 = 300;
  vsll_expected_result = (vector signed long long) {300, 300};
  vsll_result = __builtin_vsx_splat_2di (sll_arg1);  //ISSUE                    

  for (i = 0; i < 2; i++)
    if (vsll_result[i] != vsll_expected_result[i])
      abort();

  return 0;
}

The test case compiles fine with -O0.

Here is the output when I try to compile  with -O1:

 gcc -g  -O1 compiler-bug.c -o compiler-bug
compiler-bug.c: In function ‘main’:
compiler-bug.c:19:1: error: unrecognizable insn:
   19 | }
      | ^
(insn 14 13 15 2 (set (reg:V2DI 117 [ _1 ])
        (vec_duplicate:V2DI (const_int 300 [0x12c]))) "compiler-bug.c":12:17 -1
     (nil))
during RTL pass: vregs
compiler-bug.c:19:1: internal compiler error: in extract_insn, at recog.cc:2791
Please submit a full bug report, with preprocessed source.
See <http://bugzilla.redhat.com/bugzilla> for instructions.
Preprocessed source stored into /tmp/ccnoI5lr.out file, please attach this to
your bugreport.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-05-16 15:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-15 23:43 [Bug target/113950] New: PowerPC, ICE with -O1 or higher compiling __builtin_vsx_splat_2di test case carll at gcc dot gnu.org
2024-02-16  0:00 ` [Bug target/113950] " bergner at gcc dot gnu.org
2024-02-23  1:35 ` bergner at gcc dot gnu.org
2024-03-07 14:18 ` cvs-commit at gcc dot gnu.org
2024-03-15 20:36 ` bergner at gcc dot gnu.org
2024-03-21  9:55 ` cvs-commit at gcc dot gnu.org
2024-05-01  5:58 ` cvs-commit at gcc dot gnu.org
2024-05-16 13:58 ` jeevitha at gcc dot gnu.org
2024-05-16 14:02 ` jeevitha at gcc dot gnu.org
2024-05-16 15:04 ` shivam98.tkg at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).