signal handlers because
pthread_mutex_lock() is not reentrant. Using it from a signal handler
may result in a deadlock. This approach uses semaphores to notify GC
when a thread enters or leaves a safepoint.
Signed-off-by: Tomek Grabiec
---
arch/x86/include/arch/memory.h| 13 +++
include/vm/gc.h
handlers because
pthread_mutex_lock() is not reentrant. Using it from a signal handler
may result in a deadlock. This approach uses semaphores to notify GC
when a thread enters or leaves a safepoint. According to the manual
sem_post() is the only async-signal safe pthreads method.
Signed-off-by: Tomek
We need this to implement GC during which threads
should not be created nor deleted.
Signed-off-by: Tomek Grabiec
---
include/vm/thread.h |2 ++
vm/thread.c | 37 ++---
2 files changed, 32 insertions(+), 7 deletions(-)
diff --git a/include/vm
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg | 39 ++-
1 files changed, 18 insertions(+), 21 deletions(-)
diff --git a/arch/x86/insn-selector.brg b/arch/x86/insn-selector.brg
index 630af2f..5dea125 100644
--- a/arch/x86/insn-selector.brg
When jato receives SIGUSR2 all threads print their register
content and backtrace:
pkill -SIGUSR2 jato
Signed-off-by: Tomek Grabiec
---
arch/x86/backtrace.c | 23 +++-
include/vm/backtrace.h |1 +
vm/signal.c| 52
ler's frame. We must make it a macro becasue we can't rely on
__builtin_frame_address(1) because of gcc optimizations.
Signed-off-by: Tomek Grabiec
---
include/vm/stack-trace.h |8 +++-
test/vm/stack-trace-stub.c |4
vm/stack-trace.c |7 ---
3 f
SSE instructions have two prefixes depending on operand size:
0xf3 for 32-bit XMM and 0xf2 for 64-bit XMM.
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c |2 +-
regression/jvm/PutstaticPatchingTest.java | 36 -
2 files changed, 36
LIR position passed to radix_tree_lookup() should be always even.
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c |5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/jit/spill-reload.c b/jit/spill-reload.c
index 3dfb0b3..eaa2790 100644
--- a/jit/spill-reload.c
+++ b
Reported-by: Pekka Enberg
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/jit/spill-reload.c b/jit/spill-reload.c
index eaa2790..c7b3b51 100644
--- a/jit/spill-reload.c
+++ b/jit/spill-reload.c
@@ -225,7 +225,7
cases a container of insn list
head is returned. Therefore we can't get the bytecode offset by
dereferencing the result. A valid bytecode offset value is returned by
those function by setting a variable to which pointer is passed as an
argument.
Signed-off-by: Tomek Grabiec
---
jit/spill-rel
This changes the API and renames get_spill_after_insn() and
get_reload_before_insn() so that they do not return a pointer to
struct insn, since it is not always a pointer to struct insn.
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c | 57
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c | 20 +---
1 files changed, 9 insertions(+), 11 deletions(-)
diff --git a/jit/spill-reload.c b/jit/spill-reload.c
index c7b3b51..ba8ac27 100644
--- a/jit/spill-reload.c
+++ b/jit/spill-reload.c
@@ -168,20 +168,20
The if statement should be an assertion.
Reported-by: Pekka Enberg
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/jit/spill-reload.c b/jit/spill-reload.c
index 7624bd6..f8fd582 100644
--- a/jit/spill-reload.c
+++ b
) and get_reload_after_insn().
Signed-off-by: Tomek Grabiec
---
jit/spill-reload.c | 14 +++---
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/jit/spill-reload.c b/jit/spill-reload.c
index 3dfb0b3..7624bd6 100644
--- a/jit/spill-reload.c
+++ b/jit/spill-reload.c
@@ -49,11 +
ods do not perform the conversion.
Therefore it is now safe to use jbyte, jboolean, jchar and jshort as
VM native implementation return type.
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg | 32
1 files changed, 32 insertions(+), 0 deletions(-)
di
Signed-off-by: Tomek Grabiec
---
arch/mmix/call.c |6 +-
1 files changed, 1 insertions(+), 5 deletions(-)
diff --git a/arch/mmix/call.c b/arch/mmix/call.c
index 1dc640a..9c3f244 100644
--- a/arch/mmix/call.c
+++ b/arch/mmix/call.c
@@ -27,10 +27,6 @@
#include "vm/method.h"
Converter for dup_x2 didn't check the stack size of second
stack operand which caused that the forst value was put
one level deeper when second value was J_LONG or J_DOUBLE.
Signed-off-by: Tomek Grabiec
---
jit/ostack-bc.c |4
regression/jvm/DupTest.j |
Signed-off-by: Tomek Grabiec
---
arch/x86/call.c | 50 ++
include/vm/types.h |5 +++
regression/java/lang/reflect/MethodTest.java |5 +++
runtime/reflection.c |4 ++-
4 files
Signed-off-by: Tomek Grabiec
---
arch/x86/call.c | 180 ++---
include/vm/call.h |6 +--
vm/call.c |6 --
3 files changed, 62 insertions(+), 130 deletions(-)
diff --git a/arch/x86/call.c b/arch/x86/call.c
index 0b96020..389b1a6
Signed-off-by: Tomek Grabiec
---
include/runtime/classloader.h |1 +
include/vm/class.h|1 +
include/vm/classloader.h |1 +
include/vm/preload.h |1 +
runtime/classloader.c | 40 +++-
test/vm/preload-stub.c
Two different classloaders may load a class of the same name. We must
therefore make a classloader reference a part of class cache key.
Signed-off-by: Tomek Grabiec
---
include/lib/hash-map.h |1 +
include/vm/classloader.h |2 +-
lib/hash-map.c |5 +++
runtime
different classloaders. The former is always loaded
with bootstrap classloader (primitive array) while loading of the
latter can be initiated with any classloader. Class [[I must be
eventually loaded with bootstrap classloader too.
Signed-off-by: Tomek Grabiec
---
include/vm/types.h |6 ++
vm
Signed-off-by: Tomek Grabiec
---
Makefile |1 +
include/runtime/classloader.h | 10
runtime/classloader.c | 97 +
vm/jato.c | 66 +---
4 files changed, 109 insertions
The code didn't handle the case where exception handler range covers
the whole subroutine and more.
Signed-off-by: Tomek Grabiec
---
jit/subroutine.c | 180 ++
1 files changed, 127 insertions(+), 53 deletions(-)
diff --git a/jit/subrout
Signed-off-by: Tomek Grabiec
---
include/runtime/class.h |6 +++---
runtime/class.c |6 +++---
vm/jato.c |6 +++---
3 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/include/runtime/class.h b/include/runtime/class.h
index 50d1ec0..7691ac9 100644
--- a/
Signed-off-by: Tomek Grabiec
---
jit/exception.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/jit/exception.c b/jit/exception.c
index b412e25..8274eaa 100644
--- a/jit/exception.c
+++ b/jit/exception.c
@@ -352,7 +352,7 @@ print_exception_table(const struct vm_method
Signed-off-by: Tomek Grabiec
---
vm/reflection.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vm/reflection.c b/vm/reflection.c
index d97fec9..faf27bd 100644
--- a/vm/reflection.c
+++ b/vm/reflection.c
@@ -621,7 +621,7 @@ struct vm_object *native_field_get(struct
Signed-off-by: Tomek Grabiec
---
arch/x86/call.c |8
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/arch/x86/call.c b/arch/x86/call.c
index 717d53d..0b96020 100644
--- a/arch/x86/call.c
+++ b/arch/x86/call.c
@@ -137,7 +137,7 @@ void native_call(struct vm_method
Signed-off-by: Tomek Grabiec
---
regression/jvm/TestCase.java |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/regression/jvm/TestCase.java b/regression/jvm/TestCase.java
index fd00063..2a53a8b 100644
--- a/regression/jvm/TestCase.java
+++ b/regression/jvm/TestCase.java
We should perform the vm_method_is_special() check also when
public_only == false;
Signed-off-by: Tomek Grabiec
---
vm/reflection.c | 23 ++-
1 files changed, 10 insertions(+), 13 deletions(-)
diff --git a/vm/reflection.c b/vm/reflection.c
index 6d03a57..d97fec9 100644
Signed-off-by: Tomek Grabiec
---
regression/jvm/MethodTest.java | 20 +++-
1 files changed, 19 insertions(+), 1 deletions(-)
diff --git a/regression/jvm/MethodTest.java b/regression/jvm/MethodTest.java
index c633f8c..b805da4 100644
--- a/regression/jvm/MethodTest.java
+++ b
While at it, make it more robust by using valueOf() functions.
Signed-off-by: Tomek Grabiec
---
include/vm/preload.h |8 +++
vm/preload.c | 56 ++
vm/reflection.c | 153 --
3 files changed, 124 insertions(+), 93
Those functions should return values wrapped in approptiate objects,
not the value itself. This caused a SIGSEGV when running clojure
because an integer value was accessed like an object reference.
Signed-off-by: Tomek Grabiec
---
vm/reflection.c |4 ++--
1 files changed, 2 insertions(+), 2
saved. This way we can use vm_call_method_*() functions in a machine
and type independed way.
While at it, implement JNI funciton families:
CallStatic*Method()
CallStatic*MethodV()
Call*Method()
Signed-off-by: Tomek Grabiec
---
arch/x86/call.c| 222
Signed-off-by: Tomek Grabiec
---
include/vm/preload.h |2 ++
vm/preload.c | 14 ++
vm/reflection.c |7 ++-
3 files changed, 22 insertions(+), 1 deletions(-)
diff --git a/include/vm/preload.h b/include/vm/preload.h
index c71d8f9..a99fa89 100644
--- a
[main][ 359 ] 0xb0 areturn
Signed-off-by: Tomek Grabiec
---
jit/bytecode-to-ir.c |3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/jit/bytecode-to-ir.c b/jit/bytecode-to-ir.c
index a93a2ca..5f66587 100644
--- a/jit/bytecode-to-ir.c
+++ b/jit/bytecode-to-ir.c
@@ -434,6
The API spec says we shouldn't do so.
Signed-off-by: Tomek Grabiec
---
include/vm/method.h |5 +
vm/reflection.c |6 +-
2 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/include/vm/method.h b/include/vm/method.h
index ccf1db8..7c9e0d7 100644
--- a/inclu
Signed-off-by: Tomek Grabiec
---
vm/reflection.c |8
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/vm/reflection.c b/vm/reflection.c
index c7fc9e5..d0bff58 100644
--- a/vm/reflection.c
+++ b/vm/reflection.c
@@ -624,7 +624,7 @@ jint
due to register
corruption, which prevented java.awt.image.Raster.createWritableRaster()
from correct working.
Signed-off-by: Tomek Grabiec
---
jit/linear-scan.c | 14 ++
1 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/jit/linear-scan.c b/jit/linear-scan.c
index
'This' pointer was not passed to vm_call_method_this_a() in args which
caused a SIGSEGV inside that function.
Signed-off-by: Tomek Grabiec
---
vm/call.c |1 +
vm/reflection.c |6 --
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/vm/call.c b/vm/ca
'This' pointer must be added to args manually. vm_call_method_this_a()
expects that it is already in args to avoid unnecessary copying.
Signed-off-by: Tomek Grabiec
---
vm/call.c |6 +-
vm/reflection.c |3 ++-
2 files changed, 7 insertions(+), 2 deletions(-)
diff
The bracket was misplaced causing close() to use wrong file descriptor.
This led to the following error message for tetris:
.: Fatal IO error 9 (Bad file descriptor) on X server :0.0.
CC: Vegard Nossum
Signed-off-by: Tomek Grabiec
---
cafebabe/src/cafebabe/stream.c |2 +-
1 files changed
Signed-off-by: Tomek Grabiec
---
vm/jni-interface.c | 52 ++--
1 files changed, 26 insertions(+), 26 deletions(-)
diff --git a/vm/jni-interface.c b/vm/jni-interface.c
index b3b205e..ac8188f 100644
--- a/vm/jni-interface.c
+++ b/vm/jni
The condition should be negated.
Signed-off-by: Tomek Grabiec
---
vm/jni-interface.c |6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/vm/jni-interface.c b/vm/jni-interface.c
index cc1e7ca..dca174a 100644
--- a/vm/jni-interface.c
+++ b/vm/jni-interface.c
@@ -912,12
Those functions were using non-static field setters on a class object,
which is incorrect.
Signed-off-by: Tomek Grabiec
---
vm/jni-interface.c | 20 ++--
1 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/vm/jni-interface.c b/vm/jni-interface.c
index 7e502b7
We should call the constructor virtually not statically.
Signed-off-by: Tomek Grabiec
---
vm/jni-interface.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vm/jni-interface.c b/vm/jni-interface.c
index ac8188f..cc1e7ca 100644
--- a/vm/jni-interface.c
+++ b/vm/jni
0x1EEF47A7: ???
==6229==by 0x1EEF47A7: ???
==6229== Address 0x1f0d51f8 is not stack'd, malloc'd or (recently) free'd
Signed-off-by: Tomek Grabiec
---
vm/jni-interface.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vm/jni-interface.c b/vm/jni-in
The following natives are implemented:
java/lang/VMThread.isInterrupted()
java/lang/VMThread.interrupted()
java/lang/VMThread.interrupt()
Signed-off-by: Tomek Grabiec
---
Makefile|1 +
include/vm/preload.h|1 +
include/vm/thread.h |7
ntrol to the exception handler or
unwind. The workaround is to inline exception check and don't use
signal handlers when run on valgrind.
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg |9 +++--
arch/x86/unwind_32.S | 27 +++
include/jit/e
Call arguments were incorrectly inserted to args list causing the list
to represent the reverse order of arguments.
Signed-off-by: Tomek Grabiec
---
vm/types.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/vm/types.c b/vm/types.c
index e20aecf..f4fe84d 100644
--- a
Signed-off-by: Tomek Grabiec
---
vm/monitor.c | 78 +
1 files changed, 34 insertions(+), 44 deletions(-)
diff --git a/vm/monitor.c b/vm/monitor.c
index 4a22584..5705954 100644
--- a/vm/monitor.c
+++ b/vm/monitor.c
@@ -141,10 +141,9
Signed-off-by: Tomek Grabiec
---
Makefile |1 +
include/vm/object.h|1 +
test/arch-x86/Makefile |1 +
vm/jato.c |1 +
vm/monitor.c | 242
vm/object.c| 191
sulated in struct vm_method_arg and linked in a list
pointed by struct vm_method.args.
This change removes plenty of calls to type string parsing which
should not be done at run-time but rather on method or field
initialization.
Signed-off-by: Tomek Grabiec
---
include/jit/expression.h
Signed-off-by: Tomek Grabiec
---
include/vm/reflection.h |1 +
vm/jato.c |1 +
vm/reflection.c | 18 ++
3 files changed, 20 insertions(+), 0 deletions(-)
diff --git a/include/vm/reflection.h b/include/vm/reflection.h
index f9c709a..c1e3aa4 100644
We need valgrind headers to compile jato, since valgrind workarounds
were introduced.
Signed-off-by: Tomek Grabiec
---
README |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/README b/README
index 03985d6..97a9467 100644
--- a/README
+++ b/README
@@ -13,7 +13,7 @@ How
0x88D73CC: ???
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c | 12 +++-
arch/x86/insn-selector.brg |6 +++---
include/jit/compilation-unit.h |1 +
include/jit/compiler.h | 11 +--
jit/compilation-unit.c | 18 ++
CE because it could cause that integers
would be interpreted as pointers. I think the proper solution would be
to iterate over method's call argument types, and for argument type T
we should allocate register of type mimic_stack_type(T). I also think
that we only have to emit movs for registers
.
Invocations are now handled as statements and their result is pushed
onto mimic stack.
Signed-off-by: Tomek Grabiec
---
Makefile |5 +-
arch/x86/insn-selector.brg | 236 ++
include/jit/expression.h | 48 +-
include/jit
oblems with GC.
Signed-off-by: Tomek Grabiec
---
include/jit/basic-block.h |9
include/lib/stack.h | 11 +-
jit/basic-block.c |1 +
jit/bytecode-to-ir.c | 50
lib/stack.c | 17 +++
Signed-off-by: Tomek Grabiec
---
include/jit/basic-block.h |2 +-
jit/basic-block.c |6 +++---
jit/exception-bc.c|2 +-
jit/invoke-bc.c |4 ++--
4 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/include/jit/basic-block.h b/include/jit/basic
This way, the order of basic blocks matches the values of .start and .end
It also makes created basic blocks have empty bytecode range (start == end).
Signed-off-by: Tomek Grabiec
---
jit/basic-block.c |2 +-
jit/switch-bc.c |6 +++---
test/jit/basic-block-test.c
We must set that flag so that mimic stack resolution will put moves
before branch instructions.
Signed-off-by: Tomek Grabiec
---
jit/switch-bc.c |7 ---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/jit/switch-bc.c b/jit/switch-bc.c
index b1ece1a..fb3fef2 100644
--- a
Signed-off-by: Tomek Grabiec
---
include/lib/stack.h |2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/include/lib/stack.h b/include/lib/stack.h
index 7ec599d..aa60109 100644
--- a/include/lib/stack.h
+++ b/include/lib/stack.h
@@ -7,6 +7,8 @@
#include
#include
Signed-off-by: Tomek Grabiec
---
test/jit/basic-block-test.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/test/jit/basic-block-test.c b/test/jit/basic-block-test.c
index 7195487..a22d3bf 100644
--- a/test/jit/basic-block-test.c
+++ b/test/jit/basic-block-test.c
We must set that flag so that mimic stack resolution will put moves
before branch instructions.
Signed-off-by: Tomek Grabiec
---
jit/switch-bc.c |7 ---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/jit/switch-bc.c b/jit/switch-bc.c
index b1ece1a..fb3fef2 100644
--- a
is
defined. The register appears to be always live before it's use
position, which is wrong, and could cause problems with GC.
Signed-off-by: Tomek Grabiec
---
include/jit/basic-block.h |3 ++
include/lib/stack.h | 24 +-
jit/bytecode
This way, the order of basic blocks matches the values of .start and .end
It also makes created basic blocks have empty bytecode range (start == end).
Signed-off-by: Tomek Grabiec
---
jit/basic-block.c |2 +-
jit/switch-bc.c |6 +++---
2 files changed, 4 insertions(+), 4 deletions
Signed-off-by: Tomek Grabiec
---
include/jit/basic-block.h |2 +-
jit/basic-block.c |6 +++---
jit/exception-bc.c|2 +-
jit/invoke-bc.c |4 ++--
4 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/include/jit/basic-block.h b/include/jit/basic
2009/9/1 Pekka Enberg :
> Hi Tomek,
>
> On Tue, 2009-09-01 at 10:06 +0200, Tomek Grabiec wrote:
>> It disables buffering of strings passed to trace_printf().
>>
>> Signed-off-by: Tomek Grabiec
>
> Does something like this work for your scenario?
>
>
It is incorrect to write or read from memory below %esp. This patch
fixes valgrind complaints about access of uninitilized data.
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg | 152 +++-
1 files changed, 80 insertions(+), 72 deletions
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c | 16 +---
1 files changed, 1 insertions(+), 15 deletions(-)
diff --git a/arch/x86/emit-code.c b/arch/x86/emit-code.c
index a99296c..e1eb5ba 100644
--- a/arch/x86/emit-code.c
+++ b/arch/x86/emit-code.c
@@ -861,21 +861,7
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c| 24
arch/x86/include/arch/instruction.h |4
arch/x86/lir-printer.c | 28
arch/x86/use-def.c | 12
4 files
They are needed to hold temporary results when register can not be used.
Signed-off-by: Tomek Grabiec
---
include/jit/compilation-unit.h | 20 +++-
jit/compilation-unit.c | 16
2 files changed, 35 insertions(+), 1 deletions(-)
diff --git a/include
It disables buffering of strings passed to trace_printf().
Signed-off-by: Tomek Grabiec
---
include/vm/trace.h |2 ++
vm/jato.c |7 +++
vm/trace.c |9 -
3 files changed, 17 insertions(+), 1 deletions(-)
diff --git a/include/vm/trace.h b/include/vm
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c|9 -
arch/x86/include/arch/instruction.h |2 ++
arch/x86/instruction.c | 12
arch/x86/lir-printer.c | 14 ++
arch/x86/use-def.c |1
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg | 30 --
1 files changed, 16 insertions(+), 14 deletions(-)
diff --git a/arch/x86/insn-selector.brg b/arch/x86/insn-selector.brg
index 2e7367f..85f2fa6 100644
--- a/arch/x86/insn-selector.brg
+++ b/arch
liveness().
Signed-off-by: Tomek Grabiec
---
include/jit/vars.h | 18 --
jit/interval.c | 41 +++--
jit/linear-scan.c | 15 +++
3 files changed, 42 insertions(+), 32 deletions(-)
diff --git a/include/jit/vars.h b/include/jit/vars
Jato can be compiled with workarounds which make valgrind
work with jato.
To do so, define VALGRIND variable for make:
make jato VALGRIND=y
Currently workarounds eliminate class initialization
from signal handler by unconditionally selecting
calls to vm_class_ensure_init().
Signed-off-by: Tomek
those registers. For example, we do not have to
check at which position XMM0 register is available if we are
allocating a general purpose register.
Signed-off-by: Tomek Grabiec
---
jit/linear-scan.c |9 +
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/jit/linear-scan.c
Those register are not considered for allocation and their numbers are
> NR_REGISTERS. Letting those fixed intervals into register allocator
can cause memory corruption becuase use position arrays are of size
NR_REGISTERS.
Signed-off-by: Tomek Grabiec
---
jit/linear-scan.c |9 ++---
Signed-off-by: Tomek Grabiec
---
jit/trace-jit.c |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/jit/trace-jit.c b/jit/trace-jit.c
index 58ecaa4..915571d 100644
--- a/jit/trace-jit.c
+++ b/jit/trace-jit.c
@@ -360,6 +360,7 @@ void trace_regalloc(struct compilation_unit
This cleans handling of 64-bit stack slots up and fixes the buggy spilling code.
We always allocated 32-bit spill slot regardless of register type which caused
memory corruption.
Signed-off-by: Tomek Grabiec
---
arch/mmix/include/arch/instruction.h | 15 +-
arch/mmix/instruction.c
We do not longer need to do this because this bug has been solved:
http://jato.lighthouseapp.com/projects/29055/tickets/5-sse-registers-are-saved-and-registered-unconditionally
Signed-off-by: Tomek Grabiec
---
arch/x86/emit-code.c| 83 ---
arch
; this can be optimized out in the future
add ebx, ebx
Signed-off-by: Tomek Grabiec
---
arch/x86/include/arch/instruction.h |5 --
arch/x86/instruction.c |5 ++
arch/x86/use-def.c | 28 +++
include/jit/instruction.h |6 +++
i
This is a bug fix. The bug caused that floating point variables were
spilled as if they were a general purpose registers which led to
corruption of general purpose registers.
Signed-off-by: Tomek Grabiec
---
jit/compilation-unit.c |4 ++--
jit/interval.c |1 +
jit/spill-reload.c
This fixes the follwing bug:
http://jato.lighthouseapp.com/projects/29055/tickets/7-ebcdx-are-unavailable-for-allocation-after-some-call-instructions
Signed-off-by: Tomek Grabiec
---
arch/mmix/include/arch/instruction.h |5 +
arch/mmix/include/arch/registers.h |3 +++
arch/mmix
This is needed for precise modeling of live ranges.
Signed-off-by: Tomek Grabiec
---
include/jit/vars.h | 83 +---
jit/interval.c | 228 +-
jit/linear-scan.c | 51 ++
jit/liveness.c
Signed-off-by: Tomek Grabiec
---
arch/mmix/include/arch/instruction.h |8
arch/x86/include/arch/instruction.h |8
arch/x86/instruction.c |3 +--
arch/x86/use-def.c |2 +-
include/jit/instruction.h| 10
t be used in place of regular virtual registers.
Signed-off-by: Tomek Grabiec
---
arch/x86/insn-selector.brg | 134 ++--
1 files changed, 79 insertions(+), 55 deletions(-)
diff --git a/arch/x86/insn-selector.brg b/arch/x86/insn-selector.brg
index 8522667..
Signed-off-by: Tomek Grabiec
---
jit/linear-scan.c | 86 +++--
1 files changed, 37 insertions(+), 49 deletions(-)
diff --git a/jit/linear-scan.c b/jit/linear-scan.c
index 5538bc7..8baa914 100644
--- a/jit/linear-scan.c
+++ b/jit/linear-scan.c
Signed-off-by: Tomek Grabiec
---
jit/trace-jit.c |4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/jit/trace-jit.c b/jit/trace-jit.c
index 0246c3b..1bde5e1 100644
--- a/jit/trace-jit.c
+++ b/jit/trace-jit.c
@@ -811,8 +811,10 @@ void trace_return_value(struct vm_method
positions are even yet.
Signed-off-by: Tomek Grabiec
---
include/jit/compilation-unit.h |2 +
include/jit/vars.h | 10 +
jit/compilation-unit.c |4 ++-
jit/liveness.c |4 +-
jit/spill-reload.c | 16 +++--
jit/t
Selected code was adding 4 bytes too much to ESP, which led to
a memory corruption.
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 d7f506b
The values of .start_insn and .end_insn can be computed in
compute_insn_positions().
Signed-off-by: Tomek Grabiec
---
jit/compilation-unit.c |4
jit/liveness.c | 17 -
2 files changed, 4 insertions(+), 17 deletions(-)
diff --git a/jit/compilation-unit.c b
Signed-off-by: Tomek Grabiec
---
include/jit/compilation-unit.h |1 -
jit/compilation-unit.c | 15 ---
2 files changed, 0 insertions(+), 16 deletions(-)
diff --git a/include/jit/compilation-unit.h b/include/jit/compilation-unit.h
index 66aef32..f6fb0e9 100644
--- a
Signed-off-by: Tomek Grabiec
---
jit/compiler.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/jit/compiler.c b/jit/compiler.c
index 645e9b2..1fa321a 100644
--- a/jit/compiler.c
+++ b/jit/compiler.c
@@ -66,7 +66,7 @@ int compile(struct compilation_unit *cu
before the slot was
assigned a correct value.
Empty basic blocks can be a result of the following bytecode:
iconst_0
iconst_1
ifeq lab
pop // This and the next instruction generate no
iconst_1 // LIR instructions.
lab:
Cc: Arthur HUILLET
Signed-off-by: Tomek Grabiec
---
i
INSN_RET should be considered a branch because it jumps to different
basic block. It is used in LIR for athrow.
Signed-off-by: Tomek Grabiec
---
arch/x86/include/arch/instruction.h |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/arch/x86/include/arch/instruction.h
b
Signed-off-by: Tomek Grabiec
---
include/jit/instruction.h | 12
1 files changed, 12 insertions(+), 0 deletions(-)
create mode 100644 include/jit/instruction.h
diff --git a/include/jit/instruction.h b/include/jit/instruction.h
new file mode 100644
index 000..376e278
2009/8/19 Pekka Enberg :
> Hi Tomek,
>
> On Tue, 2009-08-18 at 21:21 +0200, Tomek Grabiec wrote:
>> Like I said on IRC, this will not work for empty basic blocks, because
>> spill_at_insn will belong to the preceding
>> basic block. This causes that instructions
1 - 100 of 801 matches
Mail list logo