Re: [Gems-users] Opal wont catch magic breakpoint


Date: Mon, 10 Mar 2008 17:37:31 -0600
From: Dan Gibson <degibson@xxxxxxxx>
Subject: Re: [Gems-users] Opal wont catch magic breakpoint
While the loop appears simple, Luke could be right in his observation that 100000 instructions may not be enough. In particular, I am unsure of the implementation of fabs() -- if it calls a dynamically-linked library then it could take quite some time! Try calling fabs() before the first magic call, just to be sure.

Regards,
Dan

Luke Yen wrote:
   The opal0.sim-step command takes as argument number of processor 
instructions to execute, so 100000 might be insufficient for the 
processor to reach the second breakpoint.
    Also check whether the breakpoint is caught inside Opal's magic 
instruction callback handler, in opal/system/system.C.  Grep for 
system_breakpoint() and insert some print statements.

    Luke

On Mon, 10 Mar 2008, Xuan Qi wrote:

  
Hi everyone,

I am testing the magic breakpoint on my target machine. I use the a simple
program which is provided at $GEMS/opal/benchmark/float.C. The main part
of it is:

......
 /* -- 4 == Do_Breakpoint */
 RUBY_MAGIC_CALL( 4 );

 for (int i = 0; i < numTrials; i++) {

   result_s = ((float32) fabs( pos1_s )) * value_s ;
   result_s = ((float32) fabs( neg1_s )) * value_s ;

   result_d = (fabs( pos1_d )) * value_d ;
   result_d = (fabs( neg1_d )) * value_d ;

 }

 /* -- 4 == Do_Breakpoint */
 RUBY_MAGIC_CALL( 4 );
......

And I use the following script to test the magic breakpoints:

read-configuration sarek-2core.conf
cpu-switch-time 1
instruction-fetch-mode instruction-fetch-trace
istc-disable
dstc-disable
magic-break-enable
load-module ruby
ruby0.setparam g_NUM_PROCESSORS 2
ruby0.setparam g_MEMORY_SIZE_BYTES 536870912
ruby0.setparam g_PROCS_PER_CHIP 2
ruby0.setparam g_NUM_MEMORIES 1
ruby0.setparam NUMBER_OF_VIRTUAL_NETWORKS 6
ruby0.init
@conf.con0.input = "cd ALP/MPGenc/verify\n";
@conf.con0.input = "./float 5\n";
c
echo "first breakpoint"
load-module opal
opal0.init
opal0.sim-start "output_2core.opal"
opal0.sim-step 100000

Simulation will stop at first magic breakpoint and load opal module. But
when opal drives simulation, it won't catch the second magic breakpoint.
Am I missing something? Thank you...

Best regards,
Xuan Qi


_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site:https://lists.cs.wisc.edu/archive/gems-users/" to your search.

    
_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site:https://lists.cs.wisc.edu/archive/gems-users/" to your search.


  

-- 
http://www.cs.wisc.edu/~gibson [esc]:wq!
[← Prev in Thread] Current Thread [Next in Thread→]