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

Side by Side Diff: src/IceBitVector.h

Issue 1960393002: Subzero: Add necessary PNaCl files for standalone build. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero@master
Patch Set: make format Created 4 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
« no previous file with comments | « pnacl-llvm/include/llvm/Bitcode/NaCl/NaClReaderWriter.h ('k') | src/IceCompileServer.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceBitVector.h - Inline bit vector. ----------*- C++ -*-===// 1 //===- subzero/src/IceBitVector.h - Inline bit vector. ----------*- C++ -*-===//
2 // 2 //
3 // The Subzero Code Generator 3 // The Subzero Code Generator
4 // 4 //
5 // This file is distributed under the University of Illinois Open Source 5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details. 6 // License. See LICENSE.TXT for details.
7 // 7 //
8 //===----------------------------------------------------------------------===// 8 //===----------------------------------------------------------------------===//
9 /// 9 ///
10 /// \file 10 /// \file
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 "Unsupported word size"); 256 "Unsupported word size");
257 257
258 BitWord *Bits; // Actual bits. 258 BitWord *Bits; // Actual bits.
259 unsigned Size; // Size of bitvector in bits. 259 unsigned Size; // Size of bitvector in bits.
260 unsigned Capacity; // Size of allocated memory in BitWord. 260 unsigned Capacity; // Size of allocated memory in BitWord.
261 Allocator Alloc; 261 Allocator Alloc;
262 262
263 uint64_t alignTo(uint64_t Value, uint64_t Align) { 263 uint64_t alignTo(uint64_t Value, uint64_t Align) {
264 #ifdef PNACL_LLVM 264 #ifdef PNACL_LLVM
265 return llvm::RoundUpToAlignment(Value, Align); 265 return llvm::RoundUpToAlignment(Value, Align);
266 #else // !PNACL_LLVM 266 #else // !PNACL_LLVM
267 return llvm::alignTo(Value, Align); 267 return llvm::alignTo(Value, Align);
268 #endif // !PNACL_LLVM 268 #endif // !PNACL_LLVM
269 } 269 }
270 270
271 public: 271 public:
272 typedef unsigned size_type; 272 typedef unsigned size_type;
273 // Encapsulation of a single bit. 273 // Encapsulation of a single bit.
274 class reference { 274 class reference {
275 friend class BitVectorTmpl; 275 friend class BitVectorTmpl;
276 276
(...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 821
822 namespace std { 822 namespace std {
823 /// Implement std::swap in terms of BitVectorTmpl swap. 823 /// Implement std::swap in terms of BitVectorTmpl swap.
824 template <template <typename> class AT> 824 template <template <typename> class AT>
825 inline void swap(Ice::BitVectorTmpl<AT> &LHS, Ice::BitVectorTmpl<AT> &RHS) { 825 inline void swap(Ice::BitVectorTmpl<AT> &LHS, Ice::BitVectorTmpl<AT> &RHS) {
826 LHS.swap(RHS); 826 LHS.swap(RHS);
827 } 827 }
828 } 828 }
829 829
830 #endif // SUBZERO_SRC_ICEBITVECTOR_H 830 #endif // SUBZERO_SRC_ICEBITVECTOR_H
OLDNEW
« no previous file with comments | « pnacl-llvm/include/llvm/Bitcode/NaCl/NaClReaderWriter.h ('k') | src/IceCompileServer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698