This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2] Release the GIL while running a gdb command or expression


Pedro> Hopefully it'll be possible to tighten the test a bit to avoid that.

I should have read the test more closely.  It doesn't do what it claims
to do at all.

The only way the test can fail is if one "Hello" or "Sleeping" line
comes with the wrong number:

	set n $expect_out(1,string)
	if { $hello_last + 1 != $n } {
	    fail $test

But this just isn't possible.

Also the Python code is calling print on a gdb stream in a background
thread, which is a no-no.

I could change the test to do some kind of counting in a background
thread.  But that would introduce a race, which is what I was concerned
about up-thread... I couldn't think of a non-racy way to test this.

Maybe that's better than nothing.  Anyway, we're back to square one and
I don't know what to do really.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]