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

Are the wrappers returning the right exit codes? #3

Closed
ianamason opened this issue Jun 30, 2017 · 1 comment
Closed

Are the wrappers returning the right exit codes? #3

ianamason opened this issue Jun 30, 2017 · 1 comment

Comments

@ianamason
Copy link
Member

This was why musllvm is a good test. I used to break this all the time.
Now when I compare

iam@shaman:~/Repositories/musllvm$ WLLVM_CONFIGURE_ONLY=1  CC=wllvm ./configure --target=LLVM --build=LLVM > wllvm.config.log

to

iam@shaman:~/Repositories/musllvm$ GLLVM_CONFIGURE_ONLY=1  CC=gclang ./configure --target=LLVM --build=LLVM > gllvm.config.log

I see different results:

iam@shaman:~/Repositories/musllvm$ diff wllvm.config.log gllvm.config.log
1c1
< checking for C compiler... wllvm
---
> checking for C compiler... gclang
13,14c13,14
< checking whether compiler accepts -fexcess-precision=standard... no
< checking whether compiler accepts -frounding-math... no
---
> checking whether compiler accepts -fexcess-precision=standard... yes
> checking whether compiler accepts -frounding-math... yes

a sure sign that we a making a boo boo with the exit codes.

@ianamason
Copy link
Member Author

OK so wllvm and gllvm now have exactly the same logging API.
We set the level to INFO and the output to a /tmp file.
When we configure
musl we see:

iam@shaman:/space/Repositories/musllvm$ grep "returned 1" /tmp/wllvm.txt
INFO:Calling ['/usr/local/bin/wllvm', '-Werror=unknown-warning-option', '-Werror=unused-command-line-argument', '-fexcess-precision=standard', '-c', '-o', '/dev/null', './conf2286-2428-1.c'] returned 1
INFO:Calling ['/usr/local/bin/wllvm', '-Werror=unknown-warning-option', '-Werror=unused-command-line-argument', '-frounding-math', '-c', '-o', '/dev/null', './conf2286-2428-1.c'] returned 1
INFO:Calling ['/usr/local/bin/wllvm', '-Werror=unknown-warning-option', '-Werror=unused-command-line-argument', '-fno-tree-loop-distribute-patterns', '-c', '-o', '/dev/null', './conf2286-2428-1.c'] returned 1
iam@shaman:/space/Repositories/musllvm$ grep "returned 1" /tmp/gllvm.txt
Calling [gclang -Werror=unknown-warning-option -Werror=unused-command-line-argument -fno-tree-loop-distribute-patterns -c -o /dev/null ./conf1976-2428-1.c] returned 1
iam@shaman:/space/Repositories/musllvm$

so they definitely do not agree. Currently gllvm agrees with clang. So maybe this issue should
be over in wllvm land. (Joke... we have revealed quite a few bugs in this investigation.)

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

No branches or pull requests

1 participant