lilypond-auto
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Lilypond-auto] [LilyIssues-auto] [testlilyissues:issues] #4814 grob.cc


From: Auto mailings of changes to Lily Issues
Subject: [Lilypond-auto] [LilyIssues-auto] [testlilyissues:issues] #4814 grob.cc segfaults on Fedora 24 with gcc6
Date: Sat, 23 Jul 2016 11:51:07 +0000

Issue 4814: grob.cc segfaults with gcc6

From the release notes of GCC 6:

Optimizations remove null pointer checks for this

When optimizing, GCC now assumes the this pointer can never be null,
which is guaranteed by the language rules. Invalid programs which
assume it is OK to invoke a member function through a null
pointer (possibly relying on checks like this != NULL) may crash or
otherwise fail at run time if null pointer checks are optimized
away. With the -Wnull-dereference option the compiler tries to warn
when it detects such invalid code.

If the program cannot be fixed to remove the undefined behavior then
the option -fno-delete-null-pointer-checks can be used to disable
this optimization. That option also disables other optimizations
involving pointers, not only those involving this.

As a consequence, we cannot call a member function on a prospective null
pointer (which actually is a bad idea for a number of other reasons,
like when anything tries accessing the vtable) and then try sorting out
the condition in the routine itself.

This problem was first observed with Fedora 24. The Ubuntu GCC6
prerelease does not show this problem; presumably the respective
optimization has been disabled in the Ubuntu/Debian packaging because of
affecting other programs.

Commit-message-by: David Kastrup address@hidden
Signed-off-by: David Kastrup address@hidden

http://codereview.appspot.com/309750043


[issues:#4814] grob.cc segfaults on Fedora 24 with gcc6

Status: Started
Created: Sat Mar 26, 2016 09:51 PM UTC by Valentin Villenave
Last Updated: Sat Jul 23, 2016 11:50 AM UTC
Owner: nobody

Greetings,
I’m trying to run LilyPond on Fedora 24 (with GCC 6.0); I’m able to compile it (with and without guile2 enabled) but when trying to use it, many LilyPond files trigger a segfault:

Parsing...
Interpreting music...
Preprocessing graphical objects...
Program received signal SIGSEGV, Segmentation fault.
0x0000000000496c2f in Grob::get_offset (address@hidden,
address@hidden) at grob.cc:400
400       if (dim_cache_[a].offset_)

Here are the regtests that reproduce the bug (the others compile just fine):

beam-cross-staff-slope.ly
dynamics-alignment-breaker-linebreak.ly
dynamics-alignment-breaker.ly
dynamics-alignment-breaker-order.ly
dynamics-alignment-breaker-subsequent-spanner.ly
dynamics-alignment-no-line-linebreak.ly
dynamics-alignment-no-line.ly
dynamics-context-textspan.ly
dynamics-unbound-hairpin.ly
event-listener-output.ly
fermata-rest-position.ly
font-name.ly
full-measure-rest-fermata.ly
line-arrows.ly
line-style-zigzag-spacing.ly
make-relative.ly
markup-line-thickness.ly
markup-note-grob-style.ly
metronome-mark-broken-bound.ly
minimum-length-after-break.ly
mm-rests2.ly
morgenlied.ly
mozart-hrn-3.ly
multi-measure-rest-center.ly
multi-measure-rest.ly
multi-measure-rest-spacing.ly
multi-measure-rest-text.ly
music-function-end-spanners.ly
offsets.ly
page-turn-page-breaking-repeats.ly
part-combine-a2.ly
part-combine-mmrest-apart.ly
part-combine-mmrest-shared.ly
part-combine-silence-mixed.ly
property-nested-override.ly
quote-cue-during.ly
quote-cue-event-types.ly
repeat-percent-count.ly
repeat-percent-count-visibility.ly
repeat-percent.ly
rest-positioning.ly
scheme-text-spanner.ly
skiptypesetting-multimeasurerest.ly
slur-broken-trend.ly
slur-scoring.ly
slur-tie-control-points.ly
slur-vertical-skylines.ly
spanner-after-line-breaking.ly
staff-mixed-size.ly
stem-direction.ly
stencil-scale.ly
tablature-full-notation.ly
tablature-harmonic-functions.ly
tablature-tie-spanner.ly
text-spanner-attachment-alignment.ly
text-spanner-full-rest.ly
text-spanner-override-order.ly
tie-direction-manual.ly
tie-pitched-trill.ly
trill-spanner-auto-stop.ly
trill-spanner-broken.ly
trill-spanner-chained.ly
trill-spanner-grace.ly
trill-spanner.ly
trill-spanner-pitched-consecutive.ly
trill-spanner-pitched-forced.ly
trill-spanner-pitched.ly
trill-spanner-scaled.ly

What makes is weird is that the bug happens both with my LilyPond
build (latest master branch) and with my distribution’s package
(Fedora repos generally have the latest development release: as of now
it’s 2.19.38 but this also happened with .37 and .36); however, GUB
packages of the exact same development release, don’t reproduce the
segfault.

Could it be because Fedora 24 is using GCC6? I’ve tried bisecting but I’m unable to compile any version older than a couple of weeks, prior to David’s more rigorous smob types:
http://git.savannah.gnu.org/cgit/lilypond.git/commit/?id=c6758d6d12e33779fc81218693d5650682d8a1ca

Let me know if I can provide any other information (and feel free to close this issue if it turns out to be caused by something in my environment).


Sent from sourceforge.net because address@hidden is subscribed to https://sourceforge.net/p/testlilyissues/issues/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/testlilyissues/admin/issues/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.

------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
_______________________________________________
Testlilyissues-auto mailing list
address@hidden
https://lists.sourceforge.net/lists/listinfo/testlilyissues-auto

reply via email to

[Prev in Thread] Current Thread [Next in Thread]