×

Technique for using shared resources on a multi-threaded processor

  • US 20020083252A1
  • Filed: 12/27/2000
  • Published: 06/27/2002
  • Est. Priority Date: 12/27/2000
  • Status: Active Grant
First Claim
Patent Images

1. A method of handling conflicts between threads, including an initiating thread and at least one other thread, for at least one shared resource in a multi-threaded processing system having a processor and memory, comprising:

  • (1) with the initiating thread, setting a location in memory for each other thread on the processor;

    (2) with the initiating thread, signaling an inter-processor interrupt (IPI) to all other threads on the processor;

    (3) for each other thread, initiating an interrupt handler where each other thread;

    (a) acknowledges receipt of the interrupt; and

    (b) proceeds to spin on the respective location in memory that was set in step (1), thereby guaranteeing that the respective other thread will not be using any shared resource of the processor;

    (4) the initiating thread;

    (a) waits for other threads on processor to acknowledge the inter-processor interrupt (IPI); and

    (b) when all the other threads have acknowledged the inter-processor interrupt (IPI), the initiating thread proceeds to step (5);

    (5) the initiating thread;

    (a) saves the state of the shared resource in memory;

    (b) sets the shared resource to the state wanted;

    (c ) uses the shared resource; and

    (d) restores the original state of the resource;

    (6) the initiating thread releases the other threads from their spin by resetting the location in memory that was set in step (1); and

    (7) all the threads proceed with their computations.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×