[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: regarding line-number in soot mailing thread
- To: #HUANG YUE# <huangyue@pmail.ntu.edu.sg>
- Subject: Re: regarding line-number in soot mailing thread
- From: Ondrej LHOTAK <olhotak@sable.mcgill.ca>
- Date: Mon, 9 Feb 2004 17:03:29 -0500
- Cc: soot-list@sable.mcgill.ca
- In-reply-to: <AA8D817010DB1640BECAC9D0F911ABE90171F650@mail04.student.main.ntu.edu.sg>; from huangyue@pmail.ntu.edu.sg on Sun, Feb 08, 2004 at 09:31:56PM +0800
- References: <AA8D817010DB1640BECAC9D0F911ABE90171F650@mail04.student.main.ntu.edu.sg>
- Sender: owner-soot-list@sable.mcgill.ca
- User-agent: Mutt/1.2.5i
On Sun, Feb 08, 2004 at 09:31:56PM +0800, #HUANG YUE# wrote:
> I `d like to show original source code line number in control flow graph. I
> know from mailing list that there is an attribute that can help to realize.
>
>
>
> But after I wrote the codes as shown in list, I found that no tags found in
> the units. I am not sure which part is not correct. Hope you could give me some
> help on this case.
You need two things to get the source code line numbers:
1) When you compile the code you will be analyzing, you need to use the
-g switch to javac. Otherwise, javac does not insert source line
information into the bytecode, so Soot does not find it there.
2) You need to give the -keep-line-number command-line switch to Soot.
Otherwise, by default, it throws away the source line numbers to save
memory.
Hope that helps.
Ondrej