-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compress multiple run-time uniforms into one register. #72
Comments
Although this is definitively possible to save registers, I don't think this is the direction we should go in. Also, are you talking about compressing constants (loaded via |
Sorry for confusing explanation. I am talking about constants from |
I think we can save instructions to store values from uniform. https://github.com/nineties/py-videocore/blob/master/examples/sgemm_1thread.py#L37 This uses "load imm per-elmt signed" (page 33 in VC4C reference manual). |
I never used the other versions of Then:
would be equivalent to
|
If all bits of |
The number of registers in VC4 is very limited.
One of the technique to avoid this, is compression of constants from
uniform
into one register.For example,
mov r0, uniform
fill in all of element of vector-registerr0
.If each element of
r0
hold a different value, we can save registers.So we use vector-rotation with broadcast.
Things we should do is,
The text was updated successfully, but these errors were encountered: