hotspot/src/share/vm/code/codeBlob.hpp
changeset 46620 750c6edff33b
parent 42664 29142a56c193
child 46625 edefffab74e2
equal deleted inserted replaced
46619:a3919f5e8d2b 46620:750c6edff33b
   261     _relocation_size(relocation_size),
   261     _relocation_size(relocation_size),
   262     _content_offset(CodeBlob::align_code_offset(_header_size + _relocation_size)),
   262     _content_offset(CodeBlob::align_code_offset(_header_size + _relocation_size)),
   263     _code_offset(_content_offset),
   263     _code_offset(_content_offset),
   264     _data_offset(data_offset)
   264     _data_offset(data_offset)
   265   {
   265   {
   266     assert(_relocation_size == round_to(_relocation_size, oopSize), "unaligned size");
   266     assert(is_aligned(_relocation_size, oopSize), "unaligned size");
   267 
   267 
   268     _code_begin = (address) start + _code_offset;
   268     _code_begin = (address) start + _code_offset;
   269     _code_end = (address) start + _data_offset;
   269     _code_end = (address) start + _data_offset;
   270 
   270 
   271     _content_begin = (address) start + _content_offset;
   271     _content_begin = (address) start + _content_offset;
   277   }
   277   }
   278 
   278 
   279   CodeBlobLayout(const address start, int size, int header_size, const CodeBuffer* cb) :
   279   CodeBlobLayout(const address start, int size, int header_size, const CodeBuffer* cb) :
   280     _size(size),
   280     _size(size),
   281     _header_size(header_size),
   281     _header_size(header_size),
   282     _relocation_size(round_to(cb->total_relocation_size(), oopSize)),
   282     _relocation_size(align_up(cb->total_relocation_size(), oopSize)),
   283     _content_offset(CodeBlob::align_code_offset(_header_size + _relocation_size)),
   283     _content_offset(CodeBlob::align_code_offset(_header_size + _relocation_size)),
   284     _code_offset(_content_offset + cb->total_offset_of(cb->insts())),
   284     _code_offset(_content_offset + cb->total_offset_of(cb->insts())),
   285     _data_offset(_content_offset + round_to(cb->total_content_size(), oopSize))
   285     _data_offset(_content_offset + align_up(cb->total_content_size(), oopSize))
   286   {
   286   {
   287     assert(_relocation_size == round_to(_relocation_size, oopSize), "unaligned size");
   287     assert(is_aligned(_relocation_size, oopSize), "unaligned size");
   288 
   288 
   289     _code_begin = (address) start + _code_offset;
   289     _code_begin = (address) start + _code_offset;
   290     _code_end = (address) start + _data_offset;
   290     _code_end = (address) start + _data_offset;
   291 
   291 
   292     _content_begin = (address) start + _content_offset;
   292     _content_begin = (address) start + _content_offset;