Commit Graph

7 Commits

Author SHA1 Message Date
Sean Silva d63f1f1ff2 [libprofile] Adjust dummy condition to be more forgiving.
On PS4, we have to fake environment variables by passing extra command
line arguments, so the dummy test `argc > 1` was failing.
The condition is just a dummy condition that the compiler can't fold
away, so the number is arbitrary as long as the condition is false.

Increase the number it compares against.

llvm-svn: 264491
2016-03-26 04:01:57 +00:00
Duncan P. N. Exon Smith 4a7fddca0d Update lib/profile tests for metadata assembly change
Running the upgrade script from PR21532.  Hopefully this will unstick
compiler-rt bots [1] after r224257.

[1]: http://lab.llvm.org:8080/green/job/clang-stage1-cmake-RA_check/181/

llvm-svn: 224276
2014-12-15 21:34:19 +00:00
Justin Bogner aa5bb91f5a profile: Robustify instrprof tests
Change these tests not to rely on the exact metadata numbers the
profile data gets.

llvm-svn: 222279
2014-11-18 23:03:14 +00:00
Jay Foad 8e586617c4 InstrProf: support PowerPC64
Summary:
I don't know anything about profiling but it seems to work out of the
box on PowerPC64. At least "make check-profile" works.

A few tests needed tweaking because PowerPC64 IR declares main with
"define signext i32 @main" instead of just "define i32 @main".

This also fixes the asan asan_and_llvm_coverage_test test, which
compiles with -coverage so requires that a profiling version of
libclang_rt has been built.

Reviewers: dexonsmith, kcc, samsonov

Reviewed By: samsonov

Subscribers: samsonov, llvm-commits

Differential Revision: http://reviews.llvm.org/D6233

llvm-svn: 221877
2014-11-13 09:24:32 +00:00
Saleem Abdulrasool 44a8c7233a profile: explicitly initialize file name in the test
The instrprofile-write-file-only test was failing on the builtbots.  The runtime
library initialization is explicitly being discarded to avoid the atexit hook.
However, this would also prevent the filename from being initialized.  Thus,
when the write file was invoked, the filename would not be setup, and the test
would fail as the profiling data would never be written out.  Explicitly
initialize the filename to ensure that the data is written out when requested.
This should hopefully finally get the build bots all green again.

llvm-svn: 209099
2014-05-18 20:05:35 +00:00
Alp Toker 1ee7fc7a1a Fix typos
llvm-svn: 208841
2014-05-15 02:22:34 +00:00
Duncan P. N. Exon Smith 238137294f InstrProf: Test the functions in the runtime
Check that the profile runtime works as expected.  This tests the
functions that are meant to be available to advanced users.

In particular, check that the `atexit()` hook can be disabled by
defining a custom `__llvm_profile_runtime` variable, that the libc
dependencies are optional, and that the various functions for writing
out files work for basic cases.

llvm-svn: 208460
2014-05-09 23:14:58 +00:00