harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mikhail Fursov (JIRA)" <j...@apache.org>
Subject [jira] Assigned: (HARMONY-5335) [drlvm][jit][jet] Switch improvement
Date Wed, 09 Apr 2008 15:04:24 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-5335?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Mikhail Fursov reassigned HARMONY-5335:
---------------------------------------

    Assignee: Mikhail Fursov

> [drlvm][jit][jet] Switch improvement
> ------------------------------------
>
>                 Key: HARMONY-5335
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5335
>             Project: Harmony
>          Issue Type: Improvement
>          Components: DRLVM
>            Reporter: Pavel Afremov
>            Assignee: Mikhail Fursov
>         Attachments: switch_improvement.patch
>
>
> During fixing HARMONY-5309 wrong / non optimal check was found in the JET. More correct
/ optimal patch was provided. To avoid missing of the correction this JIRA was created.
> In file vm/jitrino/src/jet/cg_br.cpp(line 237) Check 
>     int tmp = -jinst.low();
>     const int LO_BOUND = INT_MIN/(int)sizeof(void*);
>     const int UP_BOUND = INT_MAX/(int)sizeof(void*);
>     if (!(LO_BOUND<=tmp && tmp<=UP_BOUND))
> has no sense on x86-32, because operation 
>     ld(jobj, gr_tabl, gr_tabl, -jinst.low()*sizeof(void*), 
>     val.reg(), sizeof(void*));
> always is correct because of 32 bit overflow.
> Also sx(Opnd(i64, val.reg()), Opnd(i32, val.reg())); has sense on x86-64 for small negative
values of  jinst.low (INT_MIN/8,0) only. In other case this operation is useless.
> So from my point of view optimal patch should looks like switch_improvement.patch.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message