Commit Graph

53 Commits

Author SHA1 Message Date
Daniel Dunbar
3d4d01bd39 Eliminate llvmgcc_version testing variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96908 91177308-0d34-0410-b5e6-96231b3b80d8
2010-02-23 07:56:28 +00:00
Daniel Dunbar
a2b40a95b2 Kill unused llvmgccmajvers testing variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96906 91177308-0d34-0410-b5e6-96231b3b80d8
2010-02-23 07:56:18 +00:00
Daniel Dunbar
9e2556c7bf Add llvm_supports_darwin_and_target to DejaGNU as well, I'd almost forgotten it
ever existed. :)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95230 91177308-0d34-0410-b5e6-96231b3b80d8
2010-02-03 18:43:46 +00:00
Daniel Dunbar
840a718105 tests: Add llvm_supports_binding predicate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81664 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-13 01:41:18 +00:00
Daniel Dunbar
5110609ceb tests: Add a %abs_tmp substitution which is guaranteed to be a full path.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81662 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-13 01:39:50 +00:00
Daniel Dunbar
f3e2d80770 Remove prcontext.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81427 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-10 04:56:59 +00:00
Daniel Dunbar
b25f32bab8 Avoid Tcl substitution, introduced %llvmgcc_only for this one little test
(%llvmgcc includes a '-w' argument, and this test looks for warnings).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81152 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-07 19:25:54 +00:00
Erick Tryzelaar
b405bbe664 Replace ocamlc tests with ocamlopt tests since they're less noisy.
There's a bug with ocamlc that uses "char*" instead of "const char*" for
global string variables. This causes g++ to be very noisy when linking
ocamlc programs. That's why the ocaml test used to cat to /dev/null.
ocamlopt doesn't have this problem, so we can get rid of the >/dev/null,
which may obscure some problems.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80968 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 23:27:31 +00:00
Nick Lewycky
084f7bf8a7 In an XFAIL line, treat "XFAIL: foo*bar" as a regular expression to be matched
against the target triple, instead of equivalent to "XFAIL: *".


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73219 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-12 05:18:32 +00:00
Evan Cheng
802cd84eb4 Re-commit r67334 and r67349 with fix.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67451 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-21 18:12:24 +00:00
Nick Lewycky
faf880fd5d Revert r67334 and r37349 which break "make check" on Linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67368 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-20 07:56:31 +00:00
Evan Cheng
23d8539d1e Fix typo's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67349 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-20 00:14:09 +00:00
Evan Cheng
817046e1f1 More makefile changes to allow dejagnu tests to pass when system tools default to a different target from the llvm configuration (e.g. 64-bit gcc and 32-bit llvm).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67334 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-19 20:27:23 +00:00
Mikhail Glushenkov
922b2a2e86 Trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66268 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-06 12:21:40 +00:00
Devang Patel
6748f044b2 Run dsymutil on darwin, when it is expected, before running gdb test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63548 91177308-0d34-0410-b5e6-96231b3b80d8
2009-02-02 21:09:36 +00:00
Torok Edwin
237033e6ac Fix make check on Solaris 10/x86: the default grep is not GNU grep, same for as.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57912 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-21 17:21:32 +00:00
Nuno Lopes
2bdc07b398 add support for running the test suite with valgrind. to run it just type 'make VG=1', as in clang
beware of the 42000 leaks reported by valgrind in the Constant.cpp + Type.cpp files. it needs fixing IMHO

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57245 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-07 14:48:14 +00:00
Duncan Sands
96f945267c Actually run Obj-C++ tests if llvm-gcc supports.
Before there were two problems: (1) configure
turned "obj-c++" into "obj" in the langs line;
(2) the dejagnu library called it objc++ not
obj-c++.
Now the problem is that some of these tests don't
pass!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57167 91177308-0d34-0410-b5e6-96231b3b80d8
2008-10-06 10:31:21 +00:00
Duncan Sands
c93346af8e Use correct compiler component names for objc
and objc++.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54474 91177308-0d34-0410-b5e6-96231b3b80d8
2008-08-07 17:59:54 +00:00
Duncan Sands
3921266559 Regression test for PR2443.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52826 91177308-0d34-0410-b5e6-96231b3b80d8
2008-06-27 14:22:20 +00:00
Duncan Sands
53ebe352ab Turn off llvm-gcc warnings when running "make check".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52595 91177308-0d34-0410-b5e6-96231b3b80d8
2008-06-21 20:22:58 +00:00
Matthijs Kooijman
c9e00434e3 Change llvm.exp so it no longer ignores some errors when executing dejagnu
tests. This breaks 80 tests in the tree.

The interesting part here is that this no longer ignores syntax errors
in RUN command lines. Some tests have not been working all the time because of
this.

The tricky part is that it now also views any stderr output as an error. This
can be suppressed in tcl 8.5, but let's not add this dependency. Instead, all
testcases should be changed to redirect stderr if they expect stderr output.
This holds in particular for lines like:
  ; RUN: not llvm-as < %s
where an error is expected (but I think I can solve this by modifying the not
script). Also, compilations resulting in warnings will now also fail (so
the warnings should be fixed, disabled or redirected...).

I'll continue with fixing the testcases that are broken now.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52172 91177308-0d34-0410-b5e6-96231b3b80d8
2008-06-10 12:28:43 +00:00
Tanya Lattner
200d607b45 Fix error in testing for END. notation.
Patch by Julien Lerouge. Thanks!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48342 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-13 22:02:51 +00:00
Chris Lattner
aadbda85a0 Fix PR2120 by changing the replacement order to change compile_cxx
before compile_c.  Patch by Joachim Durchholz!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48132 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-10 06:45:35 +00:00
Gabor Greif
684ed3d987 While hunting for two hanging tests,
(on solaris10, which are:
  CodeGen/PowerPC/frounds.ll
  Transforms/InstCombine/2008-02-23-MulSub.ll)

I needed a tool to figure out which one is the guilty.

To this end I have added a verbosity
option to the test/Makefile.

It can be invoked thus:

gmake check TESTSUITE=CodeGen/PowerPC VERBOSE="-v -v"

(The number of "-v"s specifies the verbosity level.
 Instead of "-v" other aliases can be specified,
 please consult the dejagnu docs for info.)

At level >= 2 following line is logged for each
test, before running it:

ABOUT TO RUN: <test>.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47602 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-26 12:08:55 +00:00
Tanya Lattner
727842e9d7 Fix bug in regression tests that ignored stderr output in RUN lines. Updated tests and fixed broken run lines.
XFAILed 3 arm regressions (will file bugs)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44389 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-28 04:57:00 +00:00
Tanya Lattner
a57506eea4 Implement the XTARGET feature for PR1778
This will mark a test as PASS for all targets specified. It will override whatever is in XFAIL.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43788 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:32:17 +00:00
Gordon Henriksen
8ef426baa3 Adding ocaml language bindings for the vmcore and bitwriter libraries. These are
built atop the C language bindings, and user programs can link with them as 
such:

  # Bytecode
  ocamlc -cc g++ llvm.cma llvmbitwriter.cma -o example example.ml
  # Native
  ocamlopt -cc g++ llvm.cmxa llvmbitwriter.cmxa -o example.opt example.ml

The vmcore.ml test exercises most/all of the APIs thus far bound. Unfortunately,
they're not yet numerous enough to write hello world. But:

  $ cat example.ml
  (* example.ml *)
  
  open Llvm
  open Llvm_bitwriter
  
  let _ =
    let filename = Sys.argv.(1) in
    let m = create_module filename in
    
    let v = make_int_constant i32_type 42 false in
    let g = define_global "hello_world" v m in
    
    if not (write_bitcode_file m filename) then exit 1;
    
    dispose_module m;

  $ ocamlc -cc g++ llvm.cma llvm_bitwriter.cma -o example example.ml
  File "example.ml", line 11, characters 6-7:
  Warning Y: unused variable g.
  $ ./example example.bc
  $ llvm-dis < example.bc
  ; ModuleID = '<stdin>'
  @hello_world = global i32 42            ; <i32*> [#uses=0]

The ocaml test cases provide effective tests for the C interfaces.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42093 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-18 12:49:39 +00:00
Duncan Sands
6c7ada4c58 The Ada f-e produces various auxiliary output files
that cannot be suppressed and cannot be redirected:
they are dumped in the current working directory.
When running the testsuite this means that these
files do not end up in the Output directory.  The
best solution I could find is to change directory
into Output before running tests.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40437 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-23 15:23:35 +00:00
Duncan Sands
7d841a4914 Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37224 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-18 12:13:34 +00:00
Reid Spencer
4f6e9ab3d7 Dan is right, using "string first" would produce false positives. So,
devolve the check to a comparison against each component in the string.
Fortunately there isn't many of them.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36376 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-23 21:21:53 +00:00
Reid Spencer
3dc662c5db Fix the comparison of language names to accept any characters by using
"string first" instead of "regexp match". This helps C++ tests get executed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36339 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-22 14:14:11 +00:00
Reid Spencer
12d81f3ff4 Replace llvm_gcc_supports_ada and llvm_gcc_supports_objc with just a single
llvm_gcc_supports function that takes the language as an argument. Base that
function on the new LLVMGCC_LANGS configured variable so that we don't have
to execute feature checks during the test run.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36322 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 21:45:51 +00:00
Reid Spencer
40a4c61cb7 Add the llvm_supports_target function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36314 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 20:40:17 +00:00
Duncan Sands
4e9471d3d9 Test if the compiler supports Ada, and enable Ada tests if so. While I was
there, delete a temporary file the objc test forgot to delete.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36312 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 20:20:47 +00:00
Reid Spencer
6cdf4a93a7 Always print the same "PR" information in the same location (just after
the test name) in all cases (PASS, XPASS, FAIL, XFAIL). This makes the
output consistent and more amenable to parsing by nightly test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36311 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 18:53:12 +00:00
Reid Spencer
1e55bf251c Put failure information on a separate line. Hopefully this unbreaks the
nightly tester which expects the FAIL: line to only have the test name on
it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36310 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 18:46:52 +00:00
Devang Patel
9fe9907ff9 Enable Objective-C tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36281 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-20 21:24:01 +00:00
Duncan Sands
3724df3132 Spelling fix.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36165 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 21:19:45 +00:00
Duncan Sands
25d50d6f6a Change ne into !=.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36135 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 15:37:00 +00:00
Reid Spencer
fb7653e3ee Two changes:
1. Don't bother truncating reading of the file. It doesn't save that much
   time and we should support putting RUN lines anywhere in the file. For
   example, someone might want to put the grep match before each function
   in the test file which would sprinkle the RUN: lines throughout the file.
2. Fix a bug with llvmgcc version match .. global var wasn't declared as such


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36085 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 20:43:36 +00:00
Reid Spencer
6b2e2be2e4 Some tests have really long RUN line sets. Read the first 4096 bytes instead
of 1024.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36083 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 20:31:42 +00:00
Reid Spencer
601e845d60 Allow lines that have \ and end in \ to be recognized as ending in \
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36074 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 18:38:42 +00:00
Reid Spencer
66959cecdb Two improvements:
1. Only read the first 1024 bytes of the file. The RUN: lines should all be
   within that amount of space.  This keeps I/O costs down when reading
   very large files.
2. Print PR numbers with a PR prefix so it is clear what they are.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36071 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 10:27:54 +00:00
Reid Spencer
b0feffae1d No, don't cancel all remaining tests, just the one that failed!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36057 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 07:34:58 +00:00
Reid Spencer
0947df4606 Abandone the entire test case on the first error.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36056 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 07:21:26 +00:00
Reid Spencer
12ca929ca0 Allow replacement of %% with %
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36044 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 04:57:03 +00:00
Reid Spencer
78fb2acea2 Changes to fix problems with "make check". Apparently you can redefine
functions and Tcl's just tickled with that. The fix is to give the "new"
test system a different interface function name.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36022 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 22:51:29 +00:00
Reid Spencer
90016c7939 For PR1319:
More improvements:
1. Using ::errorInfo wasn't such a hot idea. Go back to just printing the
   offending line of code and the stderr output. This is sufficient and
   not entangled with Tcl goop.
2. Capture the problem report numbers and report them whether pass or fail.
   This helps quickly get some context when a test fails, if it has an
   associated PR number.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36010 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 19:37:22 +00:00
Reid Spencer
9a03bdac51 1. Don't generate redundant copy of stderr
2. Only match \ at the *end* of a line.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36007 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 18:51:19 +00:00