Home
last modified time | relevance | path

Searched refs:NumBits (Results 1 – 25 of 93) sorted by relevance

1234

/llvm-project-15.0.7/llvm/include/llvm/Bitstream/
H A DBitstreamReader.h189 assert(NumBits && NumBits <= BitsInWord && in Read()
195 if (BitsInCurWord >= NumBits) { in Read()
199 CurWord >>= (NumBits & Mask); in Read()
201 BitsInCurWord -= NumBits; in Read()
224 R |= R2 << (NumBits - BitsLeft); in Read()
235 assert(NumBits <= 32 && NumBits >= 1 && "Invalid NumBits value"); in ReadVBR()
250 NextBit += NumBits-1; in ReadVBR()
255 MaybeRead = Read(NumBits); in ReadVBR()
269 assert(NumBits <= 32 && NumBits >= 1 && "Invalid NumBits value"); in ReadVBR64()
284 NextBit += NumBits-1; in ReadVBR64()
[all …]
H A DBitstreamWriter.h198 assert(NumBits && NumBits <= 32 && "Invalid value size!"); in Emit()
201 if (CurBit + NumBits < 32) { in Emit()
202 CurBit += NumBits; in Emit()
213 CurBit = (CurBit+NumBits) & 31; in Emit()
230 Emit((Val & ((1 << (NumBits-1))-1)) | (1 << (NumBits-1)), NumBits); in EmitVBR()
231 Val >>= NumBits-1; in EmitVBR()
234 Emit(Val, NumBits); in EmitVBR()
246 Emit(((uint32_t)Val & ((1 << (NumBits - 1)) - 1)) | (1 << (NumBits - 1)), in EmitVBR64()
247 NumBits); in EmitVBR64()
248 Val >>= NumBits-1; in EmitVBR64()
[all …]
/llvm-project-15.0.7/llvm/lib/TextAPI/
H A DArchitecture.cpp24 #define ARCHINFO(Arch, Type, Subtype, NumBits) \ in getArchitectureFromCpuType() argument
36 #define ARCHINFO(Arch, Type, Subtype, NumBits) .Case(#Arch, AK_##Arch) in getArchitectureFromName() argument
44 #define ARCHINFO(Arch, Type, Subtype, NumBits) \ in getArchitectureName() argument
60 #define ARCHINFO(Arch, Type, Subtype, NumBits) \ in getCPUTypeFromArchitecture() argument
80 #define ARCHINFO(Arch, Type, Subtype, NumBits) \ in is64Bit() argument
82 return NumBits == 64; in is64Bit()
/llvm-project-15.0.7/llvm/lib/Support/
H A DAPSInt.cpp25 unsigned NumBits = ((Str.size() * 64) / 19) + 2; in APSInt() local
26 APInt Tmp(NumBits, Str, /*radix=*/10); in APSInt()
29 if (MinBits < NumBits) in APSInt()
35 if (ActiveBits < NumBits) in APSInt()
/llvm-project-15.0.7/llvm/utils/TableGen/
H A DVarLenCodeEmitterGen.cpp90 : TheDef(TheDef), NumBits(0U) { in VarLenInst()
93 NumBits += S.BitWidth; in VarLenInst()
132 if (!isa<StringInit>(OperandName) || !isa<IntInit>(NumBits)) in buildRec()
135 auto NumBitsVal = cast<IntInit>(NumBits)->getValue(); in buildRec()
162 unsigned NumBits = 0U; in buildRec() local
165 NumBits = static_cast<unsigned>(LoBitVal - HiBitVal + 1); in buildRec()
167 NumBits = static_cast<unsigned>(HiBitVal - LoBitVal + 1); in buildRec()
177 Segments.push_back({NumBits, in buildRec()
181 Segments.push_back({NumBits, DI, CustomEncoder}); in buildRec()
434 unsigned NumBits = ES.BitWidth; in getInstructionCaseForEncoding() local
[all …]
H A DVarLenCodeEmitterGen.h29 size_t NumBits; variable
47 VarLenInst() : TheDef(nullptr), NumBits(0U), HasDynamicSegment(false) {} in VarLenInst()
52 size_t size() const { return NumBits; } in size()
H A DAsmWriterEmitter.cpp371 unsigned NumBits = Log2_32_Ceil(UniqueOperandCommands.size()); in EmitGetMnemonic() local
374 if (NumBits > BitsLeft) { in EmitGetMnemonic()
375 LLVM_DEBUG(errs() << "Not enough bits to densely encode " << NumBits in EmitGetMnemonic()
396 BitsLeft -= NumBits; in EmitGetMnemonic()
491 unsigned NumBits = Log2_32_Ceil(Commands.size()); in EmitPrintInstruction() local
492 assert(NumBits <= BitsLeft && "consistency error"); in EmitPrintInstruction()
495 O << "\n // Fragment " << i << " encoded into " << NumBits in EmitPrintInstruction()
502 << ((1 << NumBits)-1) << ") {\n" in EmitPrintInstruction()
513 << ((1 << NumBits)-1) << ") {\n" in EmitPrintInstruction()
524 BitsLeft -= NumBits; in EmitPrintInstruction()
H A DDecoderEmitter.cpp295 unsigned NumBits; // number of bits to filter member in __anoncf345abb0311::Filter
479 unsigned NumBits) const;
573 : Owner(f.Owner), StartBit(f.StartBit), NumBits(f.NumBits), Mixed(f.Mixed), in Filter()
583 assert(StartBit + NumBits - 1 < Owner->BitWidth); in Filter()
596 bool ok = Owner->fieldFromInsn(Field, Insn, StartBit, NumBits); in Filter()
627 for (unsigned bitIndex = 0; bitIndex < NumBits; ++bitIndex) in recurse()
648 for (unsigned bitIndex = 0; bitIndex < NumBits; ++bitIndex) { in recurse()
691 TableInfo.Table.push_back(NumBits); in emitTableEntry()
1038 for (unsigned i = 0; i < NumBits; ++i) { in fieldFromInsn()
1429 unsigned NumBits = EndBits[I-1] - StartBits[I-1] + 1; in emitSingletonTableEntry() local
[all …]
/llvm-project-15.0.7/clang/lib/AST/Interp/
H A DBoolean.h56 APSInt toAPSInt(unsigned NumBits) const { in toAPSInt() argument
57 return APSInt(toAPSInt().zextOrTrunc(NumBits), true); in toAPSInt()
84 static Boolean min(unsigned NumBits) { return Boolean(false); } in min() argument
85 static Boolean max(unsigned NumBits) { return Boolean(true); } in max() argument
106 static Boolean from(T Value, unsigned NumBits) { in from() argument
110 static bool inRange(int64_t Value, unsigned NumBits) { in inRange() argument
H A DIntegral.h109 APSInt toAPSInt(unsigned NumBits) const {
111 return APSInt(toAPSInt().sextOrTrunc(NumBits), !Signed);
113 return APSInt(toAPSInt().zextOrTrunc(NumBits), !Signed);
151 static Integral min(unsigned NumBits) {
154 static Integral max(unsigned NumBits) {
178 template <typename T> static Integral from(T Value, unsigned NumBits) {
182 static bool inRange(int64_t Value, unsigned NumBits) {
H A DByteCodeExprGen.h192 bool emitConst(PrimType T, unsigned NumBits, const llvm::APInt &Value,
198 unsigned NumBits = getIntWidth(Ty); in emitConst() local
199 APInt WrappedValue(NumBits, Value, std::is_signed<T>::value); in emitConst()
200 return emitConst(*Ctx.classify(Ty), NumBits, WrappedValue, E); in emitConst()
/llvm-project-15.0.7/llvm/lib/Target/CSKY/
H A DCSKYRegisterInfo.cpp135 unsigned NumBits = 0; in IsLegalOffset() local
140 NumBits = 12; in IsLegalOffset()
144 NumBits = 12; in IsLegalOffset()
148 NumBits = 12; in IsLegalOffset()
152 NumBits = 5; in IsLegalOffset()
156 NumBits = 5; in IsLegalOffset()
160 NumBits = 5; in IsLegalOffset()
164 NumBits = 8; in IsLegalOffset()
174 unsigned Mask = (1 << NumBits) - 1; in IsLegalOffset()
/llvm-project-15.0.7/llvm/lib/Target/AMDGPU/Disassembler/
H A DAMDGPUDisassembler.h43 void insertBits(uint64_t SubBits, unsigned BitPosition, unsigned NumBits) { in insertBits() argument
44 assert(NumBits && NumBits <= 64); in insertBits()
45 assert(SubBits >> 1 >> (NumBits - 1) == 0); in insertBits()
54 uint64_t extractBitsAsZExtValue(unsigned NumBits, in extractBitsAsZExtValue() argument
56 assert(NumBits && NumBits <= 64); in extractBitsAsZExtValue()
63 return Val & ((uint64_t(2) << (NumBits - 1)) - 1); in extractBitsAsZExtValue()
/llvm-project-15.0.7/compiler-rt/lib/scudo/standalone/
H A Dsize_class_map.h64 static const u8 S = Config::NumBits - 1;
112 static const u8 S = Config::NumBits - 1;
222 static const uptr NumBits = 3; member
234 static const uptr NumBits = 3; member
247 static const uptr NumBits = 7; member
262 static const uptr NumBits = 8;
291 static const uptr NumBits = 4; member
299 static const uptr NumBits = 4;
314 static const uptr NumBits = 1; member
/llvm-project-15.0.7/llvm/lib/Target/ARM/
H A DThumb2InstrInfo.cpp635 unsigned NumBits = 0; in rewriteT2FrameIndex() local
645 NumBits = 8; in rewriteT2FrameIndex()
650 NumBits = 12; in rewriteT2FrameIndex()
658 NumBits = 8; in rewriteT2FrameIndex()
672 NumBits = 8; in rewriteT2FrameIndex()
686 case ARMII::AddrModeT2_i7s4: NumBits = 9; OffsetMask = 0x3; break; in rewriteT2FrameIndex()
696 NumBits = 8 + 2; in rewriteT2FrameIndex()
702 NumBits = 8; // 8 bits scaled by 4 in rewriteT2FrameIndex()
719 unsigned Mask = (1 << NumBits) - 1; in rewriteT2FrameIndex()
735 ImmedOffset |= 1 << NumBits; in rewriteT2FrameIndex()
[all …]
H A DARMBaseRegisterInfo.cpp734 unsigned NumBits = 0; in isFrameOffsetLegal() local
746 NumBits = 8; in isFrameOffsetLegal()
749 NumBits = 12; in isFrameOffsetLegal()
754 NumBits = 8; in isFrameOffsetLegal()
759 NumBits = 12; in isFrameOffsetLegal()
762 NumBits = 8; in isFrameOffsetLegal()
765 NumBits = (BaseReg == ARM::SP ? 8 : 5); in isFrameOffsetLegal()
782 unsigned Mask = (1 << NumBits) - 1; in isFrameOffsetLegal()
/llvm-project-15.0.7/compiler-rt/lib/scudo/standalone/tests/
H A Dsize_class_map_test.cpp32 static const scudo::uptr NumBits = 1; member
47 static const scudo::uptr NumBits = 3; member
/llvm-project-15.0.7/llvm/include/llvm/Bitcode/
H A DBitcodeAnalyzer.h70 uint64_t NumBits; member
81 : NumInstances(0), NumBits(0), NumSubBlocks(0), NumAbbrevs(0), in PerBlockIDStats()
/llvm-project-15.0.7/llvm/lib/Transforms/InstCombine/
H A DInstCombineShifts.cpp526 static bool canEvaluateShifted(Value *V, unsigned NumBits, bool IsLeftShift, in canEvaluateShifted() argument
550 return canEvaluateShiftedShift(NumBits, IsLeftShift, I, IC, CxtI); in canEvaluateShifted()
556 return canEvaluateShifted(TrueVal, NumBits, IsLeftShift, IC, SI) && in canEvaluateShifted()
557 canEvaluateShifted(FalseVal, NumBits, IsLeftShift, IC, SI); in canEvaluateShifted()
565 if (!canEvaluateShifted(IncValue, NumBits, IsLeftShift, IC, PN)) in canEvaluateShifted()
574 MulConst->countTrailingZeros() == NumBits; in canEvaluateShifted()
644 static Value *getShiftedValue(Value *V, unsigned NumBits, bool isLeftShift, in getShiftedValue() argument
649 return IC.Builder.CreateShl(C, NumBits); in getShiftedValue()
651 return IC.Builder.CreateLShr(C, NumBits); in getShiftedValue()
671 return foldShiftedShift(cast<BinaryOperator>(I), NumBits, isLeftShift, in getShiftedValue()
[all …]
/llvm-project-15.0.7/llvm/include/llvm/DebugInfo/PDB/
H A DPDBTypes.h486 #define VARIANT_WIDTH(Enum, NumBits) \ argument
488 return NumBits;
511 #define VARIANT_APSINT(Enum, NumBits, IsUnsigned) \ argument
513 return APSInt(APInt(NumBits, Value.Enum), IsUnsigned);
/llvm-project-15.0.7/clang/lib/Lex/
H A DPPExpressions.cpp394 unsigned NumBits; in EvaluateValue() local
396 NumBits = TI.getIntWidth(); in EvaluateValue()
398 NumBits = TI.getWCharWidth(); in EvaluateValue()
400 NumBits = TI.getChar16Width(); in EvaluateValue()
402 NumBits = TI.getChar32Width(); in EvaluateValue()
404 NumBits = TI.getCharWidth(); in EvaluateValue()
407 llvm::APSInt Val(NumBits); in EvaluateValue()
/llvm-project-15.0.7/llvm/include/llvm/Support/
H A DKnownBits.h216 KnownBits extractBits(unsigned NumBits, unsigned BitPosition) const { in extractBits()
217 return KnownBits(Zero.extractBits(NumBits, BitPosition), in extractBits()
218 One.extractBits(NumBits, BitPosition)); in extractBits()
/llvm-project-15.0.7/llvm/test/TableGen/
H A DVarLenEncoder.td60 // CHECK: {/*NumBits*/41,
62 // CHECK: {/*NumBits*/57,
/llvm-project-15.0.7/llvm/include/llvm/TextAPI/
H A DArchitecture.h28 #define ARCHINFO(Arch, Type, SubType, NumBits) AK_##Arch, argument
/llvm-project-15.0.7/llvm/lib/IR/
H A DType.cpp311 IntegerType *IntegerType::get(LLVMContext &C, unsigned NumBits) { in get() argument
312 assert(NumBits >= MIN_INT_BITS && "bitwidth too small"); in get()
313 assert(NumBits <= MAX_INT_BITS && "bitwidth too large"); in get()
316 switch (NumBits) { in get()
327 IntegerType *&Entry = C.pImpl->IntegerTypes[NumBits]; in get()
330 Entry = new (C.pImpl->Alloc) IntegerType(C, NumBits); in get()

1234