* Re: [Caml-list] Delimcc bug
2017-06-02 15:05 ` oleg
@ 2017-06-02 15:31 ` Ivan Gotovchits
2017-06-02 15:52 ` Evgeny Khramtsov
2017-06-03 5:26 ` Evgeny Khramtsov
2 siblings, 0 replies; 7+ messages in thread
From: Ivan Gotovchits @ 2017-06-02 15:31 UTC (permalink / raw)
To: oleg; +Cc: Evgeny Khramtsov, caml-list
[-- Attachment #1: Type: text/plain, Size: 1289 bytes --]
Wouldn't it be better to add directly to the implementation a GCC pragma
[1] or an attribute [2] that will explicitly disable the optimizations?
[1]:
https://gcc.gnu.org/onlinedocs/gcc/Function-Specific-Option-Pragmas.html#Function-Specific-Option-Pragmas
[2]:
https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#Common-Function-Attributes
On Fri, Jun 2, 2017 at 5:05 PM, <oleg@okmij.org> wrote:
> On Fri, Jun 02, 2017 at 05:32:21PM +0300, Evgeny Khramtsov wrote:
> > Does anyone know where to report bugs in Delimcc?
> > Is it even supported?
> > Under some conditions I have segfaults in it when compiled natively in
> > 4.04.1.
> >
>
> You can send me directly, or send to the list if you want. But be sure
> you fetch the latest version from my web page. The problem is usually
> GCC, which optimizes too much. So, special flags are required to switch
> off some optmizations. You can see in the Makefile. If you have a very
> recent version of GCC, chances are it needs some more flags to disable
> too aggressive optimizations.
>
> --
> Caml-list mailing list. Subscription management and archives:
> https://sympa.inria.fr/sympa/arc/caml-list
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
>
[-- Attachment #2: Type: text/html, Size: 2317 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] Delimcc bug
2017-06-02 15:05 ` oleg
2017-06-02 15:31 ` Ivan Gotovchits
@ 2017-06-02 15:52 ` Evgeny Khramtsov
2017-06-03 5:26 ` Evgeny Khramtsov
2 siblings, 0 replies; 7+ messages in thread
From: Evgeny Khramtsov @ 2017-06-02 15:52 UTC (permalink / raw)
To: caml-list
Fri, 2 Jun 2017 11:05:57 -0400
oleg@okmij.org wrote:
> You can send me directly, or send to the list if you want. But be sure
> you fetch the latest version from my web page. The problem is usually
> GCC, which optimizes too much. So, special flags are required to
> switch off some optmizations. You can see in the Makefile. If you
> have a very recent version of GCC, chances are it needs some more
> flags to disable too aggressive optimizations.
I'm using delimcc from opam, the url it's pointing to is
http://okmij.org/ftp/continuations/caml-shift.tar.gz
Sometimes it segfaults, sometimes it stops with "take_subcont: can't
happen". I tried with gcc 6.2.0 and 4.9.2. Do I need even older gcc? :)
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] Delimcc bug
2017-06-02 15:05 ` oleg
2017-06-02 15:31 ` Ivan Gotovchits
2017-06-02 15:52 ` Evgeny Khramtsov
@ 2017-06-03 5:26 ` Evgeny Khramtsov
2017-06-03 9:08 ` Jeremy Yallop
2 siblings, 1 reply; 7+ messages in thread
From: Evgeny Khramtsov @ 2017-06-03 5:26 UTC (permalink / raw)
To: caml-list
Fri, 2 Jun 2017 11:05:57 -0400
oleg@okmij.org wrote:
> So, special flags are required to switch
> off some optmizations.
I confirm, replacing -O2 with -O0 flag for compiling stacks-native.c
fixes the problem.
However, I think this (or something better) should be applied in the
patch used to compile delimcc by opam (makefile_fix.patch).
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [Caml-list] Delimcc bug
2017-06-03 5:26 ` Evgeny Khramtsov
@ 2017-06-03 9:08 ` Jeremy Yallop
2017-06-03 13:04 ` Evgeny Khramtsov
0 siblings, 1 reply; 7+ messages in thread
From: Jeremy Yallop @ 2017-06-03 9:08 UTC (permalink / raw)
To: Evgeny Khramtsov; +Cc: Caml List
On 3 June 2017 at 06:26, Evgeny Khramtsov <xramtsov@gmail.com> wrote:
> Fri, 2 Jun 2017 11:05:57 -0400
> oleg@okmij.org wrote:
>
>> So, special flags are required to switch
>> off some optmizations.
>
> I confirm, replacing -O2 with -O0 flag for compiling stacks-native.c
> fixes the problem.
> However, I think this (or something better) should be applied in the
> patch used to compile delimcc by opam (makefile_fix.patch).
The best way to achieve this is to send a pull request to the
opam-repository repository:
https://github.com/ocaml/opam-repository/pulls
mentioning the package maintainer (@rgrinberg) in the description.
Kind regards,
Jeremy
^ permalink raw reply [flat|nested] 7+ messages in thread