Skip to content

Commit 917c91d

Browse files
committed
[Safer CPP] Address new NODELETE warnings after the safer cpp static analysis upgrade
https://bugs.webkit.org/show_bug.cgi?id=327233 Reviewed by Rupin Mittal. * Source/JavaScriptCore/SaferCPPExpectations/NoDeleteCheckerExpectations: * Source/JavaScriptCore/bytecode/CallLinkInfo.h: * Source/JavaScriptCore/bytecode/CodeBlock.h: * Source/JavaScriptCore/bytecode/CodeOrigin.h: * Source/JavaScriptCore/bytecode/ICStatusMap.h: * Source/JavaScriptCore/bytecode/PutByVariant.h: * Source/JavaScriptCore/bytecode/Watchpoint.h: * Source/JavaScriptCore/dfg/DFGByteCodeParser.cpp: (JSC::DFG::ByteCodeParser::currentCodeOrigin): (JSC::DFG::ByteCodeParser::currentNodeOrigin): * Source/JavaScriptCore/dfg/DFGFixupPhase.cpp: (JSC::DFG::FixupPhase::originForCheck): * Source/JavaScriptCore/dfg/DFGTierUpCheckInjectionPhase.cpp: (JSC::DFG::TierUpCheckInjectionPhase::canOSREnterAtLoopHint): * Source/JavaScriptCore/ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileCompareStrictEq): * Source/JavaScriptCore/ftl/FTLPatchpointExceptionHandle.h: * Source/JavaScriptCore/jit/PCToCodeOriginMap.h: * Source/WebCore/Modules/contact-picker/NavigatorContacts.h: * Source/WebCore/Modules/webcodecs/WebCodecsVideoFrame.h: * Source/WebCore/SaferCPPExpectations/NoDeleteCheckerExpectations: * Source/WebCore/css/CSSColorValue.h: * Source/WebCore/css/CSSCounterStyleRule.h: * Source/WebCore/css/CSSFontFeatureValuesRule.h: * Source/WebCore/css/CSSFontPaletteValuesRule.h: * Source/WebCore/css/CSSKeyframesRule.h: * Source/WebCore/css/CSSLayerStatementRule.h: * Source/WebCore/css/CSSProperties.json: * Source/WebCore/css/CSSPropertyRule.h: * Source/WebCore/css/CSSValueList.h: * Source/WebCore/css/CSSValuePair.h: * Source/WebCore/css/CSSViewTransitionRule.cpp: (WebCore::toViewTransitionNavigationEnum): * Source/WebCore/css/CSSViewTransitionRule.h: * Source/WebCore/css/DOMMatrixReadOnly.h: * Source/WebCore/css/parser/CSSPropertyParserConsumer+Anchor.h: * Source/WebCore/css/parser/CSSPropertyParserConsumer+Display.cpp: (WebCore::CSSPropertyParserHelpers::mappedDisplayValue): * Source/WebCore/css/values/CSSValueTypes.h: * Source/WebCore/dom/Document.h: * Source/WebCore/page/Page.h: * Source/WebCore/platform/graphics/FontCascadeFonts.cpp: (WebCore::MixedFontGlyphPage::setGlyphDataForCharacter): * Source/WebCore/platform/graphics/FontCascadeFonts.h: * Source/WebCore/platform/graphics/ShadowBlur.cpp: * Source/WebCore/platform/graphics/ShadowBlur.h: * Source/WebCore/platform/graphics/WidthIterator.cpp: (WebCore::resetGlyphBuffer): * Source/WebCore/platform/graphics/filters/FEDropShadow.h: * Source/WebCore/platform/graphics/filters/FEFlood.h: * Source/WebCore/platform/graphics/filters/FELighting.h: * Source/WebCore/platform/network/cocoa/CookieCocoa.mm: (WebCore::nsSameSitePolicy): * Source/WebCore/platform/text/BidiContext.cpp: (WebCore::copyContextAndRebaselineLevel): * Source/WebCore/platform/text/BidiContext.h: * Source/WebCore/rendering/AncestorSubgridIterator.h: * Source/WebCore/rendering/FloatingObjects.h: * Source/WebCore/rendering/RenderElement.h: * Source/WebCore/rendering/RenderLayer.cpp: (WebCore::ClipRectsCache::setClipRects): * Source/WebCore/rendering/RenderTableCell.cpp: (WebCore::CollapsedBorders::addBorder): * Source/WebCore/rendering/TextBoxTrimmer.cpp: (WebCore::removeTextBoxTrimStart): * Source/WebCore/style/RuleSet.h: * Source/WebCore/style/StyleBuilderState.h: * Source/WebCore/style/StyleResolver.h: * Source/WebCore/style/StyleScopeRuleSets.h: * Source/WebCore/style/computed/data/StyleInheritedData.h: * Source/WebCore/style/values/anchor-position/StylePositionArea.h: * Source/WebCore/style/values/backgrounds/StyleRepeatStyle.h: * Source/WebCore/style/values/grid/StyleGridAutoFlow.h: * Source/WebCore/style/values/masking/StyleMaskMode.h: * Source/WebCore/style/values/overflow/StyleScrollbarGutter.h: * Source/WebCore/style/values/scroll-animations/StyleScrollFunction.h: * Source/WebCore/style/values/scroll-snap/StyleScrollSnapAlign.h: * Source/WebCore/style/values/text/StyleTextAlignLast.h: * Source/WebCore/style/values/ui/StyleResize.h: * Source/WebCore/xml/parser/XMLDocumentParserLibxml2.cpp: (WebCore::closeFunc): Canonical link: https://commits.webkit.org/323521@main
1 parent 16838ce commit 917c91d

67 files changed

Lines changed: 95 additions & 152 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1 @@
1-
[ macOS ] bytecode/CallLinkInfo.cpp
2-
[ macOS ] bytecode/CodeBlock.cpp
3-
[ macOS ] bytecode/CodeOrigin.cpp
4-
[ macOS ] bytecode/ICStatusMap.cpp
5-
[ macOS ] bytecode/PutByVariant.cpp
6-
[ macOS ] bytecode/Watchpoint.cpp
7-
[ macOS ] dfg/DFGByteCodeParser.cpp
8-
[ macOS ] dfg/DFGFixupPhase.cpp
91
dfg/DFGIntegerRangeOptimizationPhase.cpp
10-
[ macOS ] dfg/DFGTierUpCheckInjectionPhase.cpp
11-
[ macOS ] ftl/FTLLowerDFGToB3.cpp
12-
[ macOS ] ftl/FTLPatchpointExceptionHandle.cpp
13-
[ macOS ] jit/PCToCodeOriginMap.cpp

‎Source/JavaScriptCore/bytecode/CallLinkInfo.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ class OptimizingCallLinkInfo final : public CallLinkInfo {
441441
m_callType = callType;
442442
}
443443

444-
void NODELETE initializeFromDFGUnlinkedCallLinkInfo(VM&, const DFG::UnlinkedCallLinkInfo&, CodeBlock*);
444+
void initializeFromDFGUnlinkedCallLinkInfo(VM&, const DFG::UnlinkedCallLinkInfo&, CodeBlock*);
445445

446446
private:
447447
void emitFastPath(CCallHelpers&);

‎Source/JavaScriptCore/bytecode/CodeBlock.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -533,7 +533,7 @@ class CodeBlock : public JSCell {
533533

534534
static constexpr ptrdiff_t offsetOfGlobalObject() { return OBJECT_OFFSETOF(CodeBlock, m_globalObject); }
535535

536-
JSGlobalObject* NODELETE globalObjectFor(CodeOrigin);
536+
JSGlobalObject* globalObjectFor(CodeOrigin);
537537

538538
BytecodeLivenessAnalysis& livenessAnalysis()
539539
{

‎Source/JavaScriptCore/bytecode/CodeOrigin.h‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,9 @@ class CodeOrigin {
160160

161161
// This checks if the two code origins correspond to the same stack trace snippets,
162162
// but ignore whether the InlineCallFrame's are identical.
163-
bool NODELETE isApproximatelyEqualTo(const CodeOrigin& other, InlineCallFrame* terminal = nullptr) const;
163+
bool isApproximatelyEqualTo(const CodeOrigin& other, InlineCallFrame* terminal = nullptr) const;
164164

165-
unsigned NODELETE approximateHash(InlineCallFrame* terminal = nullptr) const;
165+
unsigned approximateHash(InlineCallFrame* terminal = nullptr) const;
166166

167167
template <typename Function>
168168
void walkUpInlineStack(NOESCAPE const Function&) const;

‎Source/JavaScriptCore/bytecode/ICStatusMap.h‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ typedef UncheckedKeyHashMap<CodeOrigin, ICStatus, CodeOriginApproximateHash> ICS
5454

5555
struct ICStatusContext {
5656
ICStatus get(CodeOrigin) const;
57-
bool NODELETE isInlined(CodeOrigin) const;
58-
ExitingInlineKind NODELETE inlineKind(CodeOrigin) const;
57+
bool isInlined(CodeOrigin) const;
58+
ExitingInlineKind inlineKind(CodeOrigin) const;
5959

6060
InlineCallFrame* inlineCallFrame { nullptr };
6161
CodeBlock* optimizedCodeBlock { nullptr };

‎Source/JavaScriptCore/bytecode/PutByVariant.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ class PutByVariant {
109109
return m_newStructure;
110110
}
111111

112-
void NODELETE fixTransitionToReplaceIfNecessary();
112+
void fixTransitionToReplaceIfNecessary();
113113

114114
bool NODELETE writesStructures() const;
115115
bool NODELETE reallocatesStorage() const;

‎Source/JavaScriptCore/bytecode/Watchpoint.h‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ class InlineWatchpointSet {
501501
}
502502

503503
JS_EXPORT_PRIVATE WatchpointSet* inflateSlow();
504-
JS_EXPORT_PRIVATE void NODELETE freeFat();
504+
JS_EXPORT_PRIVATE void freeFat();
505505

506506
uintptr_t m_data;
507507
};

‎Source/JavaScriptCore/dfg/DFGByteCodeParser.cpp‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1096,12 +1096,12 @@ class ByteCodeParser {
10961096
return !inlineCallFrame() || !inlineCallFrame()->getCallerSkippingTailCalls();
10971097
}
10981098

1099-
CodeOrigin NODELETE currentCodeOrigin()
1099+
CodeOrigin currentCodeOrigin()
11001100
{
11011101
return CodeOrigin(m_currentIndex, inlineCallFrame());
11021102
}
11031103

1104-
NodeOrigin NODELETE currentNodeOrigin()
1104+
NodeOrigin currentNodeOrigin()
11051105
{
11061106
CodeOrigin semantic = m_currentSemanticOrigin.isSet() ? m_currentSemanticOrigin : currentCodeOrigin();
11071107
CodeOrigin forExit = m_currentExitOrigin.isSet() ? m_currentExitOrigin : currentCodeOrigin();

‎Source/JavaScriptCore/dfg/DFGFixupPhase.cpp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5041,7 +5041,7 @@ class FixupPhase : public Phase {
50415041
return index;
50425042
}
50435043

5044-
NodeOrigin NODELETE originForCheck(unsigned index)
5044+
NodeOrigin originForCheck(unsigned index)
50455045
{
50465046
return m_block->at(index)->origin.withSemantic(m_currentNode->origin.semantic);
50475047
}

‎Source/JavaScriptCore/dfg/DFGTierUpCheckInjectionPhase.cpp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ class TierUpCheckInjectionPhase : public Phase {
154154
bool canOSREnter;
155155
};
156156

157-
bool NODELETE canOSREnterAtLoopHint(FTL::CapabilityLevel level, const BasicBlock* block, unsigned nodeIndex)
157+
bool canOSREnterAtLoopHint(FTL::CapabilityLevel level, const BasicBlock* block, unsigned nodeIndex)
158158
{
159159
Node* node = block->at(nodeIndex);
160160
ASSERT(node->op() == LoopHint);

0 commit comments

Comments
 (0)