[Boards: 3 / a / aco / adv / an / asp / b / biz / c / cgl / ck / cm / co / d / diy / e / fa / fit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mu / n / news / o / out / p / po / pol / qa / r / r9k / s / s4s / sci / soc / sp / t / tg / toy / trash / trv / tv / u / v / vg / vp / vr / w / wg / wsg / wsr / x / y ] [Home]
4chanarchives logo
Little endian is retarded You write a three-thousand four-hundred
Images are sometimes not shown due to bandwidth/network limitations. Refreshing the page usually helps.

You are currently reading a thread in /g/ - Technology

Thread replies: 45
Thread images: 4
File: Little-Endian.svg.png (104 KB, 2000x1786) Image search: [Google]
Little-Endian.svg.png
104 KB, 2000x1786
Little endian is retarded

You write a three-thousand four-hundred sixty-nine as 3469 not as 6934

Prove me wrong
>>
>>52069732
Most modern architectures support both formats anyway.
>>
>>52069758
That's bad though

Little-endian support leads to dumb people using litte-endian instead of superior big endian
>>
>>52069836
>>52069758
>>52069732
It literally does not matter.
>>
>>52069732
>Binary is retarded
>you write 3469 not 110110001101
>Prove me wrong
>>
Actually numbers the way we write them (3469) is a right-to-left way of writing numbers (i.e. backwards) as we use Arabic numbers. It makes more sense for numbers to go bigger the more they go right, to follow how we write words left-to-right.

As far as computers are concerned, little-endian makes more sense as when working with numbers over many bytes, which are loaded into the processor sequentially, things like addition operations can be started as soon as the first byte of the second operand is available, as you need to start with the least significant bit in order to carry forwards overflow when adding bits from the next byte afterwards.

Big-endian is in fact retarded, since the only reason to use that is because it seems more intuitive to people who are used to using right-to-left Arabic numbers and find it difficult to adapt.
>>
>>52069898
Underrated post.
>>
>>52069898
>2016 - .014
>not using BCDs for accurate base 10 calculations
top pleb
>>
>>52069732
you are wrong with your example
we can write 3469
(3*1000) + (4*100) + (6*10) + (9 * 1) = big endian
(9*1) + (6*10) + (4*100)+(3*1000) = little endian
>>
>>52069732
>representing numbers in hexadecimal
literally why
>>
>>52069925
/thread
>>
>>52070078
get a load of this retard
>>
>>52069732
>big endian vs little endian
Do you also try to shitpost about what it's your favorite color?
>>
>>52069925
No, it makes sense to put the most significant part on the left.
>>
>>52070126
>not easily readable
>not stored like that in memory
>not base 10
It's shit per definition and only used by high level languages that pretend to do direct memory manipulation like node
>>
>>52069925
>It makes more sense for numbers to go bigger the more they go right, to follow how we write words left-to-right.
No it doesn't. Large numbers go first because we say them first, obviously, and before you try to point out that we shouldn't say them first, I'll point out that the larger "place" you know, the more closely you can approximate the number. If you only know that the last number in 3469 is 9 you know essentially nothing about the number, but if you know that the first number is 3, that is informative. Read from largest to smallest place, the number gets more specific as you read it. Read the other way around, the number only has any meaning at all once you've finished reading it.
>>
>>52070153
>node
web-apper monkey spotted
>>
>>52070161
Knowing the number 9 from 3469 is much more useful to have sooner than the most significant digit when adding up numbers.

How people write numbers is just a case of what people are used to. Having a number in little-endian may seem not as useful to people, but that doesn't mean it isn't backwards. If it wasn't backwards, then why do you think number cells in spreadsheets are right-aligned instead of left-aligned like how English text is?
>>
File: 1450405478130.jpg (45 KB, 640x714) Image search: [Google]
1450405478130.jpg
45 KB, 640x714
I just passed a microprocessor class for the semester and I can honestly say I do not feel I learned anything important. I mean sure there's some things I remember like big/little endian, physical address, and very basic mips shit.

is this normal?
>>
>>52070288
I'm not saying that it shouldn't be different for computers and I don't give a fuck about how spreadsheets work.

Write pi as precisely as possible with the smallest place first, as a friend to read it, explaining your theory, and see how long it takes him to figure out what he's reading.

The way that it's done in human language is objectively the best way that human language could do it.
>>
>>52070350
Sounds like you're ready for web-dev
>>
>>52070350
>very basic mips shit

Heh. I remember taking a class that used MIPS. I found a bug in the code in a question on the final.

Having already done quite a bit of x86 programming, the only thing I took away from the class was learning how to multiply numbers using only... what, an OR and a NOT operation? I forget the details, but that was the critical example that put my mind to rest. Before then, I had always wondered, "yeah, but how does it work BELOW this level?" Once I learned how to use logic gates to make a seemingly complex operation, like MUL, that anxiety finally left me.

For most people, I think the most valuable thing they take away from a class like that is how pointers *actually* work. It really doesn't go into enough depth to give you much other useful information -- like how modern Intel architecture gives you process isolation and stuff like that.
>>
>>52070078
Easy to convert to/from binary
>>
>>52070353
Well it might make more sense to people, but that doesn't mean it's objectively the best. Firstly it's inconsistent, which means it isn't perfect, and secondly the endianness which "makes most sense" is different depending on whether there's loads of digits before or after the point, disregarding what people are used to. And of course it depends on what people are using numbers for.
>>
>>52070078

1) Because you can easily pack 0..255 into two characters. It makes for much simpler representation of bytes and nibbles.

2) Because you can easily (with practice) understand which bits are on and off. Honestly, I don't understand this, but every EE I've known can just glance at a hexadecimal number and easily add or remove flags mentally.
>>
File: 1338137153574.jpg (8 KB, 245x245) Image search: [Google]
1338137153574.jpg
8 KB, 245x245
>>52070078
ho boy
>>
>>52070475

Not me, I'm the retard who uses 0b values all over his programs.
>>
>>52070475
>2) Because you can easily (with practice) understand which bits are on and off. Honestly, I don't understand this, but every EE I've known can just glance at a hexadecimal number and easily add or remove flags mentally.

if you decorate all the way from 0-F (every bit), you can easily transform it to/from binary by concatenating the values.

For example, 6C:
6 = 0110
C = 1100
6C = 01101100
>>
>>52070468
>it's inconsistent
No it isn't. Neither way is inconsistent with anything.

It's not about what "makes sense" to people. It's about the effectiveness with which you can transfer information from one mind to another. That's what language is for. If a language is measurably better at that, it's objectively a better language. Biggest-place first is falsifiably a more effective way to communicate some numbers, as demonstrated by my pi example. The same is not true of any numbers and the opposite scheme. Biggest place first allows you to start considering the meaning of a number in a significant way sooner, and therefore to understand its exact meaning faster and more efficiently. It allows someone to get the gist of a number without reading all of it, whether the number is irrational or a four-digit integer, and without having to switch directions and read right-to left. If you're reading a seven digit number, you can know that something is, for example, about six and a half million without switching directions and without reading the whole number. It's true that the difference is less significant for numbers with fewer digits, but most to least significant is still at least a tiny bit better in every case. At the very least, biggest-to-smallest is significantly more effective for some numbers and not significantly different for the rest.

Even for math it's better. If you're adding two five digit numbers, 68573 and 95731, you can add their most significant digits only, consider their length, and get 150000, which is closer to the answer than anything you could get using 3 and 1.

The human mind thinks with a level of precision that varies depending on the task at hand. That makes a system where precision increases with attention more efficient.
>>
>>52071035
No, it is inconsistent. Numbers as we write them normally are right-to-left, which is inconsistent with the left-to-right way of writing we normally write. Numbers as we write them only go the other way if you keep increasing the precision, like what you keep saying with pi.

>Even for math it's better. If you're adding two five digit numbers,
No. Numbers are added starting with the least significant digit, since that's the order in which you carry overflows forwards.
>>
>>52071035
>Even for math it's better
to do that you have to fully read both numbers before the actual operation ,regardless of their endianess
>>
File: Unbenannt.png (34 KB, 401x465) Image search: [Google]
Unbenannt.png
34 KB, 401x465
>>52069732
>tfw we use big and little endian at the same time in german

see screenshot
>>
>>52069732
both formats have their advantages
>>
>>52070916

I have no idea what you're trying to tell me.
>>
>>52069732
Casting a pointer down will preserve the least significant bytes. Basically If I have 255 stored in a uint64, I can cast that to a uint8 and get 255 still.
>>
>>52071393
Counting is cheaper than reading. In fact, for relatively small numbers you have a "number sense" that gives you a feeling of how many things there are without having to consciously count them. If you saw three traffic cones near each other, you'd know there were three things there without having to think "one, two, three" like you would if there were a hundred traffic cones. If you were to count 100 traffic cones, you would probably count them in pairs ("two, four, six, eight"), but you would not have to count the pairs to know that you were looking at two things. For multi-digit numbers people usually do this three digits at a time. When you look at a long number and wonder how long it is, you count groups of three digits. You can do this without having any idea what the corresponding three digit numbers are.

>Numbers as we write them normally are right-to-left
Only if the smallest place should be considered first. For the human mind, considering the smallest place first is inefficient. Adding is possible starting from either end. Take my previous example. Looking at 68573 and 95731. You can immediately know that the answer is 150000 + something. To increase precision, you can do that again:

68573 + 95731 = 15000 + 8573 + 5731 = 150000 + 13000 + 573 + 731 = 163000 + 573 + 731 = 163000 + 1200 + 73 + 31 = etc

If you look at two prices in a store, and ask yourself how much you'll pay if you buy both things, this is what you do. $35.60 + $42.95 is $70-something. If that's acceptable you increase precision, otherwise you forget it. You probably don't bother to add cents. The fact that you usually don't need perfect precision, and that you can tell whether or not precision is important without calculating the most precise answer, is the key factor here.
>>
>>52071728
meant to also quote >>52071379
>>
>>52071728
0 is the origin. 10^0 is the first digit. 10^1 is the second digit, and so on. You can't say that the base^0 column is not the start from which numbers extend outwards. Digits further from the origin go further left in the way we write numbers (except for when you add more precision and go backwards with 10^-1, 10^-2...) therefore numbers as we write them are right-to-left, which is backwards. A lot of the time it makes sense to read numbers backwards, as we do, increasing the precision, but that is going through the powers backwards.
>>
>>52071379
>inconsistent with the left-to-right way of writing we normally write
1234
"one thousand two hundred thirty-four"
>>
>>52070202
>reading comprehension
>>
>>52071873
Yes. One thousand two hundred and thirty four is backwards, since that's based on the way the number is written, which is right-to-left.
>>
>>52069732
>You write a three-thousand four-hundred sixty-nine as 3469 not as 6934
You do read the number as 3469 in little endian because it reverses it so its human readable. If you go left to right start at the small number then the number will read from the smallest at the left which is not how numbers are written for humans.
>>
>>52070916
>do embedded for 6 years
>can do 0->D and F off the top of my head
>have to calculate E literally every single time i can never remember it even if i just worked it out 20 seconds ago.
>>
it doesn't matter in speech/writing, since you can process in either direction by moving your eyes a little
it was literally named after an archetypal meaningless debate
however, it does matter in computers, because of the order in which carry operations run, which make little-endian more efficient
>>
>>52071855
>You can't say that the base^0 column is not the start from which numbers extend outwards.
That's true, but what I'm saying it that the base^4 column is more important to the human mind's process of interpreting the meaning of the number, which makes the common method the linguistically superior one, i.e. the correct one where human language is concerned.
Thread replies: 45
Thread images: 4

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

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.
If a post contains personal/copyrighted/illegal content you can contact me at [email protected] with that post and thread number and it will be removed as soon as possible.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com, send takedown notices to them.
This is a 4chan archive - all of the content originated from them. If you need IP information for a Poster - you need to contact them. This website shows only archived content.