reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

Declarations

include/llvm/Support/LEB128.h
  194 extern unsigned getSLEB128Size(int64_t Value);

References

lib/CodeGen/AsmPrinter/DIE.cpp
  449     return getSLEB128Size(Integer);
lib/CodeGen/AsmPrinter/EHStreamer.cpp
  120         SizeActionEntry = getSLEB128Size(Actions[PrevAction].NextAction) +
  121                           getSLEB128Size(Actions[PrevAction].ValueForTypeID);
  125           SizeActionEntry -= getSLEB128Size(Actions[PrevAction].ValueForTypeID);
  137         unsigned SizeTypeID = getSLEB128Size(ValueForTypeID);
  140         SizeActionEntry = SizeTypeID + getSLEB128Size(NextAction);
lib/ObjectYAML/DWARFEmitter.cpp
  338       Length += getSLEB128Size(S);
tools/dsymutil/DwarfStreamer.cpp
  572         LineSectionSize += 1 + getSLEB128Size(LineDelta);
unittests/Support/LEB128Test.cpp
  185   EXPECT_EQ(1u, getSLEB128Size(0x0LL));
  186   EXPECT_EQ(1u, getSLEB128Size(0x1LL));
  187   EXPECT_EQ(1u, getSLEB128Size(0x3fLL));
  188   EXPECT_EQ(1u, getSLEB128Size(0x3fLL));
  189   EXPECT_EQ(2u, getSLEB128Size(0x40LL));
  191   EXPECT_EQ(2u, getSLEB128Size(0x7fLL));
  192   EXPECT_EQ(2u, getSLEB128Size(0x80LL));
  193   EXPECT_EQ(2u, getSLEB128Size(0x1f80LL));
  194   EXPECT_EQ(2u, getSLEB128Size(0x1fffLL));
  195   EXPECT_EQ(3u, getSLEB128Size(0x2000LL));
  197   EXPECT_EQ(3u, getSLEB128Size(0x3fffLL));
  198   EXPECT_EQ(3u, getSLEB128Size(0x4000LL));
  199   EXPECT_EQ(3u, getSLEB128Size(0xfc000LL));
  200   EXPECT_EQ(3u, getSLEB128Size(0xfffffLL));
  201   EXPECT_EQ(4u, getSLEB128Size(0x100000LL));
  203   EXPECT_EQ(4u, getSLEB128Size(0x1fffffLL));
  204   EXPECT_EQ(4u, getSLEB128Size(0x200000LL));
  205   EXPECT_EQ(4u, getSLEB128Size(0x7e00000LL));
  206   EXPECT_EQ(4u, getSLEB128Size(0x7ffffffLL));
  207   EXPECT_EQ(5u, getSLEB128Size(0x8000000LL));
  209   EXPECT_EQ(5u, getSLEB128Size(0xfffffffLL));
  210   EXPECT_EQ(5u, getSLEB128Size(0x10000000LL));
  211   EXPECT_EQ(5u, getSLEB128Size(0x3f0000000LL));
  212   EXPECT_EQ(5u, getSLEB128Size(0x3ffffffffLL));
  213   EXPECT_EQ(6u, getSLEB128Size(0x400000000LL));
  215   EXPECT_EQ(6u, getSLEB128Size(0x7ffffffffLL));
  216   EXPECT_EQ(6u, getSLEB128Size(0x800000000LL));
  217   EXPECT_EQ(6u, getSLEB128Size(0x1f800000000LL));
  218   EXPECT_EQ(6u, getSLEB128Size(0x1ffffffffffLL));
  219   EXPECT_EQ(7u, getSLEB128Size(0x20000000000LL));
  221   EXPECT_EQ(7u, getSLEB128Size(0x3ffffffffffLL));
  222   EXPECT_EQ(7u, getSLEB128Size(0x40000000000LL));
  223   EXPECT_EQ(7u, getSLEB128Size(0xfc0000000000LL));
  224   EXPECT_EQ(7u, getSLEB128Size(0xffffffffffffLL));
  225   EXPECT_EQ(8u, getSLEB128Size(0x1000000000000LL));
  227   EXPECT_EQ(8u, getSLEB128Size(0x1ffffffffffffLL));
  228   EXPECT_EQ(8u, getSLEB128Size(0x2000000000000LL));
  229   EXPECT_EQ(8u, getSLEB128Size(0x7e000000000000LL));
  230   EXPECT_EQ(8u, getSLEB128Size(0x7fffffffffffffLL));
  231   EXPECT_EQ(9u, getSLEB128Size(0x80000000000000LL));
  233   EXPECT_EQ(9u, getSLEB128Size(0xffffffffffffffLL));
  234   EXPECT_EQ(9u, getSLEB128Size(0x100000000000000LL));
  235   EXPECT_EQ(9u, getSLEB128Size(0x3f00000000000000LL));
  236   EXPECT_EQ(9u, getSLEB128Size(0x3fffffffffffffffLL));
  237   EXPECT_EQ(10u, getSLEB128Size(0x4000000000000000LL));
  239   EXPECT_EQ(10u, getSLEB128Size(0x7fffffffffffffffLL));
  240   EXPECT_EQ(10u, getSLEB128Size(INT64_MAX));
  250   EXPECT_EQ(1u, getSLEB128Size(0x0LL));
  251   EXPECT_EQ(1u, getSLEB128Size(-0x1LL));
  252   EXPECT_EQ(1u, getSLEB128Size(-0x3fLL));
  253   EXPECT_EQ(1u, getSLEB128Size(-0x40LL));
  254   EXPECT_EQ(1u, getSLEB128Size(-0x40LL)); // special case
  255   EXPECT_EQ(2u, getSLEB128Size(-0x41LL));
  257   EXPECT_EQ(2u, getSLEB128Size(-0x7fLL));
  258   EXPECT_EQ(2u, getSLEB128Size(-0x80LL));
  259   EXPECT_EQ(2u, getSLEB128Size(-0x1f80LL));
  260   EXPECT_EQ(2u, getSLEB128Size(-0x2000LL));
  261   EXPECT_EQ(3u, getSLEB128Size(-0x207fLL));
  262   EXPECT_EQ(3u, getSLEB128Size(-0x2080LL));
  264   EXPECT_EQ(3u, getSLEB128Size(-0x3fffLL));
  265   EXPECT_EQ(3u, getSLEB128Size(-0x4000LL));
  266   EXPECT_EQ(3u, getSLEB128Size(-0xfc000LL));
  267   EXPECT_EQ(3u, getSLEB128Size(-0x100000LL));
  268   EXPECT_EQ(4u, getSLEB128Size(-0x103fffLL));
  269   EXPECT_EQ(4u, getSLEB128Size(-0x104000LL));
  271   EXPECT_EQ(4u, getSLEB128Size(-0x1fffffLL));
  272   EXPECT_EQ(4u, getSLEB128Size(-0x200000LL));
  273   EXPECT_EQ(4u, getSLEB128Size(-0x7e00000LL));
  274   EXPECT_EQ(4u, getSLEB128Size(-0x8000000LL));
  275   EXPECT_EQ(5u, getSLEB128Size(-0x81fffffLL));
  276   EXPECT_EQ(5u, getSLEB128Size(-0x8200000LL));
  278   EXPECT_EQ(5u, getSLEB128Size(-0xfffffffLL));
  279   EXPECT_EQ(5u, getSLEB128Size(-0x10000000LL));
  280   EXPECT_EQ(5u, getSLEB128Size(-0x3f0000000LL));
  281   EXPECT_EQ(5u, getSLEB128Size(-0x400000000LL));
  282   EXPECT_EQ(6u, getSLEB128Size(-0x40fffffffLL));
  283   EXPECT_EQ(6u, getSLEB128Size(-0x410000000LL));
  285   EXPECT_EQ(6u, getSLEB128Size(-0x7ffffffffLL));
  286   EXPECT_EQ(6u, getSLEB128Size(-0x800000000LL));
  287   EXPECT_EQ(6u, getSLEB128Size(-0x1f800000000LL));
  288   EXPECT_EQ(6u, getSLEB128Size(-0x20000000000LL));
  289   EXPECT_EQ(7u, getSLEB128Size(-0x207ffffffffLL));
  290   EXPECT_EQ(7u, getSLEB128Size(-0x20800000000LL));
  292   EXPECT_EQ(7u, getSLEB128Size(-0x3ffffffffffLL));
  293   EXPECT_EQ(7u, getSLEB128Size(-0x40000000000LL));
  294   EXPECT_EQ(7u, getSLEB128Size(-0xfc0000000000LL));
  295   EXPECT_EQ(7u, getSLEB128Size(-0x1000000000000LL));
  296   EXPECT_EQ(8u, getSLEB128Size(-0x103ffffffffffLL));
  297   EXPECT_EQ(8u, getSLEB128Size(-0x1040000000000LL));
  299   EXPECT_EQ(8u, getSLEB128Size(-0x1ffffffffffffLL));
  300   EXPECT_EQ(8u, getSLEB128Size(-0x2000000000000LL));
  301   EXPECT_EQ(8u, getSLEB128Size(-0x7e000000000000LL));
  302   EXPECT_EQ(8u, getSLEB128Size(-0x80000000000000LL));
  303   EXPECT_EQ(9u, getSLEB128Size(-0x81ffffffffffffLL));
  304   EXPECT_EQ(9u, getSLEB128Size(-0x82000000000000LL));
  306   EXPECT_EQ(9u, getSLEB128Size(-0xffffffffffffffLL));
  307   EXPECT_EQ(9u, getSLEB128Size(-0x100000000000000LL));
  308   EXPECT_EQ(9u, getSLEB128Size(-0x3f00000000000000LL));
  309   EXPECT_EQ(9u, getSLEB128Size(-0x4000000000000000LL));
  310   EXPECT_EQ(10u, getSLEB128Size(-0x40ffffffffffffffLL));
  311   EXPECT_EQ(10u, getSLEB128Size(-0x4100000000000000LL));
  313   EXPECT_EQ(10u, getSLEB128Size(-0x7fffffffffffffffLL));
  314   EXPECT_EQ(10u, getSLEB128Size(-0x8000000000000000LL));
  315   EXPECT_EQ(10u, getSLEB128Size(INT64_MIN));