src/os/solaris/dtrace/generateJvmOffsets.cpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File 8015774 Sdiff src/os/solaris/dtrace

src/os/solaris/dtrace/generateJvmOffsets.cpp

Print this page




  65  * a particular workaround for the following symbols below.
  66  * It will be good to find out a generic way in the future.
  67  */
  68 
  69 #pragma weak tty
  70 #pragma weak CMSExpAvgFactor
  71 
  72 #if defined(i386) || defined(__i386) || defined(__amd64)
  73 #pragma weak noreg
  74 #endif /* i386 */
  75 
  76 LIR_Opr LIR_OprFact::illegalOpr = (LIR_Opr) 0;
  77 
  78 address StubRoutines::_call_stub_return_address = NULL;
  79 
  80 StubQueue* AbstractInterpreter::_code = NULL;
  81 
  82 #endif /* ASSERT */
  83 #endif /* COMPILER1 */
  84 
  85 #define GEN_OFFS(Type,Name)                             \
  86   switch(gen_variant) {                                 \
  87   case GEN_OFFSET:                                      \
  88     printf("#define OFFSET_%-33s %d\n",                 \
  89             #Type #Name, offset_of(Type, Name));        \
  90     break;                                              \
  91   case GEN_INDEX:                                       \
  92     printf("#define IDX_OFFSET_%-33s %d\n",             \
  93             #Type #Name, index++);                      \
  94     break;                                              \
  95   case GEN_TABLE:                                       \
  96     printf("\tOFFSET_%s,\n", #Type #Name);              \
  97     break;                                              \
  98   }
  99 



 100 #define GEN_SIZE(Type)                                  \
 101   switch(gen_variant) {                                 \
 102   case GEN_OFFSET:                                      \
 103     printf("#define SIZE_%-35s %d\n",                   \
 104             #Type, sizeof(Type));                       \
 105     break;                                              \
 106   case GEN_INDEX:                                       \
 107     printf("#define IDX_SIZE_%-35s %d\n",               \
 108             #Type, index++);                            \
 109     break;                                              \
 110   case GEN_TABLE:                                       \
 111     printf("\tSIZE_%s,\n", #Type);                      \
 112     break;                                              \
 113   }
 114 
 115 #define GEN_VALUE(String,Value)                         \
 116   switch(gen_variant) {                                 \
 117   case GEN_OFFSET:                                      \
 118     printf("#define %-40s %d\n", #String, Value);       \
 119     break;                                              \


 222   GEN_OFFS(Method, _constMethod);
 223   GEN_OFFS(Method, _access_flags);
 224   printf("\n");
 225 
 226   GEN_OFFS(ConstMethod, _constants);
 227   GEN_OFFS(ConstMethod, _flags);
 228   GEN_OFFS(ConstMethod, _code_size);
 229   GEN_OFFS(ConstMethod, _name_index);
 230   GEN_OFFS(ConstMethod, _signature_index);
 231   printf("\n");
 232 
 233   GEN_OFFS(CodeHeap, _memory);
 234   GEN_OFFS(CodeHeap, _segmap);
 235   GEN_OFFS(CodeHeap, _log2_segment_size);
 236   printf("\n");
 237 
 238   GEN_OFFS(VirtualSpace, _low_boundary);
 239   GEN_OFFS(VirtualSpace, _high_boundary);
 240   GEN_OFFS(VirtualSpace, _low);
 241   GEN_OFFS(VirtualSpace, _high);





 242   printf("\n");
 243 
 244   GEN_OFFS(CodeBlob, _name);
 245   GEN_OFFS(CodeBlob, _header_size);
 246   GEN_OFFS(CodeBlob, _content_offset);
 247   GEN_OFFS(CodeBlob, _code_offset);
 248   GEN_OFFS(CodeBlob, _data_offset);
 249   GEN_OFFS(CodeBlob, _frame_size);
 250   printf("\n");
 251 
 252   GEN_OFFS(nmethod, _method);
 253   GEN_OFFS(nmethod, _metadata_offset);
 254   GEN_OFFS(nmethod, _scopes_data_offset);
 255   GEN_OFFS(nmethod, _scopes_pcs_offset);
 256   GEN_OFFS(nmethod, _handler_table_offset);
 257   GEN_OFFS(nmethod, _deoptimize_offset);
 258   GEN_OFFS(nmethod, _orig_pc_offset);
 259 
 260   GEN_OFFS(PcDesc, _pc_offset);
 261   GEN_OFFS(PcDesc, _scope_decode_offset);




  65  * a particular workaround for the following symbols below.
  66  * It will be good to find out a generic way in the future.
  67  */
  68 
  69 #pragma weak tty
  70 #pragma weak CMSExpAvgFactor
  71 
  72 #if defined(i386) || defined(__i386) || defined(__amd64)
  73 #pragma weak noreg
  74 #endif /* i386 */
  75 
  76 LIR_Opr LIR_OprFact::illegalOpr = (LIR_Opr) 0;
  77 
  78 address StubRoutines::_call_stub_return_address = NULL;
  79 
  80 StubQueue* AbstractInterpreter::_code = NULL;
  81 
  82 #endif /* ASSERT */
  83 #endif /* COMPILER1 */
  84 
  85 #define GEN_OFFS_NAME(Type,Name,OutputType)             \
  86   switch(gen_variant) {                                 \
  87   case GEN_OFFSET:                                      \
  88     printf("#define OFFSET_%-33s %d\n",                 \
  89             #OutputType #Name, offset_of(Type, Name));  \
  90     break;                                              \
  91   case GEN_INDEX:                                       \
  92     printf("#define IDX_OFFSET_%-33s %d\n",             \
  93             #OutputType #Name, index++);                \
  94     break;                                              \
  95   case GEN_TABLE:                                       \
  96     printf("\tOFFSET_%s,\n", #OutputType #Name);        \
  97     break;                                              \
  98   }
  99 
 100 #define GEN_OFFS(Type,Name)                             \
 101   GEN_OFFS_NAME(Type,Name,Type)
 102 
 103 #define GEN_SIZE(Type)                                  \
 104   switch(gen_variant) {                                 \
 105   case GEN_OFFSET:                                      \
 106     printf("#define SIZE_%-35s %d\n",                   \
 107             #Type, sizeof(Type));                       \
 108     break;                                              \
 109   case GEN_INDEX:                                       \
 110     printf("#define IDX_SIZE_%-35s %d\n",               \
 111             #Type, index++);                            \
 112     break;                                              \
 113   case GEN_TABLE:                                       \
 114     printf("\tSIZE_%s,\n", #Type);                      \
 115     break;                                              \
 116   }
 117 
 118 #define GEN_VALUE(String,Value)                         \
 119   switch(gen_variant) {                                 \
 120   case GEN_OFFSET:                                      \
 121     printf("#define %-40s %d\n", #String, Value);       \
 122     break;                                              \


 225   GEN_OFFS(Method, _constMethod);
 226   GEN_OFFS(Method, _access_flags);
 227   printf("\n");
 228 
 229   GEN_OFFS(ConstMethod, _constants);
 230   GEN_OFFS(ConstMethod, _flags);
 231   GEN_OFFS(ConstMethod, _code_size);
 232   GEN_OFFS(ConstMethod, _name_index);
 233   GEN_OFFS(ConstMethod, _signature_index);
 234   printf("\n");
 235 
 236   GEN_OFFS(CodeHeap, _memory);
 237   GEN_OFFS(CodeHeap, _segmap);
 238   GEN_OFFS(CodeHeap, _log2_segment_size);
 239   printf("\n");
 240 
 241   GEN_OFFS(VirtualSpace, _low_boundary);
 242   GEN_OFFS(VirtualSpace, _high_boundary);
 243   GEN_OFFS(VirtualSpace, _low);
 244   GEN_OFFS(VirtualSpace, _high);
 245   printf("\n");
 246 
 247   /* We need to use different names here because of the template parameter */
 248   GEN_OFFS_NAME(GrowableArray<CodeHeap*>, _data, GrowableArray_CodeHeap);
 249   GEN_OFFS_NAME(GrowableArray<CodeHeap*>, _len, GrowableArray_CodeHeap);
 250   printf("\n");
 251 
 252   GEN_OFFS(CodeBlob, _name);
 253   GEN_OFFS(CodeBlob, _header_size);
 254   GEN_OFFS(CodeBlob, _content_offset);
 255   GEN_OFFS(CodeBlob, _code_offset);
 256   GEN_OFFS(CodeBlob, _data_offset);
 257   GEN_OFFS(CodeBlob, _frame_size);
 258   printf("\n");
 259 
 260   GEN_OFFS(nmethod, _method);
 261   GEN_OFFS(nmethod, _metadata_offset);
 262   GEN_OFFS(nmethod, _scopes_data_offset);
 263   GEN_OFFS(nmethod, _scopes_pcs_offset);
 264   GEN_OFFS(nmethod, _handler_table_offset);
 265   GEN_OFFS(nmethod, _deoptimize_offset);
 266   GEN_OFFS(nmethod, _orig_pc_offset);
 267 
 268   GEN_OFFS(PcDesc, _pc_offset);
 269   GEN_OFFS(PcDesc, _scope_decode_offset);


src/os/solaris/dtrace/generateJvmOffsets.cpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File