Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(263)

Issue 806653006: Update GPU memory buffers to use StrideInBytes internally. (Closed)

Created:
6 years ago by christiank
Modified:
5 years, 11 months ago
Reviewers:
reveman, jbauman
CC:
chromium-reviews, jam, sievers+watch_chromium.org, jbauman+watch_chromium.org, darin-cc_chromium.org, kalyank, piman+watch_chromium.org, cc-bugs_chromium.org, danakj+watch_chromium.org, auygun, peterp
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Update GPU memory buffers to use StrideInBytes internally. Tile texture compression will add support for GPU memory buffer formats that use less than a byte per pixel. This CL prepares GPU buffers for this by using a new function StrideInBytes instead of relying on bytes per pixel calculations when calculating the number of bytes needed to store a certain number of pixels. BUG=434699 Committed: https://crrev.com/53e678c7962e12efe4bca3b58c9efbf755b86798 Cr-Commit-Position: refs/heads/master@{#311862} Committed: https://crrev.com/a78ab1942c818ade187c060957f7228a1e694ec9 Cr-Commit-Position: refs/heads/master@{#312595}

Patch Set 1 #

Total comments: 7

Patch Set 2 : Use StrideInBytes #

Total comments: 8

Patch Set 3 : Use CheckedNumeric #

Total comments: 5

Patch Set 4 : Addressed nits #

Patch Set 5 : Move code that must run out of DCHECK #

Total comments: 1

Patch Set 6 : Addressed nit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+101 lines, -33 lines) Patch
M cc/test/test_gpu_memory_buffer_manager.cc View 1 4 chunks +7 lines, -5 lines 0 comments Download
M content/common/gpu/client/gpu_memory_buffer_impl.h View 1 2 1 chunk +5 lines, -3 lines 0 comments Download
M content/common/gpu/client/gpu_memory_buffer_impl.cc View 1 2 3 2 chunks +12 lines, -3 lines 0 comments Download
M content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.cc View 1 2 3 4 5 4 chunks +31 lines, -5 lines 0 comments Download
M content/common/gpu/client/gpu_memory_buffer_impl_surface_texture.cc View 1 2 1 chunk +5 lines, -1 line 0 comments Download
M content/common/gpu/client/gpu_memory_buffer_impl_unittest.cc View 1 2 1 chunk +3 lines, -3 lines 0 comments Download
M content/common/gpu/gpu_memory_buffer_factory_shared_memory.cc View 1 2 1 chunk +12 lines, -2 lines 0 comments Download
M gpu/command_buffer/tests/gl_manager.cc View 1 3 chunks +5 lines, -4 lines 0 comments Download
M ui/gl/gl_image_memory.h View 1 2 2 chunks +4 lines, -1 line 0 comments Download
M ui/gl/gl_image_memory.cc View 1 2 3 1 chunk +12 lines, -4 lines 0 comments Download
M ui/gl/gl_image_shared_memory.cc View 1 2 1 chunk +5 lines, -2 lines 0 comments Download

Messages

Total messages: 37 (9 generated)
christiank
This is the first CL for the tile texture compression feature. It's prepares the GPU ...
6 years ago (2014-12-15 14:38:21 UTC) #2
reveman
https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h File content/common/gpu/client/gpu_memory_buffer_impl.h (right): https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h#newcode44 content/common/gpu/client/gpu_memory_buffer_impl.h:44: gfx::GpuMemoryBuffer::Format format); Hm, this doesn't work with stride != ...
6 years ago (2014-12-15 17:33:34 UTC) #3
auygun
6 years ago (2014-12-16 10:29:21 UTC) #5
christiank
https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h File content/common/gpu/client/gpu_memory_buffer_impl.h (right): https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h#newcode44 content/common/gpu/client/gpu_memory_buffer_impl.h:44: gfx::GpuMemoryBuffer::Format format); On 2014/12/15 17:33:34, reveman wrote: > Hm, ...
6 years ago (2014-12-16 12:02:52 UTC) #6
reveman
https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h File content/common/gpu/client/gpu_memory_buffer_impl.h (right): https://codereview.chromium.org/806653006/diff/1/content/common/gpu/client/gpu_memory_buffer_impl.h#newcode44 content/common/gpu/client/gpu_memory_buffer_impl.h:44: gfx::GpuMemoryBuffer::Format format); On 2014/12/16 12:02:52, christiank wrote: > On ...
6 years ago (2014-12-16 16:40:12 UTC) #7
christiank
Another question regarding StrideInBytes. Following the pattern of the old BytesPePiexel it'll have to be ...
6 years ago (2014-12-18 13:58:29 UTC) #8
reveman
I'd like to keep implementation details such as StrideInBytes out of the generic gfx::GpuMemoryBuffer interface ...
6 years ago (2014-12-18 18:49:57 UTC) #9
christiank
https://codereview.chromium.org/806653006/diff/20001/content/common/gpu/client/gpu_memory_buffer_impl.cc File content/common/gpu/client/gpu_memory_buffer_impl.cc (right): https://codereview.chromium.org/806653006/diff/20001/content/common/gpu/client/gpu_memory_buffer_impl.cc#newcode79 content/common/gpu/client/gpu_memory_buffer_impl.cc:79: size_t GpuMemoryBufferImpl::StrideInBytes(size_t width, Format format) { On 2014/12/18 18:49:56, ...
5 years, 11 months ago (2015-01-12 10:35:23 UTC) #10
reveman
lgtm with nits https://codereview.chromium.org/806653006/diff/40001/content/common/gpu/client/gpu_memory_buffer_impl.cc File content/common/gpu/client/gpu_memory_buffer_impl.cc (right): https://codereview.chromium.org/806653006/diff/40001/content/common/gpu/client/gpu_memory_buffer_impl.cc#newcode83 content/common/gpu/client/gpu_memory_buffer_impl.cc:83: base::CheckedNumeric<size_t> w = width; nit: maybe ...
5 years, 11 months ago (2015-01-13 16:04:40 UTC) #11
reveman
Can you also update the description to better match the latest version of this patch? ...
5 years, 11 months ago (2015-01-13 16:05:40 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/806653006/60001
5 years, 11 months ago (2015-01-14 12:31:58 UTC) #15
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator on tryserver.chromium.mac (http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator/builds/48940)
5 years, 11 months ago (2015-01-14 12:37:37 UTC) #17
christiank
jbauman, would you mind having a look as well?
5 years, 11 months ago (2015-01-14 12:46:24 UTC) #18
jbauman
lgtm (though I'm not sure how meaningful stride is for compressed formats)
5 years, 11 months ago (2015-01-16 00:03:39 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/806653006/60001
5 years, 11 months ago (2015-01-16 09:07:56 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/35914) ios_dbg_simulator on tryserver.chromium.mac (http://build.chromium.org/p/tryserver.chromium.mac/builders/ios_dbg_simulator/builds/48939)
5 years, 11 months ago (2015-01-16 09:08:13 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/806653006/60001
5 years, 11 months ago (2015-01-16 10:05:31 UTC) #25
commit-bot: I haz the power
Committed patchset #4 (id:60001)
5 years, 11 months ago (2015-01-16 11:32:08 UTC) #26
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/53e678c7962e12efe4bca3b58c9efbf755b86798 Cr-Commit-Position: refs/heads/master@{#311862}
5 years, 11 months ago (2015-01-16 11:33:03 UTC) #27
ricow1
A revert of this CL (patchset #4 id:60001) has been created in https://codereview.chromium.org/852283003/ by ricow@google.com. ...
5 years, 11 months ago (2015-01-16 14:19:28 UTC) #28
maniscalco
A revert of this CL (patchset #4 id:60001) has been created in https://codereview.chromium.org/858583003/ by maniscalco@chromium.org. ...
5 years, 11 months ago (2015-01-16 17:04:31 UTC) #29
christiank
I have now fixed the failing test, how do I go about trying to commit ...
5 years, 11 months ago (2015-01-20 07:28:13 UTC) #30
chromium-reviews
On Mon, Jan 19, 2015 at 11:28 PM, <christiank@opera.com> wrote: > I have now fixed ...
5 years, 11 months ago (2015-01-20 21:34:51 UTC) #31
christiank
On 2015/01/20 21:34:51, chromium-reviews wrote: > On Mon, Jan 19, 2015 at 11:28 PM, <mailto:christiank@opera.com> ...
5 years, 11 months ago (2015-01-21 07:35:24 UTC) #32
reveman
lgtm with nit https://codereview.chromium.org/806653006/diff/80001/content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.cc File content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.cc (right): https://codereview.chromium.org/806653006/diff/80001/content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.cc#newcode142 content/common/gpu/client/gpu_memory_buffer_impl_shared_memory.cc:142: NOTREACHED(); nit: I would prefer: bool ...
5 years, 11 months ago (2015-01-21 18:18:21 UTC) #33
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/806653006/100001
5 years, 11 months ago (2015-01-22 08:13:19 UTC) #35
commit-bot: I haz the power
Committed patchset #6 (id:100001)
5 years, 11 months ago (2015-01-22 09:54:46 UTC) #36
commit-bot: I haz the power
5 years, 11 months ago (2015-01-22 09:55:41 UTC) #37
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/a78ab1942c818ade187c060957f7228a1e694ec9
Cr-Commit-Position: refs/heads/master@{#312595}

Powered by Google App Engine
This is Rietveld 408576698