Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -153,16 +153,16 @@ class ChipMappingITS
int getNChipsPerCable(int ruType) { return NChipsPerCableSB[ruType]; }

///< get number cables on the RU served by a given RU type
int getNCablesOnRUType(int ruType) { return NCablesPerStaveSB[ruType]; }
int getNCablesOnRUType(int ruType) const { return NCablesPerStaveSB[ruType]; }

///< get pattern of lanes on the RU served by a given RU type
int getCablesOnRUType(int ruType) { return CablesOnStaveSB[ruType]; }
int getCablesOnRUType(int ruType) const { return CablesOnStaveSB[ruType]; }

///< get number of chips served by RU of given type (i.e. RU type for ITS)
int getNChipsOnRUType(int ruType) { return NChipsPerStaveSB[ruType]; }
int getNChipsOnRUType(int ruType) const { return NChipsPerStaveSB[ruType]; }

///< get RU type from the sequential ID of the RU
int getRUType(int ruID)
int getRUType(int ruID) const
{
///< get the RU type corresponding to RU with secuential number ruID
if (ruID > NStavesSB[IB] + NStavesSB[MB] - 1) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,13 @@ class PayLoadCont
}
}

///< fill n bytes with given symbol w/o checking for the size
void fillFast(const uint8_t c, size_t n)
{
std::memset(mEnd, c, n);
mEnd += n;
}

///< add n bytes to the buffer w/o checking for the size
void addFast(const uint8_t* ptr, size_t n)
{
Expand Down Expand Up @@ -104,6 +111,13 @@ class PayLoadCont
}
}

///< fill n bytes with given symbol
void fill(const uint8_t c, size_t n)
{
ensureFreeCapacity(n);
fillFast(c, n);
}

///< add n bytes to the buffer, expand if needed. no check for overlap
void add(const uint8_t* ptr, size_t n)
{
Expand Down
Loading
Morty Proxy This is a proxified and sanitized view of the page, visit original site.