similar to: Is -disable-llvm-passes and -disable-llvm-optzns different?

Displaying 20 results from an estimated 10000 matches similar to: "Is -disable-llvm-passes and -disable-llvm-optzns different?"

2018 Jan 09
3
Is -disable-llvm-passes and -disable-llvm-optzns different?
Quick results: [twang15 at c89 temp]$ clang -mllvm -help clang-5.0: error: no input files [twang15 at c89 temp]$ clang -mllvm -help-hidden clang-5.0: error: no input files [twang15 at c89 temp]$ clang -mllvm --help-hidden clang-5.0: error: no input files [twang15 at c89 temp]$ clang -mllvm --help clang-5.0: error: no input files Anything wrong? On Tue, Jan 9, 2018 at 1:56 AM, Craig Topper
2018 Jan 09
0
Is -disable-llvm-passes and -disable-llvm-optzns different?
There's a hack in lib/Driver/ToolChains/Clang.cpp to accept "-mllvm -disable-llvm-optzns" as a hack for legacy compatibility. It's deprecated and the -Xclang spelling should be used. There does appear to be a bug with "-mllvm -disable-llvm-optzns" and -save-temps. -save-temps causes clang to be invoked separately to text assembly into binary code, and it looks like
2018 Jan 09
0
Is -disable-llvm-passes and -disable-llvm-optzns different?
clang -O3 -mllvm -help -c LULESH.cc succeeds. On Tue, Jan 9, 2018 at 2:05 AM, toddy wang <wenwangtoddy at gmail.com> wrote: > Quick results: > > [twang15 at c89 temp]$ clang -mllvm -help > clang-5.0: error: no input files > [twang15 at c89 temp]$ clang -mllvm -help-hidden > clang-5.0: error: no input files > [twang15 at c89 temp]$ clang -mllvm --help-hidden >
2018 Jan 09
1
Is -disable-llvm-passes and -disable-llvm-optzns different?
Thanks for pointing this out. The following is a more extensive test. //succeed means dumping help info without Error message. clang -help #succeed 'clang -help-hidden' #Fail 'clang --help-hidden' #Succeed clang -mllvm -v -help #Succeed clang -mllvm -v -help-hidden #Fail clang -mllvm -v --help-hidden #Succeed 'clang -mllvm -help -c LULESH.cc' #Succeed 'clang -mllvm
2018 Jan 09
0
Relationship between clang, opt and llc
Thanks, Craig. So, clang -Xclang -disable-llvm-passes actually disables all the LLVM passed populated by clang so that there is no middle-end optimization on bc files. clang -O2 LULESH.c //clang is the driver, invoking cc1, cc1as, ld //options can be passed through to cc1 directly. //maybe have different names, e.g.
2018 Jan 09
3
Relationship between clang, opt and llc
Yes that is what he meant. "-dce, -adce, etc" are command line options consumed by tools/opt/opt.cpp to give to the PassManagerBuilder that it creates. The parsing of those options doesn't exist in any of the llvm library code that is linked into clang. Clang has its own code for populating a PassManagerBuilder in tools/clang/lib/CodeGen/BackendUtil.cpp ~Craig On Mon, Jan 8, 2018
2018 Jan 09
1
Relationship between clang, opt and llc
//mllvm Options can be dumped by clang -v -help -mllvm and clang -v --help-hidden --> //mllvm Options can be dumped by clang -v -help -mllvm and clang -v --help-hidden -mllvm On Tue, Jan 9, 2018 at 3:09 AM, toddy wang <wenwangtoddy at gmail.com> wrote: > Thanks, Craig. > > So, clang -Xclang -disable-llvm-passes actually disables all the LLVM > passed populated by clang so
2018 Jan 09
0
Relationship between clang, opt and llc
Mehdi, I found -unroll-max-count can be passed w/ -mllvm. -dce, -adce, etc, are also dumped by 'opt --help-hidden'. However, they cannot be passed w/ -mllvm. Is this what "You can't schedule passes this way, only set parameters like -unroll-threshold=<uint> etc." means? [twang15 at c89 temp]$ clang++ -mllvm -unroll-max-count=4 -mllvm -dce -save-temps LULESH.cc clang
2018 Jan 08
2
Relationship between clang, opt and llc
2018-01-08 8:59 GMT-08:00 toddy wang <wenwangtoddy at gmail.com>: > > > On Mon, Jan 8, 2018 at 11:53 AM, Mehdi AMINI <joker.eph at gmail.com> wrote: > >> >> >> 2018-01-08 8:41 GMT-08:00 toddy wang <wenwangtoddy at gmail.com>: >> >>> Hi Medhi, >>> >>> It seems -mllvm does not work as expected. Anything wrong?
2018 Jan 08
2
Relationship between clang, opt and llc
2018-01-08 8:41 GMT-08:00 toddy wang <wenwangtoddy at gmail.com>: > Hi Medhi, > > It seems -mllvm does not work as expected. Anything wrong? > > [twang15 at c92 temp]$ clang++ -O3 -mllvm *-deadargelim* LULESH.cc > clang (LLVM option parsing): Unknown command line argument > '-deadargelim'. Try: 'clang (LLVM option parsing) -help' > clang (LLVM option
2018 Jan 08
0
Relationship between clang, opt and llc
Hi Medhi, It seems -mllvm does not work as expected. Anything wrong? [twang15 at c92 temp]$ clang++ -O3 -mllvm *-deadargelim* LULESH.cc clang (LLVM option parsing): Unknown command line argument '-deadargelim'. Try: 'clang (LLVM option parsing) -help' clang (LLVM option parsing): Did you mean '-regalloc'? [twang15 at c92 temp]$ clang++ -O3 -mllvm *deadargelim* LULESH.cc
2018 Jan 08
0
Relationship between clang, opt and llc
On Mon, Jan 8, 2018 at 11:53 AM, Mehdi AMINI <joker.eph at gmail.com> wrote: > > > 2018-01-08 8:41 GMT-08:00 toddy wang <wenwangtoddy at gmail.com>: > >> Hi Medhi, >> >> It seems -mllvm does not work as expected. Anything wrong? >> >> [twang15 at c92 temp]$ clang++ -O3 -mllvm *-deadargelim* LULESH.cc >> clang (LLVM option parsing):
2018 Jan 08
2
Relationship between clang, opt and llc
2018-01-07 23:16 GMT-08:00 toddy wang <wenwangtoddy at gmail.com>: > -mllvm <value> Additional arguments to forward to LLVM's option > processing > > This is dumped by clang. I am not sure what I am supposed to put as value > in order to tune unrolling/inlining threshold. > As the help says, this is used to pass argument to LLVM itself. If you remember
2018 Jan 06
0
Relationship between clang, opt and llc
@Zhaopei, thanks for the clarification. @Craig and @Michael, for clang 4.0.1, -Xclang -disable-O0-optnone gives the following error message. From which version -disable-O0-optnone gets supported? [twang15 at c89 temp]$ clang++ -O0 -Xclang -disable-O0-optnone -Xclang -disable-llvm-passes -c -emit-llvm -o a.bc LULESH.cc error: unknown argument: '-disable-O0-optnone' [twang15 at c89
2018 Jan 06
1
Relationship between clang, opt and llc
After build LLVM5.0, I found that clang-5.0 is extremely slow. Even it is built with -DCMAKE_BUILD_TYPE=Release For building LULESH.cc, it gets stucked at linkage stage. I build it as instructed from here https://github.com/flang-compiler/flang Maybe I should submit a bug. On Fri, Jan 5, 2018 at 8:41 PM, toddy wang <wenwangtoddy at gmail.com> wrote: > Craig, thanks a lot! > >
2018 Jan 08
2
Relationship between clang, opt and llc
For the types of things that you are looking for, you may just want to try a bunch of -mllvm options. You can tune inlining and unrolling threshold like that, for example. On Jan 7, 2018 10:33 PM, "toddy wang via llvm-dev" <llvm-dev at lists.llvm.org> wrote: > Hi Mehdi, > > Now we have 5 pipelines. (In addition to the first 3, which I have > described in detail above,
2018 Jan 06
4
Relationship between clang, opt and llc
O0 didn't start applying optnone until r304127 in May 2017 which is after the 4.0 family was branched. So only 5.0, 6.0, and trunk have that behavior. Commit message copied below Author: Mehdi Amini <joker.eph at gmail.com> Date: Mon May 29 05:38:20 2017 +0000 IRGen: Add optnone attribute on function during O0 Amongst other, this will help LTO to correctly handle/honor
2018 Jan 06
0
Relationship between clang, opt and llc
Craig, thanks a lot! I'm actually confused by clang optimization flags. If I run clang -help, it will show many optimizations (denoted as set A) and non-optimization options (denoted as set B). If I run llvm-as < /dev/null | opt -O0/1/2/3 -disable-output -debug-pass=Arguments, it also shows many optimization flags (denote as set C). There are many options in set C while not in set A,
2018 Jan 08
0
Relationship between clang, opt and llc
-mllvm <value> Additional arguments to forward to LLVM's option processing This is dumped by clang. I am not sure what I am supposed to put as value in order to tune unrolling/inlining threshold. On Mon, Jan 8, 2018 at 2:02 AM, Sean Silva <chisophugis at gmail.com> wrote: > For the types of things that you are looking for, you may just want to try > a bunch of
2018 Jan 06
2
Relationship between clang, opt and llc
@Craig and @Michael After installing clang-5.0 (download from http://releases.llvm.org, does not have Flang build's slowdown mention above), 1. clang++ -O0 -Xclang -disable-O0-optnone -Xclang -disable-llvm-passes -c -emit-llvm -o a.bc LULESH.cc; opt -O3 a.bc -o b.bc; llc -O3 -filetype=obj b.bc -o b.o ; clang++ b.o -o b.out; ./b.out 20 runtime: 2.354069e+01 2. clang++ -O1 -Xclang