[llbm] miBench dataset has optnone function attribute set
See original GitHub issue🐛 Bug
I am not sure whether it is a bug, or perhaps it is due to the dataset?
I run the e-greedy algorithm https://github.com/facebookresearch/CompilerGym/blob/development/leaderboard/llvm_instcount/e_greedy/e_greedy.py on mibench. The results seems does not make sense at all: all rewards are 0 in terms of instruction count.
I don’t think it is due the implementation of e_greedy.py. Actually I wrote one version of greedy algorithm and it has the same results.
Why this happen? any problem in the benchmark? should we add some notes about this in the website?
To Reproduce
Steps to reproduce the behavior:
python e_greedy.py --n=1 --epsilon=0 --test_dataset=mibench-v0 --leaderboard_results=greedy_mibench.csv
Environment
Please fill in this checklist:
- CompilerGym: 0.2.1
- How you installed CompilerGym (conda, pip, source): pip
- OS: Ubuntu 18.04
- Python version: 3.6.9
- Build command you used (if compiling from source):
- GCC/clang version (if compiling from source):
- Bazel version (if compiling from source):
- Versions of any other relevant libraries:
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
D28404 IRGen: Add optnone attribute on function during O0
Track whether we need to add the optnone LLVM attribute, // starting with the ... And Os/Oz set OptimizationLevel to 2, which is...
Read more >LLVM Environment Reference — CompilerGym 0.2.5 ...
A validatable dataset is one where the behavior of the benchmarks can be checked by compiling the programs to binaries and executing them....
Read more >[llvm-dev] Revisiting/refining the definition of ... - Google Groups
I consider this a bug - in that optnone is used to implement -O0 for LTO ... This function attribute indicates that most...
Read more >Prevent Clang/LLVM from inlining or removing ... - GitHub
Clang/LLVM can inline or remove MPIR_Breakpoint as dead function. Can the optnone attribute be added to the MPIR_Breakpoint function to ...
Read more >In clang, how do you use per-function optimization attributes?
As advocated by @dulacc in his comment, __attribute__ ((optnone)) works on clang 9.0.0 on Mac's High Sierra.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
No, just update references from mibench-v0 to mibench-v1.
Cheers, Chris
Thanks. I will have a try. Do I need to manually remove the cache of the old version mibench?