changeset in /hg/icedtea: 2007-12-04 Gary Benson <gbenson at redh...
Gary Benson
gbenson at redhat.com
Tue Dec 4 01:24:56 PST 2007
changeset 97b0531d1956 in /hg/icedtea
details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=97b0531d1956
description:
2007-12-04 Gary Benson <gbenson at redhat.com>
* patches/icedtea-c1-unimplemented.patch: New file.
* Makefile.am (ICEDTEA_PATCHES): Add the above.
* Makefile.in: Regenerate.
* ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp
(is_simm, is_simm16): New methods.
* ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp
(RangeCheckStub::RangeCheckStub): Implement.
(NewInstanceStub::NewInstanceStub): Likewise.
(NewInstanceStub::emit_code): Re-stub.
* ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp
(pd_nof_cpu_regs_frame_map): Set.
(pd_nof_fpu_regs_frame_map): Likewise.
(pd_nof_caller_save_cpu_regs_frame_map): Likewise.
(pd_nof_caller_save_fpu_regs_frame_map): Likewise.
(pd_nof_cpu_regs_linearscan): Likewise.
(pd_nof_fpu_regs_linearscan): Likewise.
(pd_first_cpu_reg): Likewise.
(pd_last_cpu_reg): Likewise.
(pd_last_fpu_reg): Likewise.
* ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp
(gpr_opr, gpr_oop_opr, fpr_opr): New fields.
(as_long_opr): New method.
* ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp
(FrameMap::init): Partially implement.
(FrameMap::map_to_opr): Likewise.
(FrameMap::validate_frame): Likewise.
* ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.hpp
(emit_unimplemented): New method.
* ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp
(receiverOpr): Partially implement.
(initial_frame_size_in_bytes): Implement.
(check_icache): Re-stub.
(emit_exception_handler): Likewise.
(emit_deopt_handler): Likewise.
(align_call): Implement.
(call): Re-stub.
(const2mem): Likewise.
(const2reg): Likewise.
(reg2reg): Likewise.
(reg2mem): Likewise.
(return_op): Likewise.
(emit_static_call_stub): Likewise.
(shift_op): Likewise.
(emit_alloc_obj): Likewise.
(peephole): Implement.
(emit_unimplemented): New method.
* ports/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp
(load_byte_item): Implement.
(load_nonconstant): Likewise.
(result_register_for): Partially implement.
(can_store_as_constant): Implement.
(can_inline_as_constant): Likewise.
(generate_address): Implement.
(emit_array_address): Partially implement.
(cmp_reg_mem): Re-stub.
(strength_reduce_multiply): Implement.
(do_ArithmeticOp_Int): New method.
(do_ArithmeticOp): Partially implement.
(do_NewInstance): Likewise.
(do_BlockBegin): Re-stub.
(do_If): Likewise.
* ports/hotspot/src/cpu/ppc/vm/c1_LinearScan_ppc.cpp
(is_processed_reg_num): Partially implement.
(num_physical_regs): Likewise.
(requires_adjacent_regs): Implement.
(pd_add_temps): Likewise.
(pd_init_regs_for_alloc): Partially implement.
* ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.hpp
(pd_init): Implement.
* ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.cpp
(verified_entry): Re-stub.
(build_frame): Likewise.
* ports/hotspot/src/cpu/ppc/vm/c1_Runtime1_ppc.cpp
(generate_code_for): Re-stub.
* ports/hotspot/src/cpu/ppc/vm/nativeInst_ppc.hpp
(NativeJump::check_verified_entry_alignment): Implement.
(NativeJump::patch_verified_entry): Likewise.
* ports/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp
(out_preserve_stack_slots): Partially implement.
* ports/hotspot/src/cpu/ppc/vm/vmreg_ppc.cpp
(is_Register): New method.
(is_FloatRegister): Likewise.
(as_Register): Implement.
(as_FloatRegister): Likewise.
* ports/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp
(non_memory_address_word): Implement.
diffstat:
20 files changed, 1337 insertions(+), 554 deletions(-)
ChangeLog | 90 ++
Makefile.am | 1
Makefile.in | 1
patches/icedtea-c1-unimplemented.patch | 136 +++
ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp | 12
ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp | 18
ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp | 18
ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp | 61 +
ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp | 8
ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp | 578 ++++++-------
ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.hpp | 2
ports/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp | 692 ++++++++++------
ports/hotspot/src/cpu/ppc/vm/c1_LinearScan_ppc.cpp | 25
ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.cpp | 4
ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.hpp | 2
ports/hotspot/src/cpu/ppc/vm/c1_Runtime1_ppc.cpp | 199 ++++
ports/hotspot/src/cpu/ppc/vm/nativeInst_ppc.hpp | 8
ports/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp | 6
ports/hotspot/src/cpu/ppc/vm/vmreg_ppc.cpp | 25
ports/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp | 5
diffs (truncated from 2182 to 500 lines):
diff -r 62c402e6e198 -r 97b0531d1956 ChangeLog
--- a/ChangeLog Fri Nov 30 11:25:24 2007 -0500
+++ b/ChangeLog Tue Dec 04 04:24:44 2007 -0500
@@ -1,3 +1,93 @@ 2007-11-30 Gary Benson <gbenson at redhat
+2007-12-04 Gary Benson <gbenson at redhat.com>
+
+ * patches/icedtea-c1-unimplemented.patch: New file.
+ * Makefile.am (ICEDTEA_PATCHES): Add the above.
+ * Makefile.in: Regenerate.
+
+ * ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp
+ (is_simm, is_simm16): New methods.
+ * ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp
+ (RangeCheckStub::RangeCheckStub): Implement.
+ (NewInstanceStub::NewInstanceStub): Likewise.
+ (NewInstanceStub::emit_code): Re-stub.
+ * ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp
+ (pd_nof_cpu_regs_frame_map): Set.
+ (pd_nof_fpu_regs_frame_map): Likewise.
+ (pd_nof_caller_save_cpu_regs_frame_map): Likewise.
+ (pd_nof_caller_save_fpu_regs_frame_map): Likewise.
+ (pd_nof_cpu_regs_linearscan): Likewise.
+ (pd_nof_fpu_regs_linearscan): Likewise.
+ (pd_first_cpu_reg): Likewise.
+ (pd_last_cpu_reg): Likewise.
+ (pd_last_fpu_reg): Likewise.
+ * ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp
+ (gpr_opr, gpr_oop_opr, fpr_opr): New fields.
+ (as_long_opr): New method.
+ * ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp
+ (FrameMap::init): Partially implement.
+ (FrameMap::map_to_opr): Likewise.
+ (FrameMap::validate_frame): Likewise.
+ * ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.hpp
+ (emit_unimplemented): New method.
+ * ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp
+ (receiverOpr): Partially implement.
+ (initial_frame_size_in_bytes): Implement.
+ (check_icache): Re-stub.
+ (emit_exception_handler): Likewise.
+ (emit_deopt_handler): Likewise.
+ (align_call): Implement.
+ (call): Re-stub.
+ (const2mem): Likewise.
+ (const2reg): Likewise.
+ (reg2reg): Likewise.
+ (reg2mem): Likewise.
+ (return_op): Likewise.
+ (emit_static_call_stub): Likewise.
+ (shift_op): Likewise.
+ (emit_alloc_obj): Likewise.
+ (peephole): Implement.
+ (emit_unimplemented): New method.
+ * ports/hotspot/src/cpu/ppc/vm/c1_LIRGenerator_ppc.cpp
+ (load_byte_item): Implement.
+ (load_nonconstant): Likewise.
+ (result_register_for): Partially implement.
+ (can_store_as_constant): Implement.
+ (can_inline_as_constant): Likewise.
+ (generate_address): Implement.
+ (emit_array_address): Partially implement.
+ (cmp_reg_mem): Re-stub.
+ (strength_reduce_multiply): Implement.
+ (do_ArithmeticOp_Int): New method.
+ (do_ArithmeticOp): Partially implement.
+ (do_NewInstance): Likewise.
+ (do_BlockBegin): Re-stub.
+ (do_If): Likewise.
+ * ports/hotspot/src/cpu/ppc/vm/c1_LinearScan_ppc.cpp
+ (is_processed_reg_num): Partially implement.
+ (num_physical_regs): Likewise.
+ (requires_adjacent_regs): Implement.
+ (pd_add_temps): Likewise.
+ (pd_init_regs_for_alloc): Partially implement.
+ * ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.hpp
+ (pd_init): Implement.
+ * ports/hotspot/src/cpu/ppc/vm/c1_MacroAssembler_ppc.cpp
+ (verified_entry): Re-stub.
+ (build_frame): Likewise.
+ * ports/hotspot/src/cpu/ppc/vm/c1_Runtime1_ppc.cpp
+ (generate_code_for): Re-stub.
+ * ports/hotspot/src/cpu/ppc/vm/nativeInst_ppc.hpp
+ (NativeJump::check_verified_entry_alignment): Implement.
+ (NativeJump::patch_verified_entry): Likewise.
+ * ports/hotspot/src/cpu/ppc/vm/sharedRuntime_ppc.cpp
+ (out_preserve_stack_slots): Partially implement.
+ * ports/hotspot/src/cpu/ppc/vm/vmreg_ppc.cpp
+ (is_Register): New method.
+ (is_FloatRegister): Likewise.
+ (as_Register): Implement.
+ (as_FloatRegister): Likewise.
+ * ports/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp
+ (non_memory_address_word): Implement.
+
2007-11-30 Gary Benson <gbenson at redhat.com>
* ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp
diff -r 62c402e6e198 -r 97b0531d1956 Makefile.am
--- a/Makefile.am Fri Nov 30 11:25:24 2007 -0500
+++ b/Makefile.am Tue Dec 04 04:24:44 2007 -0500
@@ -204,6 +204,7 @@ ICEDTEA_PATCHES = \
patches/icedtea-linker-options.patch \
patches/icedtea-ports.patch \
patches/icedtea-lcms-leak.patch \
+ patches/icedtea-c1-unimplemented.patch \
$(FAST_BUILD_PATCH) \
$(DISTRIBUTION_PATCHES)
diff -r 62c402e6e198 -r 97b0531d1956 Makefile.in
--- a/Makefile.in Fri Nov 30 11:25:24 2007 -0500
+++ b/Makefile.in Tue Dec 04 04:24:44 2007 -0500
@@ -312,6 +312,7 @@ ICEDTEA_PATCHES = \
patches/icedtea-linker-options.patch \
patches/icedtea-ports.patch \
patches/icedtea-lcms-leak.patch \
+ patches/icedtea-c1-unimplemented.patch \
$(FAST_BUILD_PATCH) \
$(DISTRIBUTION_PATCHES)
diff -r 62c402e6e198 -r 97b0531d1956 patches/icedtea-c1-unimplemented.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/icedtea-c1-unimplemented.patch Tue Dec 04 04:24:44 2007 -0500
@@ -0,0 +1,136 @@
+--- openjdk-ecj/hotspot/src/share/vm/c1/c1_LIR.hpp 2007-12-03 09:55:25.000000000 +0000
++++ openjdk/hotspot/src/share/vm/c1/c1_LIR.hpp 2007-12-03 09:30:13.000000000 +0000
+@@ -656,6 +656,9 @@
+ class LIR_OpTypeCheck;
+ class LIR_OpCompareAndSwap;
+ class LIR_OpProfileCall;
++#ifdef PPC
++class LIR_OpUnimplemented;
++#endif
+
+
+ // LIR operation codes
+@@ -764,6 +767,11 @@
+ , begin_opMDOProfile
+ , lir_profile_call
+ , end_opMDOProfile
++#ifdef PPC
++ , begin_opUnimplemented
++ , lir_unimplemented
++ , end_opUnimplemented
++#endif
+ };
+
+
+@@ -898,6 +906,9 @@
+ virtual LIR_OpTypeCheck* as_OpTypeCheck() { return NULL; }
+ virtual LIR_OpCompareAndSwap* as_OpCompareAndSwap() { return NULL; }
+ virtual LIR_OpProfileCall* as_OpProfileCall() { return NULL; }
++#ifdef PPC
++ virtual LIR_OpUnimplemented* as_OpUnimplemented() { return NULL; }
++#endif
+
+ virtual void verify() const {}
+ };
+@@ -1579,6 +1590,24 @@
+ virtual void print_instr(outputStream* out) const PRODUCT_RETURN;
+ };
+
++#ifdef PPC
++// LIR_OpUnimplemented
++class LIR_OpUnimplemented : public LIR_Op {
++ private:
++ const char* _file;
++ const int _line;
++
++ public:
++ LIR_OpUnimplemented(const char* file, int line)
++ : LIR_Op(lir_unimplemented, LIR_OprFact::illegalOpr, NULL),
++ _file(file),
++ _line(line) {}
++
++ virtual void emit_code(LIR_Assembler* masm);
++ virtual LIR_OpUnimplemented* as_OpUnimplemented() { return this; }
++ virtual void print_instr(outputStream* out) const PRODUCT_RETURN;
++};
++#endif
+
+ class LIR_InsertionBuffer;
+
+@@ -1837,6 +1866,14 @@
+
+ // methodDataOop profiling
+ void profile_call(ciMethod* method, int bci, LIR_Opr mdo, LIR_Opr recv, LIR_Opr t1, ciKlass* cha_klass) { append(new LIR_OpProfileCall(lir_profile_call, method, bci, mdo, recv, t1, cha_klass)); }
++
++ // stubbing
++#ifdef PPC
++ void unimplemented(const char* file, int line)
++ {
++ append(new LIR_OpUnimplemented(file, line));
++ }
++#endif
+ };
+
+ void print_LIR(BlockList* blocks);
+--- openjdk-ecj/hotspot/src/share/vm/c1/c1_LIR.cpp 2007-12-03 09:55:25.000000000 +0000
++++ openjdk/hotspot/src/share/vm/c1/c1_LIR.cpp 2007-12-03 09:50:04.000000000 +0000
+@@ -861,6 +861,16 @@
+ break;
+ }
+
++#ifdef PPC
++// LIR_OpUnimplemented:
++ case lir_unimplemented: {
++ assert(op->as_OpUnimplemented() != NULL, "must be");
++ assert(op->_info == NULL, "info not used by this instruction");
++ assert(op->_result->is_illegal(), "not used");
++ break;
++ }
++#endif
++
+ default:
+ ShouldNotReachHere();
+ }
+@@ -1003,6 +1013,12 @@
+ masm->emit_profile_call(this);
+ }
+
++#ifdef PPC
++void LIR_OpUnimplemented::emit_code(LIR_Assembler* masm) {
++ masm->emit_unimplemented(_file, _line);
++}
++#endif
++
+
+ // LIR_List
+ LIR_List::LIR_List(Compilation* compilation, BlockBegin* block)
+@@ -1617,6 +1633,10 @@
+ case lir_cas_int: s = "cas_int"; break;
+ // LIR_OpProfileCall
+ case lir_profile_call: s = "profile_call"; break;
++#ifdef PPC
++ // LIR_OpUnimplemented
++ case lir_unimplemented: s = "unimplemented"; break;
++#endif
+
+ case lir_none: ShouldNotReachHere();break;
+ default: s = "illegal_op"; break;
+@@ -1869,6 +1889,18 @@
+ tmp1()->print(out); out->print(" ");
+ }
+
++#ifdef PPC
++// LIR_OpUnimplemented
++void LIR_OpUnimplemented::print_instr(outputStream* out) const {
++ char sep = os::file_separator()[0];
++ const char *file = strrchr(_file, sep);
++ if (file)
++ file++;
++ else
++ file = _file;
++ out->print("[%s:%d]", file, _line);
++}
++#endif // PPC
+
+ #endif // PRODUCT
+
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp
--- a/ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/assembler_ppc.hpp Tue Dec 04 04:24:44 2007 -0500
@@ -65,6 +65,18 @@ class Assembler : public AbstractAssembl
class Assembler : public AbstractAssembler {
public:
Assembler(CodeBuffer* code) : AbstractAssembler(code) {}
+
+ private:
+ static bool is_simm(int x, int nbits)
+ {
+ return -(1 << nbits - 1) <= x && x < (1 << nbits - 1);
+ }
+
+ public:
+ static bool is_simm16(int x)
+ {
+ return is_simm(x, 16);
+ }
private:
// Instruction emitters for the various forms.
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp
--- a/ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/c1_CodeStubs_ppc.cpp Tue Dec 04 04:24:44 2007 -0500
@@ -26,10 +26,14 @@
#include "incls/_precompiled.incl"
#include "incls/_c1_CodeStubs_ppc.cpp.incl"
+#define __ ce->masm()->
+
RangeCheckStub::RangeCheckStub(CodeEmitInfo* info, LIR_Opr index,
bool throw_index_out_of_bounds_exception)
+ : _throw_index_out_of_bounds_exception(throw_index_out_of_bounds_exception),
+ _index(index)
{
- Unimplemented();
+ _info = new CodeEmitInfo(info);
}
void RangeCheckStub::emit_code(LIR_Assembler* ce)
@@ -46,12 +50,20 @@ NewInstanceStub::NewInstanceStub(LIR_Opr
ciInstanceKlass* klass, CodeEmitInfo* info,
Runtime1::StubID stub_id)
{
- Unimplemented();
+ _result = result;
+ _klass = klass;
+ _klass_reg = klass_reg;
+ _info = new CodeEmitInfo(info);
+ assert(stub_id == Runtime1::new_instance_id ||
+ stub_id == Runtime1::fast_new_instance_id ||
+ stub_id == Runtime1::fast_new_instance_init_check_id,
+ "need new_instance id");
+ _stub_id = stub_id;
}
void NewInstanceStub::emit_code(LIR_Assembler* ce)
{
- Unimplemented();
+ __ unimplemented (__FILE__, __LINE__);
}
MonitorEnterStub::MonitorEnterStub(LIR_Opr obj_reg, LIR_Opr lock_reg,
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp
--- a/ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/c1_Defs_ppc.hpp Tue Dec 04 04:24:44 2007 -0500
@@ -40,27 +40,27 @@ enum {
enum {
#ifdef XXX_EVIL_EVIL_EVIL
// numbers of registers used during code emission
- pd_nof_cpu_regs_frame_map = 0,
- pd_nof_fpu_regs_frame_map = 0,
+ pd_nof_cpu_regs_frame_map = 32,
+ pd_nof_fpu_regs_frame_map = 32,
// numbers of registers killed by calls
- pd_nof_caller_save_cpu_regs_frame_map = 1,
- pd_nof_caller_save_fpu_regs_frame_map = 1,
+ pd_nof_caller_save_cpu_regs_frame_map = 11,
+ pd_nof_caller_save_fpu_regs_frame_map = 14,
// numbers of registers visible to register allocator
pd_nof_cpu_regs_reg_alloc = 0,
pd_nof_fpu_regs_reg_alloc = 0,
// numbers of registers visible to linear scan
- pd_nof_cpu_regs_linearscan = 0,
- pd_nof_fpu_regs_linearscan = 0,
+ pd_nof_cpu_regs_linearscan = 32,
+ pd_nof_fpu_regs_linearscan = 32,
pd_nof_xmm_regs_linearscan = 0,
// specifics
- pd_first_cpu_reg = 0,
- pd_last_cpu_reg = 0,
+ pd_first_cpu_reg = 3, // skip r0, r1 and r2
+ pd_last_cpu_reg = 30, // skip Rthread
pd_first_fpu_reg = 0,
- pd_last_fpu_reg = 0,
+ pd_last_fpu_reg = 31,
#endif
};
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp
--- a/ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.cpp Tue Dec 04 04:24:44 2007 -0500
@@ -26,22 +26,69 @@
#include "incls/_precompiled.incl"
#include "incls/_c1_FrameMap_ppc.cpp.incl"
-void FrameMap::init()
+LIR_Opr FrameMap::map_to_opr(BasicType type, VMRegPair* reg, bool)
{
- Unimplemented();
+ LIR_Opr opr = LIR_OprFact::illegalOpr;
+ VMReg r_1 = reg->first();
+ VMReg r_2 = reg->second();
+ if (r_1->is_stack()) {
+ Unimplemented();
+ }
+ else if (r_1->is_Register()) {
+ Register reg = r_1->as_Register();
+ if (r_2->is_Register()) {
+ Register reg2 = r_2->as_Register();
+ opr = as_long_opr(reg2, reg);
+ } else if (type == T_OBJECT) {
+ opr = as_oop_opr(reg);
+ } else {
+ opr = as_opr(reg);
+ }
+ }
+ else if (r_1->is_FloatRegister()) {
+ Unimplemented();
+ }
+ else {
+ ShouldNotReachHere();
+ }
+ return opr;
}
-LIR_Opr FrameMap::map_to_opr(BasicType type, VMRegPair* reg, bool)
-{
- Unimplemented();
-}
+LIR_Opr FrameMap::gpr_opr[];
+LIR_Opr FrameMap::gpr_oop_opr[];
+LIR_Opr FrameMap::fpr_opr[];
LIR_Opr FrameMap::_caller_save_cpu_regs[] = { 0, };
LIR_Opr FrameMap::_caller_save_fpu_regs[] = { 0, };
+void FrameMap::init()
+{
+ if (_init_done)
+ return;
+
+ for (int i = 0; i < nof_cpu_regs; i++) {
+ map_register(i, as_Register(i));
+ gpr_opr[i] = LIR_OprFact::single_cpu(i);
+ gpr_oop_opr[i] = LIR_OprFact::single_cpu_oop(i);
+ }
+
+ for (int i = 0, j = 0; j < nof_caller_save_cpu_regs; i++) {
+ if (i != 1 && i != 2)
+ _caller_save_cpu_regs[j++] = LIR_OprFact::single_cpu(i);
+ }
+
+ for (int i = 0; i < nof_caller_save_fpu_regs; i++) {
+ _caller_save_fpu_regs[i] = LIR_OprFact::single_fpu(i);
+ }
+
+ _init_done = true;
+}
+
bool FrameMap::validate_frame()
{
- Unimplemented();
+#ifdef XXX_EVIL_EVIL_EVIL
+ return true;
+#endif
}
VMReg FrameMap::fpu_regname(int n)
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp
--- a/ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/c1_FrameMap_ppc.hpp Tue Dec 04 04:24:44 2007 -0500
@@ -31,6 +31,14 @@
#endif
};
+ static LIR_Opr gpr_opr[nof_cpu_regs];
+ static LIR_Opr gpr_oop_opr[nof_cpu_regs];
+ static LIR_Opr fpr_opr[nof_fpu_regs];
+
+ static LIR_Opr as_long_opr(Register r, Register r2) {
+ return LIR_OprFact::double_cpu(cpu_reg2rnr(r), cpu_reg2rnr(r2));
+ }
+
static VMReg fpu_regname(int n);
static bool is_caller_save_register(LIR_Opr reg);
diff -r 62c402e6e198 -r 97b0531d1956 ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp
--- a/ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp Fri Nov 30 11:25:24 2007 -0500
+++ b/ports/hotspot/src/cpu/ppc/vm/c1_LIRAssembler_ppc.cpp Tue Dec 04 04:24:44 2007 -0500
@@ -26,73 +26,309 @@
#include "incls/_precompiled.incl"
#include "incls/_c1_LIRAssembler_ppc.cpp.incl"
+#define __ _masm->
+
+LIR_Opr LIR_Assembler::receiverOpr()
+{
+#ifdef XXX_EVIL_EVIL_EVIL
+ return FrameMap::gpr_oop_opr[3];
+#endif
+}
+
+LIR_Opr LIR_Assembler::osrBufferPointer()
+{
+ Unimplemented();
+}
+
+int LIR_Assembler::initial_frame_size_in_bytes()
+{
+ return in_bytes(frame_map()->framesize_in_bytes());
+}
+
+int LIR_Assembler::check_icache()
+{
+ __ unimplemented (__FILE__, __LINE__);
+}
+
+void LIR_Assembler::osr_entry()
+{
+ Unimplemented();
+}
+
+void LIR_Assembler::emit_exception_handler()
+{
+ compilation()->offsets()->set_value(CodeOffsets::Exceptions, code_offset());
More information about the distro-pkg-dev
mailing list