caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Dmitry Bely" <dmitry.bely@gmail.com>
To: "Xavier Leroy" <Xavier.Leroy@inria.fr>
Cc: "Alain Frisch" <alain@frisch.fr>, ocaml <caml-list@inria.fr>
Subject: Re: [Caml-list] Ocaml debugger under Windows
Date: Wed, 6 Feb 2008 21:22:49 +0300	[thread overview]
Message-ID: <90823c940802061022j4135581cp7a086cc5f03379d5@mail.gmail.com> (raw)
In-Reply-To: <47A9EA89.5050407@inria.fr>

On Feb 6, 2008 8:12 PM, Xavier Leroy <Xavier.Leroy@inria.fr> wrote:
> Hello Dmitry,
>
> I'm delighted to see your attempts at getting ocamldebug to work under
> Windows.
>
> Generally speaking, the Windows port is the part of OCaml where we
> most desperately need outside help, as (1) it consumes quite a bit of
> my very limited time, (2) it's a cost center for the Caml development
> team (none of us uses Windows for our research activities), and (3)
> none of us is competent with Win32 programming.
>
> (For example, if anyone could help debugging PR#4399, that would be
> much appreciated.)

Alas, I have not migrated to Vista yet. But once the reporter has
Visual C++ experience I would recommend him to build OCaml from
sources with debug info enabled (if won't compile out-of-the-box but
the fix is trivial) and launch ocamlwin under debugger. When it should
become obvious where the access violation occurs.

> Coming back to ocamldebug:
>
> > The point is not to modify win32unix library or write Win32-specific C
> > functions for ocamldebug. I believe it's necessary to be ever accepted
> > by INRIA.
>
> Actually, I would be happy with a Win32 implementation of Unix.select
> that works over any combination of sockets and file descriptors.
> Unfortunately, it looks like we'd need a gross hack involving threads,
> WaitForMultipleObjects() and select(), but if someone comes up with an
> implementation that isn't too gross, I'll be interested.

Indeed, porting select() to Windows would be preferable.
WaitForMultipleObjects() can wait for console, pipe and network events
simultaneously so this should not be that hard (and multiple threads
are probably not necessary). Of course, there are some pitfalls like
this (taken from Cygwin sources):

      /* Some types of object (e.g., consoles) wake up on "inappropriate" events
         like mouse movements.  The verify function will detect these
situations.
         If it returns false, then this wakeup was a false alarm and
we should go
         back to waiting. */

But at least I'll try.

- Dmitry Bely


  reply	other threads:[~2008-02-06 18:22 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-05  9:46 Dmitry Bely
2008-02-05  9:54 ` [Caml-list] " Alain Frisch
2008-02-05 17:23   ` Dmitry Bely
2008-02-05 17:40     ` Benedikt Grundmann
2008-02-05 19:39       ` Dmitry Bely
2008-02-05 21:00         ` Alain Frisch
2008-02-06  8:56           ` Dmitry Bely
2008-02-06 17:12     ` Xavier Leroy
2008-02-06 18:22       ` Dmitry Bely [this message]
2008-05-03 18:39       ` Dmitry Bely
2008-02-08 13:27     ` Kuba Ober
2008-02-08 16:33       ` Dmitry Bely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=90823c940802061022j4135581cp7a086cc5f03379d5@mail.gmail.com \
    --to=dmitry.bely@gmail.com \
    --cc=Xavier.Leroy@inria.fr \
    --cc=alain@frisch.fr \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).