<div dir="ltr">I assume you were configuring for an ARM variant.<div>It appears that Vector and Vector/NEON both have files called simple.c and need to have unique prefix for their targets.<div><br></div><div>Fixed in r267439</div><div><br></div><div>--Artem<br><div><br></div><div><div><br></div></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Apr 23, 2016 at 2:15 PM, Chris Matthews <span dir="ltr"><<a href="mailto:chris.matthews@apple.com" target="_blank">chris.matthews@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">After this commit the test suite fails cmake for me:<div><br></div><div><br></div><div><pre style="white-space:pre-wrap;word-wrap:break-word;margin-top:0px;margin-bottom:0px;color:rgb(51,51,51)"><span title="CMake Error" style="color:white;background-color:red;background-position:initial initial;background-repeat:initial initial">CMake Error at cmake/modules/SingleMultiSource.cmake:45 (message):
</span>  Duplicate executable name!Please set unique prefix with
  llvm_target_prefix().
Call Stack (most recent call first):
  cmake/modules/SingleMultiSource.cmake:136 (get_unique_exe_name)
  cmake/modules/SingleMultiSource.cmake:175 (test_suite_add_executable)
  SingleSource/UnitTests/Vector/CMakeLists.txt:21 (llvm_singlesource)
</pre><div><div class="h5"><div><br></div><div><br></div><div><blockquote type="cite"><div>On Apr 22, 2016, at 3:53 PM, Artem Belevich via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:</div><br><div><div>Author: tra<br>Date: Fri Apr 22 17:53:21 2016<br>New Revision: 267243<br><br>URL: <a href="http://llvm.org/viewvc/llvm-project?rev=267243&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=267243&view=rev</a><br>Log:<br>[test-suite] Added llvm_target_prefix() command to set unique target prefix.<br><br>Differential Revision: <a href="http://reviews.llvm.org/D19423" target="_blank">http://reviews.llvm.org/D19423</a><br><br>Modified:<br>    test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/CMakeLists.txt<br>    test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt<br>    test-suite/trunk/SingleSource/Regression/C++/CMakeLists.txt<br>    test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt<br>    test-suite/trunk/cmake/modules/SingleMultiSource.cmake<br><br>Modified: test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/CMakeLists.txt<br>URL: <a href="http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout-C%2B%2B/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff</a><br>==============================================================================<br>--- test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/CMakeLists.txt (original)<br>+++ test-suite/trunk/SingleSource/Benchmarks/Shootout-C++/CMakeLists.txt Fri Apr 22 17:53:21 2016<br>@@ -1,3 +1,4 @@<br>+llvm_target_prefix("shootout-cxx")<br> list(APPEND CXXFLAGS -Wno-deprecated)<br> list(APPEND CPPFLAGS -Wno-deprecated)<br> set(FP_TOLERANCE 0.00000001)<br><br>Modified: test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt<br>URL: <a href="http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff</a><br>==============================================================================<br>--- test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt (original)<br>+++ test-suite/trunk/SingleSource/Benchmarks/Shootout/CMakeLists.txt Fri Apr 22 17:53:21 2016<br>@@ -1,3 +1,4 @@<br>+llvm_target_prefix("shootout")<br> list(APPEND LDFLAGS -lm)<br> if(ARCH STREQUAL "XCore")<br>   set(XCORE_TARGET_NEEDS_MEMORY 256)<br><br>Modified: test-suite/trunk/SingleSource/Regression/C++/CMakeLists.txt<br>URL: <a href="http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Regression/C%2B%2B/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Regression/C%2B%2B/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff</a><br>==============================================================================<br>--- test-suite/trunk/SingleSource/Regression/C++/CMakeLists.txt (original)<br>+++ test-suite/trunk/SingleSource/Regression/C++/CMakeLists.txt Fri Apr 22 17:53:21 2016<br>@@ -1,3 +1,4 @@<br>+llvm_target_prefix("regression-cxx")<br> list(APPEND LDFLAGS -lstdc++)<br> llvm_singlesource()<br><br><br>Modified: test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt<br>URL: <a href="http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt?rev=267243&r1=267242&r2=267243&view=diff</a><br>==============================================================================<br>--- test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt (original)<br>+++ test-suite/trunk/SingleSource/Regression/C/CMakeLists.txt Fri Apr 22 17:53:21 2016<br>@@ -1,3 +1,4 @@<br>+llvm_target_prefix("regression-c")<br> if(ARCH STREQUAL "x86")<br>   if(DEFINED USE_REFERENCE_OUTPUT)<br>     set(EXEC_XFAILS casts)<br><br>Modified: test-suite/trunk/cmake/modules/SingleMultiSource.cmake<br>URL: <a href="http://llvm.org/viewvc/llvm-project/test-suite/trunk/cmake/modules/SingleMultiSource.cmake?rev=267243&r1=267242&r2=267243&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/test-suite/trunk/cmake/modules/SingleMultiSource.cmake?rev=267243&r1=267242&r2=267243&view=diff</a><br>==============================================================================<br>--- test-suite/trunk/cmake/modules/SingleMultiSource.cmake (original)<br>+++ test-suite/trunk/cmake/modules/SingleMultiSource.cmake Fri Apr 22 17:53:21 2016<br>@@ -13,18 +13,27 @@<br><br> include(TestFile)<br><br>+<br>+# Set unique target prefix within caller's scope.<br>+function(llvm_target_prefix prefix)<br>+  if(prefix)<br>+    set(TARGET_PREFIX "${prefix}-" PARENT_SCOPE)<br>+  else()<br>+    set(TARGET_PREFIX "" PARENT_SCOPE)<br>+  endif()<br>+endfunction()<br>+<br> # Given a source file name after which a test should be named, create a unique<br> # name for the test. Usually this is just the source file with the suffix<br>-# stripped, but in some cases this ends up causing duplicates so attempt to<br>-# make each unique (by adding pathname segments until they become unique).<br>-#<br>-# FIXME: Swap this with a simpler procedure to just append a numeral<br>+# stripped, and ${TARGET_PREFIX} prepended.<br> set_property(GLOBAL PROPERTY registered_executables)<br> function(get_unique_exe_name new_name main_src)<br>   get_property(registered_executables GLOBAL PROPERTY registered_executables)<br><br>   string(REGEX REPLACE ".[cp]+$" "" path ${main_src})<br>-  string(REGEX REPLACE ".*/" "" name ${path})<br>+  get_filename_component(name ${path} NAME )<br>+  set(name "${TARGET_PREFIX}${name}")<br>+<br>   list(FIND registered_executables ${name} name_idx)<br><br>   if(${name_idx} EQUAL -1)<br>@@ -33,20 +42,8 @@ function(get_unique_exe_name new_name ma<br>     return()<br>   endif()<br><br>-  # There is a clash. Rename the target. Each time around the loop pull in<br>-  # a new path component.<br>-  foreach(n RANGE 1 4)<br>-    string(REGEX REPLACE ".*/([^/]+/${name})" "<a>\\1</a>" name ${path})<br>-    string(REGEX REPLACE "/" "-" safe_name ${name})<br>-<br>-    list(FIND registered_executables ${safe_name} name_idx)<br>-    if(${name_idx} EQUAL -1)<br>-      set(${new_name} ${safe_name} PARENT_SCOPE)<br>-      set_property(GLOBAL APPEND PROPERTY registered_executables ${safe_name})<br>-      return()<br>-    endif()<br>-  endforeach()<br>-  message(FATAL_ERROR "Failed to uniquify executable name!")<br>+  message(FATAL_ERROR "Duplicate executable name!"<br>+    "Please set unique prefix with llvm_target_prefix().")<br> endfunction()<br><br> # Add flags to a cmake target property.<br><br><br>_______________________________________________<br>llvm-commits mailing list<br><a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br><a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br></div></div></blockquote></div><br></div></div></div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr">--Artem Belevich</div></div>
</div>