[PATCH] regression: add test for float array element load/store

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- regression/jvm/ArrayTest.java | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/regression/jvm/ArrayTest.java b/regression/jvm/ArrayTest.java index a76c3b5..bfada1a 100644 --- a/regression/jvm/ArrayTest.java +++ b/regression/jv

[PATCH] jit: fix split_interval_at to handle fixed intervals correctly

2009-08-06 Thread Arthur HUILLET
Signed-off-by: Arthur HUILLET --- jit/interval.c |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/jit/interval.c b/jit/interval.c index 8a7620f..9ad9d97 100644 --- a/jit/interval.c +++ b/jit/interval.c @@ -74,6 +74,10 @@ struct live_interval *split_interval_at(struct li

[PATCH 19/19] jit: fix convert_multianewarray()

2009-08-06 Thread Tomek Grabiec
It was using convert_args() to encapsulate array dimensions but now convert_args() got so tightly related to java method invocations that it can no longer be used. convert_native_args() is introduced to encapsulate dimensions which are later passed to native VM functions. Signed-off-by: Tomek Grab

[PATCH 17/19] vm: implement CallStaticBooleanMethod JNI function

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- vm/jni-interface.c | 18 +- 1 files changed, 17 insertions(+), 1 deletions(-) diff --git a/vm/jni-interface.c b/vm/jni-interface.c index 929fb8b..b80ab66 100644 --- a/vm/jni-interface.c +++ b/vm/jni-interface.c @@ -696,6 +696,22 @@ vm_jni_get_s

[PATCH 18/19] vm: implement CallVoidMethod JNI function

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- vm/jni-interface.c | 19 ++- 1 files changed, 18 insertions(+), 1 deletions(-) diff --git a/vm/jni-interface.c b/vm/jni-interface.c index b80ab66..4411f0a 100644 --- a/vm/jni-interface.c +++ b/vm/jni-interface.c @@ -712,6 +712,23 @@ vm_jni_call

[PATCH 16/19] vm: implement GetStaticDoubleField JNI function

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- include/vm/object.h | 12 vm/jni-interface.c | 21 - 2 files changed, 32 insertions(+), 1 deletions(-) diff --git a/include/vm/object.h b/include/vm/object.h index 1fc65ab..98490a3 100644 --- a/include/vm/object.h +++ b/incl

[PATCH 15/19] vm: introduce vm_jni_common_get_field_id()

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- vm/jni-interface.c | 21 + 1 files changed, 1 insertions(+), 20 deletions(-) diff --git a/vm/jni-interface.c b/vm/jni-interface.c index ce36470..405a90a 100644 --- a/vm/jni-interface.c +++ b/vm/jni-interface.c @@ -677,25 +677,6 @@ vm_jni_ge

[PATCH 12/19] regression: introduce jvm/DoubleArithmeticTest.java

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- Makefile |1 + regression/jvm/DoubleArithmeticTest.java | 168 ++ regression/jvm/TestCase.java |7 ++ regression/run-suite.sh |1 + 4 files changed, 177 insertio

[PATCH 14/19] vm: implement GetStaticDoubleFieldID JNI method

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- vm/jni-interface.c | 76 +++ 1 files changed, 46 insertions(+), 30 deletions(-) diff --git a/vm/jni-interface.c b/vm/jni-interface.c index ea255dc..ce36470 100644 --- a/vm/jni-interface.c +++ b/vm/jni-interface.c

[PATCH 13/19] vm: implement GetStaticFieldID JNI function

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- vm/jni-interface.c | 33 - 1 files changed, 32 insertions(+), 1 deletions(-) diff --git a/vm/jni-interface.c b/vm/jni-interface.c index 87ef59a..ea255dc 100644 --- a/vm/jni-interface.c +++ b/vm/jni-interface.c @@ -649,6 +649,37

[PATCH 07/19] x86: support for tracing J_DOUBLE and J_FLOAT return value.

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- arch/x86/insn-selector.brg | 27 +++ include/jit/compiler.h |2 +- jit/trace-jit.c|7 +++ 3 files changed, 27 insertions(+), 9 deletions(-) diff --git a/arch/x86/insn-selector.brg b/arch/x86/insn-selector.brg

[PATCH 11/19] jit: alloc temporary with correct register type in convert_array_load()

2009-08-06 Thread Tomek Grabiec
We should really care which vm_type we assign to registers. Not only it matters because FPU operations can be only done on SSE registers, but also in some situations the only way to get the result type is to query reg->vm_type (see OP_CMPG and OP_CMPL instruction selectors). Signed-off-by: Tomek G

[PATCH 10/19] x86: add DOUBLE <-> FLOAT conversion support

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- arch/x86/emit-code.c| 18 ++ arch/x86/include/arch/instruction.h |2 + arch/x86/insn-selector.brg | 65 +++--- arch/x86/lir-printer.c | 14 +++ arch/x86/use-def.c

[PATCH 08/19] x86: replace freg: EXPR_LOCAL with freg: EXPR_FLOAT_LOCAL

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- arch/x86/insn-selector.brg |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/x86/insn-selector.brg b/arch/x86/insn-selector.brg index c255438..5df7823 100644 --- a/arch/x86/insn-selector.brg +++ b/arch/x86/insn-selector.brg @@ -253,7

[PATCH 05/19] x86: implement double precision arithmetic

2009-08-06 Thread Tomek Grabiec
This adds support for most of double precision arithmetic. The only missing things are conversions which will be added in the following patches. Operations on doubles are made using SSE2 instructions. We want to emulate those operations when current system is not equiped with SSE2 capable process

[PATCH 09/19] x86: support for DOUBLE <-> INT conversion

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- arch/x86/emit-code.c| 18 ++ arch/x86/include/arch/instruction.h |2 ++ arch/x86/insn-selector.brg |8 arch/x86/lir-printer.c | 14 ++ arch/x86/use-def.c |

[PATCH 06/19] jit: add missing new line after J_DOUBLE and J_LONG args trace

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- jit/trace-jit.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/jit/trace-jit.c b/jit/trace-jit.c index b03108a..b8c2e0c 100644 --- a/jit/trace-jit.c +++ b/jit/trace-jit.c @@ -438,6 +438,8 @@ static void print_arg(enum vm_type arg_type,

[PATCH 03/19] jit: fix convert_ldc for CAFEBABE_CONSTANT_TAG_DOUBLE

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- jit/load-store-bc.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/jit/load-store-bc.c b/jit/load-store-bc.c index 7a80053..0a4ce7a 100644 --- a/jit/load-store-bc.c +++ b/jit/load-store-bc.c @@ -137,10 +137,8 @@ static int __convert

[PATCH 04/19] x86: introduce get_local_slot_64()

2009-08-06 Thread Tomek Grabiec
On x86 64-bit variables (eg. of type double) require 2 stack slots. We must return the one which has lower memory address so that we can correctly execute movsd instruction with that address. Signed-off-by: Tomek Grabiec --- arch/x86/insn-selector.brg | 24 1 files cha

[PATCH 01/19] x86: rename _FREG token in instruction names to _XMM

2009-08-06 Thread Tomek Grabiec
This renames INSN_MOV_FREG_MEMLOCAL and INSN_MOV_MEMLOCAL_FREG to INSN_MOV_XMM_MEMLOCAL and INSN_MOV_MEMLOCAL_XMM. All other instructions already use XMM to refer FPU registers. Signed-off-by: Tomek Grabiec --- arch/x86/emit-code.c|8 arch/x86/include/arch/instructio

[PATCH 02/19] x86: add instructions for double precision floating point operations with SSE2

2009-08-06 Thread Tomek Grabiec
Those instructions are needed to implement double precision arithmetic. Signed-off-by: Tomek Grabiec --- arch/x86/emit-code.c| 163 +++ arch/x86/include/arch/instruction.h | 16 arch/x86/lir-printer.c | 112 +++

[PATCH] test: fix 'make test' breakage

2009-08-06 Thread Tomek Grabiec
Signed-off-by: Tomek Grabiec --- test/arch-x86/emit-code-test_32.c |6 -- test/arch-x86/stack-frame-test_32.c | 12 +++- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/test/arch-x86/emit-code-test_32.c b/test/arch-x86/emit-code-test_32.c index 06cd9ba..45dca

[PATCH] vm: rename vm_object_alloc_{native -> primitive}_array

2009-08-06 Thread Vegard Nossum
Signed-off-by: Vegard Nossum --- arch/x86/insn-selector.brg |4 ++-- include/vm/object.h|2 +- vm/object.c|8 vm/stack-trace.c |2 +- vm/utf8.c |2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/arc

Re: [PATCH] jit: introduce per-cu lir -> insn mapping

2009-08-06 Thread Pekka Enberg
On Thu, 2009-08-06 at 16:13 +0200, Vegard Nossum wrote: > This fixes the performance issue in liveness analysis. > > Signed-off-by: Vegard Nossum Nice! Perf report looks like this now: # Overhead CommandShared Object Symbol # ...

[PATCH] jit: introduce per-cu lir -> insn mapping

2009-08-06 Thread Vegard Nossum
This fixes the performance issue in liveness analysis. Signed-off-by: Vegard Nossum --- include/jit/compilation-unit.h |7 +- include/jit/vars.h |3 -- jit/compilation-unit.c | 21 +++-- jit/interval.c | 25 + ji