Lines Matching defs:bytes
350 constexpr unsigned bytes() const { return ((unsigned)rc & 0x1F) * (is_subdword() ? 1 : 4); }
351 // TODO: use size() less in favor of bytes()
352 constexpr unsigned size() const { return (bytes() + 3) >> 2; }
357 static constexpr RegClass get(RegType type, unsigned bytes)
360 return RegClass(type, DIV_ROUND_UP(bytes, 4u));
362 return bytes % 4u ? RegClass(type, bytes).as_subdword() : RegClass(type, bytes / 4u);
366 constexpr RegClass resize(unsigned bytes) const
369 assert(bytes % 4u == 0);
370 return get(RegType::vgpr, bytes).as_linear();
372 return get(type(), bytes);
414 constexpr unsigned bytes() const noexcept { return regClass().bytes(); }
442 constexpr PhysReg advance(int bytes) const
445 res.reg_b += bytes;
672 static Operand zero(unsigned bytes = 4) noexcept
674 if (bytes == 8)
676 else if (bytes == 4)
678 else if (bytes == 2)
680 assert(bytes == 1);
687 static Operand get_const(enum amd_gfx_level chip, uint64_t val, unsigned bytes)
689 if (val == 0x3e22f983 && bytes == 4 && chip >= GFX8) {
696 if (bytes == 8)
698 else if (bytes == 4)
700 else if (bytes == 2)
702 assert(bytes == 1);
706 static bool is_constant_representable(uint64_t val, unsigned bytes, bool zext = false,
709 if (bytes <= 4)
746 constexpr unsigned bytes() const noexcept
751 return data_.temp.bytes();
814 assert(bytes() == 2 || bytes() == 4);
816 if (bytes() == 2 && int16_t(data_.i) >= -16 && int16_t(data_.i) <= 64 && !isLiteral())
945 constexpr unsigned bytes() const noexcept { return temp.bytes(); }
2057 uint32_t lds_limit; /* in bytes */