Commit Graph

4138 Commits

Author SHA1 Message Date
Joshua Warner
9cb1f1bb26 Fix ci.sh tests on arm qemu systems
There are two problems:
* The x86 JIT compiler requires detectFeatures, defined in the x86 assembly.
  Thus it can't (currently) be built on non-x86 platforms.
  For the purposes of fixing test/ci.sh, it suffices to pretend
  codegen-targets=all means codegen-targets=native when on arm.
* Qemu can introduce some extra latency which was regularly screwing up the LinkedBlockingQueueTest.
  Solution: increase the timeout to 1/10th seconds.
2014-04-29 14:14:44 -06:00
Joel Dice
548d70b5e4 Merge pull request #248 from jentfoo/SortedMap_Interface
Added SortedMap interface
2014-04-29 13:57:15 -06:00
Joshua Warner
41adb74eb1 remove powerpc support 2014-04-29 13:26:40 -06:00
Mike Jensen
0545c07d33 Added SortedMap interface
I also changed TreeMap to implement the "SortedMap" interface, like it should.  Unfortanetly not all the code to implement the interface was there.  Where it was simple I implemented the additional functions, in the case of headMap, tailMap, subMap we are currently just throwing an UnsupportedOperationException.
2014-04-29 09:52:27 -06:00
Joshua Warner
32d25d79fd Merge pull request #243 from dicej/arm-non-ios
assume we can't use ARMv7 instructions on non-iOS platforms by default
2014-04-28 09:46:48 -06:00
Joel Dice
172ef9a7e6 Merge pull request #246 from joshuawarner32/master
Stop using *Critical functions in throwIOException
2014-04-24 19:40:10 -06:00
Joshua Warner
34962ff334 Merge pull request #245 from dicej/jdk8
add support for using the OpenJDK 8 class library
2014-04-24 18:50:38 -06:00
Joshua Warner
7f320b59b0 Merge pull request #241 from dicej/javadoc
push javadoc pages to ReadyTalk/readytalk.github.io instead of gh-pages
2014-04-24 18:49:32 -06:00
Joshua Warner
1b17ca146b Merge pull request #242 from dicej/copyright
update copyright years
2014-04-24 18:45:18 -06:00
Joshua Warner
3586481c8e Merge pull request #244 from dicej/url-set
avoid NPE in URL.set when file is null
2014-04-24 18:45:01 -06:00
Joshua Warner
690ba9cdc7 Stop using *Critical functions in throwIOException
This was a bug, wherein upon throwing an exception, we would try to
allocate memory for the message - all while holding a critical
reference to the jbyteArray representing the exception string.  This
caused an expect to fail in allocate3.
2014-04-24 15:23:05 -06:00
Joel Dice
2501929ccc assume we can't use ARMv7 instructions on non-iOS platforms by default
The only Linux/ARM machine I have access to does not support ARMv7.  I
don't know how common that is in general, but this seems like the safe
default.  You can always override it on the command line.

I've also broken the test target into build-test and run-test
subtargets, which can be useful when you're building on a shared
filesystem and running the tests on another machine (without using the
remote-test-host option).  If there's clock skew, the other machine
might try to rebuild stuff unecessarily.  Using run-test avoids
that.
2014-04-24 09:58:30 -06:00
Joel Dice
129626d91f add support for openjdk-src builds with OpenJDK 8
I've tested this on Linux with both OpenJDK 7 and 8.  Other platforms
will probably require further changes.
2014-04-23 17:09:52 -06:00
Joel Dice
3fc5e54a54 Merge pull request #240 from joshuawarner32/docker
Add basic docker image / util script for building
2014-04-23 16:50:44 -06:00
Joel Dice
a41efb76c5 avoid NPE in URL.set when file is null 2014-04-23 15:51:57 -06:00
Joshua Warner
08826580c5 improve Dockerfile with suggestions from code review 2014-04-23 14:41:44 -07:00
Joel Dice
7de555c797 add support for using the OpenJDK 8 class library
This ensures that all tests pass when Avian is built with an
openjdk=$path option such that $path points to either OpenJDK 7 or 8.

Note that I have not yet tried using the openjdk-src option with
OpenJDK 8.  I'll work on that next.
2014-04-23 15:36:56 -06:00
Joel Dice
9b7d0d1624 update copyright years 2014-04-23 15:33:41 -06:00
Joel Dice
7f646c8a38 push javadoc pages to ReadyTalk/readytalk.github.io instead of gh-pages
This, along with several other changes to the website, should help cut
repository bloat.
2014-04-23 15:32:16 -06:00
Joshua Warner
b2d242731a remove unnecessary intermediate apt-get update docker step 2014-04-23 13:28:33 -07:00
Joshua Warner
a0e7ed64d0 add script to run commands in the avian docker container 2014-04-23 12:55:23 -07:00
Joshua Warner
50bca071b2 Add basic dockerfile for avian build 2014-04-23 12:55:23 -07:00
Joshua Warner
5beb148df3 Merge pull request #239 from dicej/misc
fix Misc test failures
2014-04-21 19:50:52 -06:00
Joel Dice
4c3e0f3421 Merge pull request #238 from pcarrier/PsPN
CP: Properties.stringPropertyNames()
2014-04-20 19:24:10 -06:00
Joel Dice
1ed3de08fa fix Misc test failures
The Misc test was failing when run as "make input=Misc run" since
test-flags did not include $(build)/extra-dir in the class library,
leading the ClassLoader.getResources test to fail.

Also, the UnknownHostException test was not reliable -- some ISPs
(mine included) return DNS matches for bogus hostnames, defaulting to
the IP address of a webserver intended to help users with name
resolution problems.  That's dumb, I know, but I'm guessing I'm not
the only person with a dumb ISP, and it seems better to just remove
the test than make people think Avian is broken when it's really just
their DNS server that's broken.
2014-04-20 19:11:15 -06:00
Mike Jensen
1a8d557c72 Merge pull request #237 from pcarrier/sb
CP: StringBuilder.append(char[])
2014-04-20 08:04:47 -06:00
Pierre Carrier
91282a040f CP: StringBuilder.append(char[]) 2014-04-20 04:24:52 -07:00
Pierre Carrier
a36176baca CP: Properties.stringPropertyNames() 2014-04-20 04:24:14 -07:00
Joshua Warner
b01515ac84 Merge pull request #234 from dicej/field_getAnnotations
fix NPE in Field.getAnnotations
2014-04-17 15:18:07 -06:00
Joel Dice
b74f9e32e9 fix NPE in Field.getAnnotations 2014-04-17 13:16:21 -06:00
Joshua Warner
a6f0923678 Merge pull request #233 from jentfoo/RandomAccess_implements
Small change to make these two structures implement RandomAccess
2014-04-16 16:32:55 -06:00
Mike Jensen
7192b0081d Small change to make these two structures implement RandomAccess (as they should) 2014-04-16 14:33:32 -06:00
Joshua Warner
17f7754d2c Merge pull request #232 from dicej/readme
update "Quick Start" examples in README.md
2014-04-16 10:50:32 -06:00
Joel Dice
076cdc7cc8 update "Quick Start" examples in README.md
It's safer to assume developers are using x86_64 rather than x86_32
these days, and JAVA_HOME should be defined as
$(/usr/libexec/java_home) on OS X.
2014-04-16 08:36:21 -06:00
Joshua Warner
3cee8d1a5c Merge pull request #226 from dicej/android-bootimage
fix Android bootimage build
2014-04-13 13:22:37 -06:00
Joel Dice
a0d47c2f17 Merge pull request #230 from dscho/lastest-javadoc
Fix typo
2014-04-11 22:31:00 -06:00
Johannes Schindelin
5913dec6d7 Fix tyop
Let's not say 'lastest'. That would only confuse non-native speakears
such as yours truly.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2014-04-11 23:19:53 -05:00
Joshua Warner
2fff3a6e13 Merge pull request #229 from dicej/preBoot
fix broken Android build due to 617bd85
2014-04-11 21:54:34 -06:00
Joshua Warner
6a7ec612c3 Merge pull request #227 from dicej/flags
only define soname-flag and version-script-flag for openjdk builds
2014-04-11 21:45:42 -06:00
Joshua Warner
77dcb97bf0 Merge pull request #225 from dicej/javahome
fix incorrect EXPORT definition for Windows/x86_64 in boot-javahome.cpp
2014-04-11 21:40:38 -06:00
Joshua Warner
2c5208cb65 Merge pull request #228 from dicej/expect-executable
add expect call to ensure tryAllocateExecutable actually succeeds
2014-04-11 21:39:39 -06:00
Joel Dice
f21f11efd6 fix broken Android build due to 617bd85
617bd85 broke the Android build by creating an unresolvable
order-of-operations bug in classpath-android.cpp's
MyClasspath::preBoot method.

The problem is that, while JNIEnv::FindClass is supposed to initialize
the class that it finds, this causes JniConstants::init to indirectly
invoke native methods which are not registered until JNI_OnLoad is
called (which happens after JniConstants::init is called).  However,
if we call JNI_OnLoad first, that causes methods to be invoked which
rely on JniConstants::init having already been run.

I haven't checked to see how Dalvik handles this, but I don't see any
way around the problem besides disabling initialization by
JNIEnv::FindClass until the preBoot phase is complete.  Moreover, it's
dangerous to allow Java code to be invoked so early anyway, since the
VM is not yet fully initialized.
2014-04-11 19:56:52 -06:00
Joel Dice
1b8b27fb6b add expect call to ensure tryAllocateExecutable actually succeeds
For some reason, running Avian under the SVN version of Valgrind
caused mmap to fail, which caused tryAllocateExecutable to return a
null pointer, which led to a non-obvious crash later on.  Adding an
expect to check the result immediately will at least make it obvious
what went wrong.
2014-04-11 19:52:53 -06:00
Joel Dice
a71e75140e fix Android bootimage build
bb86500 was a step in the right direction, but there was a bug that
caused Type_pad fields to be inserted between every other field in for
a derived class when type-maps.cpp was generated, and this led to
miscompilation of e.g. Android's
java.lang.reflect.Constructor.getModifiers.
2014-04-11 19:48:06 -06:00
Joel Dice
e5ca66c305 only define soname-flag and version-script-flag for openjdk builds
These flags are only needed to ensure that libjvm.so can be used as a
drop-in replacement for OpenJDK's VM, and that only makes sense for
openjdk builds (without the openjdk-src option).  It didn't hurt
anything to define them unconditionally, but it was misleading.
2014-04-11 19:32:16 -06:00
Joel Dice
8f4ed4dd4f fix incorrect EXPORT definition for Windows/x86_64 in boot-javahome.cpp
We should define EXPORT to be __declspec(dllexport) on Windows
regardless of architecture, not just non-x86_64 arches.  This fixes
errors to to embedded JAVA_HOME files not being found in openjdk-src
builds, e.g. lib/currency.data.
2014-04-11 19:26:56 -06:00
Joshua Warner
f7614bf8a7 Merge pull request #224 from bigfatbrowncat/avian-pack
Properties don't work in some cases
2014-04-10 08:09:18 -06:00
Vasily Litvinov
74209edb7d Replacing strcpy with memcpy - should be slightly faster because we're forced to know strlen, so no need in byte-by-byte copying 2014-04-10 01:02:11 +04:00
Joshua Warner
23d1d7b07a Merge pull request #222 from elementalvoid/protect-gh-pages-token
Squash stdout/stderr in gh-pages push
2014-04-09 14:49:29 -06:00
Vasily Litvinov
647e22bf81 Fixed memory leak (which triggered asserts in tests) 2014-04-09 19:36:34 +04:00