RAPL

Check-in [143896aeaa]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:fixes
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:143896aeaa1f927bcbdc99c09fa28cd9270266a7
User & Date: arnulf 2012-03-31 22:48:29
Context
2012-04-05
13:53
fixes and removal of dead or duplicate code check-in: c3abdb2183 user: arnulf tags: trunk
2012-03-31
22:48
fixes check-in: 143896aeaa user: arnulf tags: trunk
2012-03-27
15:05
fixes found in porting to java version check-in: c31adfa6e2 user: arnulf tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to rapl_command_obj_type.js.

490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
    call_frame_ptr = frame_ptr_ptr[0];
    call_frame_ptr.argv = argv;
    call_frame_ptr.argc = argc;
    call_frame_ptr.proc_args_obj_ptr = cmd_ptr.u.proc.arg_list_obj_ptr;
    call_frame_ptr.proc_body_obj_ptr = cmd_ptr.u.proc.body_obj_ptr;
    call_frame_ptr.static_vars = cmd_ptr.u.proc.static_vars;
    call_frame_ptr.file_name_obj = file_name_obj;
    call_frame_ptr.line = linenr;
    cmd_ptr.u.proc.arg_list_obj_ptr.incrRefCount("I_COMMAND_OBJ_TYPE_5");
    cmd_ptr.u.proc.body_obj_ptr.incrRefCount("I_COMMAND_OBJ_TYPE_6");
    intp.frame_ptr = call_frame_ptr;
    /* Install a new stack for local procs */
    prev_local_procs = intp.local_procs;
    intp.local_procs = null;
    /* How many optional args are available */







|







490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
    call_frame_ptr = frame_ptr_ptr[0];
    call_frame_ptr.argv = argv;
    call_frame_ptr.argc = argc;
    call_frame_ptr.proc_args_obj_ptr = cmd_ptr.u.proc.arg_list_obj_ptr;
    call_frame_ptr.proc_body_obj_ptr = cmd_ptr.u.proc.body_obj_ptr;
    call_frame_ptr.static_vars = cmd_ptr.u.proc.static_vars;
    call_frame_ptr.file_name_obj = file_name_obj;
    call_frame_ptr.line = line_no;
    cmd_ptr.u.proc.arg_list_obj_ptr.incrRefCount("I_COMMAND_OBJ_TYPE_5");
    cmd_ptr.u.proc.body_obj_ptr.incrRefCount("I_COMMAND_OBJ_TYPE_6");
    intp.frame_ptr = call_frame_ptr;
    /* Install a new stack for local procs */
    prev_local_procs = intp.local_procs;
    intp.local_procs = null;
    /* How many optional args are available */

Changes to rapl_eval_statement.js.

394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
      var j;
      var cmd;
      var num_comments = 0;

      /* First token of the line is always TOKEN_LINE */
      argc = token[i].obj_ptr.scriptLineValue.argc();
//print("I!"+i+"!"+argc+"!"+script.getTokenString(token[i].token)+"!"+token[i].obj_ptr.toDebugString()+"!");
      linenr = token[i].obj_ptr.scriptLineValue.line();
      /* Skip the TOKEN_LINE token */
      i++;
      /* Populate the arguments objects.
       * If an error occurs, retcode will be set and
       * 'j' will be set to the number of args expanded
       */
      had_comment = false;







|







394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
      var j;
      var cmd;
      var num_comments = 0;

      /* First token of the line is always TOKEN_LINE */
      argc = token[i].obj_ptr.scriptLineValue.argc();
//print("I!"+i+"!"+argc+"!"+script.getTokenString(token[i].token)+"!"+token[i].obj_ptr.toDebugString()+"!");
      line_no = token[i].obj_ptr.scriptLineValue.line();
      /* Skip the TOKEN_LINE token */
      i++;
      /* Populate the arguments objects.
       * If an error occurs, retcode will be set and
       * 'j' will be set to the number of args expanded
       */
      had_comment = false;

Changes to rapl_list_obj_type.js.

549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
    if (idx < 0) {
      idx = list_ptr.listValue.len() + idx;
    }
    obj_ptr_ptr[0] = list_ptr.listValue.elem()[idx];
    return lst.OK;
  },

  /* ==================== _listSetIndex ===================================== */
  _listSetIndex: function(list_ptr, idx, new_obj_ptr, flags) {
    var lst = this;
    if (!list_ptr.isListObj()) {
      lst.setFromAny(list_ptr);
    }
    if ((idx >= 0 && idx >= list_ptr.listValue.len()) ||
        (idx < 0 && (-idx - 1) >= list_ptr.listValue.len())) {
        if (flags & lst.FUNCTION_FLAGS_LEAVE_ERR_MSG) {







|
|







549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
    if (idx < 0) {
      idx = list_ptr.listValue.len() + idx;
    }
    obj_ptr_ptr[0] = list_ptr.listValue.elem()[idx];
    return lst.OK;
  },

  /* ==================== listSetIndex ===================================== */
  listSetIndex: function(list_ptr, idx, new_obj_ptr, flags) {
    var lst = this;
    if (!list_ptr.isListObj()) {
      lst.setFromAny(list_ptr);
    }
    if ((idx >= 0 && idx >= list_ptr.listValue.len()) ||
        (idx < 0 && (-idx - 1) >= list_ptr.listValue.len())) {
        if (flags & lst.FUNCTION_FLAGS_LEAVE_ERR_MSG) {

Changes to rapl_trace.js.

23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
  R.Base.trace_oid++;
  trace.oid = R.Base.trace_oid;


  trace.interp = interp;
  trace.type = null;
  trace.name = name;
  trace.ops = 0;
  trace.command = command;

  var my_type_val = interp.getTraceTypeFromString(type);
  if (my_type_val == null) {
    interp.setResultString("bad type: \""+type+"\" in Trace");
    return interp.ERROR;
  }







<







23
24
25
26
27
28
29

30
31
32
33
34
35
36
  R.Base.trace_oid++;
  trace.oid = R.Base.trace_oid;


  trace.interp = interp;
  trace.type = null;
  trace.name = name;

  trace.command = command;

  var my_type_val = interp.getTraceTypeFromString(type);
  if (my_type_val == null) {
    interp.setResultString("bad type: \""+type+"\" in Trace");
    return interp.ERROR;
  }