Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[UBSAN][TrackFindingTracklet] shift exponent -1 is negative #46403

Open
smuzaffar opened this issue Oct 16, 2024 · 7 comments
Open

[UBSAN][TrackFindingTracklet] shift exponent -1 is negative #46403

smuzaffar opened this issue Oct 16, 2024 · 7 comments

Comments

@smuzaffar
Copy link
Contributor

UBSAN IBs show that we have runtime error [a] coming from if (newalpha >= (1 << (nalphabits - 1))) https://github.com/cms-sw/cmssw/blob/master/L1Trigger/TrackFindingTracklet/src/Stub.cc#L60 . This happens when https://github.com/cms-sw/cmssw/blob/master/L1Trigger/TrackFindingTracklet/src/Stub.cc#L32-L35 condition is false and nalphabits remain 0. @cms-sw/l1-l2 can you please review this code and provide a fix?

[a] https://cmssdt.cern.ch/SDT/jenkins-artifacts/ubsan_logs/CMSSW_14_2_X_2024-10-14-2300/logs/c8/c8317d776207b840ed29d1bc0b023c15/log

23634.0/step2:L1Trigger/TrackFindingTracklet/src/Stub.cc:60:22: runtime error: shift exponent -1 is negative
24034.0/step2:L1Trigger/TrackFindingTracklet/src/Stub.cc:60:22: runtime error: shift exponent -1 is negative
24834.911/step2:L1Trigger/TrackFindingTracklet/src/Stub.cc:60:22: runtime error: shift exponent -1 is negative
25234.0/step2:L1Trigger/TrackFindingTracklet/src/Stub.cc:60:22: runtime error: shift exponent -1 is negative
25634.0/step2:L1Trigger/TrackFindingTracklet/src/Stub.cc:60:22: runtime error: shift exponent -1 is negative
@smuzaffar
Copy link
Contributor Author

assign L1Trigger/TrackFindingTracklet

@cmsbuild
Copy link
Contributor

New categories assigned: l1

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

@cmsbuild
Copy link
Contributor

cms-bot internal usage

@cmsbuild
Copy link
Contributor

A new Issue was created by @smuzaffar.

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

cms-bot commands are listed here

@iarspider
Copy link
Contributor

Also reported by LLVM analyzer: https://cmssdt.cern.ch/SDT/jenkins-artifacts/ib-static-analysis/CMSSW_14_2_X_2024-10-15-1400/el8_amd64_gcc12/llvm-analysis/report-4d0f82.html#EndPath

@aloeliger
Copy link
Contributor

@BenjaminRS

@BenjaminRS
Copy link
Contributor

I believe this code comes under the L1 Tracker group. In particular this piece of code was introduced in their PR#74 here. Perhaps @tomalin and @zdemirag can comment?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants