#include "vm/vm.hpp"
#include "vmcore/options.h"
-#include "vmcore/system.h"
+#include "vmcore/os.hpp"
/* command line option ********************************************************/
opt_index++;
if (opt_index < vm_args->nOptions) {
- opt_arg = system_strdup(vm_args->options[opt_index].optionString);
+ opt_arg = os_strdup(vm_args->options[opt_index].optionString);
opt_index++;
return opts[i].value;
}
* parameter with no argument starting with same letter as param with argument
* but named after that one, ouch! */
- size_t l = system_strlen(opts[i].name);
+ size_t l = os_strlen(opts[i].name);
- if (system_strlen(option + 1) > l) {
+ if (os_strlen(option + 1) > l) {
if (memcmp(option + 1, opts[i].name, l) == 0) {
opt_index++;
- opt_arg = system_strdup(option + 1 + l);
+ opt_arg = os_strdup(option + 1 + l);
return opts[i].value;
}
}
switch (opt->type) {
case OPT_TYPE_BOOLEAN:
printf("+%s", opt->name);
- length = system_strlen(" -XX:+") + system_strlen(opt->name);
+ length = os_strlen(" -XX:+") + os_strlen(opt->name);
break;
case OPT_TYPE_VALUE:
printf("%s=<value>", opt->name);
- length = system_strlen(" -XX:") + system_strlen(opt->name) +
- system_strlen("=<value>");
+ length = os_strlen(" -XX:") + os_strlen(opt->name) +
+ os_strlen("=<value>");
break;
default:
/* Check documentation length. */
- length = system_strlen(opt->doc);
+ length = os_strlen(opt->doc);
if (length < (80 - 29)) {
printf("%s", opt->doc);
end = strchr(start, '=');
if (end == NULL) {
- length = system_strlen(start);
+ length = os_strlen(start);
value = NULL;
}
else {
in HotSpot). */
case OPT_MaxDirectMemorySize:
- opt_MaxDirectMemorySize = system_atoi(value);
+ opt_MaxDirectMemorySize = os_atoi(value);
break;
case OPT_MaxPermSize:
case OPT_InlineCount:
if (value != NULL)
- opt_InlineCount = system_atoi(value);
+ opt_InlineCount = os_atoi(value);
break;
case OPT_InlineMaxSize:
if (value != NULL)
- opt_InlineMaxSize = system_atoi(value);
+ opt_InlineMaxSize = os_atoi(value);
break;
case OPT_InlineMinSize:
if (value != NULL)
- opt_InlineMinSize = system_atoi(value);
+ opt_InlineMinSize = os_atoi(value);
break;
#endif
#endif
if (value == NULL)
opt_ProfileGCMemoryUsage = 5;
else
- opt_ProfileGCMemoryUsage = system_atoi(value);
+ opt_ProfileGCMemoryUsage = os_atoi(value);
break;
case OPT_ProfileMemoryUsage:
if (value == NULL)
opt_ProfileMemoryUsage = 5;
else
- opt_ProfileMemoryUsage = system_atoi(value);
+ opt_ProfileMemoryUsage = os_atoi(value);
# if defined(ENABLE_STATISTICS)
/* we also need statistics */
if (value == NULL)
opt_TraceInlining = 1;
else
- opt_TraceInlining = system_atoi(value);
+ opt_TraceInlining = os_atoi(value);
break;
#endif
if (value == NULL)
opt_TraceReplacement = 1;
else
- opt_TraceReplacement = system_atoi(value);
+ opt_TraceReplacement = os_atoi(value);
break;
#endif