Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.programming.threads > #605
| From | ittium <ittium@gmail.com> |
|---|---|
| Newsgroups | comp.programming.threads |
| Subject | Re: Threads and statically allocated buffer |
| Date | 2011-09-25 11:45 +0530 |
| Organization | A noiseless patient Spider |
| Message-ID | <j5mgui$emb$1@dont-email.me> (permalink) |
| References | <j5ejum$sd4$1@dont-email.me> <3b791257-790b-43e2-a447-4fcc33538138@a3g2000pro.googlegroups.com> <j5jmrm$1g7$1@dont-email.me> <553ba480-a945-4ab9-879a-1a0cfaa70f31@n36g2000yqb.googlegroups.com> |
On 25-09-2011 AM 01:12, David Schwartz wrote: > On Sep 23, 9:38 pm, ittium<itt...@gmail.com> wrote: > >> Is there any operation that is guaranteed to be atomic ? > > Your platform might have some. > >> From your >> reasoning it seems operations like ++a or a=b are also not atomic. > > Exactly. Some CPUs don't even have atomic increment operations. And > even if the CPU does, the compiler might see that it needs the value > later and prefer to have it in a register, so it might not use an > atomic in-memory increment even if it has one. You are saying even if there is some atomic operation available for some compiler+OS+CPU, this is not guaranteed to be portable, In other words, there is no portable atomic operation.
Back to comp.programming.threads | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Threads and statically allocated buffer ittium <ittium@gmail.com> - 2011-09-22 11:47 +0530
Re: Threads and statically allocated buffer David Schwartz <davids@webmaster.com> - 2011-09-22 14:34 -0700
Re: Threads and statically allocated buffer ittium <ittium@gmail.com> - 2011-09-24 10:08 +0530
Re: Threads and statically allocated buffer David Schwartz <davids@webmaster.com> - 2011-09-24 12:42 -0700
Re: Threads and statically allocated buffer ittium <ittium@gmail.com> - 2011-09-25 11:45 +0530
Re: Threads and statically allocated buffer David Schwartz <davids@webmaster.com> - 2011-09-25 04:15 -0700
Re: Threads and statically allocated buffer Marcel Müller <news.5.maazl@spamgourmet.com> - 2011-09-24 09:16 +0200
csiph-web