[PATCH] D19523: Symbolize operand bundle blocks for bcanalyzer
Sanjoy Das via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 25 23:05:00 PDT 2016
This revision was automatically updated to reflect the committed changes.
sanjoy marked an inline comment as done.
Closed by commit rL267524: Symbolize operand bundle blocks for bcanalyzer (authored by sanjoy).
Changed prior to commit:
http://reviews.llvm.org/D19523?vs=54966&id=54967#toc
Repository:
rL LLVM
http://reviews.llvm.org/D19523
Files:
llvm/trunk/test/Bitcode/operand-bundles-bc-analyzer.ll
llvm/trunk/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
Index: llvm/trunk/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
===================================================================
--- llvm/trunk/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
+++ llvm/trunk/tools/llvm-bcanalyzer/llvm-bcanalyzer.cpp
@@ -105,6 +105,7 @@
switch (BlockID) {
default: return nullptr;
+ case bitc::OPERAND_BUNDLE_TAGS_BLOCK_ID: return "OPERAND_BUNDLE_TAGS_BLOCK";
case bitc::MODULE_BLOCK_ID: return "MODULE_BLOCK";
case bitc::PARAMATTR_BLOCK_ID: return "PARAMATTR_BLOCK";
case bitc::PARAMATTR_GROUP_BLOCK_ID: return "PARAMATTR_GROUP_BLOCK_ID";
@@ -279,6 +280,7 @@
STRINGIFY_CODE(FUNC_CODE, INST_CALL)
STRINGIFY_CODE(FUNC_CODE, DEBUG_LOC)
STRINGIFY_CODE(FUNC_CODE, INST_GEP)
+ STRINGIFY_CODE(FUNC_CODE, OPERAND_BUNDLE)
}
case bitc::VALUE_SYMTAB_BLOCK_ID:
switch (CodeID) {
@@ -364,6 +366,12 @@
case bitc::USELIST_CODE_DEFAULT: return "USELIST_CODE_DEFAULT";
case bitc::USELIST_CODE_BB: return "USELIST_CODE_BB";
}
+
+ case bitc::OPERAND_BUNDLE_TAGS_BLOCK_ID:
+ switch(CodeID) {
+ default: return nullptr;
+ case bitc::OPERAND_BUNDLE_TAG: return "OPERAND_BUNDLE_TAG";
+ }
}
#undef STRINGIFY_CODE
}
Index: llvm/trunk/test/Bitcode/operand-bundles-bc-analyzer.ll
===================================================================
--- llvm/trunk/test/Bitcode/operand-bundles-bc-analyzer.ll
+++ llvm/trunk/test/Bitcode/operand-bundles-bc-analyzer.ll
@@ -0,0 +1,27 @@
+; RUN: llvm-as < %s | llvm-bcanalyzer -dump -disable-histogram | FileCheck %s
+
+; CHECK: <OPERAND_BUNDLE_TAGS_BLOCK
+; CHECK-NEXT: <OPERAND_BUNDLE_TAG
+; CHECK-NEXT: <OPERAND_BUNDLE_TAG
+; CHECK-NEXT: <OPERAND_BUNDLE_TAG
+; CHECK-NEXT: <OPERAND_BUNDLE_TAG
+; CHECK-NEXT: <OPERAND_BUNDLE_TAG
+; CHECK-NEXT: </OPERAND_BUNDLE_TAGS_BLOCK
+
+; CHECK: <FUNCTION_BLOCK
+; CHECK: <OPERAND_BUNDLE
+; CHECK: <OPERAND_BUNDLE
+; CHECK-NOT: <OPERAND_BUNDLE
+; CHECK: </FUNCTION_BLOCK
+
+; CHECK: Block ID #{{[0-9]+}} (OPERAND_BUNDLE_TAGS_BLOCK)
+
+declare void @callee0()
+
+define void @f0(i32* %ptr) {
+ entry:
+ %l = load i32, i32* %ptr
+ %x = add i32 42, 1
+ call void @callee0() [ "foo"(i32 42, i64 100, i32 %x), "bar"(float 0.000000e+00, i64 100, i32 %l) ]
+ ret void
+}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19523.54967.patch
Type: text/x-patch
Size: 2317 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160426/6226aa4a/attachment.bin>
More information about the llvm-commits
mailing list