Bug 3011 - testSyscallOpen fail on ppc64 when syscalls return negative value
Summary: testSyscallOpen fail on ppc64 when syscalls return negative value
Status: RESOLVED FIXED
Alias: None
Product: frysk
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Wu Zhou
URL:
Keywords:
Depends on:
Blocks: 2188
  Show dependency treegraph
 
Reported: 2006-08-08 05:56 UTC by Wu Zhou
Modified: 2006-08-17 16:04 UTC (History)
2 users (show)

See Also:
Host: ppc64-redhat-linux
Target: ppc64-redhat-linux
Build: ppc64-redhat-linux
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wu Zhou 2006-08-08 05:56:04 UTC
testSyscallOpen will try to open a non-existent file "a.file", this will return
-ENOENT (-2).  But on PPC64, the value in GPR3 are unsigned.  so the current
code will get a positive 2 back.  This makes testSyscallOpen fail.

Here is the failure log:

testSyscallOpen(frysk.proc.TestTaskSyscallObserver)junit.framework.AssertionFailedError:
open of a.file failed
   at
java.lang.VMThrowable._ZN4java4lang11VMThrowable16fillInStackTraceEPNS0_9ThrowableE(libgcj.so.7)
   at java.lang.Throwable._ZN4java4lang9Throwable16fillInStackTraceEv(libgcj.so.7)
   at java.lang.Throwable._ZN4java4lang9ThrowableC1EPNS0_6StringE(libgcj.so.7)
   at java.lang.Error._ZN4java4lang5ErrorC1EPNS0_6StringE(libgcj.so.7)
   at junit.framework.AssertionFailedError(TestRunner)
   at junit.framework.Assert(TestRunner)
   at junit.framework.Assert(TestRunner)
   at frysk.proc.TestTaskSyscallObserver(TestRunner)
   at
java.lang.reflect.Method._ZN4java4lang7reflect6Method6invokeEPNS0_6ObjectEP6JArrayIS4_E(libgcj.so.7)
   at frysk.junit.Runner(TestRunner)
   at TestRunner(TestRunner)
   at
gnu.java.lang.MainThread._ZN3gnu4java4lang10MainThread9call_mainEv(libgcj.so.7)
   at gnu.java.lang.MainThread._ZN3gnu4java4lang10MainThread3runEv(libgcj.so.7)
Comment 1 Wu Zhou 2006-08-08 08:06:19 UTC
I just sbumitted a patch, which can fix this.  Here is the link: 
http://sources.redhat.com/ml/frysk/2006-q3/msg00172.html.
Comment 2 Wu Zhou 2006-08-17 16:04:22 UTC
the patch is already in latest cvs tree.