mirror of
https://github.com/corda/corda.git
synced 2025-01-16 01:40:17 +00:00
Merge branch 'master' of dice:git/vm
This commit is contained in:
commit
00c611fcf9
@ -11,6 +11,10 @@ public class Hashtable<K, V> implements Map<K, V> {
|
||||
this(0);
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
return map.toString();
|
||||
}
|
||||
|
||||
public synchronized int size() {
|
||||
return map.size();
|
||||
}
|
||||
|
@ -32,8 +32,8 @@ public class LinkedList<T> implements List<T> {
|
||||
if (front == null) {
|
||||
front = rear = c;
|
||||
} else {
|
||||
c.prev = rear;
|
||||
rear = c;
|
||||
c.next = front;
|
||||
front = c;
|
||||
}
|
||||
}
|
||||
|
||||
@ -43,8 +43,8 @@ public class LinkedList<T> implements List<T> {
|
||||
if (front == null) {
|
||||
front = rear = c;
|
||||
} else {
|
||||
c.next = front;
|
||||
front = c;
|
||||
c.prev = rear;
|
||||
rear = c;
|
||||
}
|
||||
}
|
||||
|
||||
|
8
makefile
8
makefile
@ -173,6 +173,14 @@ debug-jscheme: $(executable) $(input)
|
||||
vg-jscheme: $(executable) $(input)
|
||||
LD_LIBRARY_PATH=$(bld) $(vg) $(<) -cp $(cls):$(jscheme) $(jscheme-command)
|
||||
|
||||
.PHONY: profile-jscheme
|
||||
profile-jscheme: $(executable) $(input)
|
||||
opcontrol --start; \
|
||||
echo '(+ 5 6)' | LD_LIBRARY_PATH=$(bld) \
|
||||
$(<) -cp $(cls):$(jscheme) jscheme/REPL; \
|
||||
opcontrol --stop; \
|
||||
opreport -l $(<)
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
@echo "removing build"
|
||||
|
@ -16,10 +16,11 @@ replace(char a, char b, char* c)
|
||||
jstring
|
||||
Object_toString(Thread* t, jobject this_)
|
||||
{
|
||||
unsigned hash = objectHash(t, *this_);
|
||||
object s = makeString
|
||||
(t, "%s@%p",
|
||||
(t, "%s@0x%x",
|
||||
&byteArrayBody(t, className(t, objectClass(t, *this_)), 0),
|
||||
*this_);
|
||||
hash);
|
||||
|
||||
return pushReference(t, s);
|
||||
}
|
||||
|
@ -744,7 +744,7 @@ bitsetSet(uintptr_t* p, unsigned i, bool v)
|
||||
}
|
||||
}
|
||||
|
||||
unsigned
|
||||
bool
|
||||
bitsetHasMore(uintptr_t* p)
|
||||
{
|
||||
switch (*p) {
|
||||
@ -770,7 +770,8 @@ bitsetHasMore(uintptr_t* p)
|
||||
unsigned
|
||||
bitsetNext(Context* c, uintptr_t* p)
|
||||
{
|
||||
assert(c, bitsetHasMore(p));
|
||||
bool more UNUSED = bitsetHasMore(p);
|
||||
assert(c, more);
|
||||
|
||||
switch (*p) {
|
||||
case 0: abort(c);
|
||||
|
@ -1708,12 +1708,14 @@ isAssignableFrom(Thread* t, object a, object b)
|
||||
if (classFlags(t, a) & ACC_INTERFACE) {
|
||||
for (; b; b = classSuper(t, b)) {
|
||||
object itable = classInterfaceTable(t, b);
|
||||
if (itable) {
|
||||
for (unsigned i = 0; i < arrayLength(t, itable); i += 2) {
|
||||
if (arrayBody(t, itable, i) == a) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (classArrayDimensions(t, a)) {
|
||||
if (classArrayDimensions(t, b)) {
|
||||
return isAssignableFrom
|
||||
|
Loading…
Reference in New Issue
Block a user