From 0c487e433fd6343e49b1e9dbc6492f38cfe26143 Mon Sep 17 00:00:00 2001 From: Rajasekhar Duddu Date: Mon, 21 Dec 2009 17:10:54 +0530 Subject: Tracepoint based tapset for memory subsystem. --- testsuite/buildok/vm.tracepoints.stp | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 testsuite/buildok/vm.tracepoints.stp (limited to 'testsuite/buildok') diff --git a/testsuite/buildok/vm.tracepoints.stp b/testsuite/buildok/vm.tracepoints.stp new file mode 100644 index 00000000..488ca0fc --- /dev/null +++ b/testsuite/buildok/vm.tracepoints.stp @@ -0,0 +1,31 @@ +#! stap -up4 + +probe vm.kfree { + println(name) + printf("%-15s %-15p %-15s %-15p \n", execname(), call_site, caller_function, ptr) +} + +probe vm.kmalloc { + println(name) + printf("%-15s %-15p %-15s %-15p %-15d %-15d %-15d %-15s \n", execname(), call_site, caller_function, ptr, bytes_req, bytes_alloc, gfp_flags, gfp_flag_name) +} + +probe vm.kmem_cache_alloc { + println(name) + printf("%-15s %-15p %-15s %-15p %-15d %-15d %-15d %-15s \n", execname(), call_site, caller_function, ptr, bytes_req, bytes_alloc, gfp_flags, gfp_flag_name) +} + +probe vm.kmalloc_node { + println(name) + printf("%-15s %-15p %-15s %-15p %-15d %-15d %-15d %-15s \n", execname(), call_site, caller_function, ptr, bytes_req, bytes_alloc, gfp_flags, gfp_flag_name) +} + +probe vm.kmem_cache_alloc_node { + println(name) + printf("%-15s %-15p %-15s %-15p %-15d %-15d %-15d %-15s \n", execname(), call_site, caller_function, ptr, bytes_req, bytes_alloc, gfp_flags, gfp_flag_name) +} + +probe vm.kmem_cache_free { + println(name) + printf("%-15s %-15p %-15s %-15p \n", execname(), call_site, caller_function, ptr) +} -- cgit From 40b71c4777ca110d69d5d61563d032a5ba1355df Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Mon, 21 Dec 2009 22:37:20 +0100 Subject: PR11038 Trailing semicolon as null-statement confusing. * parse.cxx (parser::parse_statement): Squash semicolon after non-block-like statements. * testsuite/buildok/semicolon.stp: New test. --- testsuite/buildok/semicolon.stp | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 testsuite/buildok/semicolon.stp (limited to 'testsuite/buildok') diff --git a/testsuite/buildok/semicolon.stp b/testsuite/buildok/semicolon.stp new file mode 100644 index 00000000..0ec41956 --- /dev/null +++ b/testsuite/buildok/semicolon.stp @@ -0,0 +1,18 @@ +#! stap -p4 + +# Test that semicolons are really optional (in non-block-like context). +# PR11038. + +global x = 0; +probe begin +{ + if (x) log("true") else log("false") + if (x) { log("true") } else { log("false") } + if (x) log("true"); else log("false") + if (x) log("true") else log("false"); +} + +probe end +{ + x = 1; +} -- cgit From 82acd39eeb4e04fc2359cb4ce1a0834f0d7769cc Mon Sep 17 00:00:00 2001 From: Andre Detsch Date: Tue, 22 Dec 2009 14:03:31 +0530 Subject: Updates to SCSI tapset scsi.stp and corresponding testcases --- testsuite/buildok/scsi.stp | 36 ++++++++++++++++++++++++------------ 1 file changed, 24 insertions(+), 12 deletions(-) (limited to 'testsuite/buildok') diff --git a/testsuite/buildok/scsi.stp b/testsuite/buildok/scsi.stp index dfe855de..036d0a47 100755 --- a/testsuite/buildok/scsi.stp +++ b/testsuite/buildok/scsi.stp @@ -15,29 +15,41 @@ fi stap -p4 - << EOF probe scsi.ioentry { - printf("ppname: %s, %d, %d, %d\n", probefunc(), - disk_major, disk_minor, device_state) + printf("%20s, disk_major=%d, disk_minor=%d, device_state=%s\n", + probefunc(), disk_major, disk_minor, device_state_str) } probe scsi.iodispatching { - printf("ppname: %s, %d, %d, %d, %d, %d, %d, %p, %d\n", probefunc(), - host_no, channel, lun, dev_id, device_state, data_direction, - request_buffer, request_bufflen) + printf("%20s, host_no=%d, channel=%d, lun=%d, dev_id=%d, device_state=%s, data_direction=%s, request_buffer=%p, request_bufflen=%d\n", + probefunc(), host_no, channel, lun, dev_id, device_state_str, + data_direction_str, request_buffer, request_bufflen) } - probe scsi.iodone { - printf("ppname: %s, %d, %d, %d, %d, %d, %d, %d\n", probefunc(), - host_no, channel, lun, dev_id, device_state, data_direction, - scsi_timer_pending) + printf("%20s, host_no=%d, channel=%d, lun=%d, dev_id=%d, device_state=%s, data_direction=%s, scsi_timer_pending=%d\n", + probefunc(), host_no, channel, lun, dev_id, device_state_str, + data_direction_str, scsi_timer_pending) } probe scsi.iocompleted { - printf("ppname: %s, %d, %d, %d, %d, %d, %d, %d\n", probefunc(), - host_no, channel, lun, dev_id, device_state, data_direction, - goodbytes) + printf("%20s, host_no=%d, channel=%d, lun=%d, dev_id=%d, device_state=%s, data_direction=%s, goodbytes=%d\n\n", + probefunc(), host_no, channel, lun, dev_id, device_state_str, + data_direction_str, goodbytes) +} + +probe scsi.set_state +{ + printf("%20s, host_no=%d, channel=%d, lun=%d, dev_id=%d, old_state=%s, state=%s\n", + probefunc(), host_no, channel, lun, dev_id, old_state_str, state_str) +} + +probe scsi.ioexecute +{ + printf("%20s, host_no=%d, channel=%d, lun=%d, dev_id=%d, device_state=%s, data_direction=%s, request_buffer=%p, request_bufflen=%d retries=%d, timeout=%d\n", + probefunc(),host_no, channel, lun, dev_id, device_state_str, + data_direction_str, request_buffer, request_bufflen, retries, timeout) } EOF -- cgit