vm commandline debugger unable to identify source files

VERIFIED FIXED

Status

Tamarin
Virtual Machine
VERIFIED FIXED
9 years ago
8 years ago

People

(Reporter: Dan Schaffer, Assigned: Steven Johnson)

Tracking

unspecified
x86
Mac OS X
Bug Flags:
in-testsuite +
flashplayer-triage +

Details

Attachments

(1 attachment)

(Reporter)

Description

9 years ago
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?
(Assignee)

Comment 1

9 years ago
This could be a side-effect of recent DEBUGGER and String stuff, I'll claim it.
Assignee: nobody → stejohns
(Assignee)

Comment 2

9 years ago
Created attachment 359100 [details] [diff] [review]
Patch

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?
(Reporter)

Comment 3

9 years ago
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)
(Assignee)

Updated

9 years ago
Attachment #359100 - Flags: review? → review?(dschaffe)
(Reporter)

Updated

9 years ago
Attachment #359100 - Flags: review?(dschaffe) → review+
(Assignee)

Comment 4

9 years ago
pushed to redux as changeset:   1359:0419f039887e
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
(Reporter)

Comment 5

8 years ago
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.