Announcement

Collapse
No announcement yet.

Let me guess: BtS is not multithreaded, right?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Let me guess: BtS is not multithreaded, right?

    You know, with a game that sucks down CPU cycles like this one, it seems a crying shame that it can't take advantage of multi-core processors.
    "It's great to be known, but it's even better to be known as strange." --Takeshi Kaga

  • #2
    Multithreaded AI is hard.

    Comment


    • #3
      Then put the AI all in one thread.
      "It's great to be known, but it's even better to be known as strange." --Takeshi Kaga

      Comment


      • #4
        It happens that CIV benefits significantly from dual core CPU's, despite not being designed to. Possibly some of the core engine is multithreaded or something.

        I can say that when I upgraded from a AMD 64 3800+ (2.4ghz) to an AMD X2 5600+ (2.8ghz, dual core), the in between turn times were cut to about 1/5, which was a far more significant increase than would be expected for a strictly single-threaded application (I also got faster ram so it's not a fair test but some of that huge performance gain simply must be attributed to the second core).

        Comment


        • #5
          Whatever, the game runs fine on my piss of the line laptop from 2 years ago.

          Comment


          • #6
            Originally posted by Blake
            It happens that CIV benefits significantly from dual core CPU's, despite not being designed to. Possibly some of the core engine is multithreaded or something.

            I can say that when I upgraded from a AMD 64 3800+ (2.4ghz) to an AMD X2 5600+ (2.8ghz, dual core), the in between turn times were cut to about 1/5, which was a far more significant increase than would be expected for a strictly single-threaded application (I also got faster ram so it's not a fair test but some of that huge performance gain simply must be attributed to the second core).
            Upgrading from a dual core to a faster dual core CPU is probably not a good example for what you are trying to demonstrate, but yeah, I know what you're saying. I made a jump from a single core AMD chip to a dual core AMD chip. Both had very similar technology and the dual core had only a slightly higher clock, and I was pleasantly surprised at the result.

            Yes, the game runs fine for me 99% of the time, but there are circumstances (particularly late game on huge maps) when it does slow down a bit.
            "It's great to be known, but it's even better to be known as strange." --Takeshi Kaga

            Comment


            • #7
              The AMD 64 is not a dual core cpu.

              Comment


              • #8
                Ah, gotcha. I misread that.

                Still, it's a huge difference in technology, so one core of your new CPU is significantly faster than the CPU you had. For me it was a slight bump in clock speed, but otherwise the major difference was the addition of another core.

                Eh, sorry for getting sidetracked.

                While I did notice a greater performance improvement than expected, I believe the game is not multi-threaded. That point has been mentioned to me plenty of times here and at the other major Civilization fan site, so this information must come from the developers (interview, maybe?). I think the performance bump I noticed was from all the other processes getting moved to the other core, leaving Civ4 with a core to itself.
                "It's great to be known, but it's even better to be known as strange." --Takeshi Kaga

                Comment


                • #9
                  Originally posted by Underseer
                  Then put the AI all in one thread.
                  The AI is most of the computation.

                  Comment


                  • #10
                    Really, consider how the engine works. There are the graphics, which are mostly determined by the graphics card. The rest of the game is played as a sequence of actions. In SP at least, you simply cannot do two things at once. And the rest of it - the turn time - is AI.
                    Last edited by Kuciwalker; July 14, 2007, 01:39.

                    Comment


                    • #11
                      Galciv is multithreaded, mostly for the ai, so Civ IV could be too. Except if the core game was not, I can't see how or why they'd rewrite everything to be multithreaded for an xp. Too much work for almost no gain for most players.
                      And there's always a graphics thread and a game thread, and not everything graphic's running on the graphics card.
                      Clash of Civilization team member
                      (a civ-like game whose goal is low micromanagement and good AI)
                      web site http://clash.apolyton.net/frame/index.shtml and forum here on apolyton)

                      Comment


                      • #12
                        Originally posted by Blake
                        The AMD 64 is not a dual core cpu.
                        I got a AMD Atholon 64 X2 which is dual core.

                        But on topic, I noticed a MASSIVE increase in performance going from P4-2.4 to the above CPU.

                        Comment


                        • #13
                          I believe that in CIV the graphics actually run in a separate thread(s) to the game/AI code. The graphics continues to be updated during the AI turns...

                          Comment


                          • #14
                            Originally posted by LDiCesare
                            Galciv is multithreaded, mostly for the ai, so Civ IV could be too.


                            Galciv did some kind of wizardry where the AI ran in a separate thread during the player turn. I assume it just helped the AI compute an approximation of what it would (since it obviously couldn't respond to actions the human hadn't made yet). The AI itself wasn't multithreaded.

                            Comment


                            • #15
                              Well there are things an AI can do while waiting. For example a better but more expensive algorithm to choose where to found cities or planing what workers will do. It is rare, that a player can change the game so dramatically in one turn that that information would become too much outdated to be useful to the AI. It is however a potential exploit as the AI basically is a turn behind the player when it comes to certain stuff.

                              Comment

                              Working...
                              X