hotspot/src/os/bsd/dtrace/jhelper.d
author coleenp
Sat, 01 Sep 2012 13:25:18 -0400
changeset 13728 882756847a04
parent 10739 91935236600e
child 13969 d2a189b83b87
permissions -rw-r--r--
6964458: Reimplement class meta-data storage to use native memory Summary: Remove PermGen, allocate meta-data in metaspace linked to class loaders, rewrite GC walking, rewrite and rename metadata to be C++ classes Reviewed-by: jmasa, stefank, never, coleenp, kvn, brutisso, mgerdin, dholmes, jrose, twisti, roland Contributed-by: jmasa <jon.masamitsu@oracle.com>, stefank <stefan.karlsson@oracle.com>, mgerdin <mikael.gerdin@oracle.com>, never <tom.rodriguez@oracle.com>
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     1
/*
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
     2
 * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     4
 *
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     7
 * published by the Free Software Foundation.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     8
 *
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    13
 * accompanied this code).
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    14
 *
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    18
 *
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    21
 * questions.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    22
 *  
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    23
 */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    24
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    25
/* This file is auto-generated */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    26
#include "JvmOffsetsIndex.h"
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    27
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    28
#define DEBUG
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    29
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    30
#ifdef DEBUG
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    31
#define MARK_LINE this->line = __LINE__
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    32
#else
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    33
#define MARK_LINE 
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    34
#endif
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    35
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    36
#ifdef _LP64
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    37
#define STACK_BIAS 0x7ff
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    38
#define pointer uint64_t
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    39
#else
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    40
#define STACK_BIAS 0
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    41
#define pointer uint32_t
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    42
#endif
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    43
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    44
extern pointer __JvmOffsets;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    45
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    46
extern pointer __1cJCodeCacheF_heap_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    47
extern pointer __1cIUniverseO_collectedHeap_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    48
extern pointer __1cIUniverseL_narrow_oop_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    49
#ifdef _LP64
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    50
extern pointer UseCompressedOops;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    51
#endif
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    52
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    53
extern pointer __1cHnmethodG__vtbl_;
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
    54
extern pointer __1cNMethodG__vtbl_;
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    55
extern pointer __1cKBufferBlobG__vtbl_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    56
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    57
#define copyin_ptr(ADDR)    *(pointer*)  copyin((pointer) (ADDR), sizeof(pointer))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    58
#define copyin_uchar(ADDR)  *(uchar_t*)  copyin((pointer) (ADDR), sizeof(uchar_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    59
#define copyin_uint16(ADDR) *(uint16_t*) copyin((pointer) (ADDR), sizeof(uint16_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    60
#define copyin_uint32(ADDR) *(uint32_t*) copyin((pointer) (ADDR), sizeof(uint32_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    61
#define copyin_int32(ADDR)  *(int32_t*)  copyin((pointer) (ADDR), sizeof(int32_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    62
#define copyin_uint8(ADDR)  *(uint8_t*)  copyin((pointer) (ADDR), sizeof(uint8_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    63
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    64
#define SAME(x) x
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    65
#define copyin_offset(JVM_CONST)  JVM_CONST = \
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    66
	copyin_int32(JvmOffsetsPtr + SAME(IDX_)JVM_CONST * sizeof(int32_t))
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    67
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    68
int init_done;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    69
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    70
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    71
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    72
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    73
  this->done = 0;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    74
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    75
   * TBD:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    76
   * Here we initialize init_done, otherwise jhelper does not work.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    77
   * Therefore, copyin_offset() statements work multiple times now.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    78
   * There is a hope we could avoid it in the future, and so,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    79
   * this initialization can be removed.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    80
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    81
  init_done  = 0;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    82
  this->error = (char *) NULL;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    83
  this->result = (char *) NULL;
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
    84
  this->isMethod = 0;
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    85
  this->codecache = 0;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    86
  this->klass = (pointer) NULL;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    87
  this->vtbl  = (pointer) NULL;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    88
  this->suffix = '\0';
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    89
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    90
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    91
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    92
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    93
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    94
  /* Initialization of JvmOffsets constants */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    95
  JvmOffsetsPtr = (pointer) &``__JvmOffsets;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    96
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    97
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    98
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
    99
/!init_done && !this->done/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   100
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   101
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   102
  init_done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   103
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   104
  copyin_offset(COMPILER);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   105
  copyin_offset(OFFSET_CollectedHeap_reserved);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   106
  copyin_offset(OFFSET_MemRegion_start);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   107
  copyin_offset(OFFSET_MemRegion_word_size);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   108
  copyin_offset(SIZE_HeapWord);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   109
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   110
  copyin_offset(OFFSET_interpreter_frame_method);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   111
  copyin_offset(OFFSET_Klass_name);
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   112
  copyin_offset(OFFSET_ConstantPool_pool_holder);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   113
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   114
  copyin_offset(OFFSET_HeapBlockHeader_used);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   115
  copyin_offset(OFFSET_oopDesc_metadata);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   116
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   117
  copyin_offset(OFFSET_Symbol_length);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   118
  copyin_offset(OFFSET_Symbol_body);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   119
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   120
  copyin_offset(OFFSET_Method_constMethod);
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   121
  copyin_offset(OFFSET_ConstMethod_constants);
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   122
  copyin_offset(OFFSET_ConstMethod_name_index);
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   123
  copyin_offset(OFFSET_ConstMethod_signature_index);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   124
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   125
  copyin_offset(OFFSET_CodeHeap_memory);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   126
  copyin_offset(OFFSET_CodeHeap_segmap);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   127
  copyin_offset(OFFSET_CodeHeap_log2_segment_size);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   128
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   129
  copyin_offset(OFFSET_VirtualSpace_low);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   130
  copyin_offset(OFFSET_VirtualSpace_high);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   131
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   132
  copyin_offset(OFFSET_CodeBlob_name);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   133
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   134
  copyin_offset(OFFSET_nmethod_method);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   135
  copyin_offset(SIZE_HeapBlockHeader);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   136
  copyin_offset(SIZE_oopDesc);
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   137
  copyin_offset(SIZE_ConstantPool);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   138
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   139
  copyin_offset(OFFSET_NarrowOopStruct_base);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   140
  copyin_offset(OFFSET_NarrowOopStruct_shift);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   141
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   142
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   143
   * The PC to translate is in arg0.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   144
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   145
  this->pc = arg0;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   146
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   147
  /*
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   148
   * The methodPtr is in %l2 on SPARC.  This can be found at
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   149
   * offset 8 from the frame pointer on 32-bit processes.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   150
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   151
#if   defined(__sparc)
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   152
  this->methodPtr = copyin_ptr(arg1 + 2 * sizeof(pointer) + STACK_BIAS);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   153
#elif defined(__i386) || defined(__amd64)
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   154
  this->methodPtr = copyin_ptr(arg1 + OFFSET_interpreter_frame_method);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   155
#else
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   156
#error "Don't know architecture"
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   157
#endif
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   158
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   159
  this->CodeCache_heap_address = copyin_ptr(&``__1cJCodeCacheF_heap_);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   160
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   161
  /* Reading volatile values */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   162
#ifdef _LP64
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   163
  this->Use_Compressed_Oops  = copyin_uint8(&``UseCompressedOops);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   164
#else
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   165
  this->Use_Compressed_Oops  = 0;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   166
#endif
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   167
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   168
  this->Universe_narrow_oop_base  = copyin_ptr(&``__1cIUniverseL_narrow_oop_ +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   169
                                               OFFSET_NarrowOopStruct_base);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   170
  this->Universe_narrow_oop_shift = copyin_int32(&``__1cIUniverseL_narrow_oop_ +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   171
                                                 OFFSET_NarrowOopStruct_shift);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   172
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   173
  this->CodeCache_low = copyin_ptr(this->CodeCache_heap_address + 
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   174
      OFFSET_CodeHeap_memory + OFFSET_VirtualSpace_low);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   175
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   176
  this->CodeCache_high = copyin_ptr(this->CodeCache_heap_address +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   177
      OFFSET_CodeHeap_memory + OFFSET_VirtualSpace_high);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   178
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   179
  this->CodeCache_segmap_low = copyin_ptr(this->CodeCache_heap_address +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   180
      OFFSET_CodeHeap_segmap + OFFSET_VirtualSpace_low);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   181
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   182
  this->CodeCache_segmap_high = copyin_ptr(this->CodeCache_heap_address +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   183
      OFFSET_CodeHeap_segmap + OFFSET_VirtualSpace_high);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   184
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   185
  this->CodeHeap_log2_segment_size = copyin_uint32(
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   186
      this->CodeCache_heap_address + OFFSET_CodeHeap_log2_segment_size);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   187
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   188
  this->Method_vtbl             = (pointer) &``__1cNMethodG__vtbl_;
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   189
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   190
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   191
   * Get Java heap bounds
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   192
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   193
  this->Universe_collectedHeap = copyin_ptr(&``__1cIUniverseO_collectedHeap_);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   194
  this->heap_start = copyin_ptr(this->Universe_collectedHeap +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   195
      OFFSET_CollectedHeap_reserved +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   196
      OFFSET_MemRegion_start);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   197
  this->heap_size = SIZE_HeapWord *
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   198
    copyin_ptr(this->Universe_collectedHeap +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   199
        OFFSET_CollectedHeap_reserved +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   200
        OFFSET_MemRegion_word_size
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   201
        );
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   202
  this->heap_end = this->heap_start + this->heap_size;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   203
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   204
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   205
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   206
/!this->done &&
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   207
this->CodeCache_low <= this->pc && this->pc < this->CodeCache_high/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   208
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   209
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   210
  this->codecache = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   211
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   212
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   213
   * Find start.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   214
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   215
  this->segment = (this->pc - this->CodeCache_low) >>
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   216
    this->CodeHeap_log2_segment_size;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   217
  this->block = this->CodeCache_segmap_low;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   218
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   219
  "second";
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   220
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   221
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   222
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   223
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   224
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   225
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   226
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   227
  this->segment = this->segment - this->tag;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   228
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   229
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   230
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   231
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   232
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   233
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   234
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   235
  this->segment = this->segment - this->tag;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   236
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   237
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   238
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   239
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   240
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   241
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   242
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   243
  this->segment = this->segment - this->tag;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   244
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   245
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   246
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   247
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   248
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   249
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   250
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   251
  this->segment = this->segment - this->tag;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   252
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   253
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   254
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   255
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   256
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   257
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   258
  this->tag = copyin_uchar(this->block + this->segment);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   259
  this->segment = this->segment - this->tag;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   260
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   261
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   262
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   263
/!this->done && this->codecache && this->tag > 0/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   264
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   265
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   266
  this->error = "<couldn't find start>";
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   267
  this->done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   268
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   269
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   270
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   271
/!this->done && this->codecache/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   272
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   273
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   274
  this->block = this->CodeCache_low +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   275
    (this->segment << this->CodeHeap_log2_segment_size);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   276
  this->used = copyin_uint32(this->block + OFFSET_HeapBlockHeader_used);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   277
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   278
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   279
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   280
/!this->done && this->codecache && !this->used/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   281
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   282
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   283
  this->error = "<block not in use>";
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   284
  this->done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   285
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   286
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   287
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   288
/!this->done && this->codecache/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   289
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   290
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   291
  this->start = this->block + SIZE_HeapBlockHeader;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   292
  this->vtbl = copyin_ptr(this->start);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   293
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   294
  this->nmethod_vtbl            = (pointer) &``__1cHnmethodG__vtbl_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   295
  this->BufferBlob_vtbl         = (pointer) &``__1cKBufferBlobG__vtbl_;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   296
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   297
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   298
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   299
/!this->done && this->vtbl == this->nmethod_vtbl/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   300
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   301
  MARK_LINE;
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   302
  this->methodPtr = copyin_ptr(this->start + OFFSET_nmethod_method);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   303
  this->suffix = '*';
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   304
  this->isMethod = 1;
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   305
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   306
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   307
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   308
/!this->done && this->vtbl == this->BufferBlob_vtbl/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   309
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   310
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   311
  this->name = copyin_ptr(this->start + OFFSET_CodeBlob_name);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   312
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   313
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   314
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   315
dtrace:helper:ustack:
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   316
/!this->done && this->vtbl == this->BufferBlob_vtbl && this->methodPtr != 0/
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   317
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   318
  MARK_LINE;
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   319
  this->klass = copyin_ptr(this->methodPtr);
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   320
  this->isMethod = this->klass == this->Method_vtbl;
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   321
  this->done = !this->isMethod;
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   322
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   323
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   324
dtrace:helper:ustack:
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   325
/!this->done && !this->isMethod/
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   326
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   327
  MARK_LINE;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   328
  this->name = copyin_ptr(this->start + OFFSET_CodeBlob_name);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   329
  this->result = this->name != 0 ? copyinstr(this->name) : "<CodeBlob>";
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   330
  this->done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   331
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   332
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   333
dtrace:helper:ustack:
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   334
/!this->done && this->isMethod/
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   335
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   336
  MARK_LINE;
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   337
  this->constMethod = copyin_ptr(this->methodPtr +
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   338
      OFFSET_Method_constMethod);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   339
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   340
  this->nameIndex = copyin_uint16(this->constMethod +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   341
      OFFSET_ConstMethod_name_index);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   342
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   343
  this->signatureIndex = copyin_uint16(this->constMethod +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   344
      OFFSET_ConstMethod_signature_index);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   345
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   346
  this->constantPool = copyin_ptr(this->constMethod +
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   347
      OFFSET_ConstMethod_constants);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   348
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   349
  this->nameSymbol = copyin_ptr(this->constantPool +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   350
      this->nameIndex * sizeof (pointer) + SIZE_ConstantPool);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   351
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   352
  this->nameSymbolLength = copyin_uint16(this->nameSymbol +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   353
      OFFSET_Symbol_length);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   354
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   355
  this->signatureSymbol = copyin_ptr(this->constantPool +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   356
      this->signatureIndex * sizeof (pointer) + SIZE_ConstantPool);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   357
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   358
  this->signatureSymbolLength = copyin_uint16(this->signatureSymbol +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   359
      OFFSET_Symbol_length);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   360
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   361
  this->klassPtr = copyin_ptr(this->constantPool +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   362
      OFFSET_ConstantPool_pool_holder);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   363
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   364
  this->klassSymbol = copyin_ptr(this->klassPtr +
13728
882756847a04 6964458: Reimplement class meta-data storage to use native memory
coleenp
parents: 10739
diff changeset
   365
      OFFSET_Klass_name);
10739
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   366
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   367
  this->klassSymbolLength = copyin_uint16(this->klassSymbol +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   368
      OFFSET_Symbol_length);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   369
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   370
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   371
   * Enough for three strings, plus the '.', plus the trailing '\0'.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   372
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   373
  this->result = (char *) alloca(this->klassSymbolLength +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   374
      this->nameSymbolLength +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   375
      this->signatureSymbolLength + 2 + 1);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   376
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   377
  copyinto(this->klassSymbol + OFFSET_Symbol_body,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   378
      this->klassSymbolLength, this->result);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   379
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   380
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   381
   * Add the '.' between the class and the name.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   382
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   383
  this->result[this->klassSymbolLength] = '.';
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   384
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   385
  copyinto(this->nameSymbol + OFFSET_Symbol_body,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   386
      this->nameSymbolLength,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   387
      this->result + this->klassSymbolLength + 1);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   388
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   389
  copyinto(this->signatureSymbol + OFFSET_Symbol_body,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   390
      this->signatureSymbolLength,
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   391
      this->result + this->klassSymbolLength +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   392
      this->nameSymbolLength + 1);
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   393
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   394
  /*
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   395
   * Now we need to add a trailing '\0' and possibly a tag character.
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   396
   */
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   397
  this->result[this->klassSymbolLength + 1 + 
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   398
      this->nameSymbolLength +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   399
      this->signatureSymbolLength] = this->suffix;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   400
  this->result[this->klassSymbolLength + 2 + 
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   401
      this->nameSymbolLength +
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   402
      this->signatureSymbolLength] = '\0';
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   403
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   404
  this->done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   405
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   406
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   407
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   408
/this->done && this->error == (char *) NULL/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   409
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   410
  this->result;   
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   411
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   412
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   413
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   414
/this->done && this->error != (char *) NULL/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   415
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   416
  this->error;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   417
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   418
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   419
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   420
/!this->done && this->codecache/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   421
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   422
  this->done = 1;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   423
  "error";
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   424
}
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   425
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   426
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   427
dtrace:helper:ustack:
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   428
/!this->done/
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   429
{
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   430
  NULL;
91935236600e 7098194: integrate macosx-port changes
dcubed
parents:
diff changeset
   431
}