Commit c8d848b2 authored by Alyssa Rosenzweig's avatar Alyssa Rosenzweig 💜 Committed by Marge Bot
Browse files

panfrost: Move pool routines to common code



We finally have it decoupled from Galliumisms (and OpenGLisms, indeed)
so we can share the file.
Signed-off-by: Alyssa Rosenzweig's avatarAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <mesa/mesa!5794>
parent 1d88f078
......@@ -2,8 +2,6 @@ C_SOURCES := \
nir/nir_lower_blend.c \
nir/nir_lower_blend.h \
\
pan_allocate.c \
pan_allocate.h \
pan_assemble.c \
pan_blend_cso.c \
pan_blend.h \
......
......@@ -31,7 +31,6 @@ files_panfrost = files(
'pan_context.c',
'pan_blit.c',
'pan_job.c',
'pan_allocate.c',
'pan_assemble.c',
'pan_blending.c',
'pan_blend_shaders.c',
......
......@@ -28,7 +28,7 @@
#include "panfrost-quirks.h"
#include "pan_allocate.h"
#include "pan_pool.h"
#include "pan_bo.h"
#include "pan_cmdstream.h"
#include "pan_context.h"
......
......@@ -28,7 +28,7 @@
#include "util/u_dynarray.h"
#include "pipe/p_state.h"
#include "pan_allocate.h"
#include "pan_pool.h"
#include "pan_resource.h"
/* panfrost_batch_fence is the out fence of a batch that users or other batches
......
......@@ -28,7 +28,7 @@
#include <panfrost-job.h>
#include "pan_screen.h"
#include "pan_allocate.h"
#include "pan_pool.h"
#include "pan_minmax_cache.h"
#include "pan_texture.h"
#include "drm-uapi/drm.h"
......
......@@ -24,7 +24,7 @@
#include "pan_context.h"
#include "pan_job.h"
#include "pan_allocate.h"
#include "pan_pool.h"
#include "panfrost-quirks.h"
#include "util/bitset.h"
......
......@@ -39,7 +39,7 @@
#include <panfrost-misc.h>
#include "pan_device.h"
#include "pan_allocate.h"
#include "pan_pool.h"
struct panfrost_batch;
struct panfrost_context;
......
......@@ -29,6 +29,8 @@ encoder_FILES := \
encoder/pan_encoder.h \
encoder/pan_format.c \
encoder/pan_invocation.c \
encoder/pan_pool.c \
encoder/pan_pool.h \
encoder/pan_props.c \
encoder/pan_sampler.c \
encoder/pan_tiler.c \
......
......@@ -31,6 +31,7 @@ libpanfrost_encoder_files = files(
'pan_tiler.c',
'pan_texture.c',
'pan_scratch.c',
'pan_pool.c',
'pan_props.c',
)
......
......@@ -23,14 +23,9 @@
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <panfrost-misc.h>
#include <panfrost-job.h>
#include "util/hash_table.h"
#include "pan_bo.h"
#include "pan_context.h"
#include "pan_pool.h"
/* TODO: What does this actually have to be? */
#define ALIGNMENT 128
......
......@@ -22,19 +22,11 @@
*
*/
#ifndef __PAN_ALLOCATE_H__
#define __PAN_ALLOCATE_H__
#include <unistd.h>
#include <sys/mman.h>
#include <stdbool.h>
#ifndef __PAN_POOL_H__
#define __PAN_POOL_H__
#include <panfrost-misc.h>
#include "util/list.h"
struct panfrost_batch;
/* Represents a pool of memory that can only grow, used to allocate objects
* with the same lifetime as the pool itself. In OpenGL, a pool is owned by the
* batch for transient structures. In Vulkan, it may be owned by e.g. the
......@@ -71,4 +63,4 @@ panfrost_pool_alloc(struct pan_pool *pool, size_t sz);
mali_ptr
panfrost_pool_upload(struct pan_pool *pool, const void *data, size_t sz);
#endif /* __PAN_ALLOCATE_H__ */
#endif
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment