#include "os/os_thread.h"
#include "state_tracker/drm_driver.h"
#include "util/list.h"
+#include "util/slab.h"
+
+#ifndef DRM_VC4_PARAM_SUPPORTS_ETC1
+#define DRM_VC4_PARAM_SUPPORTS_ETC1 4
+#endif
struct vc4_bo;
#define VC4_MAX_MIP_LEVELS 12
#define VC4_MAX_TEXTURE_SAMPLERS 16
+struct vc4_simulator_file;
+
struct vc4_screen {
struct pipe_screen base;
int fd;
- void *simulator_mem_base;
- uint32_t simulator_mem_size;
+ int v3d_ver;
+
+ const char *name;
/** The last seqno we've completed a wait for.
*
*/
uint64_t finished_seqno;
+ struct slab_parent_pool transfer_pool;
+
struct vc4_bo_cache {
/** List of struct vc4_bo freed, by age. */
struct list_head time_list;
uint32_t bo_count;
} bo_cache;
+ struct util_hash_table *bo_handles;
+ pipe_mutex bo_handles_mutex;
+
uint32_t bo_size;
uint32_t bo_count;
+ bool has_control_flow;
+ bool has_etc1;
+ bool has_threaded_fs;
+
+ struct vc4_simulator_file *sim_file;
};
static inline struct vc4_screen *
vc4_screen_bo_from_handle(struct pipe_screen *pscreen,
struct winsys_handle *whandle);
+const void *
+vc4_screen_get_compiler_options(struct pipe_screen *pscreen,
+ enum pipe_shader_ir ir, unsigned shader);
+
extern uint32_t vc4_debug;
void