Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion llvm/include/llvm/CodeGen/TargetLowering.h
Original file line number Diff line number Diff line change
Expand Up @@ -3738,7 +3738,7 @@ class LLVM_ABI TargetLoweringBase {
/// register class is the largest legal super-reg register class of the
/// register class of the specified type. e.g. On x86, i8, i16, and i32's
/// representative class would be GR32.
const TargetRegisterClass *RepRegClassForVT[MVT::VALUETYPE_SIZE] = {0};
const TargetRegisterClass *RepRegClassForVT[MVT::VALUETYPE_SIZE] = {nullptr};

/// This indicates the "cost" of the "representative" register class for each
/// ValueType. The cost is used by the scheduler to approximate register
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/DebugInfo/GSYM/GsymCreator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ llvm::Error GsymCreator::saveSegments(StringRef Path,
createSegment(SegmentSize, FuncIdx);
if (ExpectedGC) {
GsymCreator *GC = ExpectedGC->get();
if (GC == NULL)
if (GC == nullptr)
break; // We had not more functions to encode.
// Don't collect any messages at all
OutputAggregator Out(nullptr);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ struct PerfState {
std::unique_ptr<raw_fd_ostream> Dumpstream;

// perf mmap marker
void *MarkerAddr = NULL;
void *MarkerAddr = nullptr;
};

// prevent concurrent dumps from messing up the output file
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/SandboxIR/Context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ Argument *Context::getOrCreateArgument(llvm::Argument *LLVMArg) {
}

Constant *Context::getOrCreateConstant(llvm::Constant *LLVMC) {
return cast<Constant>(getOrCreateValueInternal(LLVMC, 0));
return cast<Constant>(getOrCreateValueInternal(LLVMC, nullptr));
}

BasicBlock *Context::createBasicBlock(llvm::BasicBlock *LLVMBB) {
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ Register SPIRVGlobalRegistry::buildGlobalVariable(
.addDef(ResVReg)
.addUse(getSPIRVTypeID(BaseType))
.addImm(static_cast<uint32_t>(Storage));
if (Init != 0)
if (Init != nullptr)
MIB.addUse(Init->getOperand(0).getReg());
// ISel may introduce a new register on this step, so we need to add it to
// DT and correct its type avoiding fails on the next stage.
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/TargetParser/Host.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1179,7 +1179,7 @@ static const char *getAMDProcessorTypeAndSubtype(unsigned Family,
const unsigned *Features,
unsigned *Type,
unsigned *Subtype) {
const char *CPU = 0;
const char *CPU = nullptr;

switch (Family) {
case 4:
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/Transforms/IPO/ExpandVariadics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ bool ExpandVariadics::runOnModule(Module &M) {
if (CB->isIndirectCall()) {
FunctionType *FTy = CB->getFunctionType();
if (FTy->isVarArg())
Changed |= expandCall(M, Builder, CB, FTy, 0);
Changed |= expandCall(M, Builder, CB, FTy, nullptr);
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions llvm/unittests/ProfileData/InstrProfTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -914,7 +914,7 @@ TEST_P(MaybeSparseInstrProfTest, annotate_vp_data) {
ASSERT_THAT(ValueData, SizeIs(0));

// Remove the MD_prof metadata
Inst->setMetadata(LLVMContext::MD_prof, 0);
Inst->setMetadata(LLVMContext::MD_prof, nullptr);
// Annotate 5 records this time.
annotateValueSite(*M, *Inst, R.get(), IPVK_IndirectCallTarget, 0, 5);
ValueData = getValueProfDataFromInst(*Inst, IPVK_IndirectCallTarget, 5, T);
Expand All @@ -932,7 +932,7 @@ TEST_P(MaybeSparseInstrProfTest, annotate_vp_data) {
ASSERT_EQ(2U, ValueData[4].Count);

// Remove the MD_prof metadata
Inst->setMetadata(LLVMContext::MD_prof, 0);
Inst->setMetadata(LLVMContext::MD_prof, nullptr);
// Annotate with 4 records.
InstrProfValueData VD0Sorted[] = {{1000, 6}, {2000, 5}, {3000, 4}, {4000, 3},
{5000, 2}, {6000, 1}};
Expand Down
Loading