[Mono-dev] Building Mono on Linux/Alpha

Zoltan Varga vargaz at gmail.com
Tue Aug 15 11:06:31 EDT 2006


                                    Hi,

  The code in mini.c is incorrect, _idiv and its friends should be
registered with
no_throw set to FALSE, instead of TRUE. I will fix it in a minute.

                  Zoltan

On 8/15/06, Sergey Tikhonov <tsv at solvo.ru> wrote:
> Hello Zoltan,
>
> >                                      Hi,
> >
> >> I have a question:
> >> Alpha arch doesn't have unassigned compare for floats, but IR seems to
> >> require it. What would be the best place to
> >> implement taking abs values for arguments to compare and do comparition?
> >> I was thinking of using inssel-alpha.brg file to add instruction like
> >> "stmt: OP_COND_BRANCH (OP_COMPARE(freg, freg)) { ... }"
> >> (I found usage like this in inssel-arm.brg) to implement abs of fregs
> >> and do compare, but I read documentation that this would limit
> >> optimization and register allocation logic.
> >
> >
> > I don't know how that would limit optimization, so I think it is fine
> > for now.
> >
> >> Another thing - Alpha doesn't have special flag register to hold
> >> comparition result and uses some of common registers. Right now I am
> >> using
> >> one predefined register, but this limit its usage for other ops. I would
> >> like to use local register allocation to allocate register to hold
> >> compare results and use it in conditional branch instruction.
> >>
> >
> > This is not currently possible, ia64 has the same problem and uses a
> > dedicated
> > predicate register.
>
> Ok, I was able to implement float compare (including unordered compare)
> in brg file. It really simplified things.
> Almost all basic-float tests passed.
>
> I have a problem with handling of exceptions (divide by zero exception
> to be exact).
> In my current implementation the CEE_DIV opcode uses mono_idiv function
> which does actual division.
> This method is called without wrapper function (I guess this is because
> it is registered as opcode_emulation) and
> it doesn't have flag "save_lmf" set. So I don't save LMF for it and
> couldn't find exception handler. :(
> Do I understand the current logic with unmanaged opcode emulation
> functions correctly?
> Do I need to implement div opcode? (yes I guess I need, but I was
> thinking to do it later)
>
> Thank you,
>
> --
> Sergey Tikhonov
>
> Solvo Ltd.
> Saint-Petersburg, Russia
> tsv at solvo.ru
>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>



More information about the Mono-devel-list mailing list