List:Internals« Previous MessageNext Message »
From:Marko Mäkelä Date:July 26 2005 1:21pm
Subject:bk commit into 5.0 tree (marko:1.1900)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of marko. When marko does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet
  1.1900 05/07/26 14:21:43 marko@stripped +3 -0
  Merge hundin.mysql.fi:/home/marko/mysql-4.1
  into  hundin.mysql.fi:/home/marko/mysql-5.0

  innobase/trx/trx0sys.c
    1.34 05/07/26 14:21:32 marko@stripped +0 -0
    Automerged

  innobase/os/os0file.c
    1.110 05/07/26 14:21:32 marko@stripped +0 -0
    Automerged

  innobase/include/os0file.h
    1.38 05/07/26 14:21:32 marko@stripped +1 -1
    Automerge and manual fix

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	marko
# Host:	hundin.mysql.fi
# Root:	/home/marko/mysql-5.0/RESYNC

--- 1.37/innobase/include/os0file.h	2005-06-28 10:50:52 +03:00
+++ 1.38/innobase/include/os0file.h	2005-07-26 14:21:32 +03:00
@@ -19,7 +19,9 @@
 
 typedef	struct fil_node_struct	fil_node_t;
 
+#ifdef UNIV_DO_FLUSH
 extern ibool	os_do_not_call_flush_at_each_write;
+#endif /* UNIV_DO_FLUSH */
 extern ibool	os_has_said_disk_full;
 extern ibool	os_aio_print_debug;
 

--- 1.109/innobase/os/os0file.c	2005-06-28 10:50:52 +03:00
+++ 1.110/innobase/os/os0file.c	2005-07-26 14:21:32 +03:00
@@ -40,9 +40,13 @@
 ulint	os_innodb_umask		= 0;
 #endif
 
+#ifdef UNIV_DO_FLUSH
 /* If the following is set to TRUE, we do not call os_file_flush in every
 os_file_write. We can set this TRUE when the doublewrite buffer is used. */
 ibool	os_do_not_call_flush_at_each_write	= FALSE;
+#else
+/* We do not call os_file_flush in every os_file_write. */
+#endif /* UNIV_DO_FLUSH */
 
 /* We use these mutexes to protect lseek + file i/o operation, if the
 OS does not provide an atomic pread or pwrite, or similar */
@@ -1985,6 +1989,7 @@
 	os_file_n_pending_pwrites--;
         os_mutex_exit(os_file_count_mutex);
 
+# ifdef UNIV_DO_FLUSH
 	if (srv_unix_file_flush_method != SRV_UNIX_LITTLESYNC
 	    && srv_unix_file_flush_method != SRV_UNIX_NOSYNC
 	    && !os_do_not_call_flush_at_each_write) {
@@ -1995,6 +2000,7 @@
 
 	        ut_a(TRUE == os_file_flush(file));
 	}
+# endif /* UNIV_DO_FLUSH */
 
         return(ret);
 #else
@@ -2017,6 +2023,7 @@
 	
 	ret = write(file, buf, (ssize_t)n);
 
+# ifdef UNIV_DO_FLUSH
 	if (srv_unix_file_flush_method != SRV_UNIX_LITTLESYNC
 	    && srv_unix_file_flush_method != SRV_UNIX_NOSYNC
 	    && !os_do_not_call_flush_at_each_write) {
@@ -2027,6 +2034,7 @@
 
 	        ut_a(TRUE == os_file_flush(file));
 	}
+# endif /* UNIV_DO_FLUSH */
 
 	os_mutex_exit(os_file_seek_mutexes[i]);
 
@@ -2313,9 +2321,11 @@
 	/* Always do fsync to reduce the probability that when the OS crashes,
 	a database page is only partially physically written to disk. */
 
+# ifdef UNIV_DO_FLUSH
 	if (!os_do_not_call_flush_at_each_write) {
 		ut_a(TRUE == os_file_flush(file));
 	}
+# endif /* UNIV_DO_FLUSH */
 
 	os_mutex_exit(os_file_seek_mutexes[i]);
 
@@ -3533,10 +3543,12 @@
 	if (ret && len == slot->len) {
 		ret_val = TRUE;
 
+# ifdef UNIV_DO_FLUSH
 		if (slot->type == OS_FILE_WRITE
 				&& !os_do_not_call_flush_at_each_write) {
 		         ut_a(TRUE == os_file_flush(slot->file));
 		}
+# endif /* UNIV_DO_FLUSH */
 	} else {
 		os_file_handle_error(slot->name, "Windows aio");
 		
@@ -3617,10 +3629,12 @@
 	*message1 = slot->message1;
 	*message2 = slot->message2;
 
+# ifdef UNIV_DO_FLUSH
 	if (slot->type == OS_FILE_WRITE
 				&& !os_do_not_call_flush_at_each_write) {
 		ut_a(TRUE == os_file_flush(slot->file));
 	}
+# endif /* UNIV_DO_FLUSH */
 
 	os_mutex_exit(array->mutex);
 

--- 1.33/innobase/trx/trx0sys.c	2005-03-09 14:37:14 +02:00
+++ 1.34/innobase/trx/trx0sys.c	2005-07-26 14:21:32 +03:00
@@ -97,8 +97,9 @@
 
 	/* Since we now start to use the doublewrite buffer, no need to call
 	fsync() after every write to a data file */
-
+#ifdef UNIV_DO_FLUSH
 	os_do_not_call_flush_at_each_write = TRUE;
+#endif /* UNIV_DO_FLUSH */
 
 	mutex_create(&(trx_doublewrite->mutex));
 	mutex_set_level(&(trx_doublewrite->mutex), SYNC_DOUBLEWRITE);
Thread
bk commit into 5.0 tree (marko:1.1900)Marko Mäkelä26 Jul