Thread: Atomic Operations

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #13
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Thanks, mats. I'm going to try this.
    The problem with the interlocked functions was that I couldn't find one that allowed me to simple read the value as an atomic operation.

    Quote Originally Posted by Codeplug View Post
    I would question the need for another GUI thread - but if it's to late to undo now...
    I question this one, since I don't want to do a message loop inside the event handler.
    And another problem right now is that there are GUI calls inside thread B, so it's critical that the message loop is running at all times.
    And running a message loop inside the event handler is an old way of doing things IMO. It can be error prone.
    But one way might be a MFC thread that does a message pump. But again, I want to avoid complications and rewrite the threading code.
    Last edited by Elysia; 03-26-2008 at 07:33 AM.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Atomic operations
    By MarkZWEERS in forum C++ Programming
    Replies: 3
    Last Post: 02-07-2009, 05:21 PM
  2. Atomic integers & memcpy()
    By rasta_freak in forum C Programming
    Replies: 11
    Last Post: 08-05-2008, 12:08 PM
  3. doing floating operations using integer operations
    By ammalik in forum C Programming
    Replies: 10
    Last Post: 08-15-2006, 04:30 AM
  4. Matrix and vector operations on computers
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 11
    Last Post: 05-11-2004, 06:36 AM