[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

If you were to code an operating system from scratch in 2016,

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 81
Thread images: 4

If you were to code an operating system from scratch in 2016, would you still use C?
>>
I would use assembly
>>
>>57321719
what a cute negress
>>
>>57321719
I'd fuck her senseless.
>>
>>57321733
You mean like kolibri and menuetos?
>>
>>57321719
>If you were to code an operating system from scratch in 2016, would you still use C?
Most likely, at least until I could bootstrap a C++ runtime without having to do too much work myself.

http://wiki.osdev.org/Languages
>>
>>57321765
Yes. I didn't see any part about my new operating system having to be written in a language that hasn't been used before.
>>
>>57321796
I'm genuinely interested in trying one of these assembly OS's out. If only I had the time...
>>
>>57321992
They fit in a floppy and have a boot time of 2 seconds, you have no excuses.
I've tried Kolibri and it's been an interesting proof of concept.

>>57321733
This, even if it would be a nightmare to program and mantain, the language constraints and the lack of high-level features would make it a better choice for OS development.
>but muh C is as faster as ASM
Compiled and optimized C doesn't run as fast as pure unfiltered ASM because of some compiling quirks.
>>
>>57321719
i want her to sit on my face
>>
>>57322057
How functional was it?

Could I browse the web without issue? Did it have an office suite?

>>57322118

Me too brother, me too.
>>
>>57322129
not him but the floppy version is bare bones and doesn't offer much. also I had some issues with video modes on a pentium 233 and pci gpu.

the QNX demo disks were pretty badass at the time: http://toastytech.com/guis/qnxdemo.html
>>
>>57321757
Yep, she will procreate some beautiful light skin black babies.
>>
>>57322129
The environment worked alright, I never tested the lan connectivity but it should support it with no problems, it does have a web browser but right now I don't remember if there was a office suite installed.

Also Jezabel Vessir is such a qt niggerette.
>>
>>57321719
Did she mean physically or economical?
>>
>>57322179
>>57322336
Can I boot from a live usb or does it need installation?

Also, imagine an assembly OS for modern smartphones.
Shit would be so cash.
>>
>>57321719
What else are you supposed to use? Java? Python? Javascript? HTML5?
>>
>>57322409
>python
>operating system
Someone please do this.
>>
Java is clearly the only answer. Just look at Android and Minecraft.
>>
>>57322409
C++
>>
I'd use Lua for le fast scripting language meme
>>
>>57322499
C is still better. C++ can be used for certain software, but the kernel and base OS shouldn't be made in C++.
>>
>>57322409

Whitespace
>>
>>57322559
>the kernel and base OS shouldn't be made in C++.
Why?
>>
>>57321719
As someone who develops an actual OS, yes, I would. It gets out of the way to do many of the things that you have to do when developing an OS. C++, not so much, and I've worked extensively in both. You also can't avoid assembly for many of the things you have to do in a kernel.
>>
File: ifwb.jpg (107KB, 768x1024px) Image search: [Google]
ifwb.jpg
107KB, 768x1024px
>>57321719
>>
>>57322577
C and assembly are faster. If you want to make a BloatOS go ahead and use C++, C# or even Python if you'd like. Unless you're making something irrelevant, you should choose optimisation over convenience and ease of programming. This is the same reason python isn't used for anything serious.
>>
>>57321719
I would use PHP
>>
>>57321719
>>57321733
https://en.wikipedia.org/wiki/BareMetal
>>
I would write it in Ada & processor specific assembler
>>
I would probably use Rust, and it seems someone's already doing that.

https://www.redox-os.org
>>
node.js
>>
>>57322913
>This is the same reason python isn't used for anything serious.
You are severly mistaking
>>
Either C or Rust

>>57322421
https://launchpad.net/pycorn
>>
>>57322577
I'd like to disagree with >>57322559 - it's perfectly fine writing a kernel in C++. However one has to remember that there are severe drawbacks in doing so. For one you could only use a subset of C++ since parts of the language rely on the C++ standard library which wouldn't be available since we need to write the functions that it requires.
That's a common problem with writing an OS in higher-level languages - usually you need to sacrifice parts of the languages advantages in order to be able to write kernel-level code.
>>
>>57322409
http://wiki.osdev.org/Category:Bare_bones_tutorials

>Ada
>C#
>D
>FreeBasic
>Go
>Java
>Pascal
>Rust
>Swift
>>
I'd have to consider the reason I was writing a new OS from scratch.

I'd most probably use Rust, with appropriate sprinkles of assembly language for very hot loops, ABI, memory/IO management, hardware specific drivers, and crypto primitives.

I'd probably want formal methods too, something like the proof systems used to verify the seL4 microkernel and ARM implementation against the design. That would also necessitate reproducible builds.

If I was doing it, I'd do it on a fresh, formally-verified, RISC-V designed SoC. Rockwell Collins showed it's possible to do in the AAM7PG, no reason to pussy out on the engineering.
>>
>>57321719
>If you were to code an operating system from scratch in 2016, would you still use C?
No. There are better languages in every aspect.
>>
>>57323226
Python isn't used by serious programmers. It has terrible performance. Note that AAA games aren't seriously developed either, anything that requires hardware to hide terrible optimisation is just bad code.
>>
>>57321719
Maybe go. But I'll probably never recode an os
>>
>>57324414
''serious developer '' knows than sometimes no one fucking care about performance and care about time. Learn your job.
>>
>>57326018
We're talking about OS and system software here. A developer should always care about performance. Retards like you are the reason everything is bloated and sites are infested with unnecessary javascript. Learn English.
>>
>>57321719
I would use C++ just to trigger /g/'s autism.
>>
File: fbos.webm (135KB, 720x420px) Image search: [Google]
fbos.webm
135KB, 720x420px
>>57321719
yes
https://gist.github.com/anonymous/74c951c2a45ca498c05652c8debcdf18
>>
>>57321757
>>57321758
>>57322118
>>57322129
>>57322203
Can somebody post a link to it, I missed it :(
>>
>>57326219
>A developer should always care about performance
fuck off poorfag
>>
>>57328343
t. shitty developer who wouldn't have a job if meme languages and terrible companies didn't exist
>>
>>57322714
>>57328308
>>
>>57328438
t. NEET loser whose only achievement is writing fizzbuzz in brainfuck
>>
>>57328438
I'd say the consumer's are also to blame. People should look at efficient software the same way they do efficient vehicles.
>>
>>57328953
>>57328343

Is /g/ the only enthusiast board that prefers bad things over good things?
>>
>>57321719
Why did mods delete the image in the op?

It can't be because it's off topic, because so are these and they didn't get deleted.
>>57321358
>>57328771
>>57327128
>>57324506
>>57323176
>>57326817
>>57327956
>>57328638
>>57326899
>>57328310
>>57328152
>>57327622
>>57326644
>>57327557
>>57326445
>>57327167
>>57321998

So what's up with that?
>>
>>57321733
/thread
>>
>>57329146
Bump
>>
>>57324414
He wasn't talking about OS anymore. And ask your client if they pref a program ready to use in 2 months or an absolute performance program. This is the reality, and ofc have well done ligth software are better but isn't not the reality of the actual industry
>>
>>57329146
I wonder about this too
>>
>>57322714
As a white boi, I would
>>
>>57322409
>HTML5
That's a markup language. How would that even work?
>>
A true wizard would use brainfuck.
>>
>>57329146
Bumping for this.
>>
>>57321719
No.
C++
>>
>>57321772
You don't need a C++ runtime for kernel dev.
You shouldn't be using exceptions or RTTI in the first place anyway.
>>
>>57322559
And what bullshit standards are you pulling out of your ass to come to that conclusion?
>>
>>57322913
>you should choose optimisation over convenience and ease of programming.
What if you can have programming convenience with next to zero overhead?
There's no logical reason not to use C++, only bullshit personal reasons.
>>
>>57323642

like what
>>
I might. For the really interesting parts of an OS, it doesn't matter all that much what language you write it in. The design is much more important. I think it'd be cool to write an OS in scheme but I also think it'd be pretty practical to write one in Ada. I probably wouldn't make an OS though, unless I really wanted to experiment with something that I couldn't mess with in a *NIX
>>
>>57329146
Why?
>>
>>57321719
JESUS FUCK, WHAT ARE YOU THINKING? WHY WOULD YOU POST THAT, THAT'S THE GROSSEST THING I'VE EVER SEEN!
>>
I'd use assembly for more than most operating systems do and use C for the rest. Fortran for some stuff because I can.
>>
>>57322381
RISC OS?
>>
Sorry for my english guys.
Indeed you MUST use assembly since its the easiest way to develop a bootstraper and to connect with the hardware I/O.
About C, you dont HAVE to use C, i use C myself in my OS for some reasons:
1° it transpiles to ASM so i could just compile and copy paste a bunch of code and redactor it for performance sake
2° it lets you use embedded ASM code
3° its easy, powerfull and lets you do exactly what you want with no boilerplate code
4° every single piece of code u need must be written from scratch, so with C you can literally clone the glibc library.

You could use any languages you want, from Rust to Python or JS, but itll require some boilerplate, you have to set up the interpreter thats usually written in C or C++, and you will need tons of libraries and a POSIX compatible System from the begining.

About C++, you can easily build it in C++ since it compiles to ASM too, but theres literally no advantage on doing so, C++ is not a good languange for it IMO, also, a OS should be autocompilant, and if you wanna compile C++ shit youll need the whole C++ library, and you have to write it from scratch.

And yes, you could use transpilers to switch your toy-javascript to C and try to build a 100% Js OS, but itll perform poorly and wont be autocompilant either.
>>
Yeah but I'd use ASM for the kernel
>>
>>57334992
ASM is a pain in the ass, it works, its faster and is fun to write, but you have to manage everything, you would waste days only creating a decent printf
>>
>>57335016
>kernel
>printf
>>
>>57335026

While kernels do not have a concept of standard in/out/error, they do nonetheless have functions for printing crap, particularly to logs. In the Linux kernel, a printf-like function exists called printk for printing crap at the kernel log.
>>
I would use C.

Why do so is clear to me: If I write a new operating system, it would be to demonstrate a better OS design, not to demonstrate that new fancy language X/Y/Z can be used to make a OS. Trying to do both at once would be fucking stupid.
>>
>>57329146
Bump.
>>
>>57321719
probably java, maybe ruby
>>
>>57321719
I would use javascript.
>>
>>57321719
No, I would use C++. C is deprecated.
>>
File: 14c[1].jpg (7KB, 207x253px) Image search: [Google]
14c[1].jpg
7KB, 207x253px
>>57322913
>C and assembly are faster.

You can just write hot sections in C or inline ASM if this is a genuine concern of yours.
Thread posts: 81
Thread images: 4


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.