LLVM
15.0.0git
|
Represents the relative location of an instruction. More...
#include "llvm/ProfileData/SampleProf.h"
Public Member Functions | |
LineLocation (uint32_t L, uint32_t D) | |
void | print (raw_ostream &OS) const |
void | dump () const |
bool | operator< (const LineLocation &O) const |
bool | operator== (const LineLocation &O) const |
bool | operator!= (const LineLocation &O) const |
Public Attributes | |
uint32_t | LineOffset |
uint32_t | Discriminator |
Represents the relative location of an instruction.
Instruction locations are specified by the line offset from the beginning of the function (marked by the line where the function header is) and the discriminator value within that line.
The discriminator value is useful to distinguish instructions that are on the same line but belong to different basic blocks (e.g., the two post-increment instructions in "if (p) x++; else y++;").
Definition at line 282 of file SampleProf.h.
Definition at line 283 of file SampleProf.h.
LLVM_DUMP_METHOD void LineLocation::dump | ( | ) | const |
Definition at line 132 of file SampleProf.cpp.
References llvm::dbgs(), and print().
|
inline |
Definition at line 297 of file SampleProf.h.
References Discriminator, LineOffset, and llvm::RISCVFenceField::O.
|
inline |
Definition at line 288 of file SampleProf.h.
References Discriminator, LineOffset, and llvm::RISCVFenceField::O.
|
inline |
Definition at line 293 of file SampleProf.h.
References Discriminator, LineOffset, and llvm::RISCVFenceField::O.
void LineLocation::print | ( | raw_ostream & | OS | ) | const |
Definition at line 107 of file SampleProf.cpp.
References Discriminator, and LineOffset.
Referenced by dump(), and llvm::sampleprof::operator<<().
uint32_t llvm::sampleprof::LineLocation::Discriminator |
Definition at line 302 of file SampleProf.h.
Referenced by llvm::sampleprof::SampleContext::decodeContextString(), llvm::sampleprof::FunctionSamples::getCallSiteHash(), llvm::sampleprof::hash_value(), operator!=(), operator<(), operator==(), print(), llvm::sampleprof::SampleContextFrame::toString(), llvm::sampleprof::SampleProfileWriterBinary::writeBody(), llvm::sampleprof::SampleProfileWriterExtBinaryBase::writeFuncMetadata(), and llvm::sampleprof::SampleProfileWriterText::writeSample().
uint32_t llvm::sampleprof::LineLocation::LineOffset |
Definition at line 301 of file SampleProf.h.
Referenced by llvm::sampleprof::SampleContext::decodeContextString(), llvm::sampleprof::FunctionSamples::getCallSiteHash(), llvm::sampleprof::hash_value(), operator!=(), operator<(), operator==(), print(), llvm::sampleprof::SampleContextFrame::toString(), llvm::sampleprof::SampleProfileWriterBinary::writeBody(), llvm::sampleprof::SampleProfileWriterExtBinaryBase::writeFuncMetadata(), and llvm::sampleprof::SampleProfileWriterText::writeSample().