xref: /llvm-project/bolt/unittests/Core/DynoStats.cpp (revision 66b01a89346c600b34fb9e442dbc56d827755896)
1 //===- llvm/unittest/MC/MCInstPrinter.cpp ---------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #include "bolt/Core/DynoStats.h"
10 #include "bolt/Core/BinaryFunction.h"
11 #include "gtest/gtest.h"
12 #include <map>
13 
14 using namespace llvm::bolt;
15 
TEST(DynoStatsTest,emptyFuncs)16 TEST(DynoStatsTest, emptyFuncs) {
17   std::map<uint64_t, BinaryFunction> BinaryFunctions;
18   DynoStats DynoStatsAArch64 =
19       getDynoStats(BinaryFunctions, /* BC.isAArch64() = */ true);
20   DynoStats DynoStatsNonAArch64 =
21       getDynoStats(BinaryFunctions, /* BC.isAArch64() = */ false);
22   // Both should be null
23   ASSERT_EQ(DynoStatsAArch64, DynoStatsNonAArch64);
24 }
25