Improved performance of garbage collection by moving the function that updates pointers during compacting collection into the updating visitor.  This gives the compiler a better chance to inline and avoid a function call per (potential) pointer.

Extended the shell sample with a --runtime-flags option.

Added Visual Studio project files for the shell.cc and process.cc samples.



git-svn-id: http://v8.googlecode.com/svn/trunk@14 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/public/v8.h b/public/v8.h
index d2412a1..4a5381e 100644
--- a/public/v8.h
+++ b/public/v8.h
@@ -462,17 +462,17 @@
  */
 class ScriptOrigin {
  public:
-  ScriptOrigin(Handle<String> resource_name,
+  ScriptOrigin(Handle<Value> resource_name,
                Handle<Integer> resource_line_offset = Handle<Integer>(),
                Handle<Integer> resource_column_offset = Handle<Integer>())
       : resource_name_(resource_name),
         resource_line_offset_(resource_line_offset),
         resource_column_offset_(resource_column_offset) { }
-  inline Handle<String> ResourceName();
+  inline Handle<Value> ResourceName();
   inline Handle<Integer> ResourceLineOffset();
   inline Handle<Integer> ResourceColumnOffset();
  private:
-  Handle<String> resource_name_;
+  Handle<Value> resource_name_;
   Handle<Integer> resource_line_offset_;
   Handle<Integer> resource_column_offset_;
 };
@@ -493,6 +493,13 @@
                                ScriptOrigin* origin = NULL,
                                ScriptData* pre_data = NULL);
 
+  /**
+   * Compiles the specified script using the specified file name
+   * object (typically a string) as the script's origin.
+   */
+  static Local<Script> Compile(Handle<String> source,
+                               Handle<Value> file_name);
+
   Local<Value> Run();
 };
 
@@ -2052,7 +2059,7 @@
   return Local<T>(reinterpret_cast<T*>(after));
 }
 
-Handle<String> ScriptOrigin::ResourceName() {
+Handle<Value> ScriptOrigin::ResourceName() {
   return resource_name_;
 }