Public メソッド | |
vcd_signed_char_trace (const char &object, const std::string &name_, const std::string &vcd_name_, int width_) | |
void | write (FILE *f) |
bool | changed () |
Protected 変数 | |
const char & | object |
char | old_value |
unsigned char | mask |
sc_vcd_trace.cpp の 1284 行で定義されています。
sc_core::vcd_signed_char_trace::vcd_signed_char_trace | ( | const char & | object, | |
const std::string & | name_, | |||
const std::string & | vcd_name_, | |||
int | width_ | |||
) |
void sc_core::vcd_signed_char_trace::write | ( | FILE * | f | ) | [virtual] |
sc_core::vcd_traceを実装しています。
sc_vcd_trace.cpp の 1324 行で定義されています。
01325 { 01326 char rawdata[1000]; 01327 char compdata[1000]; 01328 int bitindex; 01329 01330 // Check for overflow 01331 if (((unsigned char) object & mask) != (unsigned char) object) { 01332 for (bitindex = 0; bitindex < bit_width; bitindex++){ 01333 rawdata[bitindex] = 'x'; 01334 } 01335 } 01336 else{ 01337 unsigned bit_mask = 1 << (bit_width-1); 01338 for (bitindex = 0; bitindex < bit_width; bitindex++) { 01339 rawdata[bitindex] = (object & bit_mask)? '1' : '0'; 01340 bit_mask = bit_mask >> 1; 01341 } 01342 } 01343 rawdata[bitindex] = '\0'; 01344 compose_data_line(rawdata, compdata); 01345 std::fputs(compdata, f); 01346 old_value = object; 01347 }
bool sc_core::vcd_signed_char_trace::changed | ( | ) | [virtual] |
sc_core::vcd_traceを実装しています。
sc_vcd_trace.cpp の 1318 行で定義されています。
01319 { 01320 return object != old_value; 01321 }
const char& sc_core::vcd_signed_char_trace::object [protected] |
sc_vcd_trace.cpp の 1294 行で定義されています。
char sc_core::vcd_signed_char_trace::old_value [protected] |
sc_vcd_trace.cpp の 1295 行で定義されています。
unsigned char sc_core::vcd_signed_char_trace::mask [protected] |
sc_vcd_trace.cpp の 1296 行で定義されています。