Closed Bug 475345 Opened 15 years ago Closed 15 years ago

vm commandline debugger unable to identify source files

Categories

(Tamarin Graveyard :: Virtual Machine, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: dschaffe, Assigned: stejohns)

Details

Attachments

(1 file)

the command line debugger in the vm shell is unable to identify source files making the debugger unusable.  

It seems like a small amount of the work to make the debugger useful.

create a simple files like:
test.as:
1: function f() {
2:   print ("in funct");
3: }
4: f();
compile it: java -jar asc.jar -d test.as
debug it use debugger/release shell: avmshell -d test.abc
1: function f() {
(asdb) b 4
No source available; can't set breakpoint.
1: function f() {
(asdb) b test.as:4
No source available; can't set breakpoint.
1: function f() {
(asdb) 

the actual result is a crash in both cases but I patched the code to not crash.
Flags: flashplayer-triage+
Flags: flashplayer-qrb?
This could be a side-effect of recent DEBUGGER and String stuff, I'll claim it.
Assignee: nobody → stejohns
Attached patch PatchSplinter Review
Changes to the way debugger is created broke this -- DebugCLI used to rely on the fact that builtin abcs weren't added the the debugger abcs due to creation order, but this is no longer the case (and never was the case for Flash). Smartening DebugCLI a little fixes it.

Also re-enabled an unrelated but now-appropriate assert in MethodEnv.
Attachment #359100 - Flags: review?
built with the patch and the cmdline debugger allows setting breakpoints correctly now.  e.g.
bash-3.2$ $AVM -d testdata/debug.abc 
40:  public class debug {
(asdb) b 42
Breakpoint 1: file testdata/debug.as, 42.
40:  public class debug {
(asdb) b testdata/debug.as:43
Breakpoint 2: file testdata/debug.as, 43.
40:  public class debug {
(asdb) c
42:         print("in constructor()");
(asdb) c
in constructor()
43:     }
(asdb)
Attachment #359100 - Flags: review? → review?(dschaffe)
Attachment #359100 - Flags: review?(dschaffe) → review+
pushed to redux as changeset:   1359:0419f039887e
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
closing, setting state to verified/fixed.
Status: RESOLVED → VERIFIED
Flags: flashplayer-qrb? → in-testsuite+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: