[fpc-pascal] alternatives for "cwstring" and "cthreads"
pascaldragon at googlemail.com
Fri Dec 11 18:56:09 CET 2015
On 11.12.2015 17:31, Graeme Geldenhuys wrote:
> Many thanks Jonas for all that information. It is very useful to know.
> Maybe the documentation for cwstrings should include a link to
> fpwidestring unit and vice-verse. I didn't know about the fpwidestring unit.
> As for the thread manager being very OS-specific. Well FPC being a
> compiler that as very CPU and OS specific functionality well
> abstracted... such a thread manager should be just another abstraction
> layer. ;-) I'm not suggesting the FPC team implement it, just saying
> that on a high level it seems quite doable.
Our thread manager is already such an abstraction. It's just that for
Unix platforms only cthreads currently exists.
At least on Linux one could implement one using the clone() system call,
but that would need to be implemented for each platform and additional
features like mutexes, etc. would need to be implemented as well (it's
not as if I didn't have that idea already ;) ). The main reason it
doesn't exist yet is that no one implemented it... if one would we would
probably add it...
More information about the fpc-pascal