Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Aborting compilation seems to be broken

<< < (3/6) > >>

thomas:

--- Quote from: tiwag on August 03, 2006, 04:11:46 am ---when you start for example a compilation of a wx pch erroneously with warning option "-W"
you get thousands of warnings and it lasts ages until it completes.
--- End quote ---
What if we stop adding any more stdout data to the log window after the user has hit "abort"? We will still have to read a few megabytes from the pipe (or else the process will hang after filling the 4k pipe buffer), but we will save significant CPU time not sending it through a regex and not writing it all to the log window and drawing the text that you don't want to read anyway on screen. This might indeed turn "ages" into "a second or two", and you could just wait for gcc to exit cleanly.


--- Quote from: Ceniza on August 03, 2006, 04:39:51 am ---Windows should take care of unlocking files and freeing memory if a process is killed
--- End quote ---
Should... but you never know what actually happens. Personally, I have never seen anything go wrong killing a process, but you really don't know what happens if you just take away a process' timeslice and unmap its pages.
I could think of quite a few scenarios like object files or precompiled headers being written to disk half-way, when the user presses "abort" for whatever reason. Even if most of these conditions can be fixed by doing a clean rebuild at worst, they should not be "normal operation" (and there may be worse consequences that you cannot foresee).

takeshimiya:

--- Quote from: tiwag on August 03, 2006, 04:42:46 am ---
--- Quote from: Ceniza on August 03, 2006, 04:39:51 am ---... but I wouldn't mind :P

--- End quote ---

me too :D

--- End quote ---
Neither do I :D

I guess most are just pressing CTRL-ALT-DEL to kill and completely destroy the process, commiting a violent assassination. :P
A "Nice SIGTERM" is not what it's in the mind at that moment. :)

But if anyone is completely opposed to SIGKILLING, it will have to be made an option then.

tiwag:

--- Quote from: thomas on August 03, 2006, 10:08:23 am ---... if we stop adding any more stdout data to the log window after the user has hit "abort"? ...

--- End quote ---

extension :

1st press of Abort button:  disable output logging

if the Abort button is pressed subsequently later on (let's say more than 2 times in one second) :  kill the process

takeshimiya:

--- Quote from: tiwag on August 03, 2006, 11:02:10 am ---
--- Quote from: thomas on August 03, 2006, 10:08:23 am ---... if we stop adding any more stdout data to the log window after the user has hit "abort"? ...

--- End quote ---

extension :

1st press of Abort button:  disable output logging

if the Abort button is pressed subsequently later on (let's say more than 2 times in one second) :  kill the process

--- End quote ---
A good solution if you know it beforehand, but a bit user-unfriendly/non-intuitive if you don't.
So new users would mean new posts about "Aborting compilation seems to be broken".

Look,
If anyone considers SIGKILLING in Windows something risky, I don't, because it's what I do by hand anyways.
So either an creating an option, or directly making it the default behaviour, will alivianate the Windows inability to SIGTERM.

thomas:
Tiwag, try if this makes it any better for you (for me it seems to work, although not as good as I expected).
One might cut the line even further upstream (before a million events are being sent), that might actually be better... will look if I get that done.

[attachment deleted by admin]

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version