Quuxplusone / LLVMBugzillaTest

0 stars 0 forks source link

Assertion failed: ((NumParams == FTy->getNumParams() || (FTy->isVarArg() && NumParams > FTy->getNumParams())) && "Calling a function with bad signature!"), function init, file Instructions.cpp, line 307. #6344

Closed Quuxplusone closed 14 years ago

Quuxplusone commented 14 years ago
Bugzilla Link PR5865
Status RESOLVED FIXED
Importance P normal
Reported by Roman Divacky (rdivacky@freebsd.org)
Reported on 2009-12-23 16:45:48 -0800
Last modified on 2010-02-22 12:46:26 -0800
Version unspecified
Hardware PC FreeBSD
CC daniel@zuster.org, dgregor@apple.com, efriedma@quicinc.com, llvm-bugs@lists.llvm.org
Fixed by commit(s)
Attachments
Blocks
Blocked by
See also
pes delta$ cat 000.cc
    struct char_traits   {};
  template<typename _CharT>
    class basic_ifstream;
    class basic_ios   {};
    class basic_istream : virtual public basic_ios   {};
  template<typename _CharT>
    class basic_ifstream : public basic_istream
    {
      basic_ifstream() : basic_istream() {}
    };
  template class basic_ifstream<char>;

pes delta$ clang 000.cc
Assertion failed: ((NumParams == FTy->getNumParams() || (FTy->isVarArg() &&
NumParams > FTy->getNumParams())) && "Calling a function with bad signature!"),
function init, file Instructions.cpp, line 307.
Stack dump:
0.      Program arguments: /usr/local/bin/clang -cc1 -triple x86_64-unknown-
freebsd8.0 -S -disable-free -main-file-name 000.cc -mrelocation-model static -
mdisable-fp-elim -munwind-tables -target-cpu x86-64 -resource-dir
/usr/local/lib/clang/1.1 -fmessage-length 152 -fexceptions -fgnu-runtime -
fdiagnostics-show-option -fcolor-diagnostics -o /tmp/cc-bsJ54S.s -x c++ 000.cc
1.      000.cc:11:38: current parser token ';'
2.      000.cc:9:7: LLVM IR generation of declaration
'basic_ifstream<char>::basic_ifstream'
3.      000.cc:9:7: Generating code for declaration
'basic_ifstream<char>::basic_ifstream'
clang: error: compiler command failed due to signal 6 (use -v to see invocation)
Quuxplusone commented 14 years ago

This looks like it's from LLVM. Is it?

Quuxplusone commented 14 years ago

This looks like .

The issue here is that we aren't passing in the VTT parameter when nececssary.

Quuxplusone commented 14 years ago

See also rdar://problem/7495203 clang C++ asserts when compiling auto_gdb_interface.cpp (if you can).

Quuxplusone commented 14 years ago
seems to work with recent clang:

clang version 1.1 (trunk 93632)
Target: x86_64-unknown-freebsd8.0
Thread model: posix
pes ~$ clang -c 000.cc && echo succes
succes

I am not sure if the issue has been fixed or just covered though
Quuxplusone commented 14 years ago

Ok, lets call it fixed then.