mnemonikr / symbolic-pcode

Apache License 2.0
0 stars 0 forks source link

Add support for fixed-length symbolic buffers #68

Closed mnemonikr closed 1 year ago

mnemonikr commented 1 year ago

This is useful for the memory module which needs to store byte-addressable data. Currently this data is stored as a SymbolicBitVec which is known to be exactly 8-bits in length. However it would be better to enforce this constraint at the type level.

This PR introduces SymbolicBitBuf<N> and type SymbolicByte = SymbolicBitBuf<8>. It also defines some operations on the SymbolicBitBuf, though in retrospect these won't be useful for the emulator. The reason being is that all of the pcode operations operate on VarnodeData which defines the amount of data to read at runtime.