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

AddData in ProfileData.cc crashes computeFunctionsPointsToSet using CFLSteens #329

Open
blipper opened this issue Apr 18, 2021 · 3 comments
Assignees
Labels
external bug A bug in depending code

Comments

@blipper
Copy link
Contributor

blipper commented Apr 18, 2021

Bug description

Analyzing a program with https://github.com/gperftools/gperftools/blob/master/src/profiledata.cc#L261 's ProfileData::Add crashes Phasar

0x00007fbed345c24000:26:26.056282 - [WARNING] Large number of pointers detected - Perf is O(N^2) here: 140 for ProfileData::Add(int, void const* const*)
WARNING: Logging before InitGoogle() is written to STDERR
F0418 22:15:46.428914 3693092 logging.cc:107] assert.h assertion failed at third_party/llvm/llvm-project/llvm/lib/Analysis/CFLGraph.h:205 in void llvm::cflaa::CFLGraphBuilderllvm::CFLSteensAAResult::GetEdgesVisitor::addNode(llvm::Value *, llvm::cflaa::AliasAttrs) [CFLAA = llvm::CFLSteensAAResult]: Val != nullptr && Val->getType()->isPointerTy()
*** Check failure stack trace: ***
@ 0x7fbeeebf0c3b absl::logging_internal::LogMessage::DieIfFatal()
@ 0x7fbeeebef8a7 absl::logging_internal::LogMessage::SendToLog()
@ 0x7fbeeebed8c0 absl::logging_internal::LogMessage::Flush()
@ 0x7fbeeebf20c9 absl::logging_internal::LogMessageFatal::~LogMessageFatal()
@ 0x7fbeeebe940e __assert_fail
@ 0x7fc0465ba0ab llvm::cflaa::CFLGraphBuilder<>::GetEdgesVisitor::addNode()
@ 0x7fc0465b9ad3 llvm::InstVisitor<>::visit()
@ 0x7fc0465b92f4 llvm::cflaa::CFLGraphBuilder<>::buildGraphFrom()
@ 0x7fc0465b1da6 llvm::CFLSteensAAResult::buildSetsFrom()
@ 0x7fc0465b3761 llvm::CFLSteensAAResult::scan()
@ 0x7fc0465b406b llvm::CFLSteensAAResult::ensureCached()
@ 0x7fc0465b4711 llvm::CFLSteensAAResult::query()
@ 0x7fc05475b71f llvm::CFLSteensAAResult::alias()
@ 0x7fc05475b505 llvm::AAResults::Model<>::alias()
@ 0x7fc04647ef6e llvm::AAResults::alias()
@ 0x7fc04647e7b5 llvm::AAResults::alias()
@ 0x7fc05477fb5b psr::LLVMPointsToSet::computeFunctionsPointsToSet()
@ 0x7fc05477cc9f psr::LLVMPointsToSet::computeValuesPointsToSet()
@ 0x7fc054788aa9 psr::LLVMPointsToSet::LLVMPointsToSet()
@ 0x7fc05501f5e6 psr::AnalysisController::AnalysisController()
@ 0x7fc055d688ef main
@ 0x7fbed34ecbbd __libc_start_main
@ 0x5602cec2baa9 _start

Steps to reproduce

Analyze any program with this function

@MMory MMory self-assigned this Apr 26, 2021
@MMory
Copy link
Member

MMory commented May 6, 2022

@blipper is this still an issue?

@vulder vulder self-assigned this Nov 8, 2022
@vulder
Copy link
Collaborator

vulder commented Nov 8, 2022

Good to find this issues. @MMory Yes I have fallen into this too. This crash happens also on one of my projects.

@MMory MMory added the external bug A bug in depending code label Dec 1, 2022
@MMory
Copy link
Member

MMory commented Dec 1, 2022

I was able to reproduce this issue and create a minimal example. imho this is an LLVM bug and I need to raise an issue there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external bug A bug in depending code
Projects
None yet
Development

No branches or pull requests

3 participants