#uACPI - a portable and easy-to-integrate ACPI implementation
1 messages · Page 40 of 1
Ironclad is a free software formally verified kernel written in SPARK/Ada
ah sick
pmOS without UC stuff is faster on 5900X than on 13700 for some reason
probably the same locking stuff that proxima suffers from
also #1006539285039697981
for ironclad talk
it also has a discord and a matrix but it has a very criminally underutilised channel here
let's not clobber this one
Why does this have to happen, I have ACPI
seems to me like the first error cascaded into the other ones
@fiery turtle do you happen to know where VDID actually is? I was checking it at offset 2 in the PCI config space, but it doesnt seem like enough
@lofty dragon if you're still available to test, i moved around some ordering stuff and suddenly the performance jumped from 7M to 8.5M so i figured it's worth testing on intel as well
that's a lot of improvement for simply moving save_disable_irq from before enable_preempt to after
sometimes i do not understand why the things i do improve performance
lmao
this was supposed to just be cleanup
the arcane art of optimisation
What are you doing exactly
Vdid is just the vendor id field
Why do u even care btw
Just return Fs if you believe this device doesn't exist
Or trust the firmware and do what it tells you to do
What was you workaround attempt
dealing with firmware is disgusting
Wdym
offset 2 is the device id
I am reading the PCI config space
offset 0 is vendor id
checking for FFFFFFFF in the stuff
Like in device open?
yeah, in the search function
And what do u do if its FFs
I return the mockup
That should work
when does the mockup return Fs?
turns out its 0x100
Uhhh no
what do you mean no
no its 0
the vendor id is at offset 0
the vendor id offset is always 0
Vendor ID is the first field
0x100 would imply youre accessing the wrong device i think
BTW you dont have to care about which field, reading from any field of a non existent device will return Fs
for port io access that is
depends on whether you're using ecam or legacy io access
beat you by one message but yeah - its 0x100 for legacy and 0x1000 for ecam
also before i forget, @fiery turtle INFO (uacpi): successfully loaded 1 AML blob, 1708 ops in 1ms (avg 1504436/s) new number for imaginarium when i turn uncacheable to false like its supposed to have been lol
mightve already sent, im very forgetful today
but may as well get it in text since if i did before it was a screengrab
Btw why is it supposed to be off
Oh nvm
Uncacheable false means cacheable
its a double negative which i think is what confused me into making the mistake in the first place lol
Yeah ikr
500x speedup way bigger than i was expecting tho
Wait I thought it was a legal iso from ci
apparently not
CI is currently building a legal iso which i will test once it is done (usually takes ~20m)
bruh
Yeah thats surprising indeed
you wanted to do it 
My uacpi_kernel_get_nanoseconds_from_boot impl was calculating the current timestamp wrong, that does explain the >100M ops/s with KVM on lol
indeed
It's at around ~1.5M with KVM on now, but my notebook is pretty weak (mobile 8th gen i7), I'll also test it at home later (ryzen 7700X)
thats not bad
@fiery turtle updated score with legal iso (test cpu Intel 13900KS)
hydrogen 225fc7ff228b70959b9b8a2a5a8cb2a7c0bcc9df (built by https://github.com/proxima-os/proxima/actions/runs/13269265857)
uacpi: info: successfully loaded 1 AML blob, 1705 ops in 0ms (avg 8468599/s)
back to the old score ig?
slightly better and more consistent but yeah
@lofty dragon ^ if you want to test on intel - i made a few final changes which should dramatically reduce the number of lock acquisitions
still lower than i'd like considering many kernels are much faster on your cpu than mine but it's definitely a great improvement
oh is it?
of course
sorry my qemu lost the ability to run with smm off
I cannot run your OS anymore
unlucky
this one doesn't break with smm
it's 8.4
yes
also do you have an exact number so i can put it in the lb submission
no @strong heath please send a screenshot
Ill also post my thing here in case someone else wants to test 
thank you!
7.2M
command line?
the one i used was qemu-system-x86_64 -accel kvm -cpu host,migratable=off -M q35,smm=off -cdrom image.iso
6.5
you can extrapolate how fast it would be on streaks's CPU based on mine
without bothering him
and it will very very very likely be extremely accurate
around the same as what I get then
assuming linear, 7.7M on 13900KS
actually the type of scaling doesn't apply here since it's only 2 datapoints anyway
now i am double curious to double check the result but for getting the last one out of him i was literally screamt at so loud that my ears hurt so
so just "assuming the bottlenecks are the same as for proxima"
idk why does the score vary so much tho, like if mint got 6.5 and I think I have also seen that myself (but with an even lower score like 5M or whatever)
please change your font
and sometimes I get something stupid like 10M lol
idk who hurt you to do this but get a psychiatrist
its a font that staticsaga sent at some point lol (iirc at least)
the font isn't that bad imo the main issue is the double newlines
thanks for testing it tho
that's an issue with the uacpi glue, I do a println in there not realizing that uacpi adds newlines itself lol
WB is sufficient on x86 because of MTRR
oh cool
no... cursed because IMO caching should be explicit
but there's no easy way to get the correct caching mode to apply to a memory range on x86, besides maybe getting attributes from the EFI memmap
RIP
(that I'm aware of; I'd be delighted to be wrong)
double cursed
yeah
you can get most of the way there by just determining whether the given address is in a usable or acpi reclaimable memory region
obviously prefer the attributes from EFI mmap if available but it's a decent fallback
or on x86 scan the mtrrs but at that point just map as wb
the last thing you said is unironically brain damage sorry lol
if anyone does that they are just doing things to look smart
usable?
i don't think it should ever map anything from a usable entry though
are you sure you didn't mean reserved/non-present-in-memmap?
where you map that as UC and you map the ACPI reclaimable as WB?
yeah exactly
I meant wb when usable or reclaimable, UC otherwise - of course, acpi should never touch usable memory, but wb is the correct memory type for it and you never know what crazy firmware dev hacks you might have to accommodate
if AML tries to access anything within usable, kill it.
i don't think it should ever ever ever touch usable entries
that's insanity
like literally kill it
ye
idk I wouldn't be surprised if there's systems out there that try to detect the os by some magic signature that it happens to put in a fixed location in physical ram
like maybe you can be lenient and allow it access into <1M usable regions that the kernel otherwise doesn't use
lol probably
i mean linux allows aml to map itself
it's awful and please kill it but it's out there probably
as RO
if this, get better firmware
side note but I don't understand why so many people blindly ignore all memory below 1M, if not doing so causes problems it's a bootloader bug
too much work for little gain
I don't think I ignore low memory atm.
I currently only reserve like the zeropage
as in
page zero
ok so map ACPI NVS/reclaim as WB, usable as WB/RO (forced), any other region as UC
I don't even do that
i think this is reasonable
if the bootloader tells me a page is usable I will use it
or just map everything as wb and let it be handled by the mttr's
yeah that sounds reasonable
maybe read the MTRRs and print a warning if it doesn't match what you expect
no
that's just fancy shmancy bs
too fancy for me, waste of time (do it if you want idc lol)
it doesn't do anything except maybe indicate firmware bugs (wrong setup of mtrrs)
yeah in which case it's not like you can do much anyways
but even that is dubious since memory map based detection will almost certainly falsely mark some regions with a more restrictive cache mode than necessary
at least you can scream at the firmware devs
btw RE: why some people ignore memory below 1M: i guess because GRUB and not trusting the BIOS/more primitive bootloaders
any proper sane bootloader with a spec like e.g. Limine's will guarantee things that don't take into account below or above 1M
so you shouldn't really care either
makes sense
i mean i assume it's the same for Hyper and Ultra
it is
it allocates backwards from max phys anyway so i doubt u would see anything below 1m allocated
but its marked as loader reclaim
Limine allocates itself below 1M on BIOS + the SMP trampolines
@fiery turtle 
infy you're such a relocatable ELF file
i have tons of stuff scheduled for the leaderboad now
btw ironclad should be added too now or?
id hate myself if i was one
not yet
5M not enough? 
streaks isn't happy with it yet, and i don't think he has committed most of the changes in a final form yet
ah sure
gib list
yeah there were two recent replies
Oh yeah? Haven't looked there in months lol
Thanks for replying btw
obligatory mlibc shilling included
I have fixed all timing innacuracies in Ironclad
and the score stabilized at 5 million
it does get very slow on real hardware though, because the allocator behaves much better in small bursts
what was causing them
from 5 million to 1
TSC innacuracies and bad calibration code
TSC is a mess for wallclock, I just moved it to default to HPET for those usecases
ill publish it later today along with conditions
wait your uacpi is slower on real hardware??
I mean it depends on the aml it runs
Yes but different ops probably
thing is, as I said, Ironclad's slowest link is the allocator
and its because its bursty with the latest changes ive done
so smaller AMLs -> less allocations
less allocations -> shorter loads
real machine AML is much much bigger, thus it gets slower
Damn ironclad got 5 mil
I should ask infy to remove astral this is EMBARASSING my score is so low I gotta lock in 😭
Is it bursty to be real time?
generic unix clone gets generic score /j
it is bursty because of how the algo works, it doesnt have to do with real time
Oh
Have you written anything about the funny seal os anywhere Im curious about what you do
I do talks about the OS regularly in big events
if you are curious about the internals its a good starting point
Ironclad is a free software formally verified kernel written in SPARK/Ada
Epic Ill look into it at some point
Right now I am in "alarm set to 2 hours from now" territory which means I should probably sleep
good night mate
You really cant compare the runtime of two completely different aml programs lol
Like it can literally call sleep() and your score will go down
lmao
I'll probably add this comment in pci_device_open
might be a bit too verbose but
at least it explains well why it's needed
i forget, is uacpi-rs a thing yet
i dont believe so
i think there was an attempt by @\shinribo or smth
idr the username
it's definitely a thing, just not completely finished yet
it's linked in pins
thx
im working on it
it will not print the stats if timer returns bad values?
yup
static int invocation = 1;
return invocation++;

1705 ops in 0ms (avg 1705000000000/s) letsgo
this post was fact checked by real osdevers: 
Vinix will be #1 just you wait :^)
I'm sorry, I cannot let you do that 
@fiery turtle
depends on your current rev
Like 2-3 months old
what do u want to change?
Mostly just fix the unreadable code and actually make good designs
Yeah
It would take so long to get back to where I am which sucks but eh
Especially now that I dont have as much free time as a a year ago
yeah
I would probably snatch some more recent stuff over like the new locking code
yeah you could probably copy over a lot of things
just rewrite what actually matters
Yeah Ill think about it more and see if its something I really wannaa do
Is there any aarch64 board with full acpi? And not just hardware reduced acpi?
Also can you configure qemu with full acpi?
When running on hardware reduced do I need to choose it at compile time, or would uacpi compiled without the ifdef still work?
you need the compiler define iirc
@slim panther was pumped about getting some aarch64 board with UEFI today, I don't recall whether it had ACPI tho
orion o6 has ACPI afaict?
not sure whether it's hw reduced or not
I think it might be nice to have runtime support for both hw reduced and full acpi if it's not too much. I think the fadt has a detection bit for it no?
I'm pretty sure the define is for when you want a uacpi version that's only capable of handling reduced hw, and the full version can still handle reduced hw machines
I see, nice
it does
it came today
ill hop on vc tonight
based
70,34€ taxes
bruh
btw did you get a serial adaptor for framework laptop?
It would autodetect it of course
the define is there to compile out non-hw-reduced stuff i assume
so if you know you will only run on reduced acpi hardware you can use that?
Yeah just so you can strip some code on aarch64 etc
Yeah
what does that even mean
No events and stuff like that
Yup
but u still get power states and shit
Nothing stops them from shipping a full acpi implementation I think tho
u can suspend, sleep and all
There just hasn't been one yet Iirc
Yeah
nice i see, thanks
Np
All I asked for is an acpi timer for calibrating the systick 😔
On arm, you can usually just get the timer frequency from the dt
Doesn't acpi have an alternative mechanism for that?
you can even get it from a system register
Ah i see
cntfrq_el0
same on risc-v
timebase-freq
does acpi have a mechanism for that in risc-v? afaik there's no other way to get that
Just implemented "support" for the cursed Unload opcode, which has been deprecated and removed quite a long time ago, but now at least it won't be treated as invalid, and will instead be a no-op
stop being a COWARD and unload the table smh
this is what ACPICA does
and then proceeds to actually unload the objects
so if you have a reference to some node you will just UAF it
Unload( GDT )
Unloading GDT... SUCCESS
I remember someone saying that the Surfaces have a lot of weird AML, do you know of other examples off the top of your head?
yeah, it uses some esoteric operation region types
LMFAO what
at least it logged a warning right

thats why my PR hasnt been reviewed in a month i guess
Lmao
lol my friend has a laptop where linux fails to shut down due to acpi shenanigans
seems to be stuck in an infinite loop with a Stall(118) in the middle since acpica complains about the stall time exceeding the maximum
Unironically I think my 2024-ish desktop (a damn good computer) has ACPI problems. Last time I tried, reboot didn't work. It just kinda gets stuck somewhere. Shutdown works fine though.
Note that this was on Linux/ACPICA and not a hobby kernel/uACPI or whatever. I'm unsure if NT reboot works.
Bruh
Actually no, it doesn't. When doing Windows updates and it wants to reboot the computer, it turns off video output and just kinda sits there, spinning and not turning off. However with a short press of the power button, it powers off.
Would be nice to test e.g. Managarm on it
you can try pmOS 
though it has a major timers/scheduling issue atm, so it might be broken on its own so potentially not representative
not gonna bother him with this now
but i just found it funny that you can apparently fuck up shutdown
it shouldn't surprise me since it's arbitrary aml and yet it did
What's the status of uAPI?
Yeah on my system76 system linux entered an inf loop when trying to suspend to ram
an infy loop???
Red circle red arrow surprised face exclamation mark exclamation mark
I should do that some day
assertpilled
always has been
if you disable asserts it wont work
that sounds bad
because I do som,e things like assert(shitpiss_init() == 0)
now that I remember, I do stuff like that too
I like how u even made sure the code style is correct
#if OBOS_DEBUG
# define OBOS_ASSERT(expression) do { if (!(expression)) { OBOS_Panic(OBOS_PANIC_ASSERTION_FAILED, "Assertion failed in function %s. File: %s, line %d. %s\n", __func__, __FILE__, __LINE__, #expression); } } while(0)
#else
# define OBOS_ASSERT(expression) do { (void)(expression); } while(0)
#endif```
but I worked around it like this 
soon all of astral will be snake case
wait infy
what do you think of the style I've bee going for
like here
for(all;of;eternity)
Looks generic enough
I supposethatsbetterthanbefore
yeah
uacpi info: successfully loaded 1 AML blob, 1705 ops in 0ms (avg 4013691/s) i'll throw in this updated submission for keyronex
inlined spl routines got that
very cool
Can I submit this? 
if it is u can submit it sure why not
it was a stroke of genius for you to add this statistic to uacpi
now as well as an allocator test uacpi is an osdev benchmark
I like how the uACPI benchmark has become a de-facto standard
it pointed out an issue with my code too but I was too dumb to realise that it was an issue worth investigating until I accidentally fixed it later lmao
I think it's unironically a decent performance wellness check for a kernel
yeah
I don't care about where I am on the leaderboard but I sure do like having the number as a quick general wellness check
Is calibrated frequency 104978500 vs -cpu tsc-frequency=100000000 acceptable?
This gives this result
could you fix your calibration? idk if thats too big of a skew
It's consistently above 5 million though
its like 5% faster?
I can hardcode it...
thats fine for the sake of the submission accuracy
^
I think you should rework your TSC calibration code in that case.
that's like 5% off
I'm planning to eventually replace my timers subsystem
So I'm not in a mood of changing it now
sure
out of curiosity, do you calibrate against PIT or against HPET (or against something else)?
how are yall so fast 😭
what likely(x) does to a mf
With hardcoded 1:1 tsc to ns
letsgo, same cpu as last submission?
ye
I tried adding that around but saw no improvement whatsover
weird
can u paste the score as a number
I calibrate against HPET with a fast calibration loop of like 50ms and I consistently get measurements within like 0.1% of my CPU's clock speed
i got a 200k ish boost from putting that all over my allocators
feels like off-by-one on the amount of zeroes somewhere
or is 53M a new record?
✨ blazingly fast ✨
ah u fucked it up lol
although with wsl2 it's it's fluctuating a lot
we optimize the shit out of uacpi_kernel APIs instead of actually doing useful work
idk if that's acceptable
@slim panther can you try this out #1061407633745125397 message
my laptop is shit and wsl doesnt help
If you can get this consistently
blame it on the host
better than wsl who decides that sometimes it'll give me 1.7mil and sometimes 800k 
I'm using WSL
Thats fine
wtf
do you have a Ryzen whateverX3D CPU or similar?
damn its even worse now
i510300h
I don't have x3d
is that CPU asymmetric in some way? (efficient vs perf cores, or different cache)
I dont think so
I was a bit surprised to learn that on some X3D CPUs, half the cores (those with more cache) run at a lower clock speed
and so what CPU QEMU gets scheduled to affects the benchmark
It's not just 3D cpus
With AMD and chiplets, if you have Ryzen 9, half of the cores are just slower
could anyone with an amd cpu test this image please https://discordapp.com/channels/440442961147199490/1287456798407790684/1340475807566401548
ovmf required
qemu-system-x86_64 -smp 1 -drive format=raw,file=menix.img,if=none,id=disk -device nvme,serial=deadbeef,drive=disk -cpu host -accel kvm -machine q35,smm=off -bios <ovmf>
ovmf
iirc I do -drive if=pflash,index=0,file=/usr/share/edk2-x64/OVMF.4m.fd,readonly (or something similar)
@fiery turtle
that's better ye
(On Ryzen 9 5900X)
lmfao
i tried running uacpi on my pc with the broken aml for the first time
it's apparently still parsing the blobs
after like 2 minutes
doesn't timeout either
of curiosity, how can you know what PCI segment(s) exist with any certainty before the blobs are parsed and namespaces initialized?
i dont
ah ok, just assuming always 0 then?
yes
does this really matter though
in practice usually not
segment 0 bus 0 being the root is standard but its a do you trust firmware devs thing tbh
it still not finished? if so dang
i could make it print to console every 5 or so seconds to see if its still alive
impressively whack aml there
i know the aml is borked because acpica has a stroke on boot
does uacpi print parser errors?
@fiery turtle id like to report the first score obtained from an actually comitted Ironclad kernel for leaderboard consideration, booted with qemu-system-x86_64 -M q35,smm=off -smp 1 -m 4G -drive format=raw,file=gloire.iso -serial stdio -enable-kvm -cpu host
I hope to soon bump it to top 3, but being faster than managarm is good enough for me
the seal grows
Yeah
I think your kernel just hung
Can you try running e.g. pmos or something on it
Also post the dump I guess
Very cool
Btw what should I put for the description
formally verified, hard real-time capable kernel written in SPARK and Ada.
im thinking of adding a uacpi version printout as the first thing it logs
thoughts on this?
so it's easy to see which version a person is using by their logs
I'm also making registers.h public API as apparently there are cases when a kernel needs to be able to write arbitrary FADT regs
since haiku uses that for some cpu idling stuff
I'm also going to add something like uacpi_namespace_node_get_next for people that dont want to use for_each_node (like haiku)
yaaaay iterator api
which CPU was this on?
sure
bruh so many new osses and leaderboard changes this time
do u want me to link the github or the original link or maybe the website
+1
I suggest maybe even printing a shortrev
But for the love of god cut it manually and not using the actual short rev command
that might be tough as uACPI currently requires very little from the host build system
Hmmmm true
otherwise id of course add -dirty and stuff
I mean, shouldn't it be basically CFLAGS += -DUACPI_REV=$(shell git -C ...)
yeah
And anyone not using make would probably be able to figure out how to convert it to his favorite build system
still this will break every existing build
True
you could just check if its defined
perhaps
If it's not defined you could either have an empty string or something
Like, at work we always print both the version and the revision
ill probably just have this in the header at first
Since we have had cases of stuff being compiled not from master of people actually just forgetting to increment the version lol
lol
this is the updated leaderboard (not yet merged) pls verify if you made a submission, I might've forgotten something
I should also make a submission at some point but I want to get above davix again
the average score that I have now is 6M because in the old score some cr8/gs writes were getting optimized out (it was actually a lot worse than this but I got rid of unconditional cr8 writes in lower irql and instead do a cli + check if cr8 was modified + write if it was + sti)
probably not, davix's current score was measured on a 13700K, which is better than my 5800X (and on my 5800X that proxima build gets like 7.5M iirc?)
maybe not then
i am still in favour of someone acting as a clearinghouse for scores using a consistent testing machine and environment
yeah same
if there's a volunteer for that with a good CPU im down
ryzen 5800x with the turbo boost what-you-may-call-it not turned on
though idk if its really worth it for now tbh, like its basically good enough™️ and I have other things I need to work on like APCs so I can finally get to run some proper userspace lol
my 13700k also is a bit nerfed because wsl
i need to move to native linux
man i hate linux desktop tho
same
i might just virtualize windows
it just cant handle scaling man idk
get a better DE 
i've tried every DE there is
i might have to patch the linux kernel for anti cheats to work properly but oh well
plasma 6.3 just got scaling improvements
every time the linux desktop is about to get good they release a new major version of KDE, GNOME, GTK+, QT, etc and go back to zero features
i might try wayland this time
should probably check it out then
does it now support different scaling between displays and dragging windows between them?
lack of native discord screenshare was a big thing that prevented me from trying it out
this is the problem that i have
I haven't checked as I only have a single 1080p monitor
I had a second monitor hooked up one time and I could drag windows between monitors
ig I can try to update to it and see, would be nice if it would
screen sharing seems to break every other discord update and get fixed the next, but a decent workaround is using the web app
GNOME on Wayland 😋
switching to vesktop fixed all my problems
of course i'd try gnome
discord has screensharing now tho
except mate
i am a gnome user, just not wayland
mate remains the bulwark
that's why i keep to it
thats why bonkers is porting it to Gloire
it just works and they don't badly reinvent the "uSeR eXpErIeNcE" based on nothing but vibes every 3 years
I don't mind doing so (I have i9-13900k), as long as its just downloading a binary and running it in qemu with some basic flags
But if I do that I would prefer to do it in bulk, and ideally have it be printed to serial or debugcon 
just read the backlog a bit. feel free to ping me whenever you are discussing my kernel (davix)
also I still haven't upstreamed any 'fix' for the AMD skill issues that my kernel has (mapping memory as UC- in uacpi_kernel_map). iirc this doesn't affect the score on Intel CPUs (most likely has to do with how caching modes are handled on SVM and VMX respectively)
I will do it with my power station CPU with no conditions
But
I will cook results so ironclad is top 1
You will have to accept that
your "nuclear reactor CPU", "really fkin powerful CPU" etc. has been mentioned a lot. what CPU is it?
13900ks probably
128 core threadripper

I don't
not very good for uacpi benchmarks
Its the KS
anyway I need to select a nice console font for my kernel's fbcon lol.
will you be available fo reruns every now and again?
maybe we should have a github issues page where people would submit their ISOs
idk
I should really setup CI or something for building davix ISOs
but I won't right now (because I'm lazy)
how to get the best uacpi score:
- have friends that hold the world record for a overclocked x86_64 cpu
- ask them to repeat the record with your os running in qemu
- success
also it's literally just as simple as ./run -M q35 to build and run the kernel so it's not rocket science generating an ISO yourself
@slim panther would this comment be sufficient to understand what is meant by this helper?
"On x86, the SystemIO address space corresponds to port IO." is what I would've written, but this definitely works too
port io seems a bit overloaded no?
maybe
yeah actually this is probably better
zero probability of a misunderstanding (unless brian damage)
"On x86, the SystemIO address space corresponds to the port IO added with the i386."
Yeah of course, especially at weekends
I'll probably automate it just so it happens automatically lol
could be nice
Given it should just run qemu | grep avg
i8086, actually
like a website where u submit an image and it automatically posts on github issues lol
:^)
that sounds like asking for things that exploit vm escapes
Tbf I don't run my PC 24/7, too much power lol
it could schedule images to run ig
But yeah I would rather it's images given directly by people we know on the server
also, maybe running in docker or similar would be a good idea, to keep qemu version constant
and/or keep the latest tested image for a given kernel around to retest if qemu is updated
Tbf even kernel version can change it
But I can just say what the kernel and qemu version I am using are
yeah so linux or qemu update triggers global retest
I just have a standard Ubuntu 24 lel
yeah maybe u could store the latest iso for each leaderboard entry
I might switch to Fedora eventually but yeah
if security is a concern one could run it on a independant machine with a configured linux with custom secure boot and full chain of trust
or just auto reinstall after each run
I do have secure boot, but I ain't trusting Linux usermode enough for that
But having a dedicated computer just for that is a bit expensive 
oh i am so tempted right now
Like we could rent a server but at this point...
u can rent a dedicated server
yes
thats probably a bit too expensive lol
i have a powerful vps
we could for example use a n100 board as the reference server, cheap and serial interface
imo just "restrict it to manually submitted images from people known from this server and well-established oses built locally" provides good enough security
4 ops/s
still i am so tempted to build a thing where u can submit isos and test then
something like managarm xbbs
that would be easy enough
good enough
I can have the script just look at issues and create pull requests on demand
But I agree
also i don't think nested virt would be that bad for this, sure it'd be quite a bit slower than regular virt but the most important thing is environmental consistency
boring
Also given it's notable kernels, aka not every random on the server but the bigger projects on the server
technically, wouldn't an actual benchmark using uacpi kernel api be awesome? like seperated into mutex, alloactions, etc
a virtualized env is affected by neighboring VMs
ah true
even for the memory bus bandwidth etc
t
but if it is a virtual server then the hoster could do all sort of stuff with the underlying hardware
so much activity here
I would run it one at a time obviously
nah, test all the kernels at once
in a virtualized env u would basically get wsl2 skewing all the time
Also one thing to think is how much memory and how many cores we give it
Like not all kernels support smp, and some kernels like smp more than others
-smp 1 -m 4G is the standard for the benchmark i believe?
is a n100 board actually that bad, i wanted to buy one to tinker with it
yeah
Then I might want to pin it to a p-core as well
Some poor soul would randomly get an e-core for their benchmark :^)
also worth thinking about is how to make sure host scheduling doesn't affect it
i have a homogenous cpu and even i have multiple very different performance ranges
also try to pin the frequency
ideally u want to isolcpus=
True
taskset
taskset isn't enough
good enough
Cgroups has a way to isolate a core
it restricts it to a specific cpu but that still leaves things like cpufreq
yeah u just want to isolate a cpu, then allocate a cgroup, pin that cpu to it, and then run qemu there
we are really, really overengineering the benchmark right now lol
maybe disable variable frequency in uefi and set a fixed multiplier?
Might as well do it right
oherwise u kinda get unfair results lol
yea lol
Like, as long as it ends up as a single script I come home and run I don't mind doing it even every day lol
That's the main bottleneck, ensuring everyone is using either serial or debugcon to output the info, so I won't need to manually copy things out
I don't mind running a command over serial automatically if need be, but nothing manual
i feel like thats not too much to ask from kernel devs
like every kernel here has serial or debugcon

not pmos i think
hm
also kinda off topic but does anyone know if there's a way to make qemu riscv virt use non-hardware-reduced acpi?
dont think so, it's a very bare bones impl i think
that sucks
they're actively working on it tho
not a thing afaicr
so far only itanium and x86 have seen full acpi
i mean there's still a namespace
nope, there's not even a dsdt
i think your qemu is just old
because keyronex definitely did run a dsdt on riscv
did u make this printout yourself?
i'm not sure if you need a special qemu branch
yeah
possibly you do
I actually plan on removing (or putting in #if 0) debugcon from my kernel once I have fbcon lol
i thought it was merged
ohh it's for the microkernel?
yes
btw hardware reduced doesnt mean there's no DSDT
it's good to output to e.g serial because you can debug it on hardware if you have a serial port
no DSDT is not compliant impl
oh really?
yea. but first you gotta have a serial port lol
if your hardware has a serial port that is
yes
on all the hardware i have the most low-level debugging is framebuffer
so i just use triple fault debugging
or, if i'm trying to get rid of a triple fault, halt loop debugging
.macro hcf
42: cli
hlt
jmp 42b
.endm
so fkin useful
the reason that I'm doing fbcon right now is because I kinda want to test on a very old laptop
and for that, I need output somehow
btw how are u checking for dsdt
u do look at x_dsdt as well right
ngl i completely forgot that dsdt isn't in rsdt/xsdt
I have ns16550 driver, but it's broken on x86 atm
yep false alarm
ye
The issue is that there's SPCR table on RISC-V, but not on x86
So like do I just log to COM0 unconditionally?
the 'proper' way to do it would be to find it in the ACPI namespace
but then it obviously can't be used for uacpi benchmark
or that
but after I find the port, how do I know that it's not an UPS or a mouse, idk
no real way to tell
state_reset(), then do it again lol
that'd work yeah but then you'd have to have a separate uacpi benchmark build mode
I can actually
also the results would be invalid because the 2nd run has better cache stuff
My log server buffers certain amount of lines
true
So it would just spit the result out once the serial port was found, after the benchmark
that'd work yeah
Like this is the only issue
But stuff like SPCR explicitly tells you that a serial output should be used for logs
you just have to trust that, when the user tells you to (f.ex) use COM1 for logging, it's not connected to a mouse or ups
kind of like linux's console= option
Yeah
Isn't there a debug table that the bios can provide? I think in qemu it points to debugcon
Debug Port Table 2
@fiery turtle is there anything new I could test in uacpi?
will be waiting
or well not waiting
but more of an asynchronous read
ask him to ping you. when he does, that is an interrupt
yes
you installed an interrupt handler
then if I am in bed or taking a shit, I will register a DPC so I can do it when the IPL lowers (I wake up or finish taking a shit)
Who said you couldn't do programming while taking a shit
true
but I would still prefer deferring it
thank god none of my real life friends that are in this server
well there are two
but none of htem look here
@ oberrow irl friends

at everyone are you oberrow friend
@everyone says: yes
@left orbit was it you who tested my kernel on an i7-13700K? because I'm curious about how this image would perform:
curious about a 13900KS?
that would also be interesting
well @strong heath has one
as long as it isn't tested concurrently with a GCC compilation
whats a command you would like the davix software distribution to be run with
qemu-system-x86_64 -enable-kvm -cpu host -M q35,smm=off -m 256M -cdrom davix.iso this should work
im off pc for the night
but 13900ks should do a bit better than 13700k
Virtualize in the brain 
higher clocks and slightly better single core performance will do
varies a lot, the average seems to be 6.4-6.5, it has lows of 5, it has highs of 7
bind PCI bro
yeah I really should implement those routines
... but there's like a million other things I also should implement
such is life
indeed
like it's interesting because I consistently get results approximately in the range of 4.4-4.8M on an AMD CPU
if it still exists
soon it will all be loongarch
bad joke bad joke
new score is 6.7M as I realized that cli + sti was unnecessary, basically its enough to first write the software irql to the cpu local so then all interrupts that happen after that point can only set the hw irql to the new irql (which is fine, then no cr8 change is needed inside the lower irql function) and after that load the hw irql from a cpu local + do cr8 change if its greater than new irql (as the hw irql could have been changed to the previous irql before the first write of new irql to the software irql cpu local)
i get like 6.2-6.3M pretty consistently
btw
to @gentle peak but to everyone else really, Limine 9.0.0 is out and it features SMP wait loops using monitor/mwait
idk why i am saying it in the uACPI thread
shit
i should've used the #1282508189698625619 thread probably
uACPI thread needs to be renamed into lounge2

fuck
i need to get my game up again
beating pmOS again 
ig you can add it
I think the average on my cpu is now 6.8M
although not by much and on a faster CPU 
@fiery turtle my bad btw, the new score is on an Intel Core Ultra 7 265KF
@fiery turtle if I make a shitty allocator just for uacpi that only cares about speed and not about memory usage would that be accepted 
if the kernel is still usable with these changes (i.e. doesn't leak memory or break concurrency or anything else), my opinion would be yes. but I'm not infy
just use the shitty allocator in the entire kernel
Link and description 
Sure
I guess
imo making a shitty allocator that is used exclusively for uacpi is gaming the benchmark
if you use it in the entire kernel it's fine
Yeah
i fixed my shit allocator and got this
i have amd ryzen 5 3600 (i bought it in 2020-2021)
(3) still has 1 early reference(s)! seems a bit worrying
are you on an older version of uacpi?
no
why do you initialize uACPI before setting up the APIC etc.?
i initialize early tables
first
after init hpet
and finally init uacpi
here with non fixed allocator
its fixed
It means they leak an early table reference
Aka not calling table_unref
Basically a safeguard warning because a lot of kernels handle early mappings in a different way from late mappings
can i get into this table 👉 👈
I can add your kernel if you want, the pr is still open
dear lord its embarassing to see astral that low
Yeah
I need to buy a good computer
ok i can send link
or you already have
Link, cpu used for measuring, short description
meanwhile obos being at the 2nd bottom:
I need to optimize my kernel one day
I got 4.5mil on streak's but he didnt send the full score grrr
Beg until he does 
I'd probably be able to optimize it greatly if I did one thing...
an NT driver compatible kernel and userspace
I am bad at coming up with short descriptions (and the link, though you an probably find it https://github.com/Qwinci/crescent2), score 6,818,418/s (for something that's close to the average on i5 13600K)
Letsgo
wait qwinci your computer is good right
Cpu + exact score pls
https://github.com/cppLover0/Orange amd ryzen 5 3600 x86_64 unix like os
i trying to add a unix-like features in soon
Sure
decent yes, not as good as the i7's/i9's or whatever else
Wdym, he got 3.5M
this guy didn't
I was talking about his kernel
That's the non fixed allocator
its before
now my kheap allocator is good
do the cr8 optimizations that I did
can you see if what I did makes things better
qemu-system-x86_64 -cdrom astral.iso -M q35 -enable-kvm -cpu host,migratable=off
I guess it did letsgooo
this makes sense considering streak's cpu is better than mine
why it throws error
thats it trying to get the root device but failing because theres no nvme in the vm
the default options picks nvme0n1 as the root
a ok
maybe get qwinci to run your os as well so u get a better score
wait what
ad complete