[Lldb-commits] [lldb] [lldb] Fix offload bundle unit tests on 32-bit systems (PR #226922)

David Spickett via lldb-commits lldb-commits at lists.llvm.org
Mon Sep 28 01:57:57 PDT 2026


https://github.com/DavidSpickett created https://github.com/llvm/llvm-project/pull/226922

DataExtractor::GetByteSize returns uint64_t for reasons I don't yet understand. I might change it to size_t but let's unblock the build for now.

Fixes #222362 / 08ee0ef5da10d27d5776df1e1ff81c46a38d9b5c.

>From 778c329fcb11cf26653bf7f670bf4687143b638c Mon Sep 17 00:00:00 2001
From: David Spickett <david.spickett at arm.com>
Date: Mon, 28 Sep 2026 08:54:10 +0000
Subject: [PATCH] [lldb] Fix offload bundle unit tests on 32-bit systems

DataExtractor::GetByteSize returns uint64_t for reasons
I don't yet understand. I might change it to size_t but
let's unblock the build for now.

Fixes #222362 / 08ee0ef5da10d27d5776df1e1ff81c46a38d9b5c.
---
 .../ObjectContainer/ObjectContainerClangOffloadBundleTest.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lldb/unittests/ObjectContainer/ObjectContainerClangOffloadBundleTest.cpp b/lldb/unittests/ObjectContainer/ObjectContainerClangOffloadBundleTest.cpp
index 182a1c1214bb3..16256c7a8774a 100644
--- a/lldb/unittests/ObjectContainer/ObjectContainerClangOffloadBundleTest.cpp
+++ b/lldb/unittests/ObjectContainer/ObjectContainerClangOffloadBundleTest.cpp
@@ -281,9 +281,9 @@ TEST_F(ObjectContainerClangOffloadBundleTest,
   std::array<BundleInput, 3> inputs = {{
       {"host-x86_64-unknown-linux-gnu", {}},
       {"hipv4-amdgpu-amd-amdhsa--gfx908",
-       {gfx908_data->GetDataStart(), gfx908_data->GetByteSize()}},
+       {gfx908_data->GetDataStart(), static_cast<size_t>(gfx908_data->GetByteSize())}},
       {"hipv4-amdgpu-amd-amdhsa--gfx942",
-       {gfx942_data->GetDataStart(), gfx942_data->GetByteSize()}},
+       {gfx942_data->GetDataStart(), static_cast<size_t>(gfx942_data->GetByteSize())}},
   }};
   BundleData bundle = MakeBundle(inputs);
   auto bundled_file = MakeELFContainingBundle(bundle.bytes);



More information about the lldb-commits mailing list