Jump to page: 1 2
Thread overview
[Issue 15822] InvalidMemoryOperationError when calling GC.removeRange/Root from a finalizer
Mar 23, 2016
Martin Nowak
Mar 23, 2016
Martin Nowak
Mar 23, 2016
Martin Nowak
Mar 23, 2016
Martin Nowak
Mar 23, 2016
ag0aep6g@gmail.com
Mar 23, 2016
ag0aep6g@gmail.com
Mar 24, 2016
ag0aep6g@gmail.com
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

Martin Nowak <code@dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull

--- Comment #1 from Martin Nowak <code@dawg.eu> ---
https://github.com/D-Programming-Language/druntime/pull/1519

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

Martin Nowak <code@dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hsteoh@quickfur.ath.cx

--- Comment #2 from Martin Nowak <code@dawg.eu> ---
*** Issue 15809 has been marked as a duplicate of this issue. ***

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

Martin Nowak <code@dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ag0aep6g@gmail.com

--- Comment #3 from Martin Nowak <code@dawg.eu> ---
*** Issue 15821 has been marked as a duplicate of this issue. ***

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

Martin Nowak <code@dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |puneet@coverify.org

--- Comment #4 from Martin Nowak <code@dawg.eu> ---
*** Issue 15808 has been marked as a duplicate of this issue. ***

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

--- Comment #5 from github-bugzilla@puremagic.com ---
Commits pushed to stable at https://github.com/D-Programming-Language/druntime

https://github.com/D-Programming-Language/druntime/commit/d23d7efb3649cd543e8d0b10b9a32ab3325f5cd0
fix Issue 15822 - InvalidMemoryOperationError when calling GC.removeRange/Root
from a finalizer

- use separate locks for GC.add/removeRange/Root
- avoids GC.lock contention for manual memory management

https://github.com/D-Programming-Language/druntime/commit/c6ac077a8d544fab65b1973b385c6f479697fb0e Merge pull request #1519 from MartinNowak/fix15822

fix Issue 15822 - InvalidMemoryOperationError when calling GC.removeRange/Root from a finalizer

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

github-bugzilla@puremagic.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

hsteoh@quickfur.ath.cx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |---

--- Comment #6 from hsteoh@quickfur.ath.cx ---
This bug has not yet been (fully) fixed:

------
import std.stdio;
class Wrapper
{
    typeof(stdin.byLine()) src;
}
void main()
{
    auto x = new Wrapper();
    x.src = stdin.byLine();
}
------

Run as 'echo | ./program'. Output:

------
core.exception.InvalidMemoryOperationError@src/core/exception.d(693): Invalid
memory operation
------

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

--- Comment #7 from ag0aep6g@gmail.com ---
(In reply to hsteoh from comment #6)
> This bug has not yet been (fully) fixed:
> 
> ------
> import std.stdio;
> class Wrapper
> {
>     typeof(stdin.byLine()) src;
> }
> void main()
> {
>     auto x = new Wrapper();
>     x.src = stdin.byLine();
> }
> ------
> 
> Run as 'echo | ./program'. Output:
> 
> ------
> core.exception.InvalidMemoryOperationError@src/core/exception.d(693):
> Invalid memory operation
> ------

Works for me. Are you testing with stable?

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

--- Comment #8 from hsteoh@quickfur.ath.cx ---
Oh, was this only fixed in stable?

I'm testing with latest git HEAD.

--
March 23, 2016
https://issues.dlang.org/show_bug.cgi?id=15822

ag0aep6g@gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #9 from ag0aep6g@gmail.com ---
(In reply to hsteoh from comment #8)
> Oh, was this only fixed in stable?

Yup.

> I'm testing with latest git HEAD.

I'm closing as fixed again, assuming it works for you with stable.

--
« First   ‹ Prev
1 2