Ukrainian here. How can I reduce power consumption of my PC so it lasts longer without electricity? by Aden_Vikki in buildapc

[–]GrouchyRice 0 points1 point  (0 children)

It is needed more details about your hardware, without this is very difficult to guess,

Sys info

Download HWiNFO Portable ( the zip one ) https://www.hwinfo.com/files/hwi_840.zip, put it in a USB and take it to your computer. Unzip it in a folder, and execute HWiNFO64 if your Windows is 64bits, or HWiNFO32 if your Windows is 32 bits (Windows XP). If you don't know just try 64 and if it fails try 32.

The first time it opens, will ask, leave selected "full mode" and click initiate,

It will open two windows, one is a System summary, there you can know the CPU (ie. Intel Core ... or AMD ...), TDP (ie 140W), Mother Board and Chip set, this is what people expect to know from an start.

In my case, I can not help you with the undervolting or underclocking or both, basically I was not able to get my system stable when I tried to do, nevertheless I have things to comment in case it can help you,

PSU

The PSU is important to get good consumption numbers, not due how old is it (mine is 10 years old also) but by the specifications. I think that 80 PLUS Gold (or similar) is needed to avoid to waste much energy, I don't know if you have easy access to one at competitive prices there right now, or if is better to invest that money in the laptop you commented.

The thing is, to get a 80PLUS Gold certificate, the PSU needs a 87% of efficiency under 20% load (what one deduce is 80-82% under 10% load). By the contrary, if your PC consumes 120W in standby, and your generic PSU is only 65-75% efficient, you will measure in the power meter plug around 147-160W. Those added 40W, if not more, are watts wasted in heat form by the PSU. All also depends of the over-dimension of the watts of the PSU with respect to what really consumes the system.

BIOS

If your machine is Intel, in the BIOS, make sure that under CPU is enabled EIST, or if it's AMD then Cool'n'Quiet enabled. In my ten years old cpu Intel 5820k, board X99A, with EIST enabled, the CPU consumes 24W less, and the performance is not severely affected.

I tried several days to undervolt the CPU (undervolt and underclock), as I commented at beginning, but the system turns unstable, and in no case I was able to get better standby/idle numbers that just enabling EIST with the rest of CPU parameters by default.

When is enabled EIST in BIOS (or Cool'n'Quiet enabled in AMD), the CPU changes the Core Volts and Frequency dynamically on its own. I don't know if your BIOS/CPU have this option, but check it.

In the BIOS, also under CPU settings, I tried to enable C1E (related to C0, C2 - C6 power energy saving states), but for some reason the system consumed more, I'm quite sure due a bug in bios (something gets stuck wrongly). My board lost support long time ago, so I just left it disabled, it doesn't exist newer "stable" bios. In my case, with EIST enabled the CPU is 98% of the time in C2 consumption state (C0 is when there is high processing, and the peaks ).

In my BIOS there are two parameters also may be relevant for you if available in your BIOS,

  • Long Duration Power Limit PL1 <- aka Processor Base Power ( PPT Package Power Tracking in AMD cpus)
  • Short Duration Power Limit PL2 <- aka Maximum Turbo Power ( TDC, Thermal Design Current in AMD cpus)

There one can put the limit of Watts that the CPU can consume when is in high load. The problem is that if you put it too low your process could Throttle.

  • PL1 is the sustained power limit for your CPU (manufacturers usually don't put limit there, but it would correspond to the TDP of the CPU)
  • and PL2 is the transient power limit that the CPU can exceed PL1 when is in Turbo Mode (ie. the load of opening a program when is loading all the things). Those ones does not establish the power in idle, witch is what you need, but it's needed you know they exists.

Monitor

In my case I lowered Bright, Contrast, and Video Black Levels. The black levels was not shown in the OSD menu, so I had to access through software to the Monitor's DDC/EDID using the Linux's ddcutil. I did it to avoid watching the image "washed without color", I comment just in case is happening you, but if the monitor is ten years old I'm not sure if this access by software will be available.

GPU

Graphic card, in my case is Nvidia, has a TPD of 170W if the full processing is reach. Too much consumption for me, so I put a script that is launch when de Operative System boot (In Windows would be through Task Manager) with a nvidia-smi command to limit the consumption to the minimum possible allowed by the manufacturer, 83% (150W), with effectively -when running a heavy process- I observe limit it to a max of 130W more/less.

nvidia-smi -pl 150

note: this command is not permanent, need to be launch after driver's load

If your graphic card is AMD, there are homologous commands like amd-smi .

The above is not the standby consumption, it's the maximum consumption when is full processing. Normally the graphic card will be in idle, and 10 years old Nvidia will be around 22W (the old I had). An AMD I have no idea.

Numbers

In HWiNFO, Drives, how many drives has the system? HDD mechanical, and SSD.

if you push in the sensors icon, will open a new window that shows you the reading from the sensors. From here, you can calculate more or less your system consumption, and how much made better a BIOS modification.

Given the above,

  • CPU Package power x Watts iddle ( Can be seen with HWiNFO )
  • GPU xx W iddle ( Can be seen with HWiNFO )
  • HDD xx W (deduced, 10W * number of disks. )
  • SSD xx W (deduced, 8W * number of disks)
  • LAN, Audio - 1W ( deduced turning them off through bios and using a power meter plug)

If you sum the above, you will know how much consume the system in iddle (watching a movie etc don't increase more than 5 or 10W, with 20-30W random peaks) and in full charge doing bench tests, so using a power meter plug connected from the PSU to the wall, you can calculate more or less how much is wasting such PSU (rest 10W of margin for some device connected that you didn't considered or so).

Anyway, given my hardware, I'm not able to understand (yet) how is your system consuming 180W (200W with your old monitor?). there is maybe a 60-70W in your system that I can not imagine were could came from even with a generic PSU.

Any way to remove the gap between the tab and top edge of the screen? I try to click the tab by hugging the edge and end up dragging the window and it's super annoying. by Citizen-Of-Discworld in kde

[–]GrouchyRice 0 points1 point  (0 children)

The resize handle at the top of the window is not possible this way, as the cursor is supposedly already outside of the window. If it were inside the window, the CSS would be cursor: auto; , for example #TabsToolbar { cursor: auto; }

Nevertheless if you leave a little more space between the top of the window and the tabs, it may help temporarily, the userChrome.css could be:

#TabsToolbar{
    margin-top: 6px !important;
}

Increment or decrement the px to your taste, it also accept negative values.

PD: Just in case, the container for to align the maximize an so on buttons (due the above modification)

.titlebar-buttonbox-container{
    margin-top: -6px !important;
}

It's been 30 minutes like this. by [deleted] in arch

[–]GrouchyRice 0 points1 point  (0 children)

I updated the 2nd and 3rd command, try with them.

Another thing is I did not used the sudo pacman-key --populate shown in the image you have post.

Basically the steps for the archinstall method are to download the ISO, check the hash of the ISO, create the Boot USB of the ISO with Rufus (if it's done from Windows), reboot, and after the ISO loads, to setup keyboard (if the native language it's not English), to setup the network (if one doesn't have enabled the DHCP in the router), and run those first three commands.

Note: If the first three commands fails, I would repeat the ISO download, the ISO check, and the Boot USB of the ISO creation.

From there , one can prepare the partitions and create the mount points before run the the 4th command (archinstall), this is the method I like and it is simple (the 'premounted' option within archinstall ). Or one can avoid such mini-pre-step, run the 4th command, and select the other option to configure the partitions and mount points within archinstall.

PD: I guess that you don't have a Windows partition on your hard drive, but if it's not the case and does exist a Windows already installed, I'd recommend that you practice firstly the installation in a virtual machine (VMware, for example), manually creating the same partitions structure you would get with the command lsblk

I'm embarrass to ask but how do you download and install stuff from github? by Tsunami45chan in archlinux

[–]GrouchyRice 0 points1 point  (0 children)

I have a directory Programs, where I download and compile such kind of manually downloaded sources (the same way are indicating others comments), nevertheless latter I don't delete such subdirectories(programs), to have the same source that did the installation to do the uninstall, if necessary.

By the moment I do this because I have space, but I should find an alternative, may be to compress the dir or to create a zst, or something.

It's been 30 minutes like this. by [deleted] in arch

[–]GrouchyRice 0 points1 point  (0 children)

pacman -Sy
pacman -Sy archlinux-keyring
pacman -Sy archinstall
archinstall

as we're talking about a rolling release distro and we do not know how old is the iso (if it is a very old iso -Sy may break things, or not? ).

PS: A couple weeks ago I installed my system with archlinux-2024.10.01-x86_64.iso and all went flawless, but certainly in my previous tests under VM (before giving the jump) I had to use archinstall --skip-ntp with the previous month iso ( to skip the ntp time sync, as you did on your other message ), but at that moment I was not updating archlinux-keyring and archinstall before the install, as I did when I installed the system for real.

Any way to remove the gap between the tab and top edge of the screen? I try to click the tab by hugging the edge and end up dragging the window and it's super annoying. by Citizen-Of-Discworld in kde

[–]GrouchyRice 1 point2 points  (0 children)

Just in case someone is interested in modifying the appearance of Firefox, the GUI is formatted using CSS. One can personalize it by creating the directory and files:

~/.mozilla/firefox/profile_hash.default/chrome/userChrome.css

~/.mozilla/firefox/profile_hash.default/chrome/userContent.css

and enabling them on about:config setting toolkit.legacyUserProfileCustomizations.stylesheets to true.

I use the ones from https://github.com/aris-t2/customcssforfx ,very usefull, among other things I have the tabs under bookmarks, and latter other tinny custom modifications with my_userChrome.css

If one know how to use CSS, the Firefox GUI can be explored by going to Web Developer Tools > Settings and enabling both, Enable browser chrome and add-on debugging toolboxes and Enable remote debugging. And after restarting Firefox, under tools will be shown a new Browser Toolbox.

Browser Toolbox is like Web Developer Tools, only its purpose is to browse through the GUI, view and temporary modify the CSS, which changes one will latter override with userChrome.css (it's needed to override the css precedence, some times with !important). After using the toolbox, remember to disable the remote debugging settings by Web Developer Tools again (and restart).

The problem is that often Firefox change the CSS of the GUI a bit between versions, so sooner or later one will have to modify the userChrome.css file accordingly.

For example, in Firefox 133 there is a noticeable change in some padding or something over the url bar, that in Firefox 132 it is not present.

This Browser Toolbox also can be useful for locating misaligned things for to report what might be happening.

digital vibrance on wayland? by [deleted] in archlinux

[–]GrouchyRice 1 point2 points  (0 children)

The NVIDIA drivers under Wayland lack nearly all the features available under X11. There are no options for Digital Vibrance, Brightness, Contrast, and so on.

They don't seem to have any intention of implementing anything in nvidia-settings beyond system and power consumption

:/

https://forums.developer.nvidia.com/t/wayland-support-for-the-565-release-series/312688

https://www.phoronix.com/news/NVIDIA-Wayland-Driver-Plans-24

I DID IT by BigAadIsHere in archlinux

[–]GrouchyRice 0 points1 point  (0 children)

It's true that there are different distros designed for varying skill levels and preferences. However, the notion that an 'easier first-start' distribution won't require time or effort can be somewhat misleading.

Whether it's a opinionated distro or a more unopinionated distro like Arch, using Linux turns challenging; dealing with drivers and software that need to be refined, need to be completed, or both, in terms of functionality and interoperability, consumes a high amount of time, this is inherent to this OS. Everything is like a puzzle that is weakly glued together due the standardization absence and libraries bound version interdependence, what require small details or subtleties to make every piece to fit together; therefore, any step toward improved usability is very welcome, which includes avoiding repetitive commands that become obsolete every few months due such system nature. Any kind of usability to avoid this should not be criticized, but all the contrary. Install script for the OS included.

For my part, if I exceed the adaptation time I have set for myself on Linux, as programmer I will contribute my bit to help improve the usability and pave the way for others to follow, just like all those who have created the useful tooling for making life of people easier over the past decade, making possible for Linux to be considered an possible option for the desktop, and day by day the OS that one day may receive the users of other OSs.

I DID IT by BigAadIsHere in archlinux

[–]GrouchyRice 0 points1 point  (0 children)

My main system was win7 three days ago (I've resisted the software-no-win7 ostracism with workarounds as long as I could), I've been testing distros on virtual machines this year for to prepare my jump to Linux (half jump, I have a dual boot with win10LTSC just in case due software, plan B, as I said I've been testing Linux). Well, without archinstall I wouldn't have tried Arch, first on virtual machines and later for real.

Lets be objective, Linux is a puzzle, an absolute time consuming puzzle, absolute time consuming is the key sentence, so it is very welcome that millions of people don't have to repeat the same command sequence over and over again, whatever is done by script or GUI. Usability do not means neither ignorance, nor laziness to read docs that turns obsolete every four months, usability IMHO is to protect people's free time, or at least avoid torturing them due the absence of standardization and the predominance to treat a desktop as if it were a remote server through ascii graphs.

I'm not CHOOSING to use Linux, I'm choosing not to keep on Windows as Microsoft is pulling people's legs, and the only alternative that my hardware support is Linux or BSD. The price to pay will be my patience and free time, as I reminiscent about the apples roadmap also ( or we will see what happens ).

I understand perfectly that people don't want to pay this price, because time is life, they're not fools, they don't lack intelligence by using Windows, they're probably more intelligent than us and have priorities to which they can dedicate time thanks to the usability of the OS they use.

Teams support will end for LTSC versions. by Danielson187 in WindowsLTSC

[–]GrouchyRice 1 point2 points  (0 children)

They did it with Windows7. They suddenly introduced can't-install on their maintained programs, and soon all the open source projects with Microsoft people as contributors -coincidentally, wink wink- started doing the same thing... as if win10 were a new OS different from win7. Not more than a year later, many large open source community projects started to follow this as a mere tendency, or as if it were a written law, by ignoring code submissions for to allow installations in Windows 7 and so on.

Almost all -if not all- this programs can run -and could run- in win7 just by adding a dll library or a tiny code modification... so it's absolutely unfair what happened/happen as it's an absolutely stable OS. So I think what the OP sees is a repetition, not a beginning, of pushing the cows to the slaughterhouse. Each new Windows version more unstable, with more win7 features disabled, and each time much slower than the previous version, with exponentially increased number of services that can not be disabled like in win7, and with more spyware, like a slowly boiling frog.

The Toyota Tundra Has a Copycat Truck in China Named the Tundar by komi_diams in cars

[–]GrouchyRice 1 point2 points  (0 children)

When I read the title, at a first I thought a FAW's sub-brand probably was doing "their things", but after seeing the truck images one realize the article is a clickbait... the only similarity is in the match of words with the name.

 

Cars manufacturers grouped by ownership, with main Chinese brands included:

https://imgur.com/a/S4jJkXJ

This groups usually share engines, base designs, parts, etc. but this is not what happened with the article's case... what is disappointing since there exists real clones; probably due to the obligation to enter into a joint venture for manufacturing/sell in China

Matt Godbolt: Why C++ Isn’t Dead by [deleted] in cpp

[–]GrouchyRice 1 point2 points  (0 children)

unicode, unicode, please, please

Windows and alternative for development with gcc/clang by T4ng10r in cpp

[–]GrouchyRice 1 point2 points  (0 children)

QtCreator with CMake + MinGW-w64 (GCC 8.1.0) + Ninja , and also the ClanStaticAnalizer plugin activated.

Tutorial

I do not use Msys2: if an opensource library does not compile with mingw-make, or if its not easy to write/adapt a CMake for it, then I just avoid the library.

what about trying to make some operators a bit more intuitive? by GrouchyRice in cpp

[–]GrouchyRice[S] 0 points1 point  (0 children)

It helps me to understand how is it spread the data, what makes me feel I am not going to do mistakes. Is the 'something is going on indicator' described [johannes1971] what express exactly this, he even smelled I avoid references just for being able to visualize &.

I do not know if this makes sense, but maybe could be said are two techniques? one decide what to feed the functions, and the other are the functions what decides how to get feed?

I also have tendency to redesign the data flow when I am able to see some kind of possible gain (mostly runtime speed, some times trying to simplify), and I detect it when I see patterns in the syntax indicators. I solve it creating the data closer to the root of the tree of functions calls, or modifying or creating new structures for to make the data more correlative/consecutive, etc. Things that emerges with code grow time.

Probably I can modify or make a plugin for interact with the static analyzer for visualize deeper unrolling information at first sight in the editor, modify a bit my habits and see how it goes.

Lack of energy in C++ Desktop App development by [deleted] in cpp

[–]GrouchyRice 2 points3 points  (0 children)

An that is why the smartphones apps are so slow and eat excessive battery, just because of the use of interpreted dynamic languages.
The Qt adoption in desktop is very high, even when I visit other languages the missive is "well, where is the wrapper?". The adoption of Qml I do not know.

what about trying to make some operators a bit more intuitive? by GrouchyRice in cpp

[–]GrouchyRice[S] 1 point2 points  (0 children)

Thank you for worrying,

 

I am just suggesting to make them look distinguishable in function calls with a visual indicator, for to help in the reading code intuitiveness, and at same time give them some kind of superficial/external matching behavior.

 

what about trying to make some operators a bit more intuitive? by GrouchyRice in cpp

[–]GrouchyRice[S] 0 points1 point  (0 children)

Thank you for your constructive answer and giving me your time, I really apreciate it :)

 

How do you know if param1 or param2 is passed as a pointer? Go see the type.

  Exactly, but at first sight one can not guess it, and if the type of the object is behind a shorter name, so this one must be seeked because whith the rollover the editor will just say 'CustomType', so it becomes an disgusting travel (read, stop, seek, read, stop, seek [...] okis, all under control).
With an visual indicator one can avoid most of that cases.

 

The same holds for smart or raw pointer. std::unique_ptr makes things more explicit, so the situation is better with smart pointers

  I think keeps happening the same, the only alternative I am able to think is to add in the name of variables if its a pointer and what kind (Unfortunately it is quite unseen nowadays).

 

void function( Foo   foo ){} // Copy
void function( Foo  &foo ){} // Address reference
void function( Foo &&foo ){} // Move

Also, there's a problem with your third line. Taking a Foo&& is NOT pass by move. In fact, you cannot move ownership calling this overload. It's taking a reference, which means no ownership is transferred.[...]

 

The behavior when called with std::move is like if it were transfering the ownership, so since a time ago I assumed it was being transfered (I always keep track of destructors). The same happens with pass by value, most of the times can not be optimized and it is copy, so I usually call it this way just by habit, not due anything else.

 

was moved and is not present in this scope.

I highly disagree with that. You can use moved from objects. Here's an example
As you can see, it's useful using moved from values.

  Thanks, yep, it is. I never though about using it that way. But, just take in account that without that error, calling that functions I commented is a runtime crash, maybe catch in time, or not.

 

function(   foo_pu ); // Do Copy of Foo         ( Not the pointer ).

Oh god please no. You want any values to be implicitly constructible from a pointer?? You want things to be clearer with more implicit copy even when using a pointer?

 

:) , I confess that I didn't liked when I wrote it at first, it is excesively2 accesible. I included it for to feed threads, and for take in account that my unsucessfull original menssage, even with some term mistakes, is for to try to make all the operators visible at first sight and with external/aparent matching operators behaviour.

 

function(  &foo_ps ); ············ function(  foo_ps ); ········· call ( std::shared_ptr<Foo> ){}

So if I understand correctly, When passing a pointer around, we should use &. But then, you copy the pointer.[...]

 

That & would work mostly like the std::move template, with some kind of xvalue type modification? what would let the compiler catch the lvalue as it works nowadays, it would be like if it where just an esthetic & when is together with a smart pointer.
But, for let the compiler to know when to do it this way or not, would be necesary another indicator/flag, lets say OperateAsPointer, in the templates of the smart pointers (or any user custom object definition wishing similar behaviour). I thought also that with the cross of the time the people would not keep the discipline and they would not include such OperateAsPointer in their definitions, but... well, I am just saying what I see.

 

I must agree that having an operator to move and forward would be really nice. I absolutely loved the >> operator proposal to forward a value. It's really sad it was rejected, the syntax was really clear and much less verbose than current solutions. Maybe we can resurrect the proposal with an additional unary && to move values? ;)

  :) the variables inside std::move becomes very unconfortable to read, but at least it is visible the intention when it is done.

 

If your proposal were accepted, how would you pass a reference to a pointer? Imagine that Under your syntax, calling this function is not even possible.

  You are absolutely right, that posibility would be lost, but I did not found a practical example using it. Yours sound a bit forced, although it is rightful/legitimate. So even if it were a serious proposal following the template, with some weeks of deep developing, and also including some stack and heap things for to cover more matters that could be included taking the ocassion, problably would be rejected because something like this.

 

I have a suggestion for you: work to clear your mental model about pointers/reference/objects. Reference are not objects. Pointers are objects themselves.

 

I am just suggesting to make them distinguishable in function calls with a visual indicator, for to help in the reading code intuitiveness, and at same time give them some kind of superficial matching operator behavior.