OSDev.org

The Place to Start for Operating System Developers
It is currently Thu Mar 28, 2024 2:49 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: Artificial Intelligence
PostPosted: Tue Apr 05, 2022 6:37 pm 
Offline
Member
Member

Joined: Sat Sep 07, 2019 5:17 pm
Posts: 34
Hi.

Out of curiosity, has anyone tried to implement AI on their operating systems? With AI I mean stuff that can "learn" (more of a neural network then?). On any context, be it autocompletion, "assisted edition", or even low level stuff such as device recognition.

Of course myself haven't done one - because realistically, it's almost impossible to make one from the ground up (at least from my perspective, which might be, probably skewed from reality), and also because I really see no use on it except for big corporations which needs to do stuff with machine learning.

But others may have done so?, If so, which are the primary examples of it? It would be interesting to see in what they differ against normal OSes, and if they exist at all.

_________________
:-)


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Wed Apr 06, 2022 6:56 am 
Offline
Member
Member
User avatar

Joined: Fri Sep 03, 2021 5:20 pm
Posts: 92
Maybe AI on the OS level could be used to optimize kernel algorithm parameters in order to adapt to their typical workloads, or to better diagnose and report problems, maybe even correct them...

_________________
Writing a bootloader in under 15 minutes: https://www.youtube.com/watch?v=0E0FKjvTA0M


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Wed Apr 06, 2022 2:34 pm 
Offline
Member
Member
User avatar

Joined: Mon Jan 15, 2018 2:27 pm
Posts: 201
Very, very simple form of AI exists in CPUs themselves, since quite some time. Branch predictors decide which execution path to follow based on previous 'experience'. Usually there are only few bits of information per branch instruction, but this is still a form of learning.

As for the kernel itself… cache optimization (whatever type of cache it may be) comes to mind.


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Wed Apr 06, 2022 6:04 pm 
Offline
Member
Member

Joined: Sat Sep 07, 2019 5:17 pm
Posts: 34
pvc wrote:
Very, very simple form of AI exists in CPUs themselves, since quite some time. Branch predictors decide which execution path to follow based on previous 'experience'. Usually there are only few bits of information per branch instruction, but this is still a form of learning.

As for the kernel itself… cache optimization (whatever type of cache it may be) comes to mind.


Of course, and also they directly exist on the ISA itself for CPUs like z/Arch! :)

_________________
:-)


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Fri Apr 08, 2022 12:28 am 
Offline
Member
Member

Joined: Sun Jun 23, 2019 5:36 pm
Posts: 618
Location: North Dakota, United States
Not really sure how you'd accomplish this. Most AIs (from what I know anyway) operate using SSE/AVX or GPUs, and training an aI is not exactly a fast process.


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Fri Apr 08, 2022 1:34 am 
Offline
Member
Member

Joined: Mon Feb 02, 2015 7:11 pm
Posts: 898
1) Branch prediction is not AI. AI has nothing to do with branch prediction.
2) Training a AI model can be expensive (which is why you use GPUs), but you wouldn't have your kernel train an AI model. You would have your kernel use a pre-trained model (which is called inference).
3) Optimizing how parameters are passed to the kernel during system calls is NOT a good / possible use of AI.
4) Optimizing a caching algorithm based on workload seems like a more reasonable use of AI. More generically, AI could potentially be used for resource management (scheduling, memory / cache / swap file management, etc). But the AI model would have to be trained off-line, not at run-time in the kernel. Coming up with a model that works on all combination of hardware seems a rather non-trivial amount of work.

_________________
https://github.com/kiznit/rainbow-os


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Mon Apr 11, 2022 7:26 pm 
Offline
Member
Member

Joined: Sat Sep 07, 2019 5:17 pm
Posts: 34
kzinti wrote:
1) Branch prediction is not AI. AI has nothing to do with branch prediction.
2) Training a AI model can be expensive (which is why you use GPUs), but you wouldn't have your kernel train an AI model. You would have your kernel use a pre-trained model (which is called inference).
3) Optimizing how parameters are passed to the kernel during system calls is NOT a good / possible use of AI.
4) Optimizing a caching algorithm based on workload seems like a more reasonable use of AI. More generically, AI could potentially be used for resource management (scheduling, memory / cache / swap file management, etc). But the AI model would have to be trained off-line, not at run-time in the kernel. Coming up with a model that works on all combination of hardware seems a rather non-trivial amount of work.


Inference? So kernels actually use pre-trained models? How, for what and who does it?

_________________
:-)


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Mon Apr 11, 2022 7:29 pm 
Offline
Member
Member

Joined: Sat Sep 07, 2019 5:17 pm
Posts: 34
Ethin wrote:
Not really sure how you'd accomplish this. Most AIs (from what I know anyway) operate using SSE/AVX or GPUs, and training an aI is not exactly a fast process.


?, In such case then are there some Linux Drivers which do change codepaths or do something funky with the AI that is nearer to the kernel than an userland application?

_________________
:-)


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Mon Apr 11, 2022 7:39 pm 
Offline
Member
Member

Joined: Sun Jun 23, 2019 5:36 pm
Posts: 618
Location: North Dakota, United States
To my knowledge the Linux kernel (or, really, any OS kernel known today) does not implement any form of artificial intelligence or machine learning. As I said, I'm not even sure how you would even do that. There's a reason most really good AIs need super high-end systems.


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Mon Apr 11, 2022 10:43 pm 
Offline
Member
Member

Joined: Mon Feb 02, 2015 7:11 pm
Posts: 898
wxwisiasdf wrote:
Inference? So kernels actually use pre-trained models? How, for what and who does it?

I never said anything like that.

_________________
https://github.com/kiznit/rainbow-os


Top
 Profile  
 
 Post subject: Re: Artificial Intelligence
PostPosted: Tue May 03, 2022 1:44 am 
Offline
Member
Member

Joined: Thu Sep 27, 2018 5:10 pm
Posts: 28
Location: Turkey
I was going through arxiv articles the other day and it seems there is some research effort to use machine learning on some OS topics.

This article suggests using machine learning to scan system logs to find abnormalities.

This one uses machine learning to tune SSD settings based on usage patterns.

There was also one article talking about using machine learning to optimize the scheduler but for some reason I can't find it again.

Edit: Found a similiar article here


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

All times are UTC - 6 hours


Who is online

Users browsing this forum: Bing [Bot], SemrushBot [Bot] and 50 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
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group