Re: [PATCH] drivers/virt: vmgenid: add vm generation id driver

2020-10-19 Thread Mathieu Desnoyers
nicely as an extension of my KTLS prototype (extensible rseq): https://lore.kernel.org/lkml/20200925181518.4141-1-mathieu.desnoy...@efficios.com/ There are a few ways we could wire things up. One might be to add the UUID field into the extended KTLS structure (so it's always updated after it

Re: [Qemu-devel] [RFC PATCH] Introduce RCU-enabled DQs (v2)

2013-08-25 Thread Mathieu Desnoyers
} > +atomic_add(&n_nodes, RCU_Q_LEN); > +} > + > +static void rcu_qtest_run(int duration, int nreaders) > +{ > +int nthreads = nreaders + 1; > +while (atomic_read(&nthreadsrunning) < nthreads) { > +g_usleep(1000); > +} > + > +goflag = GOFLAG_RUN; > +sleep(duration); > +goflag = GOFLAG_STOP; > +wait_all_threads(); > +} > + > + > +static void rcu_qtest(const char *test, int duration, int nreaders) > +{ > +int i; > +long long n_removed_local=0; > + > +struct list_element *el, *prev_el; > + > +rcu_qtest_init(); > +for (i = 0; i < nreaders; i++) { > +create_thread(rcu_q_reader); > +} > +create_thread(rcu_q_updater); > +rcu_qtest_run(duration, nreaders); > +rcu_thread_offline(); > + > +QLIST_FOREACH_SAFE_RCU(prev_el, &Q_list_head, entry, el) { > +QLIST_REMOVE_RCU(prev_el, entry); > +call_rcu1(&prev_el->rcu, reclaim_list_el); > +n_removed_local++; > +} > +atomic_add(&n_nodes_removed, n_removed_local); > +rcu_quiescent_state(); > +synchronize_rcu(); > +while (n_nodes_removed > n_reclaims){ > +rcu_quiescent_state(); > +g_usleep(100); > +synchronize_rcu(); > +} > +printf("%s: %d readers; 1 updater; nodes read: %lld, nodes removed: > %lld; nodes reclaimed: %lld\n", > + test, nthreadsrunning -1, n_reads, n_nodes_removed, n_reclaims); > +exit(0); > +} > + > +static void usage(int argc, char *argv[]) > +{ > +fprintf(stderr, "Usage: %s duration nreaders\n", argv[0]); > +exit(-1); > +} > + > + > +int main(int argc, char *argv[]) > +{ > +int duration = 0, readers = 0; > + > +if (argc >= 2) { > +duration = strtoul(argv[1], NULL, 0); > +} > +if (argc >= 3) { > +readers = strtoul(argv[2], NULL, 0); > +} > + > +/* This thread is not part of the test. */ > +rcu_thread_offline(); > +if (duration && readers) > +rcu_qtest(argv[0], duration, readers); > +usage(argc, argv); > +return 0; > +} > -- > 1.8.3.1 > -- Mathieu Desnoyers EfficiOS Inc. http://www.efficios.com

Re: [Qemu-devel] [lttng-dev] [RFC PATCH v2 0/4] simpletrace : support var num of args and strings.

2012-01-10 Thread Mathieu Desnoyers
Hi Stefan, * Stefan Hajnoczi (stefa...@gmail.com) wrote: > On Tue, Jan 10, 2012 at 12:14 AM, Mathieu Desnoyers > wrote: > > This is needed to (very soon) add support for sdt.h in LTTng-UST 2.0, so > > systemtap and gdb can hook into tracepoints declared by lttng-ust 2.0. >

Re: [Qemu-devel] [lttng-dev] [RFC PATCH v2 0/4] simpletrace : support var num of args and strings.

2012-01-10 Thread Mathieu Desnoyers
* Harsh Bora (ha...@linux.vnet.ibm.com) wrote: > On 01/10/2012 02:36 PM, Harsh Bora wrote: >> On 01/10/2012 12:47 PM, Mathieu Desnoyers wrote: >>> * Harsh Bora (ha...@linux.vnet.ibm.com) wrote: >>>> On 01/10/2012 05:44 AM, Mathieu Desnoyers wrote: >>>&g

Re: [Qemu-devel] [lttng-dev] [RFC PATCH v2 0/4] simpletrace : support var num of args and strings.

2012-01-09 Thread Mathieu Desnoyers
* Harsh Bora (ha...@linux.vnet.ibm.com) wrote: > On 01/10/2012 05:44 AM, Mathieu Desnoyers wrote: >> * Harsh Bora (ha...@linux.vnet.ibm.com) wrote: >>> On 01/09/2012 09:31 PM, Mathieu Desnoyers wrote: >>>> * Harsh Prateek Bora (ha...@linux.vnet.ibm.com) wrote: >&

Re: [Qemu-devel] [RFC PATCH v2 0/4] simpletrace : support var num of args and strings.

2012-01-09 Thread Mathieu Desnoyers
* Harsh Bora (ha...@linux.vnet.ibm.com) wrote: > On 01/09/2012 09:31 PM, Mathieu Desnoyers wrote: >> * Harsh Prateek Bora (ha...@linux.vnet.ibm.com) wrote: >>> Existing simple trace can log upto 6 args per trace event and does not >>> support strings in trace record fo

Re: [Qemu-devel] [RFC PATCH v2 0/4] simpletrace : support var num of args and strings.

2012-01-09 Thread Mathieu Desnoyers
ace.py | 110 ++- > scripts/tracetool.py | 505 > > trace/simple.c | 178 ++--- > trace/simple.h | 31 +++- > 8 files changed, 702 insertions(+), 144 deletions(-) > create mode 100755 scripts/tracetool.py > -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com

Re: [Qemu-devel] [ltt-dev] [PATCH 2/3] trace: [ust] Do not use 'm' in event argument names (used by ust macros)

2011-09-20 Thread Mathieu Desnoyers
* Stefan Hajnoczi (stefa...@gmail.com) wrote: > 2011/9/20 Mathieu Desnoyers : > > * Lluís Vilanova (vilan...@ac.upc.edu) wrote: > >> Stefan Hajnoczi writes: > >> > >> > On Fri, Sep 16, 2011 at 06:59:38PM +0200, Lluís Vilanova wrote: > >> >> Si

Re: [Qemu-devel] [ltt-dev] [PATCH 2/3] trace: [ust] Do not use 'm' in event argument names (used by ust macros)

2011-09-20 Thread Mathieu Desnoyers
becomes that much richer." > -- The Princess of Pure Reason, as told by Norton Juster in The Phantom > Tollbooth > -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com

Re: [Qemu-devel] [ltt-dev] [PATCH 2/3] trace: [ust] Do not use 'm' in event argument names (used by ust macros)

2011-09-20 Thread Mathieu Desnoyers
t; assume > the two patches I sent (this naming issue and the zero-length printf format) > are > just no longer necessary with recent versions of libust. > > > Thanks, > Lluis > > -- > "And it's much the same thing with knowledge, for whenever you l

Re: [Qemu-devel] [ltt-dev] [PATCH 2/3] trace: [ust] Do not use 'm' in event argument names (used by ust macros)

2011-09-20 Thread Mathieu Desnoyers
xing that for trace_mark() instrumentation in UST 0.x ages ago (ok, probably last winter). I think simply updating to a new UST version will fix the issue. Best regards, Mathieu > > Stefan > > ___ > ltt-dev mailing list > ltt-...@lists.casi.polymtl.ca > http://lists.casi.polymtl.ca/cgi-bin/mailman/listinfo/ltt-dev > -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com

[Qemu-devel] [RELEASE] LTTng-UST 0.15 (Qemu support & tutorial)

2011-07-15 Thread Mathieu Desnoyers
5144748823020811/32575_5629652727107472206/ust_6), 0, 0, , , 0, 0x0, MODE_UNKNOWN { ptr = 0x1187660 } -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com