That feels wrong somehow, although I guess "you know what I mean" isn't a good foundation for a technical standard :)

Personally I set KDE to use the SI system (1 kB = 1000 B) for all the file sizes. It's apparently default on Mac OS X as well. It makes little sense to count file size in powers of two to begin with, it just causes confusion, especially when dealing with large files. Though it does make sense for RAM, because its modules come in sizes of powers of two.

And yea, Windows, last time I checked, still incorrectly labels "MB" and such even if it really means "MiB". Though I'm not sure if it was changed in Windows 8 or not. Probably not.

12-08-2012, 10:17 PM

Aleve Sicofante

I need an explanation about zRAM.

If I understand it well, it will use RAM instead of disk for swapping/paging, right?

Swapping happens when the system runs out of RAM and needs more. Then it will save some of the RAM contents on disk, free that RAM portion and use it. OK so far?

So a system with a lot of RAM will never need to swap, or need it very rarely. A system with very little RAM will swap pretty soon. Now, if you use zRAM, you make swapping just happen earlier. How is this good at all? Yes, you're swapping to RAM, but you might as well use that RAM directly and have no need for swapping.

Say you have 1GB of RAM and devote 256MB to zRAM. Now you have 768MB available. When the system needs 900MB, it will use part or your zRAM as its swap area. If you didn't have zRAM, the system would have accessed RAM directly: no need to swap. If the system needs 2GB, it'll swap to disk anyway, since the 256MB of zRAM will be of no use in that case.

Yeah, strictly speaking a gigabyte is 10^^9, not 2^^30, although it gets used both ways. The term "gibibyte" (BInary GIgaBYTE presumably) is being promoted for the 2^^20 definition.

That feels wrong somehow, although I guess "you know what I mean" isn't a good foundation for a technical standard :)

The JEDEC standard defines 1GB as 2**30 bytes.

12-08-2012, 10:51 PM

aceman

Quote:

Originally Posted by Aleve Sicofante

I need an explanation about zRAM.
Say you have 1GB of RAM and devote 256MB to zRAM. Now you have 768MB available. When the system needs 900MB, it will use part or your zRAM as its swap area. If you didn't have zRAM, the system would have accessed RAM directly: no need to swap. If the system needs 2GB, it'll swap to disk anyway, since the 256MB of zRAM will be of no use in that case.

But zRAM is COMPRESSED. So imagine the system can put 512MB of data into that 256MB pool. Suddenly you have like 1,25GB of RAM. Yes, there is a tradeoff. Those 512MB can't be accessed directly by the kernel and the compression/decompression takes some CPU time. However, the theory says that even this is still faster than swapping to physical disk.

12-08-2012, 11:56 PM

bridgman

Quote:

Originally Posted by ryao

The JEDEC standard defines 1GB as 2**30 bytes.

Are you talking about 100B.01 ? If so, doesn't that only cover microprocessors and memory where binary interpretation is the norm ?

Most of the other standards (which need to deal with memory, disk, networking, etc..) seem to be heading towards interpreting GB as decimal and using something like GiB for binary.

Maybe we should use JGB (Jedec GigaByte) or MGB (Memory GigaByte) for binary and GB for decimal ;)