Reorder VCD codes for better viewer packing.
This commit is contained in:
parent
c6650f88e1
commit
a2a7021914
|
|
@ -134,17 +134,24 @@ private:
|
||||||
// cppcheck-suppress functionConst
|
// cppcheck-suppress functionConst
|
||||||
void dumpDone();
|
void dumpDone();
|
||||||
inline void printCode(vluint32_t code) {
|
inline void printCode(vluint32_t code) {
|
||||||
if (code>=(94*94*94)) *m_writep++ = static_cast<char>((code/94/94/94)%94+33);
|
*m_writep++ = static_cast<char>('!' + code % 94);
|
||||||
if (code>=(94*94)) *m_writep++ = static_cast<char>((code/94/94)%94+33);
|
code /= 94;
|
||||||
if (code>=(94)) *m_writep++ = static_cast<char>((code/94)%94+33);
|
while (code) {
|
||||||
*m_writep++ = static_cast<char>((code)%94+33);
|
code--;
|
||||||
|
*m_writep++ = static_cast<char>('!' + code % 94);
|
||||||
|
code /= 94;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
static std::string stringCode(vluint32_t code) VL_PURE {
|
static std::string stringCode(vluint32_t code) VL_PURE {
|
||||||
std::string out;
|
std::string out;
|
||||||
if (code>=(94*94*94)) out += static_cast<char>((code/94/94/94)%94+33);
|
out += static_cast<char>('!' + code % 94);
|
||||||
if (code>=(94*94)) out += static_cast<char>((code/94/94)%94+33);
|
code /= 94;
|
||||||
if (code>=(94)) out += static_cast<char>((code/94)%94+33);
|
while (code) {
|
||||||
return out + static_cast<char>((code)%94+33);
|
code--;
|
||||||
|
out += static_cast<char>('!' + code % 94);
|
||||||
|
code /= 94;
|
||||||
|
}
|
||||||
|
return out;
|
||||||
}
|
}
|
||||||
|
|
||||||
// CONSTRUCTORS
|
// CONSTRUCTORS
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue