diff options
author | hunt <hunt> | 2008-02-12 14:49:44 +0000 |
---|---|---|
committer | hunt <hunt> | 2008-02-12 14:49:44 +0000 |
commit | a36378d75be5700d40fb3f9c51191305b3907abd (patch) | |
tree | c4e9ca4516b9092698c21ea7adb7066471747daf | |
parent | a8913457fffe45ca33813e045c335d0c38ab30b5 (diff) | |
download | systemtap-steved-a36378d75be5700d40fb3f9c51191305b3907abd.tar.gz systemtap-steved-a36378d75be5700d40fb3f9c51191305b3907abd.tar.xz systemtap-steved-a36378d75be5700d40fb3f9c51191305b3907abd.zip |
2008-02-12 Martin Hunt <hunt@redhat.com>
PR 5757
* tapsets.cxx, translate.cxx: Cleanup findentation a bit.
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | tapsets.cxx | 6 | ||||
-rw-r--r-- | translate.cxx | 4 |
3 files changed, 9 insertions, 5 deletions
@@ -1,3 +1,7 @@ +2008-02-12 Martin Hunt <hunt@redhat.com> + PR 5757 + * tapsets.cxx, translate.cxx: Cleanup findentation a bit. + 2008-02-11 Jim Keniston <jkenisto@us.ibm.com> PR 5693 diff --git a/tapsets.cxx b/tapsets.cxx index d5b84c91..540b3bc4 100644 --- a/tapsets.cxx +++ b/tapsets.cxx @@ -3924,7 +3924,7 @@ dwarf_derived_probe_group::emit_module_decls (systemtap_session& s) s.op->newline(1) << "struct kretprobe *krp = inst->rp;"; // NB: as of PR5673, the kprobe|kretprobe union struct is in BSS - s.op->newline(1) << "int kprobe_idx = ((uintptr_t)krp-(uintptr_t)stap_dwarf_kprobes)/sizeof(struct stap_dwarf_kprobe);"; + s.op->newline() << "int kprobe_idx = ((uintptr_t)krp-(uintptr_t)stap_dwarf_kprobes)/sizeof(struct stap_dwarf_kprobe);"; // Check that the index is plausible s.op->newline() << "struct stap_dwarf_probe *sdp = &stap_dwarf_probes["; s.op->line() << "((kprobe_idx >= 0 && kprobe_idx < " << probes_by_module.size() << ")?"; @@ -3948,7 +3948,7 @@ dwarf_derived_probe_group::emit_module_init (systemtap_session& s) { s.op->newline() << "for (i=0; i<" << probes_by_module.size() << "; i++) {"; s.op->newline(1) << "struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];"; - s.op->newline(1) << "struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];"; + s.op->newline() << "struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];"; s.op->newline() << "unsigned long relocated_addr = _stp_module_relocate (sdp->module, sdp->section, sdp->address);"; s.op->newline() << "if (relocated_addr == 0) continue;"; // quietly; assume module is absent s.op->newline() << "probe_point = sdp->pp;"; @@ -3987,7 +3987,7 @@ dwarf_derived_probe_group::emit_module_exit (systemtap_session& s) { s.op->newline() << "for (i=0; i<" << probes_by_module.size() << "; i++) {"; s.op->newline(1) << "struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];"; - s.op->newline(1) << "struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];"; + s.op->newline() << "struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];"; s.op->newline() << "if (! sdp->registered_p) continue;"; s.op->newline() << "if (sdp->return_p) {"; s.op->newline(1) << "unregister_kretprobe (&kp->u.krp);"; diff --git a/translate.cxx b/translate.cxx index 0beaf1f8..fefb0c8f 100644 --- a/translate.cxx +++ b/translate.cxx @@ -1260,8 +1260,8 @@ c_unparser::emit_module_exit () << "atomic_read (& ((struct context *)per_cpu_ptr(contexts, i))->busy)) " << "holdon = 1;"; o->newline () << "schedule ();"; - o->newline(-1) << "} while (holdon);"; - o->newline(-1); + o->newline(-2) << "} while (holdon);"; + // XXX: might like to have an escape hatch, in case some probe is // genuinely stuck somehow |