BookmarkSubscribeRSS Feed
somebody
Lapis Lazuli | Level 10

I have a DELL XPS 15 with 16gb of RAM and I would like to maximize the performance of SAS.

I have changed the MEMSIZE in the config file to 12 gb and SORTSIZE to 6GB. Would this be optimal? What other options should I change? How about REALMEMSIZE 

By the way, is there a way to change MEMSIZE by running some code? 

8 REPLIES 8
AhmedAl_Attar
Rhodochrosite | Level 12

As far as I know, Memsize allocation is a configuration/initialization option and not post-startup option.

Therefore I don't think you can run code to change the memsize value. But I could stand corrected if otherwise,

 

Ahmed

LinusH
Tourmaline | Level 20
I usually keep SORTSIZE closer to MEMSIZE, in you case perhaps 10GB. Nor sure why SAS have two seperate options?
Data never sleeps
ChrisNZ
Tourmaline | Level 20

@LinusH @somebody

MEMSIZE and SORTSIZE are totally different, and should not have the same value.

See the schema here.

AhmedAl_Attar
Rhodochrosite | Level 12

Here are 

- Paper related to Configuration and Tuning Guidelines for SAS ® 9  in Microsoft Windows Server 2008, that may give you some ideas

- SAS Tech Support Usage Note illustrating SAS® system option settings for best performance in UNIX and Windows environments

 

Ahmed

SASKiwi
PROC Star

Increasing your MEMSIZE and SORTSIZE settings to much higher values is unlikely to improve performance much. It will certainly improve performance if you have set them too small but in my experience SAS only uses the memory and sort size it requires for any particular job.

 

Tuning your SAS code is likely to have a much better payoff with regards to performance, the downside being the extra work required.

ChrisNZ
Tourmaline | Level 20

>Would this be optimal? What other options should I change?

You need to use options fullstimer and look at the log, to see where the bottlenecks in your process are.

Are your table sorts all internal sorts (in memory only)?

Is you CPU waiting for the disks to give it data?

Or is the CPU the bottleneck?

When you know where the bottleneck is, you start looking for solutions.

somebody
Lapis Lazuli | Level 10

it is not really a bottleneck as it still ran with the default setting. However it was quite slow compared to after increasing the MEMSIZE and SORTSIZE. My dataset is quite large (>50gb) and sometimes I need to run regressions with fixed effects and double clustering. My experience is increasing the MEMSIZE helps my code to run a bit faster

ChrisNZ
Tourmaline | Level 20

For regressions on that kind of volume, you could try having REALMEMSIZE close to the total amount of available RAM, maybe around 14 GB depending on what else is running.

 

Option MEMSIZE should be larger still, since it includes the paging space.

 

Note that option SUMSIZE only affects procedures MEANS, OLAP, REPORT, SUMMARY, SURVEYFREQ, SURVEYLOGISTIC, SURVEYMEANS, and TABULATE, so not regressions.

 

To see how much RAM is available for SAS to use at any point in time, you can run

%put Free RAM = %sysfunc(putn(%sysfunc(getoption(xmrlmem))/1024**2,comma10.))MB;

 

 

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 8 replies
  • 6656 views
  • 7 likes
  • 5 in conversation