• Home
  • Raw
  • Download

Lines Matching full:origin

10 // Origin id utils.
20 // Origin handling.
22 // Origin is a 32-bit identifier that is attached to any uninitialized value in
26 // There are 3 kinds of origin ids:
27 // 1xxx xxxx xxxx xxxx heap origin id
28 // 0000 xxxx xxxx xxxx stack origin id
29 // 0zzz xxxx xxxx xxxx chained origin id
31 // Heap origin id describes a heap memory allocation and contains (in the xxx
34 // Stack origin id describes a stack memory allocation and contains (in the xxx
38 // Chained origin id describes an event of storing an uninitialized value to
43 // * prev_id is another origin id that describes the earlier part of the
49 // points in value history marked with origin ids, and edges are events that are
52 // The "zzz" bits of chained origin id are used to store the length (or depth)
53 // of the origin chain.
55 class Origin {
85 // Returns the next origin in the chain and the current stack trace.
86 Origin getNextChainedOrigin(StackTrace *stack) const { in getNextChainedOrigin()
91 return Origin(prev_id); in getNextChainedOrigin()
98 static Origin CreateStackOrigin(u32 id) { in CreateStackOrigin()
100 return Origin((1 << kHeapShift) | id); in CreateStackOrigin()
103 static Origin CreateHeapOrigin(StackTrace *stack) { in CreateHeapOrigin()
107 return Origin(stack_id); in CreateHeapOrigin()
110 static Origin CreateChainedOrigin(Origin prev, StackTrace *stack) { in CreateChainedOrigin()
138 return Origin((1 << kHeapShift) | (depth << kDepthShift) | chained_id); in CreateChainedOrigin()
141 static Origin FromRawId(u32 id) { in FromRawId()
142 return Origin(id); in FromRawId()
156 explicit Origin(u32 raw_id) : raw_id_(raw_id) {} in Origin() function