X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=utils%2Fprofile.pl;h=f9950f97fea82179c1e22a23b820db1ef18211ac;hb=ebb5a971d903aa4479bb2a21472597319a9b0086;hp=dfa6bab12e4cb7ced71dad12208af662fa259509;hpb=bd02b0a91573ba1a3742e3e3077d72321800d945;p=oota-llvm.git diff --git a/utils/profile.pl b/utils/profile.pl index dfa6bab12e4..f9950f97fea 100755 --- a/utils/profile.pl +++ b/utils/profile.pl @@ -62,11 +62,10 @@ my $BytecodeFile = $ARGV[0]; shift @ARGV; -my $LLIPath = `which lli`; -$LLIPath = `dirname $LLIPath`; -chomp $LLIPath; +my $libdir = `llvm-config --libdir`; +chomp $libdir; -my $LibProfPath = $LLIPath . "/../../Debug/lib/libprofile_rt.so"; +my $LibProfPath = $libdir . "/profile_rt.so"; system "opt -q -f $ProfilePass $BytecodeFile -o $BytecodeFile.inst"; system "lli -fake-argv0 '$BytecodeFile' -load $LibProfPath " .