Commit: 7f714fdbb2643ce9886d27a4493e9c7c5235c30e
Author: Joshua Leung
Date:   Tue May 22 12:00:23 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB7f714fdbb2643ce9886d27a4493e9c7c5235c30e

Depsgraph: Enable copy on write by default

As was decided at today's dev kickoff, we're now moving to having
Copy-on-Write enabled by default, as 2.8 is barely functional with
it off.

To run Blender *without* COW (e.g. for testing), use:
--disable-copy-on-write

===================================================================

M       source/blender/depsgraph/DEG_depsgraph.h
M       source/blender/depsgraph/intern/depsgraph.cc
M       source/creator/creator_args.c

===================================================================

diff --git a/source/blender/depsgraph/DEG_depsgraph.h 
b/source/blender/depsgraph/DEG_depsgraph.h
index 0a0e7ee638b..589df5df878 100644
--- a/source/blender/depsgraph/DEG_depsgraph.h
+++ b/source/blender/depsgraph/DEG_depsgraph.h
@@ -92,7 +92,7 @@ extern "C" {
 #endif
 
 bool DEG_depsgraph_use_copy_on_write(void);
-void DEG_depsgraph_enable_copy_on_write(void);
+void DEG_depsgraph_disable_copy_on_write(void);
 
 /* ************************************************ */
 /* Depsgraph API */
diff --git a/source/blender/depsgraph/intern/depsgraph.cc 
b/source/blender/depsgraph/intern/depsgraph.cc
index 4307ac94390..32cbee7597c 100644
--- a/source/blender/depsgraph/intern/depsgraph.cc
+++ b/source/blender/depsgraph/intern/depsgraph.cc
@@ -70,16 +70,16 @@ extern "C" {
 #include "intern/depsgraph_intern.h"
 #include "util/deg_util_foreach.h"
 
-static bool use_copy_on_write = false;
+static bool use_copy_on_write = true;
 
 bool DEG_depsgraph_use_copy_on_write(void)
 {
        return use_copy_on_write;
 }
 
-void DEG_depsgraph_enable_copy_on_write(void)
+void DEG_depsgraph_disable_copy_on_write(void)
 {
-       use_copy_on_write = true;
+       use_copy_on_write = false;
 }
 
 namespace DEG {
diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c
index 44ff9810b71..95565b034e9 100644
--- a/source/creator/creator_args.c
+++ b/source/creator/creator_args.c
@@ -588,7 +588,7 @@ static int arg_handle_print_help(int UNUSED(argc), const 
char **UNUSED(argv), vo
 
        printf("\n");
        printf("Experimental Features:\n");
-       BLI_argsPrintArgDoc(ba, "--enable-copy-on-write");
+       BLI_argsPrintArgDoc(ba, "--disable-copy-on-write");
 
        /* Other options _must_ be last (anything not handled will show here) */
        printf("\n");
@@ -1294,8 +1294,8 @@ static const char arg_handle_use_copy_on_write_doc[] =
 ;
 static int arg_handle_use_copy_on_write(int UNUSED(argc), const char 
**UNUSED(argv), void *UNUSED(data))
 {
-       printf("Using copy on write. This is highly EXPERIMENTAL!\n");
-       DEG_depsgraph_enable_copy_on_write();
+       printf("Disabling copy on write. Only use for testing whether something 
else is at fault\n");
+       DEG_depsgraph_disable_copy_on_write();
        return 0;
 }
 
@@ -1896,7 +1896,7 @@ void main_args_setup(bContext *C, bArgs *ba)
        BLI_argsAdd(ba, 1, NULL, "--debug-gpu-shaders",
                    CB_EX(arg_handle_debug_mode_generic_set, gpumem), (void 
*)G_DEBUG_GPU_SHADERS);
 
-       BLI_argsAdd(ba, 1, NULL, "--enable-copy-on-write", 
CB(arg_handle_use_copy_on_write), NULL);
+       BLI_argsAdd(ba, 1, NULL, "--disable-copy-on-write", 
CB(arg_handle_use_copy_on_write), NULL);
 
        BLI_argsAdd(ba, 1, NULL, "--verbose", CB(arg_handle_verbosity_set), 
NULL);

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to