[erlang-questions] hipe problems with R14B?

Dan Kelley <>
Fri Oct 15 13:28:59 CEST 2010


I can't, but this minimal reproducer shows the problem:

-----
-module(example).
-export([bar/1]).

bar (Baz) ->
    binary_part(Baz, 0, 1).
-----

That compiles without +native, but throws the same error with +native.

While making up the reproducer, I tried this with the 2-arity version of
binary_part (i.e., binary_part(Baz, {0,1}), and that seemed to work fine,
FWIW.

Thanks,

Dan


On Fri, Oct 15, 2010 at 1:57 AM, Bengt Kleberg
<>wrote:

> Greetings,
>
> Is it possible for you to supply the code?
>
>
> bengt
>
> On Fri, 2010-10-15 at 05:47 +0200, Dan Kelley wrote:
> > Hi,
> >
> > I'm seeing the following when trying to compile with hipe in R14B on
> linux
> > (centos 5.3, x86_64):
> >
> > -----
> > erlc +native -W hth.erl
> > <HiPE (v 3.7.7)> EXITED with reason
> >
> {'trans_fun/2',{bif,binary_part,{f,0},[{x,0},{integer,0},{integer,1}],{x,1}}}
> > @hipe_beam_to_icode:1144
> >
> > =ERROR REPORT==== 14-Oct-2010::23:46:42 ===
> > Error in process <0.27.0> with exit value:
> >
> {{badmatch,{'EXIT',{{hipe_beam_to_icode,1144,{'trans_fun/2',{bif,binary_part,{f,0},[{x,0},{integer,0},{integer,1}],{x,1}}}},[{hipe_beam_to_icode,trans_fun,2},{hipe_beam_to_icode,trans_fun,2},{hipe_beam_to_icode,trans_fun,2},{hipe_beam_to_icode...
> >
> > ./hth.erl:none: internal error in native_compile;
> > crash reason: {{badmatch,
> >                    {'EXIT',
> >                        {{hipe_beam_to_icode,1144,
> >                             {'trans_fun/2',
> >                                 {bif,binary_part,
> >                                     {f,0},
> >                                     [{x,0},{integer,0},{integer,1}],
> >                                     {x,1}}}},
> >                         [{hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_fun,2},
> >                          {hipe_beam_to_icode,trans_op_call,6},
> >                          {hipe_beam_to_icode,trans_fun,2}]}}},
> >
> > [{hipe,get_beam_icode,4},{hipe,'-run_compiler_1/3-fun-0-',4}]}
> > -----
> >
> > Am I doing something wrong, or is this a bug?
> >
> > Thanks,
> >
> > Dan
>
>
> ________________________________________________________________
> erlang-questions (at) erlang.org mailing list.
> See http://www.erlang.org/faq.html
> To unsubscribe; mailto:
>
>


More information about the erlang-questions mailing list