cms-sw / cmssw

CMS Offline Software
http://cms-sw.github.io/
Apache License 2.0
1.09k stars 4.32k forks source link

[LLVM Analyzer] Called C++ object pointer is null in PtAssignment::configure #46059

Open iarspider opened 2 months ago

iarspider commented 2 months ago

LLVM analyzer reports "Called C++ object pointer is null" warning in PtAssignment::configure .

iarspider commented 2 months ago

assign L1Trigger/L1TMuonEndCap

cmsbuild commented 2 months ago

New categories assigned: l1

@epalencia,@aloeliger you have been requested to review this Pull request/Issue and eventually sign? Thanks

cmsbuild commented 2 months ago

cms-bot internal usage

cmsbuild commented 2 months ago

A new Issue was created by @iarspider.

@Dr15Jones, @antoniovilela, @makortel, @mandrenguyen, @rappoccio, @sextonkennedy, @smuzaffar can you please review it and eventually sign/assign? Thanks.

cms-bot commands are listed here

dan131riley commented 2 months ago

Looks like a false positive, the annotation at line 22 doesn't make any sense.

Dr15Jones commented 2 months ago

So it looks like emtf_assert(pt_assign_engine_dxy != nullptr); doesn't really do anything:

https://github.com/cms-sw/cmssw/blob/a18ec539ad314a5025d96238811861f94806db58/L1Trigger/L1TMuonEndCap/interface/DebugTools.h#L15C1-L19C7

so the static analyzer may have a point.