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

            Bug ID: 119308
           Summary: Cobol ICE on "hello world" on POWER in
                    rs6000_output_function_epilogue
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: cobol
          Assignee: unassigned at gcc dot gnu.org
          Reporter: tkoenig at gcc dot gnu.org
  Target Milestone: ---

Thought I'd give gcobol a spin on POWER.

For the "Hello, world" program faithfully copied from Wikipedia, I get
on POWER (gcc120) with 53fc26e54fadb51c3f655286d4475625b82a12b1 :

[tkoenig@cfarm120 ~]$ cat hello.cob 
       IDENTIFICATION DIVISION.
       PROGRAM-ID. hello-world.
       PROCEDURE DIVISION.
           DISPLAY "Hello, world!"
           .
[tkoenig@cfarm120 ~]$ trunk-bin/gcc/cobol1  hello.cob

Analyzing compilation unit
Performing interprocedural optimizations
 <*free_lang_data> {heap 1152k} <visibility> {heap 1152k} <build_ssa_passes>
{heap 1152k} <opt_local_passes> {heap 1536k} <remove_symbols> {heap 1536k}
<targetclone> {heap 1536k} <free-fnsummary> {heap 1536k}Streaming LTO
 <whole-program> {heap 1536k} <fnsummary> {heap 1536k} <inline> {heap 1536k}
<modref> {heap 1536k} <free-fnsummary> {heap 1536k} <single-use> {heap 1536k}
<comdats> {heap 1536k}Assembling functions:
 hello$worldduring RTL pass: final
In function ‘hello$world’:
cobol1: internal compiler error: in rs6000_output_function_epilogue, at
config/rs6000/rs6000-logue.cc:5361
0x123585df internal_error(char const*, ...)
        ../../trunk/gcc/diagnostic-global-context.cc:517
0x1034f707 fancy_abort(char const*, int, char const*)
        ../../trunk/gcc/diagnostic.cc:1722
0x114a877b rs6000_output_function_epilogue(_IO_FILE*)
        ../../trunk/gcc/config/rs6000/rs6000-logue.cc:5361
0x1073765b final_end_function()
        ../../trunk/gcc/final.cc:1864
0x10740a5f rest_of_handle_final
        ../../trunk/gcc/final.cc:4258
0x10740a5f execute
        ../../trunk/gcc/final.cc:4328
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

It seems that language_string being "GCC COBOL" is not handled in that
function.

Reply via email to