-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Closed
Labels
Description
| Bugzilla Link | 9126 |
| Version | trunk |
| OS | Linux |
| Reporter | LLVM Bugzilla Contributor |
| CC | @asl,@efriedma-quic |
Extended Description
I've heard about llvm only 10 minutes ago, and tried something on the website's "online compiler" 5 minutes ago:
#include <stdio.h>
#include <stdlib.h>
__float128 factorial(__float128 X) {
if (X == 0.0) return 1.0;
return X*factorial(X-1);
}
int main(int argc, char **argv) {
printf("%LLg\n", factorial(atoi(argv[1])));
}
(I had initially tried float128 and _float128 types, which don't seem to be recognized at all).
This crashes the compiler / optimizer:
/tmp/webcompile/_22203_0.c: In function 'factorial':
/tmp/webcompile/_22203_0.c:4: internal compiler error: Segmentation fault