llvm.org GIT mirror llvm / 75ee000
DIEHash: Include the trailing zero byte after the children of a DIE git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192836 91177308-0d34-0410-b5e6-96231b3b80d8 David Blaikie 7 years ago
2 changed file(s) with 4 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
382382 E = Die->getChildren().end();
383383 I != E; ++I)
384384 computeHash(*I);
385
386 // Following the last (or if there are no children), append a zero byte.
387 Hash.update((uint8_t)0);
385388 }
386389
387390 /// This is based on the type signature computation given in section 7.27 of the
2222 DIEInteger Size(4);
2323 Die.addValue(dwarf::DW_AT_byte_size, dwarf::DW_FORM_data1, &Size);
2424 uint64_t MD5Res = Hash.computeTypeSignature(&Die);
25 ASSERT_EQ(MD5Res, 0x540e9ff30ade3e4aULL);
25 ASSERT_EQ(MD5Res, 0x4F68EF1039F8D2BULL);
2626 }
2727 }