27
28 // This file holds the platform specific parts of the StubRoutines
29 // definition. See stubRoutines.hpp for a description on how to
30 // extend it.
31
32 static bool returns_to_call_stub(address return_pc) { return return_pc == _call_stub_return_address; }
33
34 // emit enum used to size per-blob code buffers
35
36 #define DEFINE_BLOB_SIZE(blob_name, size) \
37 _ ## blob_name ## _code_size = size,
38
39 enum platform_dependent_constants {
40 STUBGEN_ARCH_BLOBS_DO(DEFINE_BLOB_SIZE)
41 };
42
43 #undef DEFINE_BLOB_SIZE
44
45 class x86 {
46 friend class StubGenerator;
47 friend class VMStructs;
48
49 // declare fields for arch-specific entries
50
51 #define DECLARE_ARCH_ENTRY(arch, blob_name, stub_name, field_name, getter_name) \
52 static address STUB_FIELD_NAME(field_name) ;
53
54 #define DECLARE_ARCH_ENTRY_INIT(arch, blob_name, stub_name, field_name, getter_name, init_function) \
55 DECLARE_ARCH_ENTRY(arch, blob_name, stub_name, field_name, getter_name)
56
57 private:
58 STUBGEN_ARCH_ENTRIES_DO(DECLARE_ARCH_ENTRY, DECLARE_ARCH_ENTRY_INIT)
59
60 #undef DECLARE_ARCH_ENTRY_INIT
61 #undef DECLARE_ARCH_ENTRY
62
63
64 // define getters for arch-specific entries
65
66 #define DEFINE_ARCH_ENTRY_GETTER(arch, blob_name, stub_name, field_name, getter_name) \
|
27
28 // This file holds the platform specific parts of the StubRoutines
29 // definition. See stubRoutines.hpp for a description on how to
30 // extend it.
31
32 static bool returns_to_call_stub(address return_pc) { return return_pc == _call_stub_return_address; }
33
34 // emit enum used to size per-blob code buffers
35
36 #define DEFINE_BLOB_SIZE(blob_name, size) \
37 _ ## blob_name ## _code_size = size,
38
39 enum platform_dependent_constants {
40 STUBGEN_ARCH_BLOBS_DO(DEFINE_BLOB_SIZE)
41 };
42
43 #undef DEFINE_BLOB_SIZE
44
45 class x86 {
46 friend class StubGenerator;
47 friend class StubRoutines;
48 friend class VMStructs;
49
50 // declare fields for arch-specific entries
51
52 #define DECLARE_ARCH_ENTRY(arch, blob_name, stub_name, field_name, getter_name) \
53 static address STUB_FIELD_NAME(field_name) ;
54
55 #define DECLARE_ARCH_ENTRY_INIT(arch, blob_name, stub_name, field_name, getter_name, init_function) \
56 DECLARE_ARCH_ENTRY(arch, blob_name, stub_name, field_name, getter_name)
57
58 private:
59 STUBGEN_ARCH_ENTRIES_DO(DECLARE_ARCH_ENTRY, DECLARE_ARCH_ENTRY_INIT)
60
61 #undef DECLARE_ARCH_ENTRY_INIT
62 #undef DECLARE_ARCH_ENTRY
63
64
65 // define getters for arch-specific entries
66
67 #define DEFINE_ARCH_ENTRY_GETTER(arch, blob_name, stub_name, field_name, getter_name) \
|