Debugging in Plain English?
sameerdesai writes "CNN is carrying a story about Researchers from Carnegie Melon: Myers and a graduate student, Andrew Ko, have developed a debugging program that lets users ask questions about computer errors in plain English: Why didn't a program behave as expected? I guess with recent exploits and bugs that were found this will soon be a hot research topic or tool in the market." We recently did a story about revolutionary debugging techniques; the researchers' website has some papers and other information.
"Because you can't code worth a damn."
Mr. Debugger, I'm running a multithreaded perl app using perl 5.8.3's ithreads. I am using DBD::mysql to talk to a local mysql database. At the program start I spawn a child thread that waits for a thread::queue to be filled with data. Once the child thread receives data it spawns several children of its own to process the data. Each grandchild forms its own dbd connection and successfully processes the data, then gracefully closes the connection and waits to be joined.
The problem arises when the controlling child thread begins to join the grandchildren. Despite the mention of global destruction, the entire program is not exiting - just the grandchildren are being joined. When the grandchildren join, perl dies with the following error:
Attempt to dereference null pointer during global destruction.
When performing the same style operation without using DBD (and thus not actually doing anything useful) the error does not occur. Initially, this appears to be a thread-safety issue with DBD however when isolating the child and grandchildren in their own test program (so the controlling child is the main program and the grandchildren are spawned worker children) the error does not appear.
Help me O great plain English debugger. You are my only hope!
Karma: SELECT `karma` FROM `users` WHERE `userid`=138474;
printf, System.out.println, warn, print, etc.
Oh ... this will be wonderful for security the world over. If it works ...
Microsoft Programmer: "Why does our software suck?"
*computer hangs, then bursts into flames from the load*
In soviet russia, You ask not what country do for you, but what you do for country!
Oh wait...
Because I debug in plain english anyway, I'm always saying "Why the hell won't you work you piece of shit?!" and "Listen here you piece of shit if you insist on seg faulting again then I'll show you where you can put those damn indices!"...
So... now the computer can actually respond to my threats and questions. Excellent!
Mike.
(Yes, I did RTFA.)
Mmmm......sacrelicious.
[...] "Forty-two," said Deep Thought, with infinite majesty and calm.
It was a long time before anyone spoke. Out of the corner of his eye Phouchg could see the sea of tense expectant faces down in the square outside.
"We're going to get lynched aren't we?" he whispered.
"It was a tough assignment," said Deep Thought mildly.
"Forty-two!" yelled Loonquawl. "Is that all you've got to show for seven and a half million years' work?"
"I checked it very thoroughly," said the computer [...]
www.kitchengeek.com -- Nosh for
WHERE THE FUCK DID MY THESIS GO??? ...if it can bring calm to these situations, we may have a contender for the Nobel Peace Prize.
Know what I like about atheists? I've yet to meet one that believes God is on their side.
That's great, but does it understand expletives?
Plain english or not, make it easy for someone to debug and I'll be out of a job. I like finding other people's mistakes and being the one to say "Uh, dude, this is where you screwed up, but I fixed it for you".
Where's the fun if I can't point out someone's shortcomings?
So when is the Hawkeye movie coming out?
Why didn't a program behave as expected?
Is it because didn't a program behave as expected that you came to me?
I think I'll stick to yelling at the machine when I'm trying to run "make" when a dependency gets left out of the ./configure script and it errors out after 5 minutes of compiling.
"What the fuck is libmonkey1316-3.so??!!"
Finding whole RPMs with the name of one known file you need is always fun. On second thought, maybe asking the computer what the hell that file is could help.
It would be cool if it didn't suck.
Hello SeanTobin(138474)!
I am Surest K. Padebugtel of Mrdebugger.com
I understand that you are having a problem with I'm running a multithreaded perl app using perl 5.8.3's ithreads. I am using DBD::mysql to talk to a local mysql database. At the program start I spawn a child thread that waits for a thread::queue to be filled with data. Once the child thread receives data it spawns several children of its own to process the data. Each grandchild forms its own dbd connection and successfully processes the data, then gracefully closes the connection and waits to be joined.
Please to reboot your system.
Has this helped your problem? (Click "Reply" to this trouble ticket if you feel you need further assistance with I'm running a multithreaded perl app using perl 5.8.3's ithreads. I am using DBD::mysql to talk to a local mysql database. At the program start I spawn a child thread that waits for a thread::queue to be filled with data. Once the child thread receives data it spawns several children of its own to process the data. Each grandchild forms its own dbd connection and successfully processes the data, then gracefully closes the connection and waits to be joined.)
Thank you for your interest in Mrdebugger.com!
Sincerely,
Suresh K. Padebugtel
Hey moderators, this is NOT FUNNY! I've been wresteling with this problem off and on for nearly 3 months now. (I've come up with several varried solutions, but none of them are the way I want it to be done)
Karma: SELECT `karma` FROM `users` WHERE `userid`=138474;
Hello, I found the problem. It is as follows:( @{$w{$s}}){if($y=~/[$br
push@{$w{length$_}},$_ for split$/,`cat $f`;$x=$_ for sort{$a<=>$b}keys%w;for$n(
reverse 3..$x){for$b(@{$w{$n}}){$s=$n-1;$m{$n}=$b;H:for$y
]{$s}/){$t=$y;$t=~s/$_/X/ for split'',$b;if($t=~/X{$s}/){$m{$s}=$y;if($s==3){fo
(sort{$a<=>$b}keys%m){next if$_>$n;print$m{$_},$/;}exit;}$s--;$b=$y;goto H;}}}}}
debug> Why did my web server crash?
reply> slashdotting
So this whole article is about the UPS Debugger. Just One More Hack, and then he'll put it on the 'net...
MP3 version available at: Just One More Hack - Mark WheadonCan not parse "do what say." Perhaps you have made a grammatical error?
Error: pre-parse failed. 200406271657.msg, line: 2
Never use an apostrophe followed by the letter "s" unless you mean to indicate possession. What exactly belongs to the melon? Observe:
I love your mom's peaches; I want to shake her tree.
> My program crashed.
What does that suggest to you?
> There is a bug somewhere.
Does it make you happy to know there is a bug somewhere?
> No.
Why are you so negative?
> Are you going to help me fix this bug?
We were discussing you, not me.
"It looks like you're trying to dereference a null pointer during global destruction. Would you like to start the debugger?"
Well, this is a snippet from a response, but it really gets the core of the issue. Global destruction is a very stressful time to do just about anything. I'm by no means a programmer, and I have no idea what you're talking about, but don't you have better things to do when the end of the world comes? I'm even more alarmed if your 'threads' are actually causing global destruction. I beg of you, please stop programming!
My Blog