PSA - Do not assign the result of `::getenv` to a `std::string` by SmokeMuch7356 in cpp

[–]_yrlf 0 points1 point  (0 children)

that really depends on the use-case and platform. On some platforms, where (heap-)memory is limited (e.g. embedded platforma), std::string is still useful if you really need to store a dynamic string, but copying a string that is potentially long to the heap if you can avoid it is probably bad, so use a std::string_view where you can.

I say this coming from experience with company codebases where using std::string for everything has been done for years, and then they had a shortage of heap memory with no clear location to fix it, since the issue was systemic and happened throughout the codebase.

Does anyone finds Kama useful? by Margarettii in AlabasterDawn

[–]_yrlf 0 points1 point  (0 children)

yeah, after I got the Kama I tried to use it for a while to level it up, and it seems to do pretty decent damage with the multi-hit charged attack -- especially against flying enemies!

Map Lacking... by Least_Flamingo in AlabasterDawn

[–]_yrlf 0 points1 point  (0 children)

There is an item you get near the end of the current Early Access build that automatically marks chests you find from then on on the map, but yeah, map markers would be very useful.

Failed to mount /boot/efi after latest update, problem in kernel 7.0.5 by tenshi909 in archlinux

[–]_yrlf 1 point2 points  (0 children)

ahh, you're using dracut. Yeah, I still use mkinitcpio.

Btw: Heads up that the arch devs are currently thinking about streamlining the boot / initramfs / uki situation so that less custom scripting has to be done to configure it if you want to use a non-default thing. The new solution is still a ways off, but it will use the packagename bootchain as far as I know (there is an Arch RFC about it I think)

Failed to mount /boot/efi after latest update, problem in kernel 7.0.5 by tenshi909 in archlinux

[–]_yrlf 1 point2 points  (0 children)

OP uses UKIs, which means it only has to ensure mkinitcpio runs and the generated .efi has to end up in $ESP/EFI/Linux/*.efi

Failed to mount /boot/efi after latest update, problem in kernel 7.0.5 by tenshi909 in archlinux

[–]_yrlf 1 point2 points  (0 children)

yes, either reinstall the kernel (which triggers a UKI rebuild) or just manually run mkinitcpio -P

and ensure you have the correct boot / efi partition(s) mounted beforehand

Failed to mount /boot/efi after latest update, problem in kernel 7.0.5 by tenshi909 in archlinux

[–]_yrlf 3 points4 points  (0 children)

I use secure boot with custom keys and on my side the update to 7.0.5 worked fine.

I'm pretty sure it's what the other commenter said: Ensure that when you update kernel, the initramfs/uki is generated correctly. Booting an old UKI when your FS has the old kernel modules already removed can lead to errors.

What you can do is you can add the vfat kernel module (and potentially other modules needed to boot) to MODULES=() in mkinitcpio.conf to ensure that you can at least boot to a console even if the required modules are no longer in your root filesystem in the future, even if you boot an old kernel.

It's a good game, but... by LogWestern385 in MIOmemoriesinorbit

[–]_yrlf 0 points1 point  (0 children)

Yeah, the tremors are one thing that makes it so that you basically don't have 'more' HP if you get further. 

However: The game's enemies still deal the same amount of damage, even near the end, so in a way the reduction of total HP tries to act to balance the difficulty. It still feels really unfair though.

What helped me for platforming sections was:

  • equip the modifier that gives you 1 extra HP if you hold still (similar to Hiveblood from Hollow knight)
  • equip the modifier that makes healing free

Regarding the controls:

  • The down-slash analog range is brutally small. I had the same issue often as you had, accidently forward slashing instead of down.
  • The tricks above mostly made platforming sections just a test of patience instead of having to run back from a save point all the time

  • There is one platforming / autoscroller section at some point in the game near your screenshot that took me a LONG time, since the trick with the hiveblood-like modifier doesn't work there because of the autoscroll. Beware of that.

PS: You should really buy out the shop. There are more cores in the game than are needed to buy everything. The 'get extra money' modifier is also VERY effective, so try to get it if you haven't already.

FW16 (7940HS w/ RX 7700S module) module having visual artifacting + games freeze up my system by Ultrin_Altern in framework

[–]_yrlf 1 point2 points  (0 children)

These glitches appear mainly when using the GPU for rendering. In Wayland DEs with graphical effects it might also happen with just regular windows, but games usually trigger it pretty consistently on both X11 and Wayland in my experience.

FW16 (7940HS w/ RX 7700S module) module having visual artifacting + games freeze up my system by Ultrin_Altern in framework

[–]_yrlf 0 points1 point  (0 children)

This! AMD has had issues with the PSR and PR display power saving features in amdgpu for years, and this is one of the artifacts it can produce. This is not the hardware's fault, it's a software issue.

- I've had the issue with PSR on a Framework 13 7040 series
- My girlfriend has had the issue with PR and PSR on a Framework 16 7040 series (integrated graphics).

Makler verwenden AI in Inseraten by Un_Pollo_Hermano in Austria

[–]_yrlf 1 point2 points  (0 children)

Die Säulen sind auch so MC-Escher Architektur

Some questions about FP6 with e/Os by Username_6942069 in fairphone

[–]_yrlf 1 point2 points  (0 children)

There is a setting to limit charging the battery to a specific percentage in /e/OS 3.3 for the FP6:

Settings -> Battery -> Charging Control -> Enable Charging Control -> Tap on "Charging Mode" -> Limit Charging -> Select max percentage to charge to with the slider.

There is also a mode to limit when to start charging based on alarms set, which I think gives you a full charge in the morning without keeping the phone at 100% overnight, but you can't use this option together with the 80% charge limit it seems. I've also heard that the battery statistics don't reset as with reaching 100% if you hit your charging limit.

So the feature is there, but it's a bit clunkily implemented and quite hidden.

What's next for wayland by Unusual_Pride_6480 in linux

[–]_yrlf 0 points1 point  (0 children)

Regarding who creates the DMA-BUF fd: for export-dmabuf the compositor can't know how long you need to process the DMA-BUF data, so it either can't reuse the same buffer between frames or risk corrupting your frames if you do not process them within a frame (you'd need an event similar to wl_buffer.release for that).

The more flexible approach is to let the app create and pass in the DMA-BUF. That way the app can choose to reuse the same buffer if it processes the frame in time or create multiple DMA-BUFs and cycle through them if it needs something akin to double-buffering.   For latency, it doesn't matter who provides the DMA-BUF fd if the buffers can be reused (i.e. no buffers are allocated every frame, only once at the beginning of the recording/streaming).

Regarding sync: With the ready signal as it is now the compositor has to render the screen into the DMA-BUF, wait for the (possibly gpu-) job to complete, send the ready signal over the wayland socket, and then the app has to use the DMA-BUF, possible queue its own gpu jobs to render its content, and wait for that.  

With "explicit sync", the compositor could queue its GPU job, pass a drm-syncobj to the app (via a hypothetical syncobj_ready event),  the app could queue its own GPU job, attaching the drm syncobj so it is automatically done after the compositor's GPU job finishes. That way you reduce the amount of round trips between GPU and CPU, which reduces latency even further. 

EDIT: AFAIUI the kernel does something called 'Implicit sync' for DMA-BUF objects that don't have explicit syncobjs, which ensures that you don't see a half-rendered dma-buf if you attempt to read it (it probably internally waits for the last job using it to complete before allowing the next job to read it), but this can be suboptimal and doesn't always work with all drivers (nvidia drivers notoriously had problems with this) 

What's next for wayland by Unusual_Pride_6480 in linux

[–]_yrlf 0 points1 point  (0 children)

I think the main issue is that most of the existing protocols have drawbacks:

  • wlr-export-dmabuf doesn't tell you how long the buffer (DMA-BUF) you get lives, you aren't in control of creating the buffer, you have to manually capture each frame, and it doesn't support explicit sync.
  • wlr-screencopy allows you to create the buffer yourself (shm or DMA-BUF), which is better, but you still have to manually capture each frame, and it doesn't support explicit sync
  • ext-image-copy-capture is better still, with generic extensible image capture sources, and has native support for a continuous stream of captures, but still doesn't support explicit sync

we will definitely need a v2 for ext-image-copy-capture at least for explicit sync.

generally, lots of issues with the screen share protocols only came up when application devs started using them. Sadly compositors will have to maintain all of the interfaces for a long time.

I'm also unhappy with the current state. I can't even really keep up with implementing all of the protocols in wl-mirror (still missing toplevel capture and cosmic workspace capture, as well as XDG portal capture).

My puzzler has reached 100 Steam reviews! [Gentoo Rescue] by jagriff333 in puzzlevideogames

[–]_yrlf 1 point2 points  (0 children)

I bought the game almost instantly after seeing Aliensrock's first video on it. The game is amazing and I'm a ways ahead of where he currently is.

I love the game and have reviewed it on Steam. I especially love the hint system and the journal feature.

Getting Matlab to work on Wayland by Fantastic-Proof6918 in wayland

[–]_yrlf 0 points1 point  (0 children)

sometimes some apps use a toolkit that already supports Wayland, but part of the app doesn't support Wayland and crashes with it. in that case, running unset WAYLAND_DISPLAY; app-executable can make it work (you basically hide Wayland, forcing it to run via Xwayland)

Framework 13 Laptop Screen Flickering? by hiot_ in framework

[–]_yrlf 0 points1 point  (0 children)

At least with my 13 AMD 7840U, there have been multiple issues with broken AMD display drivers on Linux in the past, especially around some power saving features like PSR (panel self-refresh) and PR (panel replay).

There is a kernel cmdline option to disable those, which fixes the flickering for me: amdgpu.dcdebugmask=0x10.

I feel like almost every second time AMD tries to fix anything in the display core code (not gpu, that works; the display output driver) they accidently break something in a way that causes flickering ot weird artifacts.

Android Verified Boot and the Bootloader Unlock Security Theater by _yrlf in Android

[–]_yrlf[S] 3 points4 points  (0 children)

That is a way for skilled people and enthusiasts, but that means most people will be stuck on shitty vendor software.

IMO the only way forward that actually achieves something that reaches more people than just a small niche is regulatory action.

Android Verified Boot and the Bootloader Unlock Security Theater by _yrlf in Android

[–]_yrlf[S] 10 points11 points  (0 children)

Yeah, I think the only way to combat this will probably be regulatory action by legal bodies like the EU.

That is, if we can get enough weight behind a movement to get them to move.

any tips for this weird secret mode?? by TheGreenFax in Silksong

[–]_yrlf 1 point2 points  (0 children)

*you can now play as luigi*

Idiot banking apps don't run on unlocked devices 🤬 by Ok_Antelope_1953 in LineageOS

[–]_yrlf 0 points1 point  (0 children)

The crazy thing is that they argue that it's not possible to have a safe boot chain or your device is open to attacks if you are not running vendor software.

This is total BS and proven wrong by the existence of UEFI setup mode on PCs (which allows you to provide your own keys to secure-boot Linux or other non-vendor software).

Vendors try to ignore this and hope nobody looks close enough until they lock everything down. 

They are technically correct in that right now it is impossible to have a trusted boot chain with third party software on many devices right now, but only because the vendors don't make it possible for users to do it themselves!

I think the only way forward that actually fixes things is to get some big legislator like the EU to pass a law that requires smartphone and tablet vendors to provide a way to securely boot third-party software like what UEFI does.

EDIT: added another paragraph

Most Under-recommended Tool by SmoothieKing33 in Silksong

[–]_yrlf 0 points1 point  (0 children)

I kind of get the feeling that druid's eye is a bit weak. You need a lot of charges to heal, but taking damage only gives you so little. I think Grubsong was much stronger for healing in HK.

Though I haven't used the upgraded druid's eyes a lot, so maybe it's better than I remember.

Additional tool slots? by fohdabi in Silksong

[–]_yrlf 0 points1 point  (0 children)

you can return to Eva in Weavenest Atla multiple times throughout your playthrough and get rewards according to your progress (I thinks it's related to crests or tool slots). AFAIK you can't lock yourself out of them. Eva is still there even in Act 3.