From 6b7a63f77940d7746e85b1165073cb1c1cc13deb Mon Sep 17 00:00:00 2001 From: "piman@google.com" Date: Sat, 23 Apr 2011 00:57:35 +0000 Subject: Add a yield command to the command buffer. This allows more graceful scheduling so that waiting on the previous frame's swapbuffers doesn't end up being a Finish. BUG=none TEST=check in about:gpu and verify that SwapBuffers in the renderer process actually only waits for the previous SwapBuffers in the gpu process. Review URL: http://codereview.chromium.org/6899037 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82759 0039d316-1c4b-4281-b951-d872f2087c98 --- gpu/command_buffer/service/common_decoder_unittest.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'gpu/command_buffer/service/common_decoder_unittest.cc') diff --git a/gpu/command_buffer/service/common_decoder_unittest.cc b/gpu/command_buffer/service/common_decoder_unittest.cc index 8f88398..9b53a56 100644 --- a/gpu/command_buffer/service/common_decoder_unittest.cc +++ b/gpu/command_buffer/service/common_decoder_unittest.cc @@ -556,5 +556,11 @@ TEST_F(CommonDecoderTest, GetBucketData) { EXPECT_NE(error::kNoError, ExecuteCmd(cmd)); } +TEST_F(CommonDecoderTest, YieldScheduler) { + cmd::YieldScheduler cmd; + cmd.Init(); + EXPECT_EQ(error::kYield, ExecuteCmd(cmd)); +} + } // namespace gpu -- cgit v1.1