[SVN-Commit] r839 - in branches/experimental:
mail/thunderbird-esr/files mail/thunderbird/files
mail/thunderbird3/files www/firefox-esr/files
www/firefox-nightly/files www/firefox/files
www/firefox36/files www/libxul/files www/libxul19/files
www/seamonkey/files
svn-freebsd-gecko at chruetertee.ch
svn-freebsd-gecko at chruetertee.ch
Thu Jul 5 13:07:16 UTC 2012
Author: jbeich
Date: Thu Jul 5 13:07:03 2012
New Revision: 839
Log:
reduce spinning when waiting for audio data on pause
Added:
branches/experimental/mail/thunderbird-esr/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/mail/thunderbird/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/mail/thunderbird3/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/firefox-esr/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/firefox-nightly/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/firefox/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/libxul/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/libxul19/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
branches/experimental/www/seamonkey/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
Modified:
branches/experimental/www/firefox36/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
Added: branches/experimental/mail/thunderbird-esr/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/mail/thunderbird-esr/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- mozilla/media/libsydneyaudio/src/sydney_audio_oss.c~
++++ mozilla/media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/mail/thunderbird/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/mail/thunderbird/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- mozilla/media/libsydneyaudio/src/sydney_audio_oss.c~
++++ mozilla/media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/mail/thunderbird3/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/mail/thunderbird3/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- mozilla/media/libsydneyaudio/src/sydney_audio_oss.c~
++++ mozilla/media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/firefox-esr/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/firefox-esr/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- media/libsydneyaudio/src/sydney_audio_oss.c~
++++ media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/firefox-nightly/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/firefox-nightly/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- media/libsydneyaudio/src/sydney_audio_oss.c~
++++ media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/firefox/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/firefox/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- media/libsydneyaudio/src/sydney_audio_oss.c~
++++ media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Modified: branches/experimental/www/firefox36/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- branches/experimental/www/firefox36/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Wed Jul 4 01:41:22 2012 (r838)
+++ branches/experimental/www/firefox36/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -29,5 +29,14 @@
/*
* Release resources.
*/
-
-
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/libxul/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/libxul/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- media/libsydneyaudio/src/sydney_audio_oss.c~
++++ media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/libxul19/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/libxul19/files/patch-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- media/libsydneyaudio/src/sydney_audio_oss.c~
++++ media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
Added: branches/experimental/www/seamonkey/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ branches/experimental/www/seamonkey/files/patch-mozilla-media-libsydneyaudio-src-sydney_audio_oss.c Thu Jul 5 13:07:03 2012 (r839)
@@ -0,0 +1,13 @@
+--- mozilla/media/libsydneyaudio/src/sydney_audio_oss.c~
++++ mozilla/media/libsydneyaudio/src/sydney_audio_oss.c
+@@ -446,6 +446,10 @@ static void audio_callback(void* data)
+ printf("!"); /* not enough audio data */
+ #endif
+ bytes = bytes-bytes_to_copy;
++ struct timespec ts = {0, 1000000};
++ pthread_mutex_unlock(&s->mutex);
++ nanosleep(&ts, NULL);
++ pthread_mutex_lock(&s->mutex);
+ break;
+ }
+ free(s->bl_head);
More information about the freebsd-gecko
mailing list