[llvm] 82dc32e - Big-endian fix to DWARFDieTest (089c0f58)
Pavel Labath via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 20 05:36:02 PST 2019
Author: Pavel Labath
Date: 2019-11-20T14:35:41+01:00
New Revision: 82dc32e2d456c75d08bc9ffe97def409ee5a03cd
URL: https://github.com/llvm/llvm-project/commit/82dc32e2d456c75d08bc9ffe97def409ee5a03cd
DIFF: https://github.com/llvm/llvm-project/commit/82dc32e2d456c75d08bc9ffe97def409ee5a03cd.diff
LOG: Big-endian fix to DWARFDieTest (089c0f58)
Hardcode the DWARFContext to little-endian. I don't have a BE machine to
test this on, but I believe this should address the ppc64be failure.
Added:
Modified:
llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp
Removed:
################################################################################
diff --git a/llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp b/llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp
index 05e8e05b927e..6296f872433e 100644
--- a/llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp
+++ b/llvm/unittests/DebugInfo/DWARF/DWARFDieTest.cpp
@@ -84,7 +84,8 @@ TEST(DWARFLocationTable, getLocations) {
"debug_loclists",
MemoryBuffer::getMemBuffer(toStringRef(Loclists), "debug_loclists",
/*RequiresNullTerminator=*/false));
- std::unique_ptr<DWARFContext> Ctx = DWARFContext::create(*Sections, 8);
+ std::unique_ptr<DWARFContext> Ctx =
+ DWARFContext::create(*Sections, 4, /*isLittleEndian=*/true);
DWARFCompileUnit *CU = Ctx->getCompileUnitForOffset(0);
ASSERT_NE(nullptr, CU);
DWARFDie Die = CU->getUnitDIE();
More information about the llvm-commits
mailing list