MCPcopy Create free account
hub / github.com/AliveToolkit/alive2 / bitsByte

Method bitsByte

ir/memory.cpp:479–486  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

477}
478
479unsigned Byte::bitsByte() {
480 unsigned ptr_bits = does_ptr_mem_access *
481 (1 + Pointer::totalBits() + bits_ptr_byte_offset());
482 unsigned int_bits = does_int_mem_access * (bits_byte + bits_poison_per_byte)
483 + sub_byte_bits();
484 // allow at least 1 bit if there's no memory access
485 return max(1u, byte_has_ptr_bit() + max(ptr_bits, int_bits));
486}
487
488ostream& operator<<(ostream &os, const Byte &byte) {
489 if (byte.isPtr().isTrue()) {

Callers

nothing calls this directly

Calls 3

bits_ptr_byte_offsetFunction · 0.85
sub_byte_bitsFunction · 0.85
byte_has_ptr_bitFunction · 0.85

Tested by

no test coverage detected