OSDN Git Service

[BPF] fix flaky btf unit test static-var-derived-type.ll
authorYonghong Song <yhs@fb.com>
Fri, 22 Mar 2019 02:54:47 +0000 (02:54 +0000)
committerYonghong Song <yhs@fb.com>
Fri, 22 Mar 2019 02:54:47 +0000 (02:54 +0000)
commit551e44401a9806760bcb1a69dfabaa10145f6e56
tree87b061f8323327788e3c37aadbc02d38a6a19482
parent4ff2529e870334bbd215f19823347fba5162924e
[BPF] fix flaky btf unit test static-var-derived-type.ll

The DataSecEentries is defined as an unordered_map since
order does not really matter.
  std::unordered_map<std::string, std::unique_ptr<BTFKindDataSec>>
      DataSecEntries;
This seems causing the test static-var-derived-type.ll flaky
as two sections ".bss" and ".readonly" have undeterministic
ordering when performing map iterating, which decides the
output assembly code sequence of BTF_KIND_DATASEC entries.

Fix the test to have only one data section to remove
flakiness.

Signed-off-by: Yonghong Song <yhs@fb.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@356731 91177308-0d34-0410-b5e6-96231b3b80d8
test/CodeGen/BPF/BTF/static-var-derived-type.ll