Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
×
Patents

Breakpoints have now been patented 412

An anonymous reader noted that apparently Breakpoints have now been patented. From the link "A method for debugging including the steps of receiving code having a software breakpoint function therein, running the code for the purpose of debugging, monitoring the code to detect the presence of the software breakpoint function, recognizing the software breakpoint function, determining an action to be performed based on the software breakpoint function, and implementing the action. The present invention also includes an apparatus for implementing the method for debugging and a medium embodying a program of instructions for execution by a device to perform the method for debugging."
This discussion has been archived. No new comments can be posted.

Breakpoints have now been patented

Comments Filter:
  • Comment removed (Score:1, Insightful)

    by account_deleted ( 4530225 ) on Thursday May 03, 2007 @02:00PM (#18975743)
    Comment removed based on user account deletion
  • No longer news (Score:3, Insightful)

    by pembo13 ( 770295 ) on Thursday May 03, 2007 @02:03PM (#18975789) Homepage
    At this point, these things aren't really "news" any more, and certainly no longer shocking.
  • I'm not up on my patent-ese, but I think this is describing a specific type of breakpoint technology based on virtual functions. Since we've been talking about Javascript so much lately, and it's so easy to do virtual functions in JS, here's an example in JS code:

    Debugger.breakPoint = function()
    {
    //do nothing
    };
    Now if you put the function in your code, nothing happens:

    Debugger.breakPoint();
    But if you have the debugger initialized, it will replace the virtual function like this:

    Debugger.breakPoint = function()
    {
        Debugger.runDebuggerAndStopTheWorld();
    };
    Thus you end up with software breakpoints that can trigger the debugger based on optional listeners. At least, that's how I understand it. I could be wrong about the actual implementation.
  • by jshriverWVU ( 810740 ) on Thursday May 03, 2007 @02:03PM (#18975803)
    I'm curious why it was patented and then let go for free if that's the case. Patents are extremely expensive, and each year are more and more expensive. Just doesnt make sense to patent something so simple, and pay all that money for nothing.
  • by Mr. Underbridge ( 666784 ) on Thursday May 03, 2007 @02:07PM (#18975859)

    Thus you end up with software breakpoints that can trigger the debugger based on optional listeners. At least, that's how I understand it. I could be wrong about the actual implementation.

    You've just observed the slashdot patent attention span deficiency. Because most posters on this site don't have the slightest clue how to read a patent, they interpret a patent that claims to improve technology X by using method Y a synonymous to patenting X. Sure, this is obviously wrong to a moderately intelligent Orangutan, but nevertheless, it happens a lot here.

  • are you kidding? (Score:5, Insightful)

    by nanosquid ( 1074949 ) on Thursday May 03, 2007 @02:11PM (#18975943)
    "Free patents online" is a service that lets you search for patents on-line for free; the patents themselves aren't "free".
  • I can believe that. MULTICS was a truly incredible operating system, but is so poorly known by the programming public at large. It wouldn't surprise me at all if HP reinvented something that was already invented in MULTICS.

    It's simply too bad that Honeywell drove the system into the ground. We might all be using MULTICS derivatives today if Honeywell hadn't tried to compete against their own computers. :-(
  • by giafly ( 926567 ) on Thursday May 03, 2007 @02:22PM (#18976127)
    to prevent horrors like OP. Did you notice how the "free(b)" call was after an unconditional return? Somebody didn't.
  • Re:Next up... (Score:3, Insightful)

    by pclminion ( 145572 ) on Thursday May 03, 2007 @02:23PM (#18976147)

    Wouldn't nested 'if..then's be better in this case?

    That requires one level of nesting for every initialized resource. That can become ridiculous very quickly. A rollback or "error ladder" is something you see in a lot of commercial AND open source code. Examples I know of include FreeType and the Linux kernel.

    It's only "unclear" in the sense that a for-loop was "unclear" to you when you first learned how to use it. This is a common, generally accepted idiom for the use of goto.

  • Yeah, except that debugging, breakpoints, and "virtual functions" or closures, interpreted code, or whatnot have been around for so long, that there is essentially nothing new under the sun. Smalltalk implementations were able to call into the debugger through an assert-like mechanism. You could then enter the debugger, change values around, and continue execution. Made things much easier when you were in the middle of a multi-day simulation test run and hit a problem. You could note the problem, fix it, and continue. Various Lisp, Scheme, ProLog and so forth variants have done some very neat things with debugging support through assertions, exceptions, traps, and all kinds of mechanisms. Essentially, any time you have an interpretive runtime, people play with different ways to do debugging.

    Another way to look at it is that many runtimes will automatically enter the debugger on an exception or trap of some kind. An assertion failure generates an exception or trap. Assertions are generally controlled by DEBUG variables of some kind. Viola! Configurable code-side breakpoints. Different languages handle resumption from exceptions in different ways.

    The problem is that people who write patents think that the mere act of putting two things together is innovative, even if the first thing is a tool, and the second is a logical extension of the tool's purpose, like adding "on the Internet" to something and calling it an invention. In this case, they did not even bother to see if it was done before, probably because they have no knowledge of languages outside the mainstream.
  • by richie2000 ( 159732 ) <rickard.olsson@gmail.com> on Thursday May 03, 2007 @02:32PM (#18976311) Homepage Journal
    I had a hardware breakpoint debugger in The Final Cartridge II on the Commodore 64. That was, what - 20-25 years ago? This patent was issued last year.

    That said, the first 13 claims pertain to software only (curio: the word "software" appears no less than 17 times in the first claim, "hardware" scores a big fat zero). Subsequent claims seem to revolve around a device reading a medium where the debug code is stored, ie RAM, some kind of ROM or even a CD with reader would fit this description.
    It's so vaguely stated as to be totally useless. Useless, that is, if someone were to actually use this patent to implement something useful. You know, like the patent system was supposed to do. Very useful if it's to be used to threaten competitors and stifle innovation.

    "To promote the progress of science and useful arts", my ass.
  • by Anonymous Coward on Thursday May 03, 2007 @02:32PM (#18976325)
    That's reasonable - if more code is added that may fail, and hence require b to be freed, then the free() is already there as a reminder.
  • by Anonymous Coward on Thursday May 03, 2007 @02:54PM (#18976749)

    Readers are encouraged to read the claims and not spread FUD because they can.


    This is Slashdot... you must be new here.
  • by kalaf ( 963208 ) on Thursday May 03, 2007 @03:15PM (#18977113)

    You read the article, You corrected yourself before someone else did, AND you want people to take your Karma away.

    I don't think you belong here...

  • Re:Next up... (Score:3, Insightful)

    by Chris Burke ( 6130 ) on Thursday May 03, 2007 @03:18PM (#18977171) Homepage
    I really don't see how you figure those 'goto's increased the understandability or maintainability of that code. 'If' statements make the control flow clear simply by the structure. "goto" makes that structure meaningless since the program can leap out of it to some arbitrary point at any time.

    Just on general principle I eschew multiple returns from a function. For one, it makes control flow harder to understand (the exact same problem with goto) by creating alternative exits from a function and whatever other control structures (for loops etc) you put the return inside. For two, it can pollute branch prediction resources on some computers, specifically ones that use the BTB to identify call/returns for use with a Return Address Stack.

    Your function would be trivial to refactor without using any gotos, and it would be both easier to understand and easier on the hardware.
  • Re:Next up... (Score:1, Insightful)

    by Anonymous Coward on Thursday May 03, 2007 @03:42PM (#18977655)

    char *a = malloc(100);
    if (!a)
    throw new err_malloc_a();

    Heh. What do you do when you fail to allocate memory? You allocate more memory!

    What's more interesting that all the attempts I've seen so far at rewriting the original code snippet without using gotos end up with more convoluted, less readable code. But I guess that's cargo cult programming for you...

  • by The_Dude ( 26374 ) on Thursday May 03, 2007 @03:43PM (#18977677)
    If you enter the application number in the US PTO search function, you get: http://patft.uspto.gov/netacgi/nph-Parser?Sect1=PT O2&Sect2=HITOFF&p=1&u=%2Fnetahtml%2FPTO%2Fsearch-a dv.htm&r=1&f=G&l=50&d=PALL&S1=20030208745&OS=20030 208745&RS=20030208745 [uspto.gov]

    Patent 7,055,140: Software breakpoints implementation via specially named function.
  • by SL Baur ( 19540 ) <steve@xemacs.org> on Thursday May 03, 2007 @03:45PM (#18977727) Homepage Journal
    No that's not what they've patented. They've patented source level debugging with static break points. Apparently the developer litters the source code with SOFTWARE_BREAKPOINT; calls which turn into do-nothing statements if there is no debugger running the code. The target environment appears to be an embedded system like a cellphone.

    They have not patented hardware breakpoints, gdb, etc. and a huge advantage of their system is that you could apparently debug and selectively enable/disable breakpoints in a production ROM executable image.

    I know noone reads these patents when these kinds of articles go by, this is /., but is it too much to ask that the article submitter or the editor read them first?
  • Prior art! (Score:3, Insightful)

    by Opportunist ( 166417 ) on Thursday May 03, 2007 @03:53PM (#18977881)
    0xCC
  • Re:Next up... (Score:3, Insightful)

    by Anonymous Coward on Thursday May 03, 2007 @04:08PM (#18978105)
    Great, now add ten more ifs there and see how readable it becomes vs. the goto solution with ten more labels and gotos

    What on earth is wrong with people? Doesn't anyone ever actually sit back and THINK about how to write readable, maintainable procedural code?! First of all, any half-sensible person would put these things into a structure, containing pointers to such allocated memory. Then you just have functions that initialize and destroy that structure.

    But, if you're hell-bent on allocating a bunch of memory in separate pointers, try this on for size:

    int allocstuff(void)
    {
                int return_val = 0;

                char *a = malloc(100);
                if (!a) {
                            return -1;
                }

                char *b = malloc(100);
                if (!b) {
                            free(a);
                            return -2;
                }

                char *c = malloc(100);
                if (!c) {
                            free(a);
                            free(b);
                            return -3;
                }

                char *d = malloc(100);
                if (!d) {
                            free(a);
                            free(b);
                            free(c);
                            return -4;
                }
    .
    .
    .
                return return_val;
    }

    Advantages:
    1) This way, it's very easy to read and follow the code. Any error causes you to abort immediately.
    2) It makes it very easy to assign different return codes for different errors.
    3) There's no complicated and messy multiply-nested control blocks here.

    Disadvantages:
    1) Later failure clauses can have a long list of free() statements. BUT, this way the code is simple to follow, and it's easy to verify any oversight.
    2) Potentially, you have code bloat, from lots of redundant free() statements. Only a problem if you're writing for some tiny-ass embedded system. In my experience, the number of people who THINK they need to worry about code bloat is a lot larger than the number of people who actually DO need to worry about code bloat.

    I can't count the number of times I've come across code that looks like the grandparent poster's, and re-wrote it. If you're writing for anything larger than a cellphone, and you think nested goto statements are the best way to handle this problem, you're not qualified to write procedural C code. Go learn OOP and use some higher-level language with a garbage collector.

          -D
  • Re:Next up... (Score:2, Insightful)

    by Threni ( 635302 ) on Thursday May 03, 2007 @05:08PM (#18979341)
    > That requires one level of nesting for every initialized resource. That can become ridiculous very
    > quickly.

    It becomes ridiculous less quickly than your spaghetti! If you have a lot of resources being allocated/deallocated often then obviously you'd want a different approach - perhaps a linked list (or some other collection) of resources to free up at some later point.

    You seem to admire the fact that this sort of code is in common use - even in Linux! Much of the code I see is a joke, so that doesn't surprise me.

    > It's only "unclear" in the sense that a for-loop was "unclear" to you when you first learned how to
    > use it.

    No, a for-loop is something you learn once and then never forget. Goto-ridden code is something you have to pick your way around every time you come to attempt to expand (or debug!) it.

  • by pcause ( 209643 ) on Thursday May 03, 2007 @05:25PM (#18979623)
    The recent Supreme Court ruling about "obviousness" will make this patent worth less than the paper it was printed on. This one will clearly get tossed if they try to enforce it. It is obvious, in the sense that the Court defined the term and prior art exists.
  • by nitecoder ( 683258 ) on Thursday May 03, 2007 @05:50PM (#18980035) Homepage
    IANAL, but from what I understand there is a reason people don't read patents, at least in the US. If you violate a patent knowingly, you are liable for triple damages, whereas is you violate it unknowingly, only single damages.

He has not acquired a fortune; the fortune has acquired him. -- Bion

Working...