I use the following command to figure out the sequence of clang O3,
$ opt -enable-new-pm=0 -O3 -debug-pass=Arguments input.ll
and I get a very long optimization sequence.
Is that sequence same for all of code? Or O3 can change the order according to the source code?
And, I found that if I use -O0 flag to generate IR file, the attributes may be like this,
attributes #0 = { noinline nounwind uwtable "frame-pointer"="all" "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-pr otector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { "frame-pointer"="all" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target- features"="+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
we can see the value of frame-pointer = all, and I think that may let the code slow.
( It will be turned to none by using O3 flag)
How can I change this value by opt command?
thanks a lot.