Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1709)

Side by Side Diff: include/llvm/Bitcode/NaCl/NaClBitcodeBitsDist.h

Issue 1151093004: Changes from 3.7 merge to files not in upstream (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-llvm.git@master
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 //===- NaClBitcodeBitsDist.h ------------------------------------*- C++ -*-===// 1 //===- NaClBitcodeBitsDist.h ------------------------------------*- C++ -*-===//
2 // Maps distributions of values and corresponding number of 2 // Maps distributions of values and corresponding number of
3 // bits in PNaCl bitcode records. 3 // bits in PNaCl bitcode records.
4 // 4 //
5 // The LLVM Compiler Infrastructure 5 // The LLVM Compiler Infrastructure
6 // 6 //
7 // This file is distributed under the University of Illinois Open Source 7 // This file is distributed under the University of Illinois Open Source
8 // License. See LICENSE.TXT for details. 8 // License. See LICENSE.TXT for details.
9 // 9 //
10 //===----------------------------------------------------------------------===// 10 //===----------------------------------------------------------------------===//
11 // 11 //
12 // Creates a (nestable) distribution map of values, and the correspdonding 12 // Creates a (nestable) distribution map of values, and the correspdonding
13 // bits, in PNaCl bitcode records. These distributions are built directly 13 // bits, in PNaCl bitcode records. These distributions are built directly
14 // on top of the NaClBitcodeDistElement class. 14 // on top of the NaClBitcodeDistElement class.
15 15
16 #ifndef LLVM_BITCODE_NACL_NACLBITCODEBITSDIST_H 16 #ifndef LLVM_BITCODE_NACL_NACLBITCODEBITSDIST_H
17 #define LLVM_BITCODE_NACL_NACLBITCODEBITSDIST_H 17 #define LLVM_BITCODE_NACL_NACLBITCODEBITSDIST_H
18 18
19 #include "llvm/Bitcode/NaCl/NaClBitcodeDist.h" 19 #include "llvm/Bitcode/NaCl/NaClBitcodeDist.h"
20 20
21 namespace llvm { 21 namespace llvm {
22 22
23 /// Defines the element type of a PNaCl bitcode distribution map when 23 /// Defines the element type of a PNaCl bitcode distribution map when
24 /// we want to count both the number of instances, and the number of 24 /// we want to count both the number of instances, and the number of
25 /// bits used by each record. Also tracks the number to times an 25 /// bits used by each record. Also tracks the number to times an
26 /// abbreviation was used to parse the corresponding record. 26 /// abbreviation was used to parse the corresponding record.
27 class NaClBitcodeBitsDistElement : public NaClBitcodeDistElement { 27 class NaClBitcodeBitsDistElement : public NaClBitcodeDistElement {
28 NaClBitcodeBitsDistElement(const NaClBitcodeBitsDistElement&) 28 NaClBitcodeBitsDistElement(const NaClBitcodeBitsDistElement&) = delete;
29 LLVM_DELETED_FUNCTION; 29 void operator=(const NaClBitcodeBitsDistElement&) = delete;
30 void operator=(const NaClBitcodeBitsDistElement&)
31 LLVM_DELETED_FUNCTION;
32 30
33 public: 31 public:
34 static bool classof(const NaClBitcodeDistElement *Dist) { 32 static bool classof(const NaClBitcodeDistElement *Dist) {
35 return Dist->getKind() >= RDE_BitsDist 33 return Dist->getKind() >= RDE_BitsDist
36 && Dist->getKind() < RDE_BitsDistLast; 34 && Dist->getKind() < RDE_BitsDistLast;
37 } 35 }
38 36
39 // Create an element with no instances. 37 // Create an element with no instances.
40 explicit NaClBitcodeBitsDistElement( 38 explicit NaClBitcodeBitsDistElement(
41 NaClBitcodeDistElementKind Kind=RDE_BitsDist) 39 NaClBitcodeDistElementKind Kind=RDE_BitsDist)
(...skipping 19 matching lines...) Expand all
61 const NaClBitcodeDist *Distribution) const; 59 const NaClBitcodeDist *Distribution) const;
62 60
63 private: 61 private:
64 // Number of bits used to represent all instances of the value. 62 // Number of bits used to represent all instances of the value.
65 uint64_t TotalBits; 63 uint64_t TotalBits;
66 }; 64 };
67 65
68 } 66 }
69 67
70 #endif 68 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698