aboutsummaryrefslogtreecommitdiff
path: root/backend/unittests/CodeGen/MachineIRCoreTest.cpp
diff options
context:
space:
mode:
authorRichard-Qin-X <richard.qin.001@gmail.com>2026-08-13 06:52:15 +0800
committerRichard-Qin-X <richard.qin.001@gmail.com>2026-08-13 06:52:15 +0800
commitaa7c85ca71859aab15bdf1e6dc1ea3a5aa5d1e28 (patch)
tree20d94c4debfe4900e362c6c7f8443bcfbd58ec28 /backend/unittests/CodeGen/MachineIRCoreTest.cpp
parentd62f022c92fcc3ebe2269273628943a0089683fd (diff)
downloadrcc-project-aa7c85ca71859aab15bdf1e6dc1ea3a5aa5d1e28.tar.gz
rcc-project-aa7c85ca71859aab15bdf1e6dc1ea3a5aa5d1e28.tar.xz
[Support] Split APInt and APFloat ownership
Diffstat (limited to 'backend/unittests/CodeGen/MachineIRCoreTest.cpp')
-rw-r--r--backend/unittests/CodeGen/MachineIRCoreTest.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/backend/unittests/CodeGen/MachineIRCoreTest.cpp b/backend/unittests/CodeGen/MachineIRCoreTest.cpp
index 7982b04..6365e59 100644
--- a/backend/unittests/CodeGen/MachineIRCoreTest.cpp
+++ b/backend/unittests/CodeGen/MachineIRCoreTest.cpp
@@ -102,7 +102,7 @@ void testOperandKinds(TestContext &Context) {
return;
const std::array<std::uint64_t, 1> HalfWords{0x3c00};
- auto HalfBits = rcc::FloatingPointBits::create(rcc::FloatSemantics::IEEEHalf, HalfWords);
+ auto HalfBits = rcc::APFloat::create(rcc::FloatSemantics::IEEEHalf, HalfWords);
Context.expect(HalfBits.has_value(), "well-sized floating immediate must be accepted");
if (!HalfBits)
return;
@@ -110,10 +110,10 @@ void testOperandKinds(TestContext &Context) {
"floating immediate must preserve semantics and raw bits");
const std::array<std::uint64_t, 1> OverflowHalfWords{0x10000};
- Context.expect(!rcc::FloatingPointBits::create(rcc::FloatSemantics::IEEEHalf, OverflowHalfWords),
+ Context.expect(!rcc::APFloat::create(rcc::FloatSemantics::IEEEHalf, OverflowHalfWords),
"floating immediate bits above semantics width must be rejected");
const std::array<std::uint64_t, 2> TooManyHalfWords{0, 0};
- Context.expect(!rcc::FloatingPointBits::create(rcc::FloatSemantics::IEEEHalf, TooManyHalfWords),
+ Context.expect(!rcc::APFloat::create(rcc::FloatSemantics::IEEEHalf, TooManyHalfWords),
"floating immediate word-count mismatch must be rejected");
auto Virtual = Function->registerInfo().createVirtualRegister(*rcc::LLT::makeInteger(32));