mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-26 20:50:23 +01:00
broadcom/commmon: add has_accumulators field on v3d_device_info
Even if we can just check for the version on the code, checking for this field makes several places more readable. So for example, on the register allocate code we doesn't assign an accumulator because we don't have accumulators on that hw, instead of because hw version is a given one. Reviewed-by: Iago Toral Quiroga <itoral@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25450>
This commit is contained in:
parent
ef75d07b87
commit
3e42b9ff47
2 changed files with 5 additions and 0 deletions
|
|
@ -65,6 +65,8 @@ v3d_get_device_info(int fd, struct v3d_device_info* devinfo, v3d_ioctl_fun drm_i
|
|||
int qups = (ident1.value >> 8) & 0xf;
|
||||
devinfo->qpu_count = nslc * qups;
|
||||
|
||||
devinfo->has_accumulators = devinfo->ver < 71;
|
||||
|
||||
switch (devinfo->ver) {
|
||||
case 33:
|
||||
case 41:
|
||||
|
|
|
|||
|
|
@ -42,6 +42,9 @@ struct v3d_device_info {
|
|||
|
||||
/* NSLC * QUPS from the core's IDENT registers. */
|
||||
int qpu_count;
|
||||
|
||||
/* If the hw has accumulator registers */
|
||||
bool has_accumulators;
|
||||
};
|
||||
|
||||
typedef int (*v3d_ioctl_fun)(int fd, unsigned long request, void *arg);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue