GAMS CPU time

Problems with syntax of GAMS
Post Reply
Luca
User
User
Posts: 23
Joined: 1 year ago

GAMS CPU time

Post by Luca » 6 months ago

Dear all,

I know in gams the elapsed time can be retrive by the couple of instructions:

scalar starttime; starttime = jnow;
....
scalar elapsed; elapsed = (jnow - starttime)*24*3600; display elapsed;

but how can i retrive the cpu time spent in gams by my code?

Thanks in advance,
Luca

User avatar
Renger
Posts: 353
Joined: 2 years ago

Re: GAMS CPU time

Post by Renger » 6 months ago

Hi Luca

There is an option "profile" to have a closer look at the time used by Gams. You can find more information Profile option and here McCarl.

Hope this helps
Cheers
Renger
____________________________________
Enjoy modeling even more: The lazy economist

User avatar
bussieck
Moderator
Moderator
Posts: 337
Joined: 2 years ago

Re: GAMS CPU time

Post by bussieck » 6 months ago

Luca,

CPU time make little sense in today's multi-threading world, so reporting CPU time has gone out of fashion.

-Michael

Luca
User
User
Posts: 23
Joined: 1 year ago

Re: GAMS CPU time

Post by Luca » 6 months ago

usually I test code with single thread and I report this CPU time.
otherwise what you suggest to do ?

Thanks,
Luca

User avatar
bussieck
Moderator
Moderator
Posts: 337
Joined: 2 years ago

Re: GAMS CPU time

Post by bussieck » 6 months ago

Take an empty/idle machine and give it all the juice/cores it got (I would not do hyperthreading) and report wall time.

-Michael

Post Reply