41 void try_allocate(
42 Register obj, // result: pointer to object after successful allocation
43 Register var_size_in_bytes, // object size in bytes if unknown at compile time; invalid otherwise
44 int con_size_in_bytes, // object size in bytes if known at compile time
45 Register t1, // temp register
46 Register t2, // temp register
47 Label& slow_case // continuation point if fast allocation fails
48 );
49
50 void initialize_header(Register obj, Register klass, Register len, Register t1, Register t2);
51 void initialize_body(Register obj, Register len_in_bytes, int hdr_size_in_bytes, Register t1, Register t2);
52
53 void float_cmp(bool is_float, int unordered_result,
54 FloatRegister f0, FloatRegister f1,
55 Register result);
56
57 // locking
58 // hdr : must be r0, contents destroyed
59 // obj : must point to the object to lock, contents preserved
60 // disp_hdr: must point to the displaced header location, contents preserved
61 // scratch : scratch register, contents destroyed
62 // returns code offset at which to add null check debug information
63 int lock_object (Register swap, Register obj, Register disp_hdr, Register scratch, Label& slow_case);
64
65 // unlocking
66 // hdr : contents destroyed
67 // obj : must point to the object to lock, contents preserved
68 // disp_hdr: must be r0 & must point to the displaced header location, contents destroyed
69 void unlock_object(Register swap, Register obj, Register lock, Label& slow_case);
70
71 void initialize_object(
72 Register obj, // result: pointer to object after successful allocation
73 Register klass, // object klass
74 Register var_size_in_bytes, // object size in bytes if unknown at compile time; invalid otherwise
75 int con_size_in_bytes, // object size in bytes if known at compile time
76 Register t1, // temp register
77 Register t2, // temp register
78 bool is_tlab_allocated // the object was allocated in a TLAB; relevant for the implementation of ZeroTLAB
79 );
80
81 // allocation of fixed-size objects
82 // (can also be used to allocate fixed-size arrays, by setting
83 // hdr_size correctly and storing the array length afterwards)
84 // obj : will contain pointer to allocated object
85 // t1, t2 : scratch registers - contents destroyed
86 // header_size: size of object header in words
87 // object_size: total size of object in words
88 // slow_case : exit to slow case implementation if fast allocation fails
89 void allocate_object(Register obj, Register t1, Register t2, int header_size, int object_size, Register klass, Label& slow_case);
|
41 void try_allocate(
42 Register obj, // result: pointer to object after successful allocation
43 Register var_size_in_bytes, // object size in bytes if unknown at compile time; invalid otherwise
44 int con_size_in_bytes, // object size in bytes if known at compile time
45 Register t1, // temp register
46 Register t2, // temp register
47 Label& slow_case // continuation point if fast allocation fails
48 );
49
50 void initialize_header(Register obj, Register klass, Register len, Register t1, Register t2);
51 void initialize_body(Register obj, Register len_in_bytes, int hdr_size_in_bytes, Register t1, Register t2);
52
53 void float_cmp(bool is_float, int unordered_result,
54 FloatRegister f0, FloatRegister f1,
55 Register result);
56
57 // locking
58 // hdr : must be r0, contents destroyed
59 // obj : must point to the object to lock, contents preserved
60 // disp_hdr: must point to the displaced header location, contents preserved
61 // temp : temporary register, must not be rscratch1 or rscratch2
62 // returns code offset at which to add null check debug information
63 int lock_object (Register swap, Register obj, Register disp_hdr, Register temp, Label& slow_case);
64
65 // unlocking
66 // hdr : contents destroyed
67 // obj : must point to the object to lock, contents preserved
68 // disp_hdr: must be r0 & must point to the displaced header location, contents destroyed
69 // temp : temporary register, must not be rscratch1 or rscratch2
70 void unlock_object(Register swap, Register obj, Register lock, Register temp, Label& slow_case);
71
72 void initialize_object(
73 Register obj, // result: pointer to object after successful allocation
74 Register klass, // object klass
75 Register var_size_in_bytes, // object size in bytes if unknown at compile time; invalid otherwise
76 int con_size_in_bytes, // object size in bytes if known at compile time
77 Register t1, // temp register
78 Register t2, // temp register
79 bool is_tlab_allocated // the object was allocated in a TLAB; relevant for the implementation of ZeroTLAB
80 );
81
82 // allocation of fixed-size objects
83 // (can also be used to allocate fixed-size arrays, by setting
84 // hdr_size correctly and storing the array length afterwards)
85 // obj : will contain pointer to allocated object
86 // t1, t2 : scratch registers - contents destroyed
87 // header_size: size of object header in words
88 // object_size: total size of object in words
89 // slow_case : exit to slow case implementation if fast allocation fails
90 void allocate_object(Register obj, Register t1, Register t2, int header_size, int object_size, Register klass, Label& slow_case);
|