Author Topic: Server use max 25% CPU?  (Read 5784 times)

0 Members and 1 Guest are viewing this topic.

Offline soldat-game

  • Camper
  • ***
  • Posts: 407
Server use max 25% CPU?
« on: March 10, 2016, 01:55:36 pm »
Server use max 25% CPU?
Server uses a a maximum of 25% of CPU capacity? can not exceed this value or 26% Then there is a big lag server all have +900 ping. How im can change soldat server limits? Windows 10 4x3.4Ghz.

Offline Rev

  • Major(1)
  • Posts: 4
Re: Server use max 25% CPU?
« Reply #1 on: March 10, 2016, 03:17:42 pm »
If soldatserver is a single threaded application only one thread/core can be used.

Offline soldat-game

  • Camper
  • ***
  • Posts: 407
Re: Server use max 25% CPU?
« Reply #2 on: March 10, 2016, 03:48:45 pm »
WTF this not work?

Offline Savage

  • Soldier
  • **
  • Posts: 155
Re: Server use max 25% CPU?
« Reply #3 on: March 10, 2016, 04:30:30 pm »
If we are talking about CPU usage I would like to ask why that keeps looping?(It will spam random values up to 255 and overload processor)
Code: [Select]
var
i: Byte;

begin
for i := 0 downto 0 do
WriteLn(inttostr(i));
end.

Offline urraka

  • Soldat Developer
  • Flagrunner
  • ******
  • Posts: 703
Re: Server use max 25% CPU?
« Reply #4 on: March 10, 2016, 05:15:06 pm »
If we are talking about CPU usage I would like to ask why that keeps looping?(It will spam random values up to 255 and overload processor)

Byte is an unsigned integer in the 0..255 range. Decrementing "i" when its value is 0 will cause an underflow making it wrap to 255. I imagine that's what's happening there.
urraka

Offline Savage

  • Soldier
  • **
  • Posts: 155
Re: Server use max 25% CPU?
« Reply #5 on: March 10, 2016, 06:00:54 pm »
IKR, signed types like Integer works but 0 is in Byte range so I thought it's gonna work, at least will throw some error.

Offline soldat-game

  • Camper
  • ***
  • Posts: 407
Re: Server use max 25% CPU?
« Reply #6 on: March 10, 2016, 06:32:42 pm »
 see this  ;D looool where is this fucking file? Im see log foler and dont see 15gb file :O
« Last Edit: March 10, 2016, 06:34:51 pm by soldat-game »