Comments (5)
For user bits, I totally agree.
And yes, we have the problem that the current components are not spec compliant, so we either break old code or keep being incompatible with the spec.
I am not sure if there is a way to fix this. Maybe we can first change the implementation to deal with arbitrary user widths also, then change the API with new signatures?
I think the spec has higher priority and our implementation is incompliant.
(I have not used the SpinalHDL AXI Streaming components from the library for reasons like this.)
(I would even consider to allow for an arbitrary number of bits in the data width. For me it makes perfect sense to stream 12-bit video or image samples across AXI Stream.)
from spinalhdl.
The width of the TUSER (user) field can be any number of bits, according to the AMBA AXI 4 Stream specification.
Thus there is no implicit correlation between the data width and the user width.
Quoting the specification: TUSER width. Recommended number of bits is an integer multiple of the width of the interface in bytes.
(https://documentation-service.arm.com/static/642583d7314e245d086bc8c9?token=)
The data width is typically specified in bytes; the specification requires this to be integer multiple of bytes.
In case we only want to allow the recommendation, the user width is a multiple integer number of bits for each byte in the data width.
Ideally though, we allow the number of user bits to be anything.
from spinalhdl.
ok so no I just got to an IP which has this :
So maybe it should be better to keep userWidth
as bits,
keep the that.config.userWidth <= this.config.userWidth
assert,
let the subdivideIn
make slices being bits, and let the pairing make sure that.config.userWidth
is a multiple of this.config.userWidth
?
from spinalhdl.
Thanks a lot for the clarification @likewise,
so as I get it,
the current choice has been to only allow the recommendation then.
Would an additional Boolean like userWidthIntMultiple
true as default, to keep current code fully compatible,
but which could allow to opt-out of the recommendation for cases like the one in my first message (being 3:2),
be conceivable ?
from spinalhdl.
I'd be for allowing an arbitrary number of bits, I have seen a bunch of components that did not conform to the ARM recommendation.
If we allow something that is not an integer multiple of the data width then I don't see a reason why we'd limit it to bytes?
W.r.t. connecting: we could pre-pad with zeros in case the master is narrower then the slave, and create an error in case the master is too wide for the slave? (a user can then still manually resize if they know it's ok to throw bits away?)
The only question: how to do the change w/o breaking older code?
from spinalhdl.
Related Issues (20)
- How to understand the Simulated behavior in SpinalHDL? HOT 4
- spinal.lib.misc.pipeline refractoring
- SpinalConfig.generate does not work as expected When define two modules with implicit parameter in "generate" func HOT 7
- Implicit parity signal in Bundle, freeze, and signalCache HOT 7
- Arbitrary data bundle type for Axi4Stream HOT 8
- Blackbox Verilog sources are not included in formal verification
- Vec as packed array in io HOT 9
- Issues with verilator 5 HOT 2
- Documentation / example usage for `Axi4ReadOnlyMasterAgent` and `Axi4WriteOnlyMasterAgent` HOT 5
- Signals in simulation pruned HOT 2
- Explain the lib:Apb3SpiXdrMasterCtrl.scala and SpiXdrMasterCtrl.scala HOT 1
- Async programming in simulation HOT 6
- BusSlaveFactory driveFlow does not honor byteEnable HOT 5
- how can i using axi stream fifo frame mode HOT 2
- Fix nameless enum in VHDL
- How to use clock generated by rtl in spinal sim? HOT 1
- Port names get lost on dev branch HOT 3
- Question about sim data sample and drive delay HOT 18
- Reg(False) / Reg(True) are valid statements HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from spinalhdl.