6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation.
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "code/codeBlob.hpp"
27 #include "code/codeCache.hpp"
28 #include "code/relocInfo.hpp"
29 #include "compiler/disassembler.hpp"
30 #include "interpreter/bytecode.hpp"
31 #include "memory/allocation.inline.hpp"
32 #include "memory/heap.hpp"
33 #include "memory/resourceArea.hpp"
34 #include "oops/oop.inline.hpp"
35 #include "prims/forte.hpp"
36 #include "prims/jvm.h"
37 #include "runtime/handles.inline.hpp"
38 #include "runtime/interfaceSupport.hpp"
39 #include "runtime/mutexLocker.hpp"
40 #include "runtime/safepoint.hpp"
41 #include "runtime/sharedRuntime.hpp"
42 #include "runtime/vframe.hpp"
43 #include "services/memoryService.hpp"
44 #include "utilities/align.hpp"
45 #ifdef COMPILER1
46 #include "c1/c1_Runtime1.hpp"
47 #endif
48
49 const char* CodeBlob::compiler_name() const {
50 return compilertype2name(_type);
51 }
52
53 unsigned int CodeBlob::align_code_offset(int offset) {
54 // align the size to CodeEntryAlignment
55 return
56 ((offset + (int)CodeHeap::header_size() + (CodeEntryAlignment-1)) & ~(CodeEntryAlignment-1))
|
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation.
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "jvm.h"
27 #include "code/codeBlob.hpp"
28 #include "code/codeCache.hpp"
29 #include "code/relocInfo.hpp"
30 #include "compiler/disassembler.hpp"
31 #include "interpreter/bytecode.hpp"
32 #include "memory/allocation.inline.hpp"
33 #include "memory/heap.hpp"
34 #include "memory/resourceArea.hpp"
35 #include "oops/oop.inline.hpp"
36 #include "prims/forte.hpp"
37 #include "runtime/handles.inline.hpp"
38 #include "runtime/interfaceSupport.hpp"
39 #include "runtime/mutexLocker.hpp"
40 #include "runtime/safepoint.hpp"
41 #include "runtime/sharedRuntime.hpp"
42 #include "runtime/vframe.hpp"
43 #include "services/memoryService.hpp"
44 #include "utilities/align.hpp"
45 #ifdef COMPILER1
46 #include "c1/c1_Runtime1.hpp"
47 #endif
48
49 const char* CodeBlob::compiler_name() const {
50 return compilertype2name(_type);
51 }
52
53 unsigned int CodeBlob::align_code_offset(int offset) {
54 // align the size to CodeEntryAlignment
55 return
56 ((offset + (int)CodeHeap::header_size() + (CodeEntryAlignment-1)) & ~(CodeEntryAlignment-1))
|