This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [PATCH 1/2] rewrite the case typemismatch
- From: "Zhou, Wenjian/åæå" <zhouwj-fnst at cn dot fujitsu dot com>
- To: David Smith <dsmith at redhat dot com>
- Cc: <systemtap at sourceware dot org>
- Date: Tue, 1 Dec 2015 11:15:07 +0800
- Subject: Re: [PATCH 1/2] rewrite the case typemismatch
- Authentication-results: sourceware.org; auth=none
- References: <1448935063-2946-1-git-send-email-zhouwj-fnst at cn dot fujitsu dot com>
Hello David,
I will describe the bug in typemismatch in the following.
On 12/01/2015 09:57 AM, Zhou Wenjian wrote:
* testsuite/semko/typemismatch.stp: use the following cases to replace it
* testsuite/semko/typemismatch1.stp
* testsuite/semko/typemismatch2.stp
* testsuite/semko/typemismatch3.stp
---
testsuite/semko/typemismatch.stp | 8 --------
testsuite/semko/typemismatch1.stp | 8 ++++++++
testsuite/semko/typemismatch2.stp | 4 ++++
testsuite/semko/typemismatch3.stp | 3 +++
4 files changed, 15 insertions(+), 8 deletions(-)
delete mode 100755 testsuite/semko/typemismatch.stp
create mode 100755 testsuite/semko/typemismatch1.stp
create mode 100755 testsuite/semko/typemismatch2.stp
create mode 100755 testsuite/semko/typemismatch3.stp
diff --git a/testsuite/semko/typemismatch.stp b/testsuite/semko/typemismatch.stp
deleted file mode 100755
index 94a49d5..0000000
--- a/testsuite/semko/typemismatch.stp
+++ /dev/null
@@ -1,8 +0,0 @@
-#! stap -p2
-
-
-global noo
-
-probe begin { foo = 1 ; foo = "bar" ; noo = 4 }
-
-probe end { foo = "zoo" ; foo <<< 2 ; noo = "zoo" }
The 'foo = 1; foo = "bar";' and 'foo = "zoo" ; foo <<< 2;' will just cause some warnings,
and won't cause error.
It means the case just have the same coverage as typemismatch1.stp in the following.
So I rewrite it by the following cases.
\ No newline at end of file
diff --git a/testsuite/semko/typemismatch1.stp b/testsuite/semko/typemismatch1.stp
new file mode 100755
index 0000000..e60b376
--- /dev/null
+++ b/testsuite/semko/typemismatch1.stp
@@ -0,0 +1,8 @@
+#! stap -p2
+
+
+global noo
+
+probe begin { noo = 4 }
+
+probe end { noo = "zoo" }
diff --git a/testsuite/semko/typemismatch2.stp b/testsuite/semko/typemismatch2.stp
new file mode 100755
index 0000000..940582e
--- /dev/null
+++ b/testsuite/semko/typemismatch2.stp
@@ -0,0 +1,4 @@
+#! stap -p2
+
+
+probe begin { foo = 1 ; foo = "bar" ; print(foo) }
diff --git a/testsuite/semko/typemismatch3.stp b/testsuite/semko/typemismatch3.stp
new file mode 100755
index 0000000..74e367d
--- /dev/null
+++ b/testsuite/semko/typemismatch3.stp
@@ -0,0 +1,3 @@
+#! stap -p2
+
+probe begin { foo = "zoo" ; foo <<< 2 ; print(foo) }
--
Thanks
Zhou