// Copyright 2012 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifdef UNSAFE_BUFFERS_BUILD // TODO(crbug.com/40285824): Remove this and convert code to safer constructs. #pragma allow_unsafe_buffers #endif // This file contains the definition of the RingBuffer class. #ifndef GPU_COMMAND_BUFFER_CLIENT_RING_BUFFER_H_ #define GPU_COMMAND_BUFFER_CLIENT_RING_BUFFER_H_ #include <stdint.h> #include "base/containers/circular_deque.h" #include "base/memory/raw_ptr.h" #include "gpu/gpu_export.h" namespace gpu { class CommandBufferHelper; // RingBuffer manages a piece of memory as a ring buffer. Memory is allocated // with Alloc and then a is freed pending a token with FreePendingToken. Old // allocations must not be kept past new allocations. class GPU_EXPORT RingBuffer { … }; } // namespace gpu #endif // GPU_COMMAND_BUFFER_CLIENT_RING_BUFFER_H_