Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 10 Jan 2016 18:38:25 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-ports-bugs@FreeBSD.org
Subject:   [Bug 206111] lang/ruby23: fix setjmp clobbered variables (using clang 3.8.0 and optimizing for 'high' CPUs)
Message-ID:  <bug-206111-13@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D206111

            Bug ID: 206111
           Summary: lang/ruby23: fix setjmp clobbered variables (using
                    clang 3.8.0 and optimizing for 'high' CPUs)
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: Individual Port(s)
          Assignee: ruby@FreeBSD.org
          Reporter: dim@FreeBSD.org
          Assignee: ruby@FreeBSD.org
             Flags: maintainer-feedback?(ruby@FreeBSD.org)

Created attachment 165371
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D165371&action=
=3Dedit
Mark several variables volatile so they won't have undefined state after
setjmp()

During my preparations for bug 206074 (exp-run for clang 3.8.0), I noticed =
that
lang/ruby23 would sometimes crash during the build.  Specifically, on i386,
with CPUTYPE=3Divybridge, you would get segfaults in miniruby.

It turns out these are because there are several places in ruby where setjm=
p()
is used, and where not all variables accessed after setjmp() are marked
volatile.  This can cause them to have undefined state.

Fix this by marking several variables in different functions volatile.

These patches were obtained from NetBSD pkgsrc, thanks to J=C3=B6rg Sonnenb=
erger for
the hint.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-206111-13>