Erlang Mailing Lists

Author Message

<  Erlang  ~  Profiler in Distel gives memql error

Bill M.
Posted: Thu Jul 17, 2008 3:14 am Reply with quote
User Joined: 06 Jun 2008 Posts: 24 Location: New York
Using Distel (recent extraction, ChangeLog says last update was 2008-05-23), I get
Quote:

Symbol's function definition is void: memql

error message in Xemacs on OpenSuse 11.0 where:
Code:

rpm -q -a | grep erlang
erlang-R12B3-22.1
erlang-jinterface-R12B3-22.1
erlang-doc-R12B3-22.1
rpm -q -a | grep xemacs
xemacs-el-21.5.28.20080401-16.1
xemacs-packages-el-20070427-112.1
xemacs-info-21.5.28.20080401-16.1
xemacs-packages-20070427-112.1
xemacs-21.5.28.20080401-16.1
xemacs-packages-info-20070427-112.1

To trigger the symptom I use xemacs, compile a module (I have one called dlmath) which has a test/0 function defined and exported. In the shell generated by erlang->compile->compile buffer in the pull down menus, I can invoke dlmath:test() and it runs as expected. However, when I'm in the dlmath.erl buffer, and I select distel->Profile an erlang expression, I am prompted for the node name, which I get from running node() under the erlang shell and then I am prompted for the Erlang expression, which I enter after which I then get the error message mentioned above.

Am I going about profiling that function in the wrong way, do I have a configuration error, or am I hitting some distel glitch?
View user's profile Send private message
Bill M.
Posted: Fri Jul 18, 2008 1:48 am Reply with quote
User Joined: 06 Jun 2008 Posts: 24 Location: New York
In my previous post I said:
Quote:

To trigger the symptom I use xemacs, compile a module (I have one called dlmath) which has a test/0 function defined and exported. In the shell generated by erlang->compile->compile buffer in the pull down menus, I can invoke dlmath:test() and it runs as expected. However, when I'm in the dlmath.erl buffer, and I select distel->Profile an erlang expression, I am prompted for the node name, which I get from running node() under the erlang shell and then I am prompted for the Erlang expression, which I enter after which I then get the error message mentioned above.

However, it may be that Distel's directions aren't clear to people new to Erlang (like me Smile). When I meant I entered an erlang expresion to profile, I entered:
Code:

dlmath:test().

I'm not sure that is the correct format for the expression.
The comments read:
Code:

%% ----------------------------------------------------------------------
%% Profiling
%% fprof_expr(E) -> {ok, Preamble, Header, Entry}
%% Preamble = binary()
%% Entry = {Tag, MFA, Text, Callers, Callees, Beamfile}
%% Callers = Callees = [Tag]
%% MFA = [Module, Function, Arity] | undefined
%%
%% Entry example,
%%   {'foo:bar/2', "foo:bar/2  10 100 200", ['baz:beer/2'], [], "/foo.beam"}

My elisp is not so good, but it looks like there may be a function named fprof on the elisp side that interacts with the erlang side. My question is what text should I enter when prompted for an expression, do I enter module:functionname/arity?
e:g:
Code:

dlmath:test/0

If I enter that, I get a message:
Code:

Symbol's function definition is void: memql

I also tried entering:
Code:

dlmath:test().

This also failed in the same fashion as did an attempt without the terminating period.
So What is the right syntax for entering the expression and how are parameters entered? If I got it right, how can I trouble shoot this?

Regards:

Bill M.
View user's profile Send private message

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum