harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pavel Afremov (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HARMONY-5309) [EUT] 274 NPE in checkAndTagAsMalformed on Linux x86_64
Date Tue, 18 Dec 2007 20:39:43 GMT

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

Pavel Afremov updated HARMONY-5309:
-----------------------------------

    Attachment: HARMONY-5309_fix1.patch

I found source of the bug. It is in not correct on 100 % ceck in JET
cr_br.cpp line 233:

    int tmp = -jinst.low()/sizeof(void*);
    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)) 

right check should looks like 

    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))

You can find fix in attached HARMONY-5309_fix1.patch.

But I'm not sure on 100% and review is required. Also this check is not reqired for x86-32
platfor. There right offset should be calculated aotomaticly for any value of jinst.low(),
because 32 bits overflow.


> [EUT] 274 NPE in checkAndTagAsMalformed on Linux x86_64
> -------------------------------------------------------
>
>                 Key: HARMONY-5309
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5309
>             Project: Harmony
>          Issue Type: Bug
>          Components: App-Oriented Bug Reports
>         Environment: Linux / x86_64
>            Reporter: Vladimir Beliaev
>         Attachments: HARMONY-5309_fix1.patch, SwitchTest.java
>
>
> 274 tests from EUT suites failed with NPE in the same method on Linux x86_64:
>       java.lang.NullPointerException
>      at org.eclipse.jdt.core.dom.ASTSyntaxErrorPropagator.checkAndTagAsMalformed(ASTSyntaxErrorPropagator.java:34)
>      at org.eclipse.jdt.core.dom.ASTSyntaxErrorPropagator.visit(ASTSyntaxErrorPropagator.java:117)
>      at org.eclipse.jdt.core.dom.CompilationUnit.accept0(CompilationUnit.java:208)
>      <skipped>
> This is not a regressions, still a sensetive difference of EUT behaviour on Linux x86_64
from x86 platforms, so it better be fixed.

-- 
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