summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2008-09-19 17:45:51 -0600
committerBrian Paul <brian.paul@tungstengraphics.com>2008-09-19 17:56:45 -0600
commit7af5f944e5709920623c766bc572f8d587709270 (patch)
tree6c99b417e190622b9ba54c5cdd75a100dbe061a9 /src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c
parent33bef5866c81a7f358c0aa2e37e20443dafb9eb2 (diff)
gallium: added spe_code_size()
Diffstat (limited to 'src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c')
-rw-r--r--src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c b/src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c
index 85280f680a..1c3e21b4c0 100644
--- a/src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c
+++ b/src/gallium/auxiliary/rtasm/rtasm_ppc_spe.c
@@ -383,6 +383,13 @@ void spe_release_func(struct spe_function *p)
}
+/** Return current code size in bytes. */
+unsigned spe_code_size(const struct spe_function *p)
+{
+ return p->num_inst * SPE_INST_SIZE;
+}
+
+
/**
* Allocate a SPE register.
* \return register index or -1 if none left.