ByteMaskedStore constructor
Creates a byte-masked store forwarding candidate.
Implementation
ByteMaskedStore({
required this.addressWidth,
required this.dataWidth,
String? name,
}) : super([
Logic(name: 'address', width: addressWidth),
Logic(name: 'data', width: dataWidth),
Logic(name: 'byteEnable', width: dataWidth ~/ 8),
Logic(name: 'valid'),
], name: name ?? 'byte_masked_store') {
_requirePositive(addressWidth, 'addressWidth');
_requirePositive(dataWidth, 'dataWidth');
if (dataWidth % 8 != 0) {
throw ArgumentError.value(
dataWidth,
'dataWidth',
'Must contain a whole number of bytes.',
);
}
}