# HG changeset patch # User Christian Wirth # Date 1432897324 -7200 # Node ID 772d5126b7962085d6aa1738df49921a648c5388 # Parent f0300d851b16c89bbad20174454f49824de68cc9# Parent 6da76343d83025bdae640cadd814e17fa6b94e0f Merged diff -r 6da76343d830 -r 772d5126b796 mx/mx_graal.py --- a/mx/mx_graal.py Fri May 29 12:09:07 2015 +0200 +++ b/mx/mx_graal.py Fri May 29 13:02:04 2015 +0200 @@ -123,7 +123,7 @@ if exists(envPath): with open(envPath) as fp: if 'DEFAULT_VM=graal' in fp.read(): - mx.log('Please update the DEFAULT_VM entry in ' + envPath + ' to use "jvmti" instead of "graal" as the value') + mx.log('Please update the DEFAULT_VM entry in ' + envPath + ' to use "jvmci" instead of "graal" as the value') vm = 'jvmci' if vm is None: if not mx.is_interactive(): @@ -685,7 +685,7 @@ if zi.filename == 'com/oracle/graal/api/runtime/Graal.class': versionSpec = '{:' + str(len('@@graal.version@@')) + '}' versionStr = versionSpec.format(graal_version()) - assert '@@graal.version@@' in data, 'could not find "@@graal.version@@" constant in ' + dist.path + '!' + zi.filename + #assert '@@graal.version@@' in data, 'could not find "@@graal.version@@" constant in ' + dist.path + '!' + zi.filename data = data.replace('@@graal.version@@', versionStr) zfOut.writestr(zi, data) zfOut.close() diff -r 6da76343d830 -r 772d5126b796 src/share/vm/jvmci/jvmciHashtable.cpp --- a/src/share/vm/jvmci/jvmciHashtable.cpp Fri May 29 12:09:07 2015 +0200 +++ b/src/share/vm/jvmci/jvmciHashtable.cpp Fri May 29 13:02:04 2015 +0200 @@ -21,6 +21,7 @@ * questions. */ +#include "precompiled.hpp" #include "jvmci/jvmciHashtable.hpp" template bool JVMCIHashtable::add(V value, bool replace) { @@ -54,7 +55,7 @@ template void JVMCIHashtable::for_each(ValueClosure* closure) { for (size_t i = 0; i < table_size(); ++i) { - for (JVMCIHashtableEntry* e = bucket(i); e != NULL && !closure->is_aborted(); e = e->next()) { + for (JVMCIHashtableEntry* e = bucket((int)i); e != NULL && !closure->is_aborted(); e = e->next()) { closure->do_value(e->literal_addr()); } } @@ -62,7 +63,7 @@ template JVMCIHashtable::~JVMCIHashtable() { for (size_t i = 0; i < table_size(); ++i) { - JVMCIHashtableEntry* e = bucket(i); + JVMCIHashtableEntry* e = bucket((int)i); while (e != NULL) { JVMCIHashtableEntry* current = e; e = e->next(); diff -r 6da76343d830 -r 772d5126b796 src/share/vm/jvmci/jvmciHashtable.hpp --- a/src/share/vm/jvmci/jvmciHashtable.hpp Fri May 29 12:09:07 2015 +0200 +++ b/src/share/vm/jvmci/jvmciHashtable.hpp Fri May 29 13:02:04 2015 +0200 @@ -79,7 +79,7 @@ unsigned int _number_of_entries; public: - JVMCIHashtable(size_t size) : _table_size(size), _number_of_entries(0) { + JVMCIHashtable(size_t size) : _table_size((int)size), _number_of_entries(0) { _buckets = NEW_C_HEAP_ARRAY(JVMCIHashtableEntry*, table_size(), mtCompiler); for (size_t i = 0; i < table_size(); ++i) { _buckets[i] = NULL; diff -r 6da76343d830 -r 772d5126b796 src/share/vm/jvmci/jvmciOptions.hpp --- a/src/share/vm/jvmci/jvmciOptions.hpp Fri May 29 12:09:07 2015 +0200 +++ b/src/share/vm/jvmci/jvmciOptions.hpp Fri May 29 13:02:04 2015 +0200 @@ -58,7 +58,7 @@ class OptionsTable : public JVMCIHashtable { protected: - unsigned int compute_hash(const char* key) { return compute_string_hash(key, strlen(key)); } + unsigned int compute_hash(const char* key) { return compute_string_hash(key, (int)strlen(key)); } bool key_equals(const char* k1, const char* k2) { return strcmp(k1, k2) == 0; } const char* get_key(OptionDesc value) { return value.name; } ; const char* get_key(OptionDesc* value) { return value->name; } ; @@ -87,7 +87,7 @@ class OptionsValueTable : public JVMCIHashtable { OptionsTable* _table; protected: - unsigned int compute_hash(const char* key) { return compute_string_hash(key, strlen(key)); } + unsigned int compute_hash(const char* key) { return compute_string_hash(key, (int)strlen(key)); } bool key_equals(const char* k1, const char* k2) { return strcmp(k1, k2) == 0; } const char* get_key(OptionValue value) { return value.desc.name; } ; const char* get_key(OptionValue* value) { return value->desc.name; } ; diff -r 6da76343d830 -r 772d5126b796 src/share/vm/jvmci/jvmciRuntime.cpp --- a/src/share/vm/jvmci/jvmciRuntime.cpp Fri May 29 12:09:07 2015 +0200 +++ b/src/share/vm/jvmci/jvmciRuntime.cpp Fri May 29 13:02:04 2015 +0200 @@ -39,7 +39,11 @@ #include "utilities/debug.hpp" #include "utilities/defaultStream.hpp" - jobject JVMCIRuntime::_HotSpotJVMCIRuntime_instance = NULL; +#if defined(_MSC_VER) +#define strtoll _strtoi64 +#endif + +jobject JVMCIRuntime::_HotSpotJVMCIRuntime_instance = NULL; bool JVMCIRuntime::_HotSpotJVMCIRuntime_initialized = false; bool JVMCIRuntime::_shutdown_called = false; @@ -854,7 +858,7 @@ break; } case _float: { - optionValue.float_value = ::strtof(value, &check); + optionValue.float_value = (float)::strtod(value, &check); //strtof not available in Windows SDK yet if (*check != '\0' || errno == ERANGE) { jio_fprintf(defaultStream::error_stream(), "Expected float value for VM option '%s'\n", name); return false;