< prev index next >

src/share/vm/asm/codeBuffer.hpp

Print this page




 210 
 211   // Share a scratch buffer for relocinfo.  (Hacky; saves a resource allocation.)
 212   void initialize_shared_locs(relocInfo* buf, int length);
 213 
 214   // Manage labels and their addresses.
 215   address target(Label& L, address branch_pc);
 216 
 217   // Emit a relocation.
 218   void relocate(address at, RelocationHolder const& rspec, int format = 0);
 219   void relocate(address at,    relocInfo::relocType rtype, int format = 0, jint method_index = 0);
 220 
 221   // alignment requirement for starting offset
 222   // Requirements are that the instruction area and the
 223   // stubs area must start on CodeEntryAlignment, and
 224   // the ctable on sizeof(jdouble)
 225   int alignment() const             { return MAX2((int)sizeof(jdouble), (int)CodeEntryAlignment); }
 226 
 227   // Slop between sections, used only when allocating temporary BufferBlob buffers.
 228   static csize_t end_slop()         { return MAX2((int)sizeof(jdouble), (int)CodeEntryAlignment); }
 229 
 230   csize_t align_at_start(csize_t off) const { return (csize_t) align_size_up(off, alignment()); }
 231 
 232   // Mark a section frozen.  Assign its remaining space to
 233   // the following section.  It will never expand after this point.
 234   inline void freeze();         //  { _outer->freeze_section(this); }
 235 
 236   // Ensure there's enough space left in the current section.
 237   // Return true if there was an expansion.
 238   bool maybe_expand_to_ensure_remaining(csize_t amount);
 239 
 240 #ifndef PRODUCT
 241   void decode();
 242   void dump();
 243   void print(const char* name);
 244 #endif //PRODUCT
 245 };
 246 
 247 class CodeString;
 248 class CodeStrings VALUE_OBJ_CLASS_SPEC {
 249 private:
 250 #ifndef PRODUCT




 210 
 211   // Share a scratch buffer for relocinfo.  (Hacky; saves a resource allocation.)
 212   void initialize_shared_locs(relocInfo* buf, int length);
 213 
 214   // Manage labels and their addresses.
 215   address target(Label& L, address branch_pc);
 216 
 217   // Emit a relocation.
 218   void relocate(address at, RelocationHolder const& rspec, int format = 0);
 219   void relocate(address at,    relocInfo::relocType rtype, int format = 0, jint method_index = 0);
 220 
 221   // alignment requirement for starting offset
 222   // Requirements are that the instruction area and the
 223   // stubs area must start on CodeEntryAlignment, and
 224   // the ctable on sizeof(jdouble)
 225   int alignment() const             { return MAX2((int)sizeof(jdouble), (int)CodeEntryAlignment); }
 226 
 227   // Slop between sections, used only when allocating temporary BufferBlob buffers.
 228   static csize_t end_slop()         { return MAX2((int)sizeof(jdouble), (int)CodeEntryAlignment); }
 229 
 230   csize_t align_at_start(csize_t off) const { return (csize_t) align_up(off, alignment()); }
 231 
 232   // Mark a section frozen.  Assign its remaining space to
 233   // the following section.  It will never expand after this point.
 234   inline void freeze();         //  { _outer->freeze_section(this); }
 235 
 236   // Ensure there's enough space left in the current section.
 237   // Return true if there was an expansion.
 238   bool maybe_expand_to_ensure_remaining(csize_t amount);
 239 
 240 #ifndef PRODUCT
 241   void decode();
 242   void dump();
 243   void print(const char* name);
 244 #endif //PRODUCT
 245 };
 246 
 247 class CodeString;
 248 class CodeStrings VALUE_OBJ_CLASS_SPEC {
 249 private:
 250 #ifndef PRODUCT


< prev index next >