[llvm-dev] Archive file test problem

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[llvm-dev] Archive file test problem

Tom Stellard via llvm-dev
Hello,

I've come across a potential problem with:

/llvm/tools/lld/test/ELF/archive.s

Line 7: # RUN: llvm-ar rcs %t.a %t2 %t3 %t4

This line is not preceded by a delete of the target archive %t.a. Therefore, if for some reason this archive is corrupted, perhaps by a previous test run, then the test will fail.

I suggest that an 'rm -f %t.a' should be added to this and all similar lit tests calling llvm-ar with the 'r' command line flag. A similar file delete is used later in the same test before a call to llvm-ar.

I'm not quite sure of the correct way to file a potential bug against a test in bugzilla. This problem may be present in other lit tests.

regards,


Chris

_______________________________________________
LLVM Developers mailing list
[hidden email]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
Reply | Threaded
Open this post in threaded view
|

Re: [llvm-dev] Archive file test problem

Tom Stellard via llvm-dev
Hi Chris,

I'd consider the test to be part of the lld component, so if you need to file a bug report about this, I'd file it against the lld component.

Thanks,

Kristof

Op do 5 jul. 2018 om 11:03 schreef Chris Jackson via llvm-dev <[hidden email]>:
Hello,

I've come across a potential problem with:

/llvm/tools/lld/test/ELF/archive.s

Line 7: # RUN: llvm-ar rcs %t.a %t2 %t3 %t4

This line is not preceded by a delete of the target archive %t.a. Therefore, if for some reason this archive is corrupted, perhaps by a previous test run, then the test will fail.

I suggest that an 'rm -f %t.a' should be added to this and all similar lit tests calling llvm-ar with the 'r' command line flag. A similar file delete is used later in the same test before a call to llvm-ar.

I'm not quite sure of the correct way to file a potential bug against a test in bugzilla. This problem may be present in other lit tests.

regards,


Chris
_______________________________________________
LLVM Developers mailing list
[hidden email]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev

_______________________________________________
LLVM Developers mailing list
[hidden email]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
Reply | Threaded
Open this post in threaded view
|

Re: [llvm-dev] Archive file test problem

Tom Stellard via llvm-dev
In reply to this post by Tom Stellard via llvm-dev
Chris,

Thank you for reporting! I've added an rm in r336366.

On Thu, Jul 5, 2018 at 2:03 AM Chris Jackson via llvm-dev <[hidden email]> wrote:
Hello,

I've come across a potential problem with:

/llvm/tools/lld/test/ELF/archive.s

Line 7: # RUN: llvm-ar rcs %t.a %t2 %t3 %t4

This line is not preceded by a delete of the target archive %t.a. Therefore, if for some reason this archive is corrupted, perhaps by a previous test run, then the test will fail.

I suggest that an 'rm -f %t.a' should be added to this and all similar lit tests calling llvm-ar with the 'r' command line flag. A similar file delete is used later in the same test before a call to llvm-ar.

I'm not quite sure of the correct way to file a potential bug against a test in bugzilla. This problem may be present in other lit tests.

regards,


Chris
_______________________________________________
LLVM Developers mailing list
[hidden email]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev

_______________________________________________
LLVM Developers mailing list
[hidden email]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev