It is currently Wed Jun 19, 2013 1:35 am

All times are UTC + 1 hour




Post new topic Reply to topic  [ 9 posts ] 
Author Message
 Post subject: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 6:23 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat Apr 26, 2003 2:15 pm
Posts: 354
Location: Vancouver Island, Canada
Noticed a real slowdown in both my laptop and home computer. (Win7 Pro)

Found out that where PureBasic creates PureBasic_Compilation0.exe is the problem.
(Looks like MSE spends some time scanning the file)

----------------------------------------------------------------------------------------------------
Since Microsoft Security Essentials is very popular perhaps this should be a sticky, or
when PureBasic compiles our code it could see that MSE is running and suggest to:

Go to:
- 'Excluded Files and Locations' on the Settings Folder of MSE
- Add: C:\Users\Bob\AppData\Local\Temp <<< where ever 'PureBasic_Compilation0.exe' is created

This worked well for me.

--Bob

_________________
- It was too lonely at the top.


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 6:58 pm 
Offline
Addict
Addict
User avatar

Joined: Sat Apr 26, 2003 8:26 am
Posts: 1291
I wouldn't recommend excluding the whole TEMP folder.

Better use the compiler option "Create temporary executable in the source directory"
for you sources. You can set this option as default in the IDE options.
With this option enabled, start of your compiled program is very fast again.

For excluding PureBasic itself from Microsoft Security Essentials scan (so compilation is faster),
see PB compilation problems with MSE.


Last edited by Danilo on Wed May 02, 2012 8:37 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 8:36 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat Apr 26, 2003 2:15 pm
Posts: 354
Location: Vancouver Island, Canada
Danilo wrote:
I wouldn't recommend excluding the whole TEMP folder.


Yes... I've been giving this some thought.

Can the PureBasic compiler be made to create a temporary EXE in another folder than the default Windows temp folder?


Thanks,
--Bob

_________________
- It was too lonely at the top.


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 8:37 pm 
Offline
Addict
Addict
User avatar

Joined: Sat Apr 26, 2003 8:26 am
Posts: 1291
See above: compiler option "Create temporary executable in the source directory" ;)


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 8:57 pm 
Offline
Addict
Addict

Joined: Fri Oct 23, 2009 2:33 am
Posts: 2919
Location: Wales, UK
Unfortunately "Create temporary executable in the source directory" does not help, because MSE does intercept 'PureBasic_Compilation0.exe'.

Perhaps a solution is to use a home made folder specifically for 'PureBasic_Compilation0.exe'?

Edit: I should mention that MSE has started slowing down PB compiling significantly in the last few weeks or so - before that, probably had an effect but only 1 or 2 seconds. So, seems that MSE is working harder! Added PureBasic.exe to the Exclude Process list and that has speeded-up things considerably, back to the 1 or 2 seconds mark (for around 10,000 code lines). That's fine for me.

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Last edited by IdeasVacuum on Wed May 02, 2012 9:13 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 9:07 pm 
Offline
Addict
Addict
User avatar

Joined: Sat Apr 26, 2003 8:26 am
Posts: 1291
IdeasVacuum wrote:
Unfortunately "Create temporary executable in the source directory" does not help, because MSE does intercept 'PureBasic_Compilation0.exe'.

Works perfectly here. Of course only for saved sourced, because unsaved sources are still created in TEMP.

You can exclude 'TEMP\PureBasic_Compilation0.exe' if you want, but we already said that in the other topic.

It is a slightly higher risk because an attacker could name his virus "TEMP\PureBasic_Compilation0.exe". :D


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 9:15 pm 
Offline
Addict
Addict

Joined: Fri Oct 23, 2009 2:33 am
Posts: 2919
Location: Wales, UK
Quote:
an attacker could name his virus "TEMP\PureBasic_Compilation0.exe


...would not surprise me :lol:

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 9:20 pm 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Sat Apr 26, 2003 2:15 pm
Posts: 354
Location: Vancouver Island, Canada
It'd be nicer if we could have 'our' own folder as I noticed that I had:
TEMP\PureBasic_Compilation0.exe
TEMP\PureBasic_Compilation1.exe
TEMP\PureBasic_Compilation2.exe
TEMP\PureBasic_Compilation3.exe
TEMP\PureBasic_Compilation4.exe
TEMP\PureBasic_Compilation5.exe
in my temp folder.

Apparently PureBasic fires off a new EXE for every file in my IDE.

They do clear where I leave the IDE.

--Bob

_________________
- It was too lonely at the top.


Top
 Profile  
 
 Post subject: Re: Microsoft Security Essentials Issue
PostPosted: Wed May 02, 2012 9:35 pm 
Offline
Addict
Addict
User avatar

Joined: Sat Apr 26, 2003 8:26 am
Posts: 1291
Danilo wrote:
Maybe using
Code:
GetEnvironmentVariable("APPDATA")+"\PureBasic\TEMP\"

would be a better place instead general TEMP directory.

No, it's not. Just tested it, it is as slow as TEMP. It takes round about 4-5 seconds now
when started from within the IDE, same as TEMP!

I have my source code folder on d:\ and everything is fine and very fast
with compiler option "Create temporary executable in the source directory".

The same compiler option used for files in TEMP or GetEnvironmentVariable("APPDATA")+"\PureBasic\TEMP\"
is very slow. Using the system drive for compilation seems to be the issue!?

This code starts immediately:
Code:
Debug GetEnvironmentVariable("APPDATA")+"\PureBasic\TEMP\"


This code starts very slowly (4 to 5 seconds here):
Code:
If OpenWindow(0, 0, 0, 800, 600, "PicHide", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
    Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
EndIf


The last code saved to d:\ and enabled compiler option "Create temporary executable in the source directory"
starts immediately (0 seconds). :)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 9 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye