Ticket #26 (closed bug: fixed)

Opened 6 years ago

Last modified 6 years ago

failure during build on ubuntu intrepid amd64

Reported by: RobertCollins Owned by:
Priority: normal Milestone:
Component: none Version: trunk
Severity: none Keywords:
Cc: Language:
Patch status: Platform:

Description (last modified by Infinoid) (diff)

robertc@lifeless-64:~/source/parrot/parrot/compilers/pge$ ../../parrot -o PGE.pbc --output-pbc PGE.pir
robertc@lifeless-64:~/source/parrot/parrot/compilers/pge$ gdb --args ../../parrot  ../../runtime/parrot/library/PGE/Perl6Grammar.pir  --output=PGE/builtins_gen.pir PGE/builtins.pg
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu"...
(gdb) r
Starting program: /home/robertc/source/parrot/parrot/parrot ../../runtime/parrot/library/PGE/Perl6Grammar.pir --output=PGE/builtins_gen.pir PGE/builtins.pg
warning: Lowest section in /usr/lib/libicudata.so.38 is .hash at 0000000000000158
[Thread debugging using libthread_db enabled]
[New Thread 0x7fc986df26f0 (LWP 4305)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fc986df26f0 (LWP 4305)]
Parrot_Iterator_shift_string (interp=0x1c7c080, pmc=0x1e9bdb0) at ./src/pmc/iterator.pmc:545
545             STRING * const ret   = VTABLE_get_string_keyed(INTERP, agg, key);
(gdb) bt
#0  Parrot_Iterator_shift_string (interp=0x1c7c080, pmc=0x1e9bdb0) at ./src/pmc/iterator.pmc:545
#1  0x00007fc9867b9bb0 in build_attrib_index (interp=0x1c7c080, self=<value optimized out>) at ./src/pmc/class.pmc:138
#2  0x00007fc9867baa9a in Parrot_Class_instantiate (interp=0x1c7c080, pmc=0x1e1a840, init=0x1d136f0) at ./src/pmc/class.pmc:1065
#3  0x00007fc9866533ea in Parrot_new_p_p (cur_opcode=0x7fc986d63730, interp=0x1c7c080) at src/ops/pmc.ops:96
#4  0x00007fc9866cf27d in runops_slow_core (interp=0x1c7c080, pc=0x7fc986d63730) at src/runops_cores.c:222
#5  0x00007fc9866a875a in runops_int (interp=0x1c7c080, offset=3301) at src/interpreter.c:938
#6  0x00007fc9866a91cb in runops (interp=0x1c7c080, offs=<value optimized out>) at src/inter_run.c:103
#7  0x00007fc9866a9330 in runops_args (interp=0x1c7c080, sub=0x1eb0608, obj=<value optimized out>, meth_unused=<value optimized out>, sig=0x7fc98683cb87 "vP", ap=0x7fff8ee15330) at src/inter_run.c:240
#8  0x00007fc9866a9d07 in Parrot_runops_fromc_args (interp=0x1c7c080, sub=0x1e9bdb0, sig=0x7fc98683cb87 "vP") at src/inter_run.c:305
#9  0x00007fc9866956e3 in Parrot_ex_throw_from_c (interp=0x1c7c080, exception=0x1eaeed8) at src/exceptions.c:311
#10 0x00007fc986695af5 in Parrot_ex_throw_from_c_args (interp=0x1c7c080, ret_addr=<value optimized out>, exitcode=<value optimized out>, format=<value optimized out>) at src/exceptions.c:378
#11 0x00007fc9866c76ca in Parrot_oo_register_type (interp=0x1c7c080, name=0x1eaef48) at src/oo.c:539
#12 0x00007fc9867b951e in init_class_from_hash (interp=0x1c7c080, self=0x1eafe60, info=0x1eaf648) at ./src/pmc/class.pmc:221
#13 0x00007fc9866ce912 in pmc_new_init (interp=0x1c7c080, base_type=<value optimized out>, init=0x1d6c2d8) at src/pmc.c:391
#14 0x00007fc986653e5a in Parrot_newclass_p_p (cur_opcode=0x7fc986c52af8, interp=0x1c7c080) at src/ops/object.ops:254
#15 0x00007fc9866cf27d in runops_slow_core (interp=0x1c7c080, pc=0x7fc986c52af8) at src/runops_cores.c:222
#16 0x00007fc9866a875a in runops_int (interp=0x1c7c080, offset=22) at src/interpreter.c:938
#17 0x00007fc9866a91cb in runops (interp=0x1c7c080, offs=<value optimized out>) at src/inter_run.c:103
#18 0x00007fc9866a9330 in runops_args (interp=0x1c7c080, sub=0x1d6c268, obj=<value optimized out>, meth_unused=<value optimized out>, sig=0x7fc98683c9c6 "P", ap=0x7fff8ee15720) at src/inter_run.c:240
#19 0x00007fc9866a9d07 in Parrot_runops_fromc_args (interp=0x1c7c080, sub=0x1e9bdb0, sig=0x7fc98683c9c6 "P") at src/inter_run.c:305
#20 0x00007fc9866cb469 in run_sub (interp=0x1c7c080, sub_pmc=0x1e9bdb0) at src/packfile.c:496
#21 0x00007fc9866cb677 in do_sub_pragmas (interp=<value optimized out>, self=<value optimized out>, action=<value optimized out>, eval_pmc=0x0) at src/packfile.c:588
#22 0x00007fc98682b8dd in imcc_run (interp=0x1c7c080, sourcefile=0x7fff8ee16f13 "../../runtime/parrot/library/PGE/Perl6Grammar.pir", argc=3, argv=0x7fff8ee159f0) at compilers/imcc/main.c:787
#23 0x0000000000400c02 in main (argc=3, argv=0x7fff8ee159f0) at src/main.c:61
(gdb) 

(full follows ----_

#0  Parrot_Iterator_shift_string (interp=0x1c7c080, pmc=0x1e9bdb0) at ./src/pmc/iterator.pmc:545
        key = (PMC * const) 0x1e9bd78
        agg = (PMC * const) 0x0
        ret = <value optimized out>
#1  0x00007fc9867b9bb0 in build_attrib_index (interp=0x1c7c080, self=<value optimized out>) at ./src/pmc/class.pmc:138
        cur_attrib = <value optimized out>
        attrib_name = <value optimized out>
        full_key = <value optimized out>
        attribs = (PMC * const) 0x1e154b0
        iter = (PMC * const) 0x1e9bdb0
        fq_class = (STRING * const) 0x1d149d8
        class_cache = (PMC * const) 0x1d0b3f8
        cur_class = <value optimized out>
        _class = (Parrot_Class_attributes * const) 0x1e4b2e0
        cur_index = 6
        table = (PMC * const) 0x1e9d7f0
        cache = (PMC * const) 0x1e9d780
        num_classes = 5
#2  0x00007fc9867baa9a in Parrot_Class_instantiate (interp=0x1c7c080, pmc=0x1e1a840, init=0x1d136f0) at ./src/pmc/class.pmc:1065
        resolve_count = 0
        cur_hll = 0
        mro_length = <value optimized out>
        _class = (Parrot_Class_attributes * const) 0x1e4b2e0
        object = <value optimized out>
#3  0x00007fc9866533ea in Parrot_new_p_p (cur_opcode=0x7fc986d63730, interp=0x1c7c080) at src/ops/pmc.ops:96
        classname_key = <value optimized out>
        classobj = (PMC * const) 0xe
#4  0x00007fc9866cf27d in runops_slow_core (interp=0x1c7c080, pc=0x7fc986d63730) at src/runops_cores.c:222
No locals.
#5  0x00007fc9866a875a in runops_int (interp=0x1c7c080, offset=3301) at src/interpreter.c:938
        lo_var_ptr = 0
        core = (opcode_t *(*)(Parrot_Interp, opcode_t *)) 0x1ccc530
#6  0x00007fc9866a91cb in runops (interp=0x1c7c080, offs=<value optimized out>) at src/inter_run.c:103
        offset = 3301
        old_runloop_id = 1
#7  0x00007fc9866a9330 in runops_args (interp=0x1c7c080, sub=0x1eb0608, obj=<value optimized out>, meth_unused=<value optimized out>, sig=0x7fc98683cb87 "vP", ap=0x7fff8ee15330) at src/inter_run.c:240
        dest = <value optimized out>
        ctx = (Parrot_Context *) 0x1f5bc70
        new_sig = "\000\000\000\000\000\000\000\000e\023"
        sig_p = 0x7fc98683cb88 "P"
        old_ctx = (Parrot_Context * const) 0x1f94b20
#8  0x00007fc9866a9d07 in Parrot_runops_fromc_args (interp=0x1c7c080, sub=0x1e9bdb0, sig=0x7fc98683cb87 "vP") at src/inter_run.c:305
        args = {{gp_offset = 24, fp_offset = 48, overflow_arg_area = 0x7fff8ee15420, reg_save_area = 0x7fff8ee15350}}
        ctx = <value optimized out>
#9  0x00007fc9866956e3 in Parrot_ex_throw_from_c (interp=0x1c7c080, exception=0x1eaeed8) at src/exceptions.c:311
        handler = (PMC * const) 0x1eb0608
        profile = (RunProfile * const) 0x0
        return_point = (Parrot_runloop *) 0x1dc4450
#10 0x00007fc986695af5 in Parrot_ex_throw_from_c_args (interp=0x1c7c080, ret_addr=<value optimized out>, exitcode=<value optimized out>, format=<value optimized out>) at src/exceptions.c:378
        exception = (PMC *) 0x1e9bdb0
        arglist = {{gp_offset = 40, fp_offset = 48, overflow_arg_area = 0x7fff8ee15530, reg_save_area = 0x7fff8ee15470}}
#11 0x00007fc9866c76ca in Parrot_oo_register_type (interp=0x1c7c080, name=0x1eaef48) at src/oo.c:539
        type = <value optimized out>
        classname_hash = <value optimized out>
        item = <value optimized out>
#12 0x00007fc9867b951e in init_class_from_hash (interp=0x1c7c080, self=0x1eafe60, info=0x1eaf648) at ./src/pmc/class.pmc:221
        new_name = (STRING *) 0x1ccc530
        new_namespace = (PMC *) 0x1d6c2d8
        name_arg = (PMC *) 0x1eaef48
        name_str = <value optimized out>
        parents_str = (STRING * const) 0x1c88358
        methods_str = (STRING * const) 0x1c88310
        roles_str = (STRING * const) 0x1c882c8
        attrs_str = (STRING * const) 0x1c92dd0
        old_ns = (PMC *) 0x1d136f0

        resolve_method_str = <value optimized out>
        type_num = <value optimized out>
#13 0x00007fc9866ce912 in pmc_new_init (interp=0x1c7c080, base_type=<value optimized out>, init=0x1d6c2d8) at src/pmc.c:391
        pmc = (PMC * const) 0x1eafe60
        classobj = <value optimized out>
#14 0x00007fc986653e5a in Parrot_newclass_p_p (cur_opcode=0x7fc986c52af8, interp=0x1c7c080) at src/ops/object.ops:254
No locals.
#15 0x00007fc9866cf27d in runops_slow_core (interp=0x1c7c080, pc=0x7fc986c52af8) at src/runops_cores.c:222
No locals.
#16 0x00007fc9866a875a in runops_int (interp=0x1c7c080, offset=22) at src/interpreter.c:938
        lo_var_ptr = 0
        core = (opcode_t *(*)(Parrot_Interp, opcode_t *)) 0x1ccc530
#17 0x00007fc9866a91cb in runops (interp=0x1c7c080, offs=<value optimized out>) at src/inter_run.c:103
        offset = 22
        old_runloop_id = 0
#18 0x00007fc9866a9330 in runops_args (interp=0x1c7c080, sub=0x1d6c268, obj=<value optimized out>, meth_unused=<value optimized out>, sig=0x7fc98683c9c6 "P", ap=0x7fff8ee15720) at src/inter_run.c:240
        dest = <value optimized out>
        ctx = (Parrot_Context *) 0x1dcd420
        new_sig = "\000\000\000\000\000\000\000\000��"
        sig_p = 0x7fc98683c9c7 ""
        old_ctx = (Parrot_Context * const) 0x1c7c720
#19 0x00007fc9866a9d07 in Parrot_runops_fromc_args (interp=0x1c7c080, sub=0x1e9bdb0, sig=0x7fc98683c9c6 "P") at src/inter_run.c:305
        args = {{gp_offset = 24, fp_offset = 48, overflow_arg_area = 0x7fff8ee15810, reg_save_area = 0x7fff8ee15740}}
        ctx = <value optimized out>
#20 0x00007fc9866cb469 in run_sub (interp=0x1c7c080, sub_pmc=0x1e9bdb0) at src/packfile.c:496
        old = 0
        retval = (PMC *) 0x1ccc530
#21 0x00007fc9866cb677 in do_sub_pragmas (interp=<value optimized out>, self=<value optimized out>, action=<value optimized out>, eval_pmc=0x0) at src/packfile.c:588
        result = <value optimized out>
        ci = 67
        sub_pmc = (PMC *) 0x1d6c268
        i = 1
        ft = (PackFile_FixupTable * const) 0x1da8d90
        ct = <value optimized out>
#22 0x00007fc98682b8dd in imcc_run (interp=0x1c7c080, sourcefile=0x7fff8ee16f13 "../../runtime/parrot/library/PGE/Perl6Grammar.pir", argc=3, argv=0x7fff8ee159f0) at compilers/imcc/main.c:787
        obj_file = 0
        yyscanner = (yyscan_t) 0x1da8480
        output_file = 0x0
#23 0x0000000000400c02 in main (argc=3, argv=0x7fff8ee159f0) at src/main.c:61
        sourcefile = 0x1e9bdb0 "x��\001"
        interp = <value optimized out>

Change History

  Changed 6 years ago by RobertCollins

oh, also: Revision: 33740

  Changed 6 years ago by coke

  • version set to trunk

follow-up: ↓ 4   Changed 6 years ago by Infinoid

Hi,

I cannot reproduce this on gentoo/amd64. I even installed ubuntu intrepid in a chroot (with debootstrap) and I can't reproduce it there either. So on both gentoo/amd64 and ubuntu/amd64, r33740 passes all tests (and an additional bonus TODO test) for me. So it seems like there's something different about my system which is preventing me from seeing the crash, but I don't know what it is.

It also looks like someone reported this same issue in the old RT system:  http://rt.perl.org/rt3/Ticket/Display.html?id=61092

They are also using ubuntu, but I can't reproduce it with the versions mentioned there either.

in reply to: ↑ 3   Changed 6 years ago by Infinoid

Replying to Infinoid:

Hi, I cannot reproduce this on gentoo/amd64. I even installed ubuntu intrepid in a chroot (with debootstrap) and I can't reproduce it there either.

After talking with ihrd++ on IRC, it sounds like the crashes are caused by configuring with the --optimize flag. After adding that flag, I can reproduce this on ubuntu intrepid amd64, but not gentoo amd64 for whatever reason. I think the crash is highly compiler-specific.

@Reporter: Can you verify that your build was configured with the --optimize flag?

Mark

follow-up: ↓ 6   Changed 6 years ago by whiteknight

r33967 build succeeds for me on Ubuntu Intrepid, x86-64 with --optimize. Make test also succeeds with no failures. Haven't tried a make fulltest with it though (doing that now).

Are there any other variables that could explain this problem? Are we sure this is still an issue, ~200 commits after it was reported?

in reply to: ↑ 5   Changed 6 years ago by mikehh

Replying to whiteknight:

r33967 build succeeds for me on Ubuntu Intrepid, x86-64 with --optimize. Make test also succeeds with no failures. Haven't tried a make fulltest with it though (doing that now). Are there any other variables that could explain this problem? Are we sure this is still an issue, ~200 commits after it was reported?

This still seems to be a problem.

I have been buildibg parrot on ubuntu Intrepid AMD64 (and i386) for a couple of months now but have not used the --optimize flag in the build. I tried that this morning - firstly on i386 and this went ok

 http://smolder.plusthree.com/app/public_projects/report_details/14394

I then tried on AMD64 and i got a segfault

with

mhk64@mhk64-desktop:~/parrot_t$ perl Configure.pl --optimize ... auto::revision - Determine Parrot's revision......................r35583. ... ... make[1]: Leaving directory `/home/mhk64/parrot_t/src/dynoplibs' make -C compilers/pct make[1]: Entering directory `/home/mhk64/parrot_t/compilers/pct' ../../parrot -o ../../runtime/parrot/library/PCT.pbc --output-pbc PCT.pir ../../parrot -o ../../runtime/parrot/library/PCT/PAST.pbc --output-pbc src/PAST.pir ../../parrot -o ../../runtime/parrot/library/PCT/Grammar.pbc --output-pbc src/PCT/Grammar.pir ../../parrot -o ../../runtime/parrot/library/PCT/HLLCompiler.pbc --output-pbc src/PCT/HLLCompiler.pir make[1]: Leaving directory `/home/mhk64/parrot_t/compilers/pct' make -C compilers/pge make[1]: Entering directory `/home/mhk64/parrot_t/compilers/pge' /usr/bin/perl -MExtUtils::Command -e rm_f PGE.pbc ../../runtime/parrot/library/PGE.pbc /usr/bin/perl -e "" >PGE/builtins_gen.pir ../../parrot -o PGE.pbc --output-pbc PGE.pir ../../parrot ../../runtime/parrot/library/PGE/Perl6Grammar.pir --output=PGE/builtins_gen.pir PGE/builtins.pg make[1]: *** [PGE.pbc] Segmentation fault make[1]: *** Deleting file `PGE.pbc' make[1]: Leaving directory `/home/mhk64/parrot_t/compilers/pge' make: *** [compilers.dummy] Error 2 mhk64@mhk64-desktop:~/parrot_t$

after a make realclean I repeated the build without the --optimize

 http://smolder.plusthree.com/app/public_projects/report_details/14433

So it appears that this ticket still applies

All my software on Intrepid is up to date as is CPAN as of the build

Cheers,

Michael

follow-up: ↓ 8   Changed 6 years ago by mikehh

Sorry it got all scrunched up

I copy pasted and it drops the line breaks - I suppose that is the html

Cheers,

Michael

in reply to: ↑ 7   Changed 6 years ago by mikehh

Replying to mikehh:

Sorry it got all scrunched up I copy pasted and it drops the line breaks - I suppose that is the html Cheers, Michael

Lets see how this works:

mhk64@mhk64-desktop:~/parrot_t$ perl Configure.pl --optimize
...
auto::revision - Determine Parrot's revision......................r35583.
...
...
make[1]: Leaving directory `/home/mhk64/parrot_t/compilers/pct'
make -C compilers/pge
make[1]: Entering directory `/home/mhk64/parrot_t/compilers/pge'
/usr/bin/perl -MExtUtils::Command -e rm_f PGE.pbc ../../runtime/parrot/library/PGE.pbc
/usr/bin/perl -e "" >PGE/builtins_gen.pir
../../parrot -o PGE.pbc --output-pbc PGE.pir
../../parrot ../../runtime/parrot/library/PGE/Perl6Grammar.pir --output=PGE/builtins_gen.pir PGE/builtins.pg
make[1]: *** [PGE.pbc] Segmentation fault
make[1]: *** Deleting file `PGE.pbc'
make[1]: Leaving directory `/home/mhk64/parrot_t/compilers/pge'
make: *** [compilers.dummy] Error 2
mhk64@mhk64-desktop:~/parrot_t$

gcc version 4.3.2 (Ubuntu 4.3.2-1ubuntu11)

perl, v5.10.0 built for x86_64-linux-gnu-thread-multi

Cheers,

Michael

  Changed 6 years ago by Infinoid

  • description modified (diff)

  Changed 6 years ago by allison

  • status changed from new to closed
  • resolution set to fixed

chromatic fixed a segfault and this now works.

Note: See TracTickets for help on using tickets.