Bug 6661 - testBacktrace(frysk.debuginfo.TestDebugInfoStackTrace)frysk.sys.Errno$Eio: ptrace: Input/output error (op 0x2 (PTRACE_PEEKDATA), pid 16287, addr 0xfffffffffffffff8, data 0x0)
Summary: testBacktrace(frysk.debuginfo.TestDebugInfoStackTrace)frysk.sys.Errno$Eio: pt...
Status: RESOLVED FIXED
Alias: None
Product: frysk
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Andrew Cagney
URL:
Keywords:
: 6665 (view as bug list)
Depends on: 6665
Blocks: 6675
  Show dependency treegraph
 
Reported: 2008-06-20 13:11 UTC by Andrew Cagney
Modified: 2008-06-20 19:32 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew Cagney 2008-06-20 13:11:35 UTC
testBacktrace(frysk.debuginfo.TestDebugInfoStackTrace)frysk.sys.Errno$Eio:
ptrace: Input/output error (op 0x2 (PTRACE_PEEKDATA), pid 16287, addr
0xfffffffffffffff8, data 0x0)
   at frysk.sys.ptrace.AddressSpace.transfer(AddressSpace.java:104)
   at
frysk.proc.live.AddressSpaceByteBuffer$TransferRequest.transfer(AddressSpaceByteBuffer.java:158)
   at
frysk.proc.live.AddressSpaceByteBuffer$TransferRequest.request(AddressSpaceByteBuffer.java:169)
   at frysk.proc.live.AddressSpaceByteBuffer.peek(AddressSpaceByteBuffer.java:183)
   at frysk.proc.live.LogicalMemoryBuffer.peek(LogicalMemoryBuffer.java:125)
   at inua.eio.ByteBuffer.peekFully(ByteBuffer.java:88)
   at inua.eio.ByteBuffer.get(ByteBuffer.java:329)
   at frysk.stack.LibunwindAddressSpace.accessMem(LibunwindAddressSpace.java:90)
   at lib.unwind.Cursor.step(Cursor.java:95)
   at lib.unwind.Cursor.unwind(Cursor.java:110)
   at frysk.stack.LibunwindFrame.unwind(LibunwindFrame.java:75)
   at frysk.stack.Frame.getOuter(Frame.java:133)
   at frysk.debuginfo.DebugInfoFrame.unwind(DebugInfoFrame.java:252)
   at frysk.stack.Frame.getOuter(Frame.java:133)
   at frysk.debuginfo.DebugInfoFrame.getOuterDebugInfoFrame(DebugInfoFrame.java:248)
   at
frysk.debuginfo.TestDebugInfoStackTrace.firstTestBacktraceAssertions(TestDebugInfoStackTrace.java:200)
   at
frysk.debuginfo.TestDebugInfoStackTrace.access$0(TestDebugInfoStackTrace.java:144)
   at
frysk.debuginfo.TestDebugInfoStackTrace$LockObserver.update(TestDebugInfoStackTrace.java:707)
   at java.util.Observable.notifyObservers(libgcj.so.8rh)
   at
frysk.stepping.SteppingEngine$SteppingObserver.updateExecuted(SteppingEngine.java:1146)
   at frysk.proc.live.LinuxPtraceProc$14.add(LinuxPtraceProc.java:754)
   at
frysk.proc.live.LinuxPtraceTaskState$Attached.handleAddObservation(LinuxPtraceTaskState.java:331)
   at frysk.proc.live.LinuxPtraceTask.handleAddObservation(LinuxPtraceTask.java:451)
   at frysk.proc.live.TaskObservation.handleAdd(TaskObservation.java:87)
   at
frysk.proc.live.LinuxPtraceProcState$Attaching.allAttached(LinuxPtraceProcState.java:171)
   at
frysk.proc.live.LinuxPtraceProcState$Attaching.access$0(LinuxPtraceProcState.java:165)
   at
frysk.proc.live.LinuxPtraceProcState$Attaching$ToMainTask.handleTaskAttachCompleted(LinuxPtraceProcState.java:215)
   at frysk.proc.live.LinuxPtraceProc$2.execute(LinuxPtraceProc.java:349)
   at frysk.event.EventLoop.runEventLoop(EventLoop.java:365)
   at frysk.event.EventLoop.runPolling(EventLoop.java:455)
   at frysk.testbed.TestLib.assertRunUntilStop(TestLib.java:80)
   at frysk.testbed.TestLib.assertRunUntilStop(TestLib.java:90)
   at
frysk.debuginfo.TestDebugInfoStackTrace.testBacktrace(TestDebugInfoStackTrace.java:109)
   at frysk.junit.Runner.runCases(Runner.java:214)
   at frysk.junit.Runner.runTestCases(Runner.java:441)
   at TestRunner.main(TestRunner.java:64)
Comment 1 Andrew Cagney 2008-06-20 19:25:11 UTC
The problem was an incorrect implementation of JNIXX catch code in the unwinder
- wasn't actually catching anything.

commit 75e76209d2bde38c31b45978fcda6aa863547aeb
Author: Andrew Cagney <cagney@redhat.com>
Date:   Fri Jun 20 15:21:02 2008 -0400

    Throw/catch UserExceptions, not RuntimeExceptions in unwinder.
    
    This first gets the stack code catching just user (i.e., not bad frysk
    code) exceptions; and secondly, for jni, gets it catching them
    correctly.
    
    frysk-core/frysk/proc/dead/ChangeLog
    2008-06-20  Andrew Cagney  <cagney@redhat.com>
    
        * CorefileByteBuffer.java: Throw UserException, not
        RuntimeException.
    
    frysk-sys/lib/unwind/ChangeLog
    2008-06-20  Andrew Cagney  <cagney@redhat.com>
    
        * jni/UnwindH.hxx (access_mem): Catch Throwable and then use
        instanceof to identify a UserException.
        * cni/UnwindH.hxx (access_mem): Ditto.

Comment 2 Andrew Cagney 2008-06-20 19:32:07 UTC
*** Bug 6665 has been marked as a duplicate of this bug. ***