**Bug** in jitter

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Lee Alexander

    #1

    **Bug** in jitter

    Hello,
    I have spent the past four days nailing down what looks to me like a bug in
    the jitter.

    Problem
    ~~~~~~
    When my program is run without the debugger attached in release an object is
    disposed of whilst execution is still in one of it's methods. I have a C#
    application talking to a managed C++ data access layer that then talks to a
    managed/unmanaged data access engine. It's whilst in the unmanaged portion
    that the object is incorrectly disposed via a system triggered GC.

    Workaround
    ~~~~~~~~~
    I have turned off via the linker optimisations for the offending module.

    Reproducible code
    ~~~~~~~~~~~~~
    I have a reproducible console based test application that demonstrates the
    problem. Unfortunately because it uses the data access engine I cannot post
    the code directly here. I only have authorisation to email the source / test
    app to a MS employee.

    Regards
    Lee


  • Ken Alverson

    #2
    Re: **Bug** in jitter

    "Lee Alexander" <lee@No_Spam_Pl ease_Digita.com > wrote in message
    news:utHQd95TDH A.556@TK2MSFTNG P12.phx.gbl...[color=blue]
    > Hello,
    > I have spent the past four days nailing down what looks to me like a bug in
    > the jitter.
    >
    > Problem
    > ~~~~~~
    > When my program is run without the debugger attached in release an object is
    > disposed of whilst execution is still in one of it's methods. I have a C#
    > application talking to a managed C++ data access layer that then talks to a
    > managed/unmanaged data access engine. It's whilst in the unmanaged portion
    > that the object is incorrectly disposed via a system triggered GC.[/color]

    Sounds like a known issue:




    Ken


    Comment

    • Lee Alexander

      #3
      Re: **Bug** in jitter

      Ken,

      Thanks very much for that. GC.KeepAlive fixed it! Unbelievable I never would
      have thought that the GC could collect an object whose methods are still
      running. I'll have to run some of these debug probes on my application.

      Thanks again

      Regards
      Lee

      "Ken Alverson" <Ken@Alverson.n et> wrote in message
      news:uEXwpJ6TDH A.2648@TK2MSFTN GP10.phx.gbl...[color=blue]
      > "Lee Alexander" <lee@No_Spam_Pl ease_Digita.com > wrote in message
      > news:utHQd95TDH A.556@TK2MSFTNG P12.phx.gbl...[color=green]
      > > Hello,
      > > I have spent the past four days nailing down what looks to me like a bug[/color][/color]
      in[color=blue][color=green]
      > > the jitter.
      > >
      > > Problem
      > > ~~~~~~
      > > When my program is run without the debugger attached in release an[/color][/color]
      object is[color=blue][color=green]
      > > disposed of whilst execution is still in one of it's methods. I have a[/color][/color]
      C#[color=blue][color=green]
      > > application talking to a managed C++ data access layer that then talks[/color][/color]
      to a[color=blue][color=green]
      > > managed/unmanaged data access engine. It's whilst in the unmanaged[/color][/color]
      portion[color=blue][color=green]
      > > that the object is incorrectly disposed via a system triggered GC.[/color]
      >
      > Sounds like a known issue:
      >
      >[/color]
      http://blogs.gotdotnet.com/cbrumme/c...0-f0fa27ab6cc0[color=blue]
      >[/color]
      http://blogs.gotdotnet.com/anathan/c...7-1b6c677214cb[color=blue]
      >
      > Ken
      >
      >[/color]


      Comment

      Working...