Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Algorithms
  4. Lock free data structures

Lock free data structures

Scheduled Pinned Locked Moved Algorithms
csharpasp-netquestion
6 Posts 4 Posters 4 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sijin
    wrote on last edited by
    #1

    I was thinking today that it should be relatively easy to implement lock free data structures using Thread Local Storage but surprisingly Google didn't reveal anything that really stood out or even a library of basic data structures that have been built using this. Is there something I am missing?


    I always think that the idea of a compiler that compiles another compiler or itself is rather incestuous in a binary way. - Colin Davies My .Net Blog

    L E 2 Replies Last reply
    0
    • S Sijin

      I was thinking today that it should be relatively easy to implement lock free data structures using Thread Local Storage but surprisingly Google didn't reveal anything that really stood out or even a library of basic data structures that have been built using this. Is there something I am missing?


      I always think that the idea of a compiler that compiles another compiler or itself is rather incestuous in a binary way. - Colin Davies My .Net Blog

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      Hi, thread local storage offers storage that is private to the thread. When threads cooperate, they have to share data; thread local data does not help here, it prevents sharing. To share data safely most often one needs a synchronization mechanism; a lock is one example thereof. :)

      Luc Pattyn [My Articles] [Forum Guidelines]

      S 1 Reply Last reply
      0
      • L Luc Pattyn

        Hi, thread local storage offers storage that is private to the thread. When threads cooperate, they have to share data; thread local data does not help here, it prevents sharing. To share data safely most often one needs a synchronization mechanism; a lock is one example thereof. :)

        Luc Pattyn [My Articles] [Forum Guidelines]

        S Offline
        S Offline
        Sijin
        wrote on last edited by
        #3

        Of course, thanks for clearing that up :)


        I always think that the idea of a compiler that compiles another compiler or itself is rather incestuous in a binary way. - Colin Davies My Blog

        1 Reply Last reply
        0
        • S Sijin

          I was thinking today that it should be relatively easy to implement lock free data structures using Thread Local Storage but surprisingly Google didn't reveal anything that really stood out or even a library of basic data structures that have been built using this. Is there something I am missing?


          I always think that the idea of a compiler that compiles another compiler or itself is rather incestuous in a binary way. - Colin Davies My .Net Blog

          E Offline
          E Offline
          El Corazon
          wrote on last edited by
          #4

          Sijin wrote:

          Lock free data structures

          There are many lock free algorithms, unfortunately most are patented. But as pointed out local storage comes off the thread's private memory storage and is by definition "local" only to that thread and cannot be shared. I keep debating on writing something for this, and have been encouraged to do so.... started once, but it is not as easy concept as it sounds. It gets complicated real quick.

          _________________________ Asu no koto o ieba, tenjo de nezumi ga warau. Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)

          S 1 Reply Last reply
          0
          • E El Corazon

            Sijin wrote:

            Lock free data structures

            There are many lock free algorithms, unfortunately most are patented. But as pointed out local storage comes off the thread's private memory storage and is by definition "local" only to that thread and cannot be shared. I keep debating on writing something for this, and have been encouraged to do so.... started once, but it is not as easy concept as it sounds. It gets complicated real quick.

            _________________________ Asu no koto o ieba, tenjo de nezumi ga warau. Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)

            S Offline
            S Offline
            spin vector
            wrote on last edited by
            #5

            Mind you -- that most are patented it a great thing -- you can read exactly how it is done. www.uspto.gov or patents.google.com. I'm not advocating IP theft, but the constitutional point of the patent system is to exchange temporary monopoly for full public disclosure. The best parts of a patent for non-lawyers is the background and following 'spec' (specification). Good luck, spin-vec

            E 1 Reply Last reply
            0
            • S spin vector

              Mind you -- that most are patented it a great thing -- you can read exactly how it is done. www.uspto.gov or patents.google.com. I'm not advocating IP theft, but the constitutional point of the patent system is to exchange temporary monopoly for full public disclosure. The best parts of a patent for non-lawyers is the background and following 'spec' (specification). Good luck, spin-vec

              E Offline
              E Offline
              El Corazon
              wrote on last edited by
              #6

              spin vector wrote:

              you can read exactly how it is done.

              I am quite familiar with how it is done. I was pointing out that most algorithms are patented, as both a warning, and information since as you pointed out they all can be searched online. What someone chooses to do with that information, learn, use, or find another way is up to them.

              _________________________ Asu no koto o ieba, tenjo de nezumi ga warau. Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups