diff src/share/vm/c1x/c1x_Compiler.cpp @ 1437:9e5e83ca2259

Enabled -C1X:OPTIONS when running HotSpot/C1X. Enabled checkstyle for the HotSpotVM Java project.
author Thomas Wuerthinger <wuerthinger@ssw.jku.at>
date Mon, 25 Oct 2010 16:47:52 +0200
parents 72cfb36c6bb2
children 1b7acf75f900
line wrap: on
line diff
--- a/src/share/vm/c1x/c1x_Compiler.cpp	Fri Oct 22 17:33:24 2010 +0200
+++ b/src/share/vm/c1x/c1x_Compiler.cpp	Mon Oct 25 16:47:52 2010 +0200
@@ -36,6 +36,7 @@
 // Initialization
 void C1XCompiler::initialize() {
   if (_initialized) return;
+  Thread* THREAD = Thread::current();
   _initialized = true;
   TRACE_C1X_1("C1XCompiler::initialize");
 
@@ -47,6 +48,16 @@
   check_pending_exception("Could not register natives");
 
   c1x_compute_offsets();
+
+  {
+    VM_ENTRY_MARK;
+    HandleMark hm;
+    for (int i = 0; i < Arguments::num_c1x_args(); ++i) {
+      const char* arg = Arguments::c1x_args_array()[i];
+      Handle option = java_lang_String::create_from_str(arg, THREAD);
+      VMExits::setOption(option);
+    }
+  }
 }
 
 // Compilation entry point for methods