[llvm] r214318 - Rename llvm-uselistorder => verify-uselistorder
Duncan P. N. Exon Smith
dexonsmith at apple.com
Wed Jul 30 10:11:28 PDT 2014
Author: dexonsmith
Date: Wed Jul 30 12:11:27 2014
New Revision: 214318
URL: http://llvm.org/viewvc/llvm-project?rev=214318&view=rev
Log:
Rename llvm-uselistorder => verify-uselistorder
Added:
llvm/trunk/tools/verify-uselistorder/
llvm/trunk/tools/verify-uselistorder/CMakeLists.txt
- copied, changed from r214317, llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt
llvm/trunk/tools/verify-uselistorder/LLVMBuild.txt
- copied, changed from r214317, llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt
llvm/trunk/tools/verify-uselistorder/Makefile
- copied, changed from r214317, llvm/trunk/tools/llvm-uselistorder/Makefile
llvm/trunk/tools/verify-uselistorder/verify-uselistorder.cpp
- copied, changed from r214317, llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp
Removed:
llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt
llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt
llvm/trunk/tools/llvm-uselistorder/Makefile
llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp
Modified:
llvm/trunk/test/Bitcode/2006-12-11-Cast-ConstExpr.ll
llvm/trunk/test/Bitcode/2009-06-11-FirstClassAggregateConstant.ll
llvm/trunk/test/Bitcode/aggregateInstructions.3.2.ll
llvm/trunk/test/Bitcode/arm32_neon_vcnt_upgrade.ll
llvm/trunk/test/Bitcode/atomic.ll
llvm/trunk/test/Bitcode/attributes-3.3.ll
llvm/trunk/test/Bitcode/attributes.ll
llvm/trunk/test/Bitcode/binaryFloatInstructions.3.2.ll
llvm/trunk/test/Bitcode/binaryIntInstructions.3.2.ll
llvm/trunk/test/Bitcode/bitwiseInstructions.3.2.ll
llvm/trunk/test/Bitcode/calling-conventions.3.2.ll
llvm/trunk/test/Bitcode/case-ranges-3.3.ll
llvm/trunk/test/Bitcode/cmpxchg-upgrade.ll
llvm/trunk/test/Bitcode/conversionInstructions.3.2.ll
llvm/trunk/test/Bitcode/drop-debug-info.ll
llvm/trunk/test/Bitcode/extractelement.ll
llvm/trunk/test/Bitcode/flags.ll
llvm/trunk/test/Bitcode/function-encoding-rel-operands.ll
llvm/trunk/test/Bitcode/global-variables.3.2.ll
llvm/trunk/test/Bitcode/inalloca.ll
llvm/trunk/test/Bitcode/linkage-types-3.2.ll
llvm/trunk/test/Bitcode/local-linkage-default-visibility.3.4.ll
llvm/trunk/test/Bitcode/memInstructions.3.2.ll
llvm/trunk/test/Bitcode/metadata.ll
llvm/trunk/test/Bitcode/old-aliases.ll
llvm/trunk/test/Bitcode/ptest-new.ll
llvm/trunk/test/Bitcode/ptest-old.ll
llvm/trunk/test/Bitcode/select.ll
llvm/trunk/test/Bitcode/shuffle.ll
llvm/trunk/test/Bitcode/tailcall.ll
llvm/trunk/test/Bitcode/terminatorInstructions.3.2.ll
llvm/trunk/test/Bitcode/upgrade-global-ctors.ll
llvm/trunk/test/Bitcode/upgrade-loop-metadata.ll
llvm/trunk/test/Bitcode/upgrade-tbaa.ll
llvm/trunk/test/Bitcode/use-list-order.ll
llvm/trunk/test/Bitcode/vectorInstructions.3.2.ll
llvm/trunk/test/Bitcode/visibility-styles.3.2.ll
llvm/trunk/test/Bitcode/weak-cmpxchg-upgrade.ll
llvm/trunk/test/CMakeLists.txt
llvm/trunk/test/lit.cfg
llvm/trunk/tools/CMakeLists.txt
llvm/trunk/tools/LLVMBuild.txt
llvm/trunk/tools/Makefile
Modified: llvm/trunk/test/Bitcode/2006-12-11-Cast-ConstExpr.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/2006-12-11-Cast-ConstExpr.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/2006-12-11-Cast-ConstExpr.ll (original)
+++ llvm/trunk/test/Bitcode/2006-12-11-Cast-ConstExpr.ll Wed Jul 30 12:11:27 2014
@@ -1,7 +1,7 @@
; This test ensures that we get a bitcast constant expression in and out,
; not a sitofp constant expression.
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; CHECK: bitcast (
@G = external global i32
Modified: llvm/trunk/test/Bitcode/2009-06-11-FirstClassAggregateConstant.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/2009-06-11-FirstClassAggregateConstant.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/2009-06-11-FirstClassAggregateConstant.ll (original)
+++ llvm/trunk/test/Bitcode/2009-06-11-FirstClassAggregateConstant.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis -disable-output
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; PR4373
@foo = weak global { i32 } zeroinitializer
Modified: llvm/trunk/test/Bitcode/aggregateInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/aggregateInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/aggregateInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/aggregateInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; aggregateOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread instructions with aggregate operands
Modified: llvm/trunk/test/Bitcode/arm32_neon_vcnt_upgrade.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/arm32_neon_vcnt_upgrade.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/arm32_neon_vcnt_upgrade.ll (original)
+++ llvm/trunk/test/Bitcode/arm32_neon_vcnt_upgrade.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; Tests vclz and vcnt
define <4 x i16> @vclz16(<4 x i16>* %A) nounwind {
Modified: llvm/trunk/test/Bitcode/atomic.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/atomic.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/atomic.ll (original)
+++ llvm/trunk/test/Bitcode/atomic.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as %s -o - | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
define void @test_cmpxchg(i32* %addr, i32 %desired, i32 %new) {
cmpxchg i32* %addr, i32 %desired, i32 %new seq_cst seq_cst
Modified: llvm/trunk/test/Bitcode/attributes-3.3.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/attributes-3.3.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/attributes-3.3.ll (original)
+++ llvm/trunk/test/Bitcode/attributes-3.3.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; attributes-3.3.ll.bc was generated by passing this file to llvm-as-3.3.
; The test checks that LLVM does not silently misread attributes of
Modified: llvm/trunk/test/Bitcode/attributes.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/attributes.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/attributes.ll (original)
+++ llvm/trunk/test/Bitcode/attributes.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; PR12696
define void @f1(i8 zeroext)
Modified: llvm/trunk/test/Bitcode/binaryFloatInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/binaryFloatInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/binaryFloatInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/binaryFloatInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; BinaryFloatOperation.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread binary float instructions from
Modified: llvm/trunk/test/Bitcode/binaryIntInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/binaryIntInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/binaryIntInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/binaryIntInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; BinaryIntOperation.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread binary integer instructions from
Modified: llvm/trunk/test/Bitcode/bitwiseInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/bitwiseInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/bitwiseInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/bitwiseInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; bitwiseOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread bitwise instructions from
Modified: llvm/trunk/test/Bitcode/calling-conventions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/calling-conventions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/calling-conventions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/calling-conventions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; calling-conventions.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not silently misread calling conventions of
Modified: llvm/trunk/test/Bitcode/case-ranges-3.3.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/case-ranges-3.3.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/case-ranges-3.3.ll (original)
+++ llvm/trunk/test/Bitcode/case-ranges-3.3.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; case-ranges.ll.bc was generated by passing this file to llvm-as from the 3.3
; release of LLVM. This tests that the bitcode for switches from that release
Modified: llvm/trunk/test/Bitcode/cmpxchg-upgrade.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/cmpxchg-upgrade.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/cmpxchg-upgrade.ll (original)
+++ llvm/trunk/test/Bitcode/cmpxchg-upgrade.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc | FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; cmpxchg-upgrade.ll.bc was produced by running a version of llvm-as from just
; before the IR change on this file.
Modified: llvm/trunk/test/Bitcode/conversionInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/conversionInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/conversionInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/conversionInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; conversionOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread conversion instructions from
Modified: llvm/trunk/test/Bitcode/drop-debug-info.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/drop-debug-info.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/drop-debug-info.ll (original)
+++ llvm/trunk/test/Bitcode/drop-debug-info.ll Wed Jul 30 12:11:27 2014
@@ -1,6 +1,6 @@
; RUN: llvm-as < %s -o %t.bc 2>&1 >/dev/null | FileCheck -check-prefix=WARN %s
; RUN: llvm-dis < %t.bc | FileCheck %s
-; RUN: llvm-uselistorder < %t.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %t.bc -preserve-bc-use-list-order -num-shuffles=5
define i32 @main() {
entry:
Modified: llvm/trunk/test/Bitcode/extractelement.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/extractelement.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/extractelement.ll (original)
+++ llvm/trunk/test/Bitcode/extractelement.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: opt < %s -constprop | llvm-dis -disable-output
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; PR3465
define double @test() {
Modified: llvm/trunk/test/Bitcode/flags.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/flags.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/flags.ll (original)
+++ llvm/trunk/test/Bitcode/flags.ll Wed Jul 30 12:11:27 2014
@@ -1,7 +1,7 @@
; RUN: llvm-as < %s | llvm-dis > %t0
; RUN: opt -S < %s > %t1
; RUN: diff %t0 %t1
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; PR6140
; Make sure the flags are serialized/deserialized properly for both
Modified: llvm/trunk/test/Bitcode/function-encoding-rel-operands.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/function-encoding-rel-operands.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/function-encoding-rel-operands.ll (original)
+++ llvm/trunk/test/Bitcode/function-encoding-rel-operands.ll Wed Jul 30 12:11:27 2014
@@ -1,7 +1,7 @@
; Basic sanity test to check that instruction operands are encoded with
; relative IDs.
; RUN: llvm-as < %s | llvm-bcanalyzer -dump | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; CHECK: FUNCTION_BLOCK
; CHECK: INST_BINOP {{.*}}op0=1 op1=1
Modified: llvm/trunk/test/Bitcode/global-variables.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/global-variables.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/global-variables.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/global-variables.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; global-variables.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not silently misread global variables attributes of
Modified: llvm/trunk/test/Bitcode/inalloca.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/inalloca.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/inalloca.ll (original)
+++ llvm/trunk/test/Bitcode/inalloca.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; inalloca should roundtrip.
Modified: llvm/trunk/test/Bitcode/linkage-types-3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/linkage-types-3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/linkage-types-3.2.ll (original)
+++ llvm/trunk/test/Bitcode/linkage-types-3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; linkage-types-3.2.ll.bc was generated by passing this file to llvm-as-3.2
; The test checks that LLVM does not silently misread linkage types of
Modified: llvm/trunk/test/Bitcode/local-linkage-default-visibility.3.4.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/local-linkage-default-visibility.3.4.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/local-linkage-default-visibility.3.4.ll (original)
+++ llvm/trunk/test/Bitcode/local-linkage-default-visibility.3.4.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc | FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; local-linkage-default-visibility.3.4.ll.bc was generated by passing this file
; to llvm-as-3.4. The test checks that LLVM upgrades visibility of symbols
Modified: llvm/trunk/test/Bitcode/memInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/memInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/memInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/memInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; memOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread memory related instructions of
Modified: llvm/trunk/test/Bitcode/metadata.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/metadata.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/metadata.ll (original)
+++ llvm/trunk/test/Bitcode/metadata.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis -disable-output
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
!llvm.foo = !{!0}
!0 = metadata !{i32 42}
Modified: llvm/trunk/test/Bitcode/old-aliases.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/old-aliases.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/old-aliases.ll (original)
+++ llvm/trunk/test/Bitcode/old-aliases.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc | FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; old-aliases.bc consist of this file assembled with an old llvm-as (3.5 trunk)
; from when aliases contained a ConstantExpr.
Modified: llvm/trunk/test/Bitcode/ptest-new.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/ptest-new.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/ptest-new.ll (original)
+++ llvm/trunk/test/Bitcode/ptest-new.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
define i32 @foo(<2 x i64> %bar) nounwind {
entry:
Modified: llvm/trunk/test/Bitcode/ptest-old.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/ptest-old.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/ptest-old.ll (original)
+++ llvm/trunk/test/Bitcode/ptest-old.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
define i32 @foo(<4 x float> %bar) nounwind {
entry:
Modified: llvm/trunk/test/Bitcode/select.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/select.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/select.ll (original)
+++ llvm/trunk/test/Bitcode/select.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
define <2 x i32> @main() {
ret <2 x i32> select (<2 x i1> <i1 false, i1 undef>, <2 x i32> zeroinitializer, <2 x i32> <i32 0, i32 undef>)
Modified: llvm/trunk/test/Bitcode/shuffle.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/shuffle.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/shuffle.ll (original)
+++ llvm/trunk/test/Bitcode/shuffle.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis -disable-output
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; <rdar://problem/8622574>
; tests the bitcodereader can handle the case where the reader will initially
Modified: llvm/trunk/test/Bitcode/tailcall.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/tailcall.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/tailcall.ll (original)
+++ llvm/trunk/test/Bitcode/tailcall.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; Check that musttail and tail roundtrip.
Modified: llvm/trunk/test/Bitcode/terminatorInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/terminatorInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/terminatorInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/terminatorInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; TerminatorOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread terminator instructions from
Modified: llvm/trunk/test/Bitcode/upgrade-global-ctors.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/upgrade-global-ctors.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/upgrade-global-ctors.ll (original)
+++ llvm/trunk/test/Bitcode/upgrade-global-ctors.ll Wed Jul 30 12:11:27 2014
@@ -1,4 +1,4 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; CHECK: @llvm.global_ctors = appending global [0 x { i32, void ()*, i8* }] zeroinitializer
Modified: llvm/trunk/test/Bitcode/upgrade-loop-metadata.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/upgrade-loop-metadata.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/upgrade-loop-metadata.ll (original)
+++ llvm/trunk/test/Bitcode/upgrade-loop-metadata.ll Wed Jul 30 12:11:27 2014
@@ -1,7 +1,7 @@
; Test to make sure loop vectorizer metadata is automatically upgraded.
;
; RUN: llvm-dis < %s.bc | FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
define void @_Z28loop_with_vectorize_metadatav() {
entry:
Modified: llvm/trunk/test/Bitcode/upgrade-tbaa.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/upgrade-tbaa.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/upgrade-tbaa.ll (original)
+++ llvm/trunk/test/Bitcode/upgrade-tbaa.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-as < %s | llvm-dis | FileCheck %s
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
; Function Attrs: nounwind
define void @_Z4testPiPf(i32* nocapture %pI, float* nocapture %pF) #0 {
Modified: llvm/trunk/test/Bitcode/use-list-order.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/use-list-order.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/use-list-order.ll (original)
+++ llvm/trunk/test/Bitcode/use-list-order.ll Wed Jul 30 12:11:27 2014
@@ -1,4 +1,4 @@
-; RUN: llvm-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s -preserve-bc-use-list-order -num-shuffles=5
@a = global [4 x i1] [i1 0, i1 1, i1 0, i1 1]
@b = alias i1* getelementptr ([4 x i1]* @a, i64 0, i64 2)
Modified: llvm/trunk/test/Bitcode/vectorInstructions.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/vectorInstructions.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/vectorInstructions.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/vectorInstructions.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; vectorOperations.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not misread vector operations of
Modified: llvm/trunk/test/Bitcode/visibility-styles.3.2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/visibility-styles.3.2.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/visibility-styles.3.2.ll (original)
+++ llvm/trunk/test/Bitcode/visibility-styles.3.2.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc| FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; visibility-styles.3.2.ll.bc was generated by passing this file to llvm-as-3.2.
; The test checks that LLVM does not silently misread visibility styles of
Modified: llvm/trunk/test/Bitcode/weak-cmpxchg-upgrade.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Bitcode/weak-cmpxchg-upgrade.ll?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/Bitcode/weak-cmpxchg-upgrade.ll (original)
+++ llvm/trunk/test/Bitcode/weak-cmpxchg-upgrade.ll Wed Jul 30 12:11:27 2014
@@ -1,5 +1,5 @@
; RUN: llvm-dis < %s.bc | FileCheck %s
-; RUN: llvm-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
+; RUN: verify-uselistorder < %s.bc -preserve-bc-use-list-order -num-shuffles=5
; cmpxchg-upgrade.ll.bc was produced by running a version of llvm-as from just
; before the IR change on this file.
Modified: llvm/trunk/test/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CMakeLists.txt?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/CMakeLists.txt (original)
+++ llvm/trunk/test/CMakeLists.txt Wed Jul 30 12:11:27 2014
@@ -44,7 +44,6 @@ set(LLVM_TEST_DEPENDS
llvm-rtdyld
llvm-symbolizer
llvm-tblgen
- llvm-uselistorder
llvm-vtabledump
macho-dump
opt
@@ -53,6 +52,7 @@ set(LLVM_TEST_DEPENDS
not
yaml2obj
obj2yaml
+ verify-uselistorder
)
# If Intel JIT events are supported, depend on a tool that tests the listener.
Modified: llvm/trunk/test/lit.cfg
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/lit.cfg?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/test/lit.cfg (original)
+++ llvm/trunk/test/lit.cfg Wed Jul 30 12:11:27 2014
@@ -228,7 +228,6 @@ for pattern in [r"\bbugpoint\b(?!-)",
r"\bllvm-rtdyld\b",
r"\bllvm-size\b",
r"\bllvm-tblgen\b",
- r"\bllvm-uselistorder\b",
r"\bllvm-vtabledump\b",
r"\bllvm-c-test\b",
r"\bmacho-dump\b",
@@ -236,6 +235,7 @@ for pattern in [r"\bbugpoint\b(?!-)",
r"\bFileCheck\b",
r"\bobj2yaml\b",
r"\byaml2obj\b",
+ r"\bverify-uselistorder\b",
# Handle these specially as they are strings searched
# for during testing.
r"\| \bcount\b",
Modified: llvm/trunk/tools/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/CMakeLists.txt?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/tools/CMakeLists.txt (original)
+++ llvm/trunk/tools/CMakeLists.txt Wed Jul 30 12:11:27 2014
@@ -43,7 +43,7 @@ add_llvm_tool_subdirectory(llvm-bcanalyz
add_llvm_tool_subdirectory(llvm-stress)
add_llvm_tool_subdirectory(llvm-mcmarkup)
-add_llvm_tool_subdirectory(llvm-uselistorder)
+add_llvm_tool_subdirectory(verify-uselistorder)
add_llvm_tool_subdirectory(llvm-symbolizer)
Modified: llvm/trunk/tools/LLVMBuild.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/LLVMBuild.txt?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/tools/LLVMBuild.txt (original)
+++ llvm/trunk/tools/LLVMBuild.txt Wed Jul 30 12:11:27 2014
@@ -16,7 +16,7 @@
;===------------------------------------------------------------------------===;
[common]
-subdirectories = bugpoint llc lli llvm-ar llvm-as llvm-bcanalyzer llvm-cov llvm-diff llvm-dis llvm-dwarfdump llvm-extract llvm-jitlistener llvm-link llvm-lto llvm-mc llvm-nm llvm-objdump llvm-profdata llvm-rtdyld llvm-size macho-dump opt llvm-mcmarkup llvm-uselistorder
+subdirectories = bugpoint llc lli llvm-ar llvm-as llvm-bcanalyzer llvm-cov llvm-diff llvm-dis llvm-dwarfdump llvm-extract llvm-jitlistener llvm-link llvm-lto llvm-mc llvm-nm llvm-objdump llvm-profdata llvm-rtdyld llvm-size macho-dump opt llvm-mcmarkup verify-uselistorder
[component_0]
type = Group
Modified: llvm/trunk/tools/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/Makefile?rev=214318&r1=214317&r2=214318&view=diff
==============================================================================
--- llvm/trunk/tools/Makefile (original)
+++ llvm/trunk/tools/Makefile Wed Jul 30 12:11:27 2014
@@ -32,7 +32,7 @@ PARALLEL_DIRS := opt llvm-as llvm-dis ll
macho-dump llvm-objdump llvm-readobj llvm-rtdyld \
llvm-dwarfdump llvm-cov llvm-size llvm-stress llvm-mcmarkup \
llvm-profdata llvm-symbolizer obj2yaml yaml2obj llvm-c-test \
- llvm-vtabledump llvm-uselistorder
+ llvm-vtabledump verify-uselistorder
# If Intel JIT Events support is configured, build an extra tool to test it.
ifeq ($(USE_INTEL_JITEVENTS), 1)
Removed: llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt?rev=214317&view=auto
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt (original)
+++ llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt (removed)
@@ -1,12 +0,0 @@
-set(LLVM_LINK_COMPONENTS
- AsmParser
- BitReader
- BitWriter
- Core
- IRReader
- Support
- )
-
-add_llvm_tool(llvm-uselistorder
- llvm-uselistorder.cpp
- )
Removed: llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt?rev=214317&view=auto
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt (original)
+++ llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt (removed)
@@ -1,22 +0,0 @@
-;===- ./tools/llvm-uselistorder/LLVMBuild.txt ------------------*- Conf -*--===;
-;
-; The LLVM Compiler Infrastructure
-;
-; This file is distributed under the University of Illinois Open Source
-; License. See LICENSE.TXT for details.
-;
-;===------------------------------------------------------------------------===;
-;
-; This is an LLVMBuild description file for the components in this subdirectory.
-;
-; For more information on the LLVMBuild system, please see:
-;
-; http://llvm.org/docs/LLVMBuild.html
-;
-;===------------------------------------------------------------------------===;
-
-[component_0]
-type = Tool
-name = llvm-uselistorder
-parent = Tools
-required_libraries = IRReader BitWriter Support
Removed: llvm/trunk/tools/llvm-uselistorder/Makefile
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-uselistorder/Makefile?rev=214317&view=auto
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/Makefile (original)
+++ llvm/trunk/tools/llvm-uselistorder/Makefile (removed)
@@ -1,17 +0,0 @@
-##===- tools/llvm-uselistorder/Makefile --------------------*- Makefile -*-===##
-#
-# The LLVM Compiler Infrastructure
-#
-# This file is distributed under the University of Illinois Open Source
-# License. See LICENSE.TXT for details.
-#
-##===----------------------------------------------------------------------===##
-
-LEVEL := ../..
-TOOLNAME := llvm-uselistorder
-LINK_COMPONENTS := AsmParser BitReader BitWriter Core IRReader Support
-
-# This tool has no plugins, optimize startup time.
-TOOL_NO_EXPORTS := 1
-
-include $(LEVEL)/Makefile.common
Removed: llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp?rev=214317&view=auto
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp (original)
+++ llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp (removed)
@@ -1,394 +0,0 @@
-//===- llvm-uselistorder.cpp - The LLVM Modular Optimizer -----------------===//
-//
-// The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-//
-// Verify that use-list order can be serialized correctly. After reading the
-// provided IR, this tool shuffles the use-lists and then writes and reads to a
-// separate Module whose use-list orders are compared to the original.
-//
-//===----------------------------------------------------------------------===//
-
-#include "llvm/ADT/DenseMap.h"
-#include "llvm/AsmParser/Parser.h"
-#include "llvm/Bitcode/ReaderWriter.h"
-#include "llvm/IR/LLVMContext.h"
-#include "llvm/IR/Module.h"
-#include "llvm/IR/UseListOrder.h"
-#include "llvm/IRReader/IRReader.h"
-#include "llvm/Support/CommandLine.h"
-#include "llvm/Support/Debug.h"
-#include "llvm/Support/ErrorHandling.h"
-#include "llvm/Support/FileSystem.h"
-#include "llvm/Support/FileUtilities.h"
-#include "llvm/Support/ManagedStatic.h"
-#include "llvm/Support/MemoryBuffer.h"
-#include "llvm/Support/PrettyStackTrace.h"
-#include "llvm/Support/Signals.h"
-#include "llvm/Support/SourceMgr.h"
-#include "llvm/Support/SystemUtils.h"
-
-using namespace llvm;
-
-#define DEBUG_TYPE "use-list-order"
-
-static cl::opt<std::string> InputFilename(cl::Positional,
- cl::desc("<input bitcode file>"),
- cl::init("-"),
- cl::value_desc("filename"));
-
-static cl::opt<bool> SaveTemps("save-temps", cl::desc("Save temp files"),
- cl::init(false));
-
-static cl::opt<unsigned>
- NumShuffles("num-shuffles",
- cl::desc("Number of times to shuffle and verify use-lists"),
- cl::init(1));
-
-namespace {
-
-struct TempFile {
- std::string Filename;
- FileRemover Remover;
- bool init(const std::string &Ext);
- bool writeBitcode(const Module &M) const;
- bool writeAssembly(const Module &M) const;
- std::unique_ptr<Module> readBitcode(LLVMContext &Context) const;
- std::unique_ptr<Module> readAssembly(LLVMContext &Context) const;
-};
-
-struct ValueMapping {
- DenseMap<const Value *, unsigned> IDs;
- std::vector<const Value *> Values;
-
- /// \brief Construct a value mapping for module.
- ///
- /// Creates mapping from every value in \c M to an ID. This mapping includes
- /// un-referencable values.
- ///
- /// Every \a Value that gets serialized in some way should be represented
- /// here. The order needs to be deterministic, but it's unnecessary to match
- /// the value-ids in the bitcode writer.
- ///
- /// All constants that are referenced by other values are included in the
- /// mapping, but others -- which wouldn't be serialized -- are not.
- ValueMapping(const Module &M);
-
- /// \brief Map a value.
- ///
- /// Maps a value. If it's a constant, maps all of its operands first.
- void map(const Value *V);
- unsigned lookup(const Value *V) const { return IDs.lookup(V); }
-};
-
-} // end namespace
-
-bool TempFile::init(const std::string &Ext) {
- SmallVector<char, 64> Vector;
- DEBUG(dbgs() << " - create-temp-file\n");
- if (auto EC = sys::fs::createTemporaryFile("use-list-order", Ext, Vector)) {
- (void)EC;
- DEBUG(dbgs() << "error: " << EC.message() << "\n");
- return true;
- }
- assert(!Vector.empty());
-
- Filename.assign(Vector.data(), Vector.data() + Vector.size());
- Remover.setFile(Filename, !SaveTemps);
- DEBUG(dbgs() << " - filename = " << Filename << "\n");
- return false;
-}
-
-bool TempFile::writeBitcode(const Module &M) const {
- DEBUG(dbgs() << " - write bitcode\n");
- std::string ErrorInfo;
- raw_fd_ostream OS(Filename.c_str(), ErrorInfo, sys::fs::F_None);
- if (!ErrorInfo.empty()) {
- DEBUG(dbgs() << "error: " << ErrorInfo << "\n");
- return true;
- }
-
- WriteBitcodeToFile(&M, OS);
- return false;
-}
-
-bool TempFile::writeAssembly(const Module &M) const {
- DEBUG(dbgs() << " - write assembly\n");
- std::string ErrorInfo;
- raw_fd_ostream OS(Filename.c_str(), ErrorInfo, sys::fs::F_Text);
- if (!ErrorInfo.empty()) {
- DEBUG(dbgs() << "error: " << ErrorInfo << "\n");
- return true;
- }
-
- OS << M;
- return false;
-}
-
-std::unique_ptr<Module> TempFile::readBitcode(LLVMContext &Context) const {
- DEBUG(dbgs() << " - read bitcode\n");
- ErrorOr<std::unique_ptr<MemoryBuffer>> BufferOr =
- MemoryBuffer::getFile(Filename);
- if (!BufferOr) {
- DEBUG(dbgs() << "error: " << BufferOr.getError().message() << "\n");
- return nullptr;
- }
-
- std::unique_ptr<MemoryBuffer> Buffer = std::move(BufferOr.get());
- ErrorOr<Module *> ModuleOr = parseBitcodeFile(Buffer.get(), Context);
- if (!ModuleOr) {
- DEBUG(dbgs() << "error: " << ModuleOr.getError().message() << "\n");
- return nullptr;
- }
- return std::unique_ptr<Module>(ModuleOr.get());
-}
-
-std::unique_ptr<Module> TempFile::readAssembly(LLVMContext &Context) const {
- DEBUG(dbgs() << " - read assembly\n");
- SMDiagnostic Err;
- std::unique_ptr<Module> M(ParseAssemblyFile(Filename, Err, Context));
- if (!M.get())
- DEBUG(dbgs() << "error: "; Err.print("verify-use-list-order", dbgs()));
- return M;
-}
-
-ValueMapping::ValueMapping(const Module &M) {
- // Every value should be mapped, including things like void instructions and
- // basic blocks that are kept out of the ValueEnumerator.
- //
- // The current mapping order makes it easier to debug the tables. It happens
- // to be similar to the ID mapping when writing ValueEnumerator, but they
- // aren't (and needn't be) in sync.
-
- // Globals.
- for (const GlobalVariable &G : M.globals())
- map(&G);
- for (const GlobalAlias &A : M.aliases())
- map(&A);
- for (const Function &F : M)
- map(&F);
-
- // Constants used by globals.
- for (const GlobalVariable &G : M.globals())
- if (G.hasInitializer())
- map(G.getInitializer());
- for (const GlobalAlias &A : M.aliases())
- map(A.getAliasee());
- for (const Function &F : M)
- if (F.hasPrefixData())
- map(F.getPrefixData());
-
- // Function bodies.
- for (const Function &F : M) {
- for (const Argument &A : F.args())
- map(&A);
- for (const BasicBlock &BB : F)
- map(&BB);
- for (const BasicBlock &BB : F)
- for (const Instruction &I : BB)
- map(&I);
-
- // Constants used by instructions.
- for (const BasicBlock &BB : F)
- for (const Instruction &I : BB)
- for (const Value *Op : I.operands())
- if ((isa<Constant>(Op) && !isa<GlobalValue>(*Op)) ||
- isa<InlineAsm>(Op))
- map(Op);
- }
-}
-
-void ValueMapping::map(const Value *V) {
- if (IDs.lookup(V))
- return;
-
- if (auto *C = dyn_cast<Constant>(V))
- if (!isa<GlobalValue>(C))
- for (const Value *Op : C->operands())
- map(Op);
-
- Values.push_back(V);
- IDs[V] = Values.size();
-}
-
-#ifndef NDEBUG
-static void dumpMapping(const ValueMapping &VM) {
- dbgs() << "value-mapping (size = " << VM.Values.size() << "):\n";
- for (unsigned I = 0, E = VM.Values.size(); I != E; ++I) {
- dbgs() << " - id = " << I << ", value = ";
- VM.Values[I]->dump();
- }
-}
-
-static void debugValue(const ValueMapping &M, unsigned I, StringRef Desc) {
- const Value *V = M.Values[I];
- dbgs() << " - " << Desc << " value = ";
- V->dump();
- for (const Use &U : V->uses()) {
- dbgs() << " => use: op = " << U.getOperandNo()
- << ", user-id = " << M.IDs.lookup(U.getUser()) << ", user = ";
- U.getUser()->dump();
- }
-}
-
-static void debugUserMismatch(const ValueMapping &L, const ValueMapping &R,
- unsigned I) {
- dbgs() << " - fail: user mismatch: ID = " << I << "\n";
- debugValue(L, I, "LHS");
- debugValue(R, I, "RHS");
-
- dbgs() << "\nlhs-";
- dumpMapping(L);
- dbgs() << "\nrhs-";
- dumpMapping(R);
-}
-
-static void debugSizeMismatch(const ValueMapping &L, const ValueMapping &R) {
- dbgs() << " - fail: map size: " << L.Values.size()
- << " != " << R.Values.size() << "\n";
- dbgs() << "\nlhs-";
- dumpMapping(L);
- dbgs() << "\nrhs-";
- dumpMapping(R);
-}
-#endif
-
-static bool matches(const ValueMapping &LM, const ValueMapping &RM) {
- DEBUG(dbgs() << "compare value maps\n");
- if (LM.Values.size() != RM.Values.size()) {
- DEBUG(debugSizeMismatch(LM, RM));
- return false;
- }
-
- // This mapping doesn't include dangling constant users, since those don't
- // get serialized. However, checking if users are constant and calling
- // isConstantUsed() on every one is very expensive. Instead, just check if
- // the user is mapped.
- auto skipUnmappedUsers =
- [&](Value::const_use_iterator &U, Value::const_use_iterator E,
- const ValueMapping &M) {
- while (U != E && !M.lookup(U->getUser()))
- ++U;
- };
-
- // Iterate through all values, and check that both mappings have the same
- // users.
- for (unsigned I = 0, E = LM.Values.size(); I != E; ++I) {
- const Value *L = LM.Values[I];
- const Value *R = RM.Values[I];
- auto LU = L->use_begin(), LE = L->use_end();
- auto RU = R->use_begin(), RE = R->use_end();
- skipUnmappedUsers(LU, LE, LM);
- skipUnmappedUsers(RU, RE, RM);
-
- while (LU != LE) {
- if (RU == RE) {
- DEBUG(debugUserMismatch(LM, RM, I));
- return false;
- }
- if (LM.lookup(LU->getUser()) != RM.lookup(RU->getUser())) {
- DEBUG(debugUserMismatch(LM, RM, I));
- return false;
- }
- if (LU->getOperandNo() != RU->getOperandNo()) {
- DEBUG(debugUserMismatch(LM, RM, I));
- return false;
- }
- skipUnmappedUsers(++LU, LE, LM);
- skipUnmappedUsers(++RU, RE, RM);
- }
- if (RU != RE) {
- DEBUG(debugUserMismatch(LM, RM, I));
- return false;
- }
- }
-
- return true;
-}
-
-static bool verifyBitcodeUseListOrder(const Module &M) {
- DEBUG(dbgs() << "*** verify-use-list-order: bitcode ***\n");
- TempFile F;
- if (F.init("bc"))
- return false;
-
- if (F.writeBitcode(M))
- return false;
-
- LLVMContext Context;
- std::unique_ptr<Module> OtherM = F.readBitcode(Context);
- if (!OtherM)
- return false;
-
- return matches(ValueMapping(M), ValueMapping(*OtherM));
-}
-
-static bool verifyAssemblyUseListOrder(const Module &M) {
- DEBUG(dbgs() << "*** verify-use-list-order: assembly ***\n");
- TempFile F;
- if (F.init("ll"))
- return false;
-
- if (F.writeAssembly(M))
- return false;
-
- LLVMContext Context;
- std::unique_ptr<Module> OtherM = F.readAssembly(Context);
- if (!OtherM)
- return false;
-
- return matches(ValueMapping(M), ValueMapping(*OtherM));
-}
-
-int main(int argc, char **argv) {
- sys::PrintStackTraceOnErrorSignal();
- llvm::PrettyStackTraceProgram X(argc, argv);
-
- // Enable debug stream buffering.
- EnableDebugBuffering = true;
-
- llvm_shutdown_obj Y; // Call llvm_shutdown() on exit.
- LLVMContext &Context = getGlobalContext();
-
- cl::ParseCommandLineOptions(argc, argv,
- "llvm tool to verify use-list order\n");
-
- SMDiagnostic Err;
-
- // Load the input module...
- std::unique_ptr<Module> M;
- M.reset(ParseIRFile(InputFilename, Err, Context));
-
- if (!M.get()) {
- Err.print(argv[0], errs());
- return 1;
- }
-
- DEBUG(dbgs() << "*** verify-use-list-order ***\n");
- if (!shouldPreserveBitcodeUseListOrder()) {
- // Can't verify if order isn't preserved.
- DEBUG(dbgs() << "warning: cannot verify bitcode; "
- "try -preserve-bc-use-list-order\n");
- return 0;
- }
-
- for (unsigned I = 0, E = NumShuffles; I != E; ++I) {
- DEBUG(dbgs() << "*** iteration: " << I << " ***\n");
-
- // Shuffle with a different seed each time so that use-lists that aren't
- // modified the first time are likely to be modified the next time.
- shuffleUseLists(*M, I);
- if (!verifyBitcodeUseListOrder(*M))
- report_fatal_error("bitcode use-list order changed");
-
- if (shouldPreserveAssemblyUseListOrder())
- if (!verifyAssemblyUseListOrder(*M))
- report_fatal_error("assembly use-list order changed");
- }
-
- return 0;
-}
Copied: llvm/trunk/tools/verify-uselistorder/CMakeLists.txt (from r214317, llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/verify-uselistorder/CMakeLists.txt?p2=llvm/trunk/tools/verify-uselistorder/CMakeLists.txt&p1=llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt&r1=214317&r2=214318&rev=214318&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/CMakeLists.txt (original)
+++ llvm/trunk/tools/verify-uselistorder/CMakeLists.txt Wed Jul 30 12:11:27 2014
@@ -7,6 +7,6 @@ set(LLVM_LINK_COMPONENTS
Support
)
-add_llvm_tool(llvm-uselistorder
- llvm-uselistorder.cpp
+add_llvm_tool(verify-uselistorder
+ verify-uselistorder.cpp
)
Copied: llvm/trunk/tools/verify-uselistorder/LLVMBuild.txt (from r214317, llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/verify-uselistorder/LLVMBuild.txt?p2=llvm/trunk/tools/verify-uselistorder/LLVMBuild.txt&p1=llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt&r1=214317&r2=214318&rev=214318&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/LLVMBuild.txt (original)
+++ llvm/trunk/tools/verify-uselistorder/LLVMBuild.txt Wed Jul 30 12:11:27 2014
@@ -1,4 +1,4 @@
-;===- ./tools/llvm-uselistorder/LLVMBuild.txt ------------------*- Conf -*--===;
+;===- ./tools/verify-uselistorder/LLVMBuild.txt ----------------*- Conf -*--===;
;
; The LLVM Compiler Infrastructure
;
@@ -17,6 +17,6 @@
[component_0]
type = Tool
-name = llvm-uselistorder
+name = verify-uselistorder
parent = Tools
required_libraries = IRReader BitWriter Support
Copied: llvm/trunk/tools/verify-uselistorder/Makefile (from r214317, llvm/trunk/tools/llvm-uselistorder/Makefile)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/verify-uselistorder/Makefile?p2=llvm/trunk/tools/verify-uselistorder/Makefile&p1=llvm/trunk/tools/llvm-uselistorder/Makefile&r1=214317&r2=214318&rev=214318&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/Makefile (original)
+++ llvm/trunk/tools/verify-uselistorder/Makefile Wed Jul 30 12:11:27 2014
@@ -1,4 +1,4 @@
-##===- tools/llvm-uselistorder/Makefile --------------------*- Makefile -*-===##
+##===- tools/verify-uselistorder/Makefile ------------------*- Makefile -*-===##
#
# The LLVM Compiler Infrastructure
#
@@ -8,7 +8,7 @@
##===----------------------------------------------------------------------===##
LEVEL := ../..
-TOOLNAME := llvm-uselistorder
+TOOLNAME := verify-uselistorder
LINK_COMPONENTS := AsmParser BitReader BitWriter Core IRReader Support
# This tool has no plugins, optimize startup time.
Copied: llvm/trunk/tools/verify-uselistorder/verify-uselistorder.cpp (from r214317, llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp)
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/verify-uselistorder/verify-uselistorder.cpp?p2=llvm/trunk/tools/verify-uselistorder/verify-uselistorder.cpp&p1=llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp&r1=214317&r2=214318&rev=214318&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-uselistorder/llvm-uselistorder.cpp (original)
+++ llvm/trunk/tools/verify-uselistorder/verify-uselistorder.cpp Wed Jul 30 12:11:27 2014
@@ -1,4 +1,4 @@
-//===- llvm-uselistorder.cpp - The LLVM Modular Optimizer -----------------===//
+//===- verify-uselistorder.cpp - The LLVM Modular Optimizer ---------------===//
//
// The LLVM Compiler Infrastructure
//
More information about the llvm-commits
mailing list